Subject title, larger

Started by Panoulis64, July 13, 2021, 10:24:05 AM

Previous topic - Next topic

Panoulis64

I am looking for a way for the title of the topic to have more text than its default.
Is it possible to do?
And if so, how can I do it?
Thanks for your time.

Ninja ZX-10RR

/Themes/default/Post.template.php
Code (find) Select
// Now show the subject box for this post.
echo '
<dt>
<span', isset($context['post_error']['no_subject']) ? ' class="error"' : '', ' id="caption_subject">', $txt['subject'], ':</span>
</dt>
<dd>
<input type="text" name="subject"', $context['subject'] == '' ? '' : ' value="' . $context['subject'] . '"', ' tabindex="', $context['tabindex']++, '" size="80" maxlength="80" class="input_text" />

The first 80 controls the visual input box size, the second one controls how many characters you can insert, and I assume it's what you want to change :)
Quote from: BeastMode topic=525177.msg3720020#msg3720020
It's so powerful that on this post and even in the two PMs you sent me,you still answered my question very quickly and you're apologizing for the delay. You're the #1 support I've probably ever encountered man, so much respect for that. Thank you, and get better soon.

I'll keep this in my siggy for a while just to remind me that someone appreciated what I did while others didn't.

♥ Jess ♥

STOP EDITING MY PROFILE

Panoulis64

Thank you very much for your prompt reply.
I'm glad that this is done through code and not by choice in the management of the forum, because I would be sorry to bother you unfairly  :D

shadav

you'll also need to change in sources/post.php
// Make sure the subject isn't too long - taking into account special characters.
if ($smcFunc['strlen']($form_subject) > 100)
$form_subject = $smcFunc['substr']($form_subject, 0, 100);

change the 100s to whatever limit you want

may like to read this thread as well, just for some information/warnings
https://www.simplemachines.org/community/index.php?topic=553143.msg4030564#msg4030564
basically don't go crazy...I upped mine to 120, which should be plenty as long as there aren't any special characters in the title.

Panoulis64

Thank you again.
I also put it at 120.

Advertisement: