Just saying thanks.
Date: 07/18/06
(PHP Community) Keywords: php
I just want to thank you guys for those tips.
What I did instead of search for sites that gave me line-by-line explanations, I figured out what I wanted to do and found the appropriate commands and related tutorials and did them.
So, I owe the creation of this homemade guestbook made from scratch to you guys.
I am now much more interested in PHP now that I have an alternate learning method!
I'll probably post here if I have any major problems.
Actually, I DO have a problem now!
Files are Pastebin'd here:
I'm trying to make Sex work, here. Everything else works flawless.
Here's what I have set up:
Two radio buttons, both with the name 'sex.'
The Male button has the value 'Male' and the Female, 'Female.'
On the register.php you'll see the following:
$sex = $_GET["sex"];
if ($sex = 'Male') {
$s = 1;
}
if ($sex = 'Female') {
$s = 2;
}
Which should, logically, work.
So what's the problem?
Oh, in index.php I have this:
if ($row['sex'] = 1) {
$sex = 'Male';
}
if ($row['sex'] = 2) {
$sex = 'Female';
}
What the hell was I doing? Nevermind, haha. Wow, I'm stupid.
Source: http://community.livejournal.com/php/471617.html