Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 2 of 2
  1. #1
    Junior Member
    Join Date
    Sep 2008
    Posts
    7
    Member #
    17438
    OK, so Running into a problem, I have a page that has a couple boxes that need different amounts of text limited in them, 2 of the boxes are text input fields, and the third is a text area.
    I can get it to limit fine if I use the input as opposed to the text area, which is ok, for 2 of the 3, and the reason those 2 are working.
    www.girl360.net/registration.php Here is the actual page,
    the "favorite quote" at the bottom og the left panel is supposed to limit to 125 characters and is working fine
    the "one piece of advice" near the top of the right panel is supposed to limit 250 characters and is working fine
    The box below that (needs to be a box at that size, per graphic designer's orders) is supposed to limit to 1000 character, but it is a textarea not an input="text" like the others, the limiting works if I change it, however it doesn't work as is, any tweaks to the code I can do to get it to work and be the appropriate size?
    I will admit, I found the Javascripting and code for the boxes here http://www.mediacollege.com/internet...haracters.html and tweaked them to fit my needs, but their code for the text area doesn't work like I need it to, and I don't want the countdown boxes below anything.
    OK, so here is the code for the entire page, attached rather than pasted as requested by the forum. Any help would be appreciated!!

  2.  

  3. #2
    Senior Member Seldimi's Avatar
    Join Date
    Dec 2002
    Location
    Kozani, Greece
    Posts
    488
    Member #
    409
    You dont need 3 incoming variables on your script... you just need
    HTML Code:
    <script language="javascript" type="text/javascript">
    function limitText(limitField, limitNum) {
    	if (limitField.value.length > limitNum) {
    		limitField.value = limitField.value.substring(0, limitNum);
    	} 
    }
    </script>
    Using firebug this.form.countdown was undefined So use this function and I hope we will get it work
    - Webmaster's Planet . Greek Vortal For Webmasters ...
    - MyPortFolio - View My Creations


Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 05:55 AM.
Powered by vBulletin® Version 4.2.3
Copyright © 2019 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com