i wrote my first php script today

He has: 388 posts

Joined: Apr 2005

Yes iwrote my first php script today here it is
Here it is

He has: 1,758 posts

Joined: Jul 2002

Daft question but what does it do?

The first php script I ever wrote went something like this:

<?php echo("hello world"); ?>' Smiling

Regarding how you put html in php... (your question on your page). It's easy! Simply close the php script and enter normal html! you can do this as much as you like! like this:

<?php

$title
= "amazing php script";
$description = "la la la la la la la la la";

?>


<h1>My title is <?php echo("$title"); ?></h1>
<p>heres a description <?php echo("$description"); ?></p>
'

Andy

He has: 388 posts

Joined: Apr 2005

It dosn't do anything Its just there

They have: 52 posts

Joined: Dec 2002

Very cool, and congratulations! Smiling
I actually saved a few exercises I did from a book a long time ago.
Take a Look

He has: 1,758 posts

Joined: Jul 2002

it doesn't do anything? How can it not do anything? Surely it at least echo's out some html or accesses a variable or something?

He has: 388 posts

Joined: Apr 2005

O sorry i mean its not useful but it echos text

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.