สอบถามวิธีการทำให้ตั้งหัวข้อ SMF ได้ยาวขึ้น

เริ่มโดย PreciousTar, 24 เมษายน 2015, 18:54:20

หัวข้อก่อนหน้า - หัวข้อถัดไป

0 สมาชิก และ 1 ผู้มาเยือน กำลังดูหัวข้อนี้

PreciousTar

คือตอนนี้ ผมตั้งหัวข้อใน SMF ได้ไม่ยาวเท่าไหร่ครับ ทำยังไงให้มันตั้งได้ยาวขึ้นครับ

ขอบคุณครับ  :'(

romance69

ปกติจะตั้งได้ 80 ตัวอักษรใช่หรือเปล่าครับ ให้ไปแก้ที่ไฟล์ Themes\default\Post.template.php นะครับ
หาโค้ด
<input type="text" name="subject"', $context['subject'] == '' ? '' : ' value="' . $context['subject'] . '"', ' tabindex="', $context['tabindex']++, '" size="80" maxlength="80" class="input_text" />

แก้ตรง maxlength="80" เป็นจำนวนที่ต้องการได้เลยครับ หรือตั้งไป 255 ก็ได้ครับ
ขายปลั๊กอิน Wordpress ตรวจหวยออนไลน์ อัปเดตอัตโนมัติ ราคา 2,500 บาท ใส่โค้ด THAISEO10 รับส่วนลด 10%
รับเขียนเว็บไซต์, รับเขียน Theme wordpress, รับเขียน Plugin wordpress

Alphaone

เปิด ไฟล์  /Sources/Post.php แล้วหาบรรทัดคำสั่ง

   // Make sure the subject isn't too long - taking into account special characters.
   if ($func['strlen']($form_subject) > 100)
      $form_subject = $func['substr']($form_subject, 0, 100);

   // At this point, we want to make sure the subject isn't too long.
   if ($func['strlen']($_POST['subject']) > 100)
      $_POST['subject'] = addslashes($func['substr'](stripslashes($_POST['subject']), 0, 100));

   // Maximum number of characters.
   if ($func['strlen']($_POST['subject']) > 100)
      $_POST['subject'] = addslashes($func['substr'](stripslashes($_POST['subject']), 0, 100));

ลอง เปลี่ยนตัวเลขจาก 100 ให้เพิ่มขึ้นเป็นซัก 300 - 500 แทน

PreciousTar

อ้างถึงจาก: Alphaone ใน 24 เมษายน 2015, 19:43:47
เปิด ไฟล์  /Sources/Post.php แล้วหาบรรทัดคำสั่ง

   // Make sure the subject isn't too long - taking into account special characters.
   if ($func['strlen']($form_subject) > 100)
      $form_subject = $func['substr']($form_subject, 0, 100);

   // At this point, we want to make sure the subject isn't too long.
   if ($func['strlen']($_POST['subject']) > 100)
      $_POST['subject'] = addslashes($func['substr'](stripslashes($_POST['subject']), 0, 100));

   // Maximum number of characters.
   if ($func['strlen']($_POST['subject']) > 100)
      $_POST['subject'] = addslashes($func['substr'](stripslashes($_POST['subject']), 0, 100));

ลอง เปลี่ยนตัวเลขจาก 100 ให้เพิ่มขึ้นเป็นซัก 300 - 500 แทน

อ้างถึงจาก: romance69 ใน 24 เมษายน 2015, 19:14:29
ปกติจะตั้งได้ 80 ตัวอักษรใช่หรือเปล่าครับ ให้ไปแก้ที่ไฟล์ Themes\default\Post.template.php นะครับ
หาโค้ด
<input type="text" name="subject"', $context['subject'] == '' ? '' : ' value="' . $context['subject'] . '"', ' tabindex="', $context['tabindex']++, '" size="80" maxlength="80" class="input_text" />

แก้ตรง maxlength="80" เป็นจำนวนที่ต้องการได้เลยครับ หรือตั้งไป 255 ก็ได้ครับ

ผมแก้ตามท่านทั้ง 2 แล้วนะครับ ทำไมมันยังไม่ได้อะครับ