Reply to A Simple PHP Question, I'm sure

Your name:

Reply:


Posted by Kees Boer on 06/08/05 01:06

Hi, I had a question, which I'm sure is fairly simple, but for some reason,
I can't seem to be able to find the answer on line.

I'm trying to create webpages that are all very similar, just with some
variable content. I can do it in Java script, but then Internet Explorer 6.0
will block it for most side, so I tried to do it in PHP, but I'm getting
errors.

This is the code in JavaScript, which works:

<html>
<head>
<title>Untitled Document</title>

<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body bgcolor="#FFFFFF" text="#000000">

<script language="JavaScript">
var greeting = "Hello There!!!"

document.write("I am saying " + greeting)

</script>

</body>
</html>

Now I'm trying to run it in PHP.

This is what I came up with but it has errors:

<html>
<head>
<title>Untitled Document</title>

<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body bgcolor="#FFFFFF" text="#000000">

<script language="php">
var greeting = "Hello There!!!"

document.write("I am saying " + greeting)

echo greeting

</script>


</body>
</html>

I've been searching on line for some tutorial or something to teach me the
syntax, but I can't seem to find it. What did I do wrong?

Thank you!

Kees

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация