undefined variable

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
lilyatie
Forum Newbie
Posts: 2
Joined: Wed Jul 30, 2003 3:11 am
Contact:

undefined variable

Post by lilyatie »

:(
i new in php...
can u tell me why it appeared thie error when i submit the form :
"Undefined variable: txtnama in D:\Inetpub\wwwroot\guestbook.php on line 16"

txtnama refer to textfield
please help me....
User avatar
twigletmac
Her Royal Site Adminness
Posts: 5371
Joined: Tue Apr 23, 2002 2:21 am
Location: Essex, UK

Post by twigletmac »

Show us your code and we'll be able to give you a better idea of where the problem is, although it's most likely to do with register_globals - read this:
Before Post Read: Concerning Passing Variables in PHP 4.2+

Mac
User avatar
twigletmac
Her Royal Site Adminness
Posts: 5371
Joined: Tue Apr 23, 2002 2:21 am
Location: Essex, UK

Post by twigletmac »

P.S. I've moved this to the PHP forum as it hasn't got anything to do with databases.
lilyatie
Forum Newbie
Posts: 2
Joined: Wed Jul 30, 2003 3:11 am
Contact:

undefined variables

Post by lilyatie »

actually i want insert into database but it appeared the error that i give u before...
so what supposed i do to solved that error problem....
please help me..
User avatar
twigletmac
Her Royal Site Adminness
Posts: 5371
Joined: Tue Apr 23, 2002 2:21 am
Location: Essex, UK

Post by twigletmac »

As I said initially - show us the lines of the code that are causing the error (line 10 - 20 would be a start) and we can help you better.

Mac
Post Reply