HTML form to php

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

User avatar
koola
Forum Newbie
Posts: 11
Joined: Mon Mar 22, 2004 4:02 am
Location: Leeds, UK

Post by koola »

Oh, I just noticed, the cat is always being outputed as a 1, this is probs why the 'dvd.db.txt' is always selected.

How is it always being outputed as a 1 then?
User avatar
patrikG
DevNet Master
Posts: 4235
Joined: Thu Aug 15, 2002 5:53 am
Location: Sussex, UK

Post by patrikG »

echo fwrite so it reads:

Code: Select all

echo "<h3>bytes written:</h3> ".fwrite($data, $news);
User avatar
patrikG
DevNet Master
Posts: 4235
Joined: Thu Aug 15, 2002 5:53 am
Location: Sussex, UK

Post by patrikG »

Ack, bloody monday mornings. I didn't see that in your if statements you're assigning a value to $cat rather than comparing.

Use == instead of =
User avatar
koola
Forum Newbie
Posts: 11
Joined: Mon Mar 22, 2004 4:02 am
Location: Leeds, UK

Post by koola »

Yay, it works :D

Thank you very much patrikG!
User avatar
patrikG
DevNet Master
Posts: 4235
Joined: Thu Aug 15, 2002 5:53 am
Location: Sussex, UK

Post by patrikG »

<--- needs glasses and a coffee.

Glad it worked.
Post Reply