1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.2 How to change character limit for thread titles?

Discussion in 'XenForo Questions and Support' started by a.tushkanov, Jul 10, 2013.

  1. a.tushkanov

    a.tushkanov Active Member

    Unlike this and this questions about how to change thread title length, i need to reduced it to 70/75 characters.
    How can i do this with no problems in HTML or while editing thread titles?
    Thank you.
     
  2. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    It should be sufficient to change the maxlength of the form field:

    Admin CP -> Appearance -> Templates -> thread_create

    In red:

    Code:
    		<dl class="ctrlUnit fullWidth surplusLabel">
    			<dt><label for="ctrl_title_thread_create">{xen:phrase title}:</label></dt>
    			<dd><input type="text" name="title" class="textCtrl titleCtrl" id="ctrl_title_thread_create" maxlength="100" autofocus="true"
    				placeholder="{xen:phrase thread_title}..."
    				data-liveTitleTemplate="{xen:phrase create_thread}: <em>%s</em>" /></dd>
    		</dl>
    
     
    a.tushkanov likes this.
  3. a.tushkanov

    a.tushkanov Active Member

  4. Jeremy

    Jeremy XenForo Moderator Staff Member

    You will need to edit the database and DataWriter to allow for 300 characters.
     
  5. Nusaint

    Nusaint Member

    Hello,

    Sorry to dig up an old thread but this is the closest I could find to my question. What if I want to increase the minimum lenght. I am getting people starting threads with one words and I want to change it.

    Thanks in advance
     
  6. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    You should probably have a proper addon for this so you can extend the datawriter, do word checking, and give appropriate error messages to the user. You can post a request here:

    https://xenforo.com/community/forums/resource-and-add-on-requests.68/
     
  7. pankaj2345

    pankaj2345 Member

    After making changes in "library/XenForo/DataWriter/Node.php" and "Admin CP -> Appearance -> Templates -> thread_create" with the same value I am still getting error as "please enter a value using 100 characters or fewer after increasing title". Can you tell me why I am getting this error even after making changes in both.

    error.jpg

    (Seeking for reply on urgent bases)
     

Share This Page