My first PHP script

I’ve just started teaching myself PHP. So far I’ve grasped the concept of variables and their use with html forms, at least I think I have.
I’ve written my first script. It’s sorta a madlib, well actually it is a madlib. I didn’t pay close attention to the grammatical correctness of the story it outputs and I also need to go back and comment the script( I forgot ) but I’m very pleased with it.
I wrote the entire script myself except for a javascipt I added for appearance.
I’m still learning so I’m sure I’ll be looking back at it and wondering why I used this array or that function instead of other better ones.
If you want to get a good chuckle by viewing a newbies first script or just really like lame madlibs you can see it here.

Source Code:

Story/Output
[code lang=”php”]



$a = $_POST["a"];
$b = $_POST["b"];
$c = $_POST["c"];
$d = $_POST["d"];
$e = $_POST["e"];
$f = $_POST["f"];
$g = $_POST["g"];
$h = $_POST["h"];
$i = $_POST["i"];
$j = $_POST["j"];
$k = $_POST["k"];
?>

Rickie and the

It began one Morning When Rickie woke from a deep sleep and shouted I want a !
She then asked her brothers Nathan , and Alex , if they where craving a
They replied, my , Sissy, Lets go get our snack on.

They put on they’re and grabbed they’re and where off to for a

When they arrived Alex looked at his Big Sissy and Big Bubba and said

Nathan concurred!
Rickie called to take them back home.



[/code]

MadLib Questions
[code lang=”php”]

Food or beverage:
Affectionate Moniker:
Affectionate Moniker:
Exclamation:
Adjective:
Adjective:
Article of Clothing:
Article of Clothing:
Local Eatery:
Silly Phrase:
Fictitious Character:

[/code]


2 Comments so far
Leave a comment

LinksBlogging under the influence?: BUIBlikis Blikis Blikis: So what’s a Bliki?Please with sugar on top: Guest MapMy Gallery My first attempt at a PHP script : PHP NOOb[IMG ][IMG ]

lgvx8100

TrackBack URI

Leave a comment
Line and paragraph breaks automatic, e-mail address never displayed, HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

(required)

(required)




AUTHOR

  • footerWrite up a little something about yourself here. Something short and sweet, or longer if you'd like.

FLICKR

  • add flickr code here, or delete this and use the widget version.

TWEETS

  • add twitter code here, or delete this and use the widget version.