Zen Cart Logo
Forums / Bug Reports / [SERVER ISSUE] Problem with maxlength 0 in all text forms

[SERVER ISSUE] Problem with maxlength 0 in all text forms

Locked

Views: 2,255

Results 1 to 3 of 3
This thread is locked. New replies are disabled.
18 Dec 2006, 5:44 PM
#1
method3 avatar

method3

New Zenner

Join Date:
Dec 2006
Posts:
2
Plugin Contributions:
0

[SERVER ISSUE] Problem with maxlength 0 in all text forms

Hello all, I've got a problem that is somewhat urgent D:
I've not had too much experience with zen cart yet, but having been forced to move a site with zen cart over to another server I've been learning pretty quick. I noticed the same problem I've been having is posted here, but alas I have not found a solution.

The problem in a bit more detail is that none of the text fields in the various forms throughout the site have a correct maxlength attribute. For instance:

<input name="email_address" size="1" maxlength="0" type="text">

I am using:
Zen Cart 1.2.6
Database Patch Level: 1.2.6
PHP Version 5.0.4
** HTTP Server: ** Apache/2.0.51 (Fedora)
** Database: ** MySQL 4.1.21
** Server OS: ** Linux 2.6.10-1.771_FC2smp
Our server is also running Fedora Core 2... sigh... I know... :yuck:

with:
This program makes use of the Zend Scripting Language Engine:
Zend Engine v2.0.4-dev, Copyright (c) 1998-2004 Zend Technologies
with Zend Extension Manager v1.0.10, Copyright (c) 2003-2006, by Zend Technologies
with Zend Optimizer v3.0.1, Copyright (c) 1998-2006, by Zend Technologies

Does someone have any more experience with this problem? Tried searching for other solutions... haven't found one yet.

18 Dec 2006, 6:55 PM
#2
method3 avatar

method3

New Zenner

Join Date:
Dec 2006
Posts:
2
Plugin Contributions:
0

Re: [SERVER ISSUE] Problem with maxlength 0 in all text forms

Well, in any case we've found a solution (temporarily?) for this issue. Doing a disgusting hack on the form functions in includes/functions/html_output.php and admin/includes/functions/html_output.php to have an additional over-riding maxlength property.

If anyone could post where this bugged maxlength = 0 property is actually coming from it would be helpful, thanks!

18 Dec 2006, 8:08 PM
#3
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: [SERVER ISSUE] Problem with maxlength 0 in all text forms

method3:

If anyone could post where this bugged maxlength = 0 property is actually coming from it would be helpful, thanks!

It's coming from your database server.

Zen Cart asks the database what the field length is, and uses that information.
If your MySQL is configured to not disclose that information, then 0 is the returned value.
If your MySQL connector for PHP (the software on the server that lets PHP and MySQL talk to each other) is an older version or mismatched version, then this problem typically occurs.