Register Register Member Login Member Login Member Login Forgot Password ??
PHP , ASP , ASP.NET, VB.NET, C#, Java , jQuery , Android , iOS , Windows Phone
 

Registered : 109,027

HOME > PHP > PHP Forum > LIMIT TEXT <!-- TWO STEPS TO INSTALL LIMIT TEXTAREA: 1. Copy the coding into the HEAD of y



 

LIMIT TEXT <!-- TWO STEPS TO INSTALL LIMIT TEXTAREA: 1. Copy the coding into the HEAD of y

 



Topic : 020277



โพสกระทู้ ( 1,008 )
บทความ ( 0 )



สถานะออฟไลน์
Twitter Facebook




<!-- TWO STEPS TO INSTALL LIMIT TEXTAREA:

1. Copy the coding into the HEAD of your HTML document
2. Add the last code into the BODY of your HTML document -->

<!-- STEP ONE: Paste this code into the HEAD of your HTML document -->

<HEAD>

<SCRIPT LANGUAGE="JavaScript">
<!-- Original: Ronnie T. Moore -->
<!-- Web Site: Free Script And Source Code For Webmaster ,ASP,HTML,VB,Java, Java Script, Dhtml,xml,ajax,programming -->

<!-- Dynamic 'fix' by: Nannette Thacker -->
<!-- Web Site: http://www.shiningstar.net -->

<! >
<! >

<!-- Begin
function textCounter(field, countfield, maxlimit) {
if (field.value.length > maxlimit) // if too long...trim it!
field.value = field.value.substring(0, maxlimit);
// otherwise, update 'characters left' counter
else
countfield.value = maxlimit - field.value.length;
}
// End -->
</script>
</HEAD>

<!-- STEP TWO: Copy this code into the BODY of your HTML document -->

<BODY>

<!-- textCounter() parameters are: text field, the count field, max length -->

<center>
<form name=myform action="YOUR-SCRIPT.CGI">
<font size="1" face="arial, helvetica, sans-serif"> ( You may enter up to 125 characters. )<br>
<textarea name=message wrap=physical cols=28 rows=4 onKeyDown="textCounter(this.form.message,this.form.remLen,125);" onKeyUp="textCounter(this.form.message,this.form.remLen,125);"></textarea>
<br>
<input readonly type=text name=remLen size=3 maxlength=3 value="125"> characters left</font>
</form>
</center>

<p><center>
<font face="arial, helvetica" SIZE="-2">Free JavaScripts provided<br>
by <a href="http://javascriptsource.com">Free Script And Source Code For Webmaster ,ASP,HTML,VB,Java, Java Script, Dhtml,xml,ajax,programming</a></font>
</center><p>

<!-- Script Size: 1.37 KB -->


Tag : - - - -







Move To Hilight (Stock) 
Send To Friend.Bookmark.
Date : 2 มิ.ย. 2551 00:28:18 By : arsachi View : 1751 Reply : 1
 

 

No. 1



โพสกระทู้ ( 1,008 )
บทความ ( 0 )



สถานะออฟไลน์
Twitter Facebook


<!-- TWO STEPS TO INSTALL LIMIT BOXES:

1. Copy the coding into the HEAD of your HTML document
2. Add the last code into the BODY of your HTML document -->

<!-- STEP ONE: Paste this code into the HEAD of your HTML document -->

<HEAD>

<SCRIPT LANGUAGE="JavaScript">
<!-- Original: Glenn Wang ([email protected]) -->
<!-- Web Site: http://capsule.bayside.net/ -->

<!-- Modified by Ronnie T. Moore (Free Script And Source Code For Webmaster ,ASP,HTML,VB,Java, Java Script, Dhtml,xml,ajax,programming) -->

<! >
<! >

<!-- Begin
function countChoices(obj) {
max = 2; // max. number allowed at a time

box1 = obj.form.box1.checked; // your checkboxes here
box2 = obj.form.box2.checked;
box3 = obj.form.box3.checked; // add more if necessary

count = (box1 ? 1 : 0) + (box2 ? 1 : 0) + (box3 ? 1 : 0);
// If you have more checkboxes on your form
// add more (box_ ? 1 : 0) 's separated by '+'

if (count > max) {
alert("Oops! You can only choose up to " + max + " choices! \nUncheck an option if you want to pick another.");
obj.checked = false;
}
}
// End -->
</script>
</HEAD>

<!-- STEP TWO: Copy this code into the BODY of your HTML document -->

<BODY>

<center>
<form>
Please choose up to 2 sections:
<p>
<input type=checkbox name=box1 onClick="countChoices(this)">Section 1
<p>
<input type=checkbox name=box2 onClick="countChoices(this)">Section 2
<p>
<input type=checkbox name=box3 onClick="countChoices(this)">Section 3
<p>
</form>
</center>



<!-- Script Size: 1.55 KB -->






Date : 2 มิ.ย. 2551 00:30:42 By : arsachi
 

   

ค้นหาข้อมูล


   
 

แสดงความคิดเห็น
Re : LIMIT TEXT &lt;!-- TWO STEPS TO INSTALL LIMIT TEXTAREA: 1. Copy the coding into the HEAD of y
 
 
รายละเอียด
 
ตัวหนา ตัวเอียง ตัวขีดเส้นใต้ ตัวมีขีดกลาง| ตัวเรืองแสง ตัวมีเงา ตัวอักษรวิ่ง| จัดย่อหน้าอิสระ จัดย่อหน้าชิดซ้าย จัดย่อหน้ากึ่งกลาง จัดย่อหน้าชิดขวา| เส้นขวาง| ขนาดตัวอักษร แบบตัวอักษร
ใส่แฟลช ใส่รูป ใส่ไฮเปอร์ลิ้งค์ ใส่อีเมล์ ใส่ลิ้งค์ FTP| ใส่แถวของตาราง ใส่คอลัมน์ตาราง| ตัวยก ตัวห้อย ตัวพิมพ์ดีด| ใส่โค้ด ใส่การอ้างถึงคำพูด| ใส่ลีสต์
smiley for :lol: smiley for :ken: smiley for :D smiley for :) smiley for ;) smiley for :eek: smiley for :geek: smiley for :roll: smiley for :erm: smiley for :cool: smiley for :blank: smiley for :idea: smiley for :ehh: smiley for :aargh: smiley for :evil:
Insert PHP Code
Insert ASP Code
Insert VB.NET Code Insert C#.NET Code Insert JavaScript Code Insert C#.NET Code
Insert Java Code
Insert Android Code
Insert Objective-C Code
Insert XML Code
Insert SQL Code
Insert Code
เพื่อความเรียบร้อยของข้อความ ควรจัดรูปแบบให้พอดีกับขนาดของหน้าจอ เพื่อง่ายต่อการอ่านและสบายตา และตรวจสอบภาษาไทยให้ถูกต้อง

อัพโหลดแทรกรูปภาพ

Notice

เพื่อความปลอดภัยของเว็บบอร์ด ไม่อนุญาติให้แทรก แท็ก [img]....[/img] โดยการอัพโหลดไฟล์รูปจากที่อื่น เช่นเว็บไซต์ ฟรีอัพโหลดต่าง ๆ
อัพโหลดแทรกรูปภาพ ให้ใช้บริการอัพโหลดไฟล์ของไทยครีเอท และตัดรูปภาพให้พอดีกับสกรีน เพื่อความโหลดเร็วและไฟล์ไม่ถูกลบทิ้ง

   
  เพื่อความปลอดภัยและการตรวจสอบ กระทู้ที่แทรกไฟล์อัพโหลดไฟล์จากที่อื่น อาจจะถูกลบทิ้ง
 
โดย
อีเมล์
บวกค่าให้ถูก
<= ตัวเลขฮินดูอารบิก เช่น 123 (หรือล็อกอินเข้าระบบสมาชิกเพื่อไม่ต้องกรอก)







Exchange: นำเข้าสินค้าจากจีน, Taobao, เฟอร์นิเจอร์, ของพรีเมี่ยม, ร่ม, ปากกา, power bank, แฟลชไดร์ฟ, กระบอกน้ำ

Load balance : Server 00
ThaiCreate.Com Logo
© www.ThaiCreate.Com. 2003-2024 All Rights Reserved.
ไทยครีเอทบริการ จัดทำดูแลแก้ไข Web Application ทุกรูปแบบ (PHP, .Net Application, VB.Net, C#)
[Conditions Privacy Statement] ติดต่อโฆษณา 081-987-6107 อัตราราคา คลิกที่นี่