[PHP] mysql field getting cut off

2003-05-30 Thread Larry Brown
If anyone can help I seem to be stuck on a problem getting a mysql field
inserted correctly.  For instance the first page would have a field such
as...

input type=text name=field size=12

info that is placed into the field is St. Petersburg, FL (without the
quotes)

the php code for the statement...

$query = insert into table values( $variable, '$field', $variable2 );

This is where there are 3 fields in the table and the second is the one I
want populated with St. Petersburg, FL.  It ends up with St. (I'm not
sure if the period makes it).  I have verified that the entire statement
arrives at the php script in the variable $field and I have used the mysql
client to give the same command with St. Petersburg, FL as the value and
it accepts it without a problem.

Larry S. Brown
Dimension Networks, Inc.
(727) 723-8388




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] mysql field getting cut off

2003-05-30 Thread John W. Holmes
 If anyone can help I seem to be stuck on a problem getting a mysql
field
 inserted correctly.  For instance the first page would have a field
such
 as...
 
 input type=text name=field size=12
 
 info that is placed into the field is St. Petersburg, FL (without
the
 quotes)
 
 the php code for the statement...
 
 $query = insert into table values( $variable, '$field', $variable2
);
 
 This is where there are 3 fields in the table and the second is the
one
 I
 want populated with St. Petersburg, FL.  It ends up with St. (I'm
not
 sure if the period makes it).  I have verified that the entire
statement
 arrives at the php script in the variable $field and I have used the
mysql
 client to give the same command with St. Petersburg, FL as the value
and
 it accepts it without a problem.

When you run a SELECT from the command line, do you only see St. in
the column? What kind of column is it?

Are you sure it's not fine in the database and you're just showing it
like:

input type=text value=$value name=field

which will end up like

input type=text value=St. Petersburg, FL name=field

and will only show St. in the text box...

---John W. Holmes...

Amazon Wishlist: http://www.amazon.com/o/registry/3BEXC84AB3A5E

PHP Architect - A monthly magazine for PHP Professionals. Get your copy
today. http://www.phparch.com/



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] mysql field getting cut off

2003-05-30 Thread Larry Brown
That, indirectly, is exactly what happened.  I have a subsequent screen for
modifying the results.  I must have gone back into that screen to change
something else and since it only pulled the St. when I applied it it changed
the field in the database.  Thanks a lot.  It seemed weird.

Larry S. Brown
Dimension Networks, Inc.
(727) 723-8388

-Original Message-
From: John W. Holmes [mailto:[EMAIL PROTECTED]
Sent: Thursday, May 29, 2003 9:44 PM
To: 'Larry Brown'; 'PHP List'
Subject: RE: [PHP] mysql field getting cut off

 If anyone can help I seem to be stuck on a problem getting a mysql
field
 inserted correctly.  For instance the first page would have a field
such
 as...

 input type=text name=field size=12

 info that is placed into the field is St. Petersburg, FL (without
the
 quotes)

 the php code for the statement...

 $query = insert into table values( $variable, '$field', $variable2
);

 This is where there are 3 fields in the table and the second is the
one
 I
 want populated with St. Petersburg, FL.  It ends up with St. (I'm
not
 sure if the period makes it).  I have verified that the entire
statement
 arrives at the php script in the variable $field and I have used the
mysql
 client to give the same command with St. Petersburg, FL as the value
and
 it accepts it without a problem.

When you run a SELECT from the command line, do you only see St. in
the column? What kind of column is it?

Are you sure it's not fine in the database and you're just showing it
like:

input type=text value=$value name=field

which will end up like

input type=text value=St. Petersburg, FL name=field

and will only show St. in the text box...

---John W. Holmes...

Amazon Wishlist: http://www.amazon.com/o/registry/3BEXC84AB3A5E

PHP Architect - A monthly magazine for PHP Professionals. Get your copy
today. http://www.phparch.com/



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php