osCommerce and osCMax shopping cart software forums

Shopping Cart Software

osCommerce with teeth!

 

how to set maxlength on an input field?

This is a discussion on how to set maxlength on an input field? within the osCMax v1.7 Discussion forums, part of the osCMax v1.7 Forums category; I need to restrict the max chars on the street address field of the Create An Account form to 30 ...


Go Back   osCommerce and osCMax shopping cart software forums > osCMax v1.7 Forums > osCMax v1.7 Discussion

Register FAQ Members List Calendar Mark Forums Read


Free community membership! Fast easy FREE membership
Closed Thread

 

LinkBack Thread Tools
  #1  
Old 01-23-2007, 12:07 PM
New Member
 
Join Date: Dec 2006
Posts: 5
Thanks: 0
Thanked 1 Time in 1 Post
Rep Power: 0
shazam-fu is on a distinguished road
Default how to set maxlength on an input field?

I need to restrict the max chars on the street address field of the Create An Account form to 30 chars. I know I could set this in the database but I need to restrict it on the html form. Otherwise the additional chars would just get cut off when the data is inserted and we wouldn't have a complete address. Does anyone know how to do this?

I know if it were a regular html form I would just set maxlength="30" in the input field but since the form is constructed from a class I'm having a hard time tracing back to see what method might be available & how to use it.

Thanks!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #2  
Old 01-23-2007, 12:28 PM
New Member
 
Join Date: Dec 2006
Posts: 5
Thanks: 0
Thanked 1 Time in 1 Post
Rep Power: 0
shazam-fu is on a distinguished road
Default Re: how to set maxlength on an input field?

Hey, I figured it out. Maybe this will help someone else:

tep_draw_input_field('street_address', '', 'maxlength="30"')
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
The Following User Says Thank You to shazam-fu For This Useful Post:
michael_s (01-23-2007)
Closed Thread



Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads

Thread Thread Starter Forum Replies Last Post
Need to add input text field in product attributes bethphilbin osCommerce 2.2 Modification Help 15 08-07-2006 07:48 PM
Attributes, Text Input + Price donm1021 osCommerce 2.2 Discussion 0 08-07-2006 11:58 AM
Input Field Width??? OmarC osCommerce 2.2 Modification Help 3 12-20-2004 10:45 AM
Problem with Input Field type - must restrict chars... Anonymous osCMax v1.7 Discussion 4 02-26-2004 04:43 PM
Positioning order of Customer Input Boxes WebMistress osCommerce 2.2 Modification Help 6 11-10-2003 08:45 PM


All times are GMT -8. The time now is 02:27 AM.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO
Copyright 2008 osCMax