You are here: Re: script help « PHP Programming Language « IT news, forums, messages
Re: script help

Posted by Anonymous on 09/15/06 19:51

hoozdiss wrote:
>
> i installed apache 2.2 on winxp with php5. when i write a piece of
> html and include a php or java script in the html i have no problem.
> when i file the script and use something like
> <script src="script.php"></script>
> i get nothing. he finds the file - if i rename it - he complains.
> i'm guessing a config param. please help.

You made two substantial mistakes.

1) If you use the HTML <script> tag you must tell the user agent which
language it is written in.

e.g. <SCRIPT type="text/vbscript"
src="http://someplace.com/progs/vbcalc">

2) The <script> tag is for client side scripting only! The server should
just pass the script to the user agent which should execute it.


If you want to include PHP scripts from a file use

<?php
include("/path/script.php");
?>

Bye!

 

Navigation:

[Reply to this 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

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