The first php script I ever wrote went something like this:
<?php echo("hello world"); ?>'
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>
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.
andy206uk posted this at 20:44 — 14th May 2005.
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"); ?>
'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
baldrick posted this at 20:59 — 14th May 2005.
He has: 388 posts
Joined: Apr 2005
It dosn't do anything Its just there
dvduval posted this at 22:58 — 14th May 2005.
They have: 52 posts
Joined: Dec 2002
Very cool, and congratulations!
I actually saved a few exercises I did from a book a long time ago.
Take a Look
andy206uk posted this at 19:24 — 15th May 2005.
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?
baldrick posted this at 19:34 — 15th May 2005.
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.