Go Back   Webmaster Malaysia Forum » Website Design & Development » Website Programming

Reply
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 19-12-2003, 09:21 AM
mya mya is offline
New kid on the block
 
Join Date: Dec 2003
Location: pg
Posts: 6
Rep Power: 0
mya is on a distinguished road
Unhappy Help Me With My First Php Script !!!!

hi..i really need ur guys help. i'm doing my final year project. i'm using mysql+php+pws on windows98. my first simple script doesnt work out:

<html>
<body>

< ?php echo "Hello World"; ?>

</body>
</html>

Just wondering is there any prob with the php itself or pws. I understand that pws does support php. In fact, php was designed to run as a plug-in for existin web server software. rite? Or do i need a third party to interpret it? pls correct me if i'm wrong..tq..
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 19-12-2003, 09:58 AM
lcf's Avatar
lcf lcf is offline
Pro-Blogger
 
Join Date: Feb 2003
Location: Kluang, Johor
Posts: 2,376
Rep Power: 118
lcf will become famous soon enough
Send a message via ICQ to lcf Send a message via MSN to lcf Send a message via Yahoo to lcf
try: <?php echo "hello world"; ?>

btw, make sure you have properly set up PHP for PWS. Please refer to: http://my.php.net/install.iis
__________________
LiewCF | Malaysia Bloggers Forum

Last edited by lcf; 19-12-2003 at 10:00 AM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 19-12-2003, 10:03 AM
lcf's Avatar
lcf lcf is offline
Pro-Blogger
 
Join Date: Feb 2003
Location: Kluang, Johor
Posts: 2,376
Rep Power: 118
lcf will become famous soon enough
Send a message via ICQ to lcf Send a message via MSN to lcf Send a message via Yahoo to lcf
For easy set up PHP and webserver(Apache), try:
- EasyPHP: http://www.easyphp.org/index.php3?lang=en
- AppServ: http://www.appservnetwork.com/

Both installer will install PHP, Apache, MySQL, phpMyAdmin for you. No headache.
__________________
LiewCF | Malaysia Bloggers Forum
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 19-12-2003, 10:26 AM
mya mya is offline
New kid on the block
 
Join Date: Dec 2003
Location: pg
Posts: 6
Rep Power: 0
mya is on a distinguished road
icf, thanx..i'll try it out..
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 19-12-2003, 02:34 PM
mysticmind's Avatar
Super Moderator
 
Join Date: Jun 2001
Location: Mystic Kingdoms
Posts: 2,687
Rep Power: 145
mysticmind will become famous soon enough mysticmind will become famous soon enough
Send a message via Yahoo to mysticmind
easyphp best best best..
yeah yeah.. download easyphp now! and start coding without any... doubt.
__________________
Personal's Blog! - Malaysian Artist!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6 (permalink)  
Old 19-12-2003, 04:31 PM
mya mya is offline
New kid on the block
 
Join Date: Dec 2003
Location: pg
Posts: 6
Rep Power: 0
mya is on a distinguished road
Question

Quote:
Originally posted by lcf
try: <?php echo "hello world"; ?>

btw, make sure you have properly set up PHP for PWS. Please refer to: http://my.php.net/install.iis
lcf, i've tried <?php[/b] echo "hello world"; ?> still didnt work..
i'm sure that i didnt miss any instruction in the installation manual..

this is what i get while trying to preview a page in a browser:

"Security Alert! The PHP CGI cannot be accessed directly.
This PHP CGI binary was compiled with force-cgi-redirect enabled. This means that a page will only be served up if the REDIRECT_STATUS CGI variable is set, e.g. via an Apache Action directive.
For more information as to why this behaviour exists, see the manual page for CGI security.
For more information about changing this behaviour or re-enabling this webserver, consult the installation file that came with this distribution, or visit the manual page."

i'm sure that i didnt miss any instruction in the installation manual..

i've been figuring out bout this stuff whole week..seems that i couldnt find da solution..i'm reaaallly sick of this

my questions are:
1- what does da statement(which appeared in the browser) really mean?..somebody please explain in a simpler way..u see..im a newbie to php..

2-if i use myql+php+apache..will there be any prob if i were 2 upload it to iis server? i think there might b some problems.that's da reason y i use pws instead of apache..coz da project i'm working on now going to be upload to iis server..

SOMEBODY OUT THERE HELP ME FIND DA SOLUTION PLEAAAASE!!!!
THANX
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #7 (permalink)  
Old 19-12-2003, 05:43 PM
lcf's Avatar
lcf lcf is offline
Pro-Blogger
 
Join Date: Feb 2003
Location: Kluang, Johor
Posts: 2,376
Rep Power: 118
lcf will become famous soon enough
Send a message via ICQ to lcf Send a message via MSN to lcf Send a message via Yahoo to lcf
1. no idea about PHP CGI error.

>>For more information as to why this behaviour exists, see the manual page for CGI security.
For more information about changing this behaviour or re-enabling this webserver, consult the installation file that came with this distribution, or visit the manual page."

have you read the 'more information'?

2. no problem to run the same PHP script on both IIS / Apache, except you use platform specificied PHP functions. The only problem will be the database. If the IIS is not using mysql database, then your PHP script cannot use mysql database, for sure. You may need to install the same database that used on IIS server.
__________________
LiewCF | Malaysia Bloggers Forum
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #8 (permalink)  
Old 19-12-2003, 07:34 PM
Senior Webmaster
 
Join Date: Oct 2001
Location: Melbourne, AU
Posts: 456
Rep Power: 97
sufyan is on a distinguished road
Hi,

1) In your php.ini, edit the line:
cgi.force_redirect = 1
and change it to:
cgi.force_redirect = 0

See if that works. (However I doubt it)

The best 'fix' to your problem is to get Apache+PHP (or one of those pre-assembled packages - easyphp).

2) Ditto what LCF said.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #9 (permalink)  
Old 21-12-2003, 03:27 AM
ardiles's Avatar
Senior Webmaster
 
Join Date: Mar 2003
Location: Kamunting, Perak
Posts: 640
Rep Power: 83
ardiles is on a distinguished road
Send a message via MSN to ardiles Send a message via Yahoo to ardiles
EasyPHP - easy'ing' your PHP
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #10 (permalink)  
Old 23-12-2003, 10:35 AM
mya mya is offline
New kid on the block
 
Join Date: Dec 2003
Location: pg
Posts: 6
Rep Power: 0
mya is on a distinguished road
Quote:
Originally posted by sufyan
Hi,

1) In your php.ini, edit the line:
cgi.force_redirect = 1
and change it to:
cgi.force_redirect = 0 .
sufyan, it doesnt work..thanx anyway...
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #11 (permalink)  
Old 08-01-2004, 08:11 PM
hymns's Avatar
Senior Webmaster
 
Join Date: Nov 2001
Location: Johor
Posts: 769
Rep Power: 101
hymns is on a distinguished road
Send a message via ICQ to hymns Send a message via Yahoo to hymns
lalala pakai server dayak je senang tak yah pening2 kepale
__________________
I hate when:

vBulletin Message:
Sorry! The administrator has specified that users can only post one message every 60 seconds
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #12 (permalink)  
Old 08-01-2004, 10:45 PM
mysticmind's Avatar
Super Moderator
 
Join Date: Jun 2001
Location: Mystic Kingdoms
Posts: 2,687
Rep Power: 145
mysticmind will become famous soon enough mysticmind will become famous soon enough
Send a message via Yahoo to mysticmind
easyphp <-- sesuai untuk semua
__________________
Personal's Blog! - Malaysian Artist!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #13 (permalink)  
Old 09-01-2004, 11:58 AM
white_neck's Avatar
Senior Webmaster
 
Join Date: Jan 2003
Location: dreamland
Posts: 240
Rep Power: 76
white_neck is on a distinguished road
Send a message via Yahoo to white_neck
semua promote easyphp nampak...
dapat komisen ker?...
hahahahhahaha...

__________________
^_^ <== stay happy
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #14 (permalink)  
Old 09-01-2004, 12:06 PM
Ben-davis's Avatar
Senior Webmaster
 
Join Date: Jan 2002
Location: SoObHanG JhaYa
Posts: 501
Rep Power: 94
Ben-davis is on a distinguished road
Send a message via ICQ to Ben-davis Send a message via Yahoo to Ben-davis
Musti la... EasyPHP memang best!!!!... Jadi, disable PWS, Enable EasyPHP!!!!
__________________
<form name="jump">
<select name="menu" onChange="location=document.jump.menu.options[document.jump.menu.selectedIndex].value;" style="border:1px #393F31 solid;color:#393F31;font:10px Verdana;font-weight:bold;" >
<option value="0" style="background: #9CC8FE" selected>*SELECT-LINKS</option>
<option value="http://www.gengturbo.org/" style="background: #FF0000">GENGTURBO</option>
<option value="http://www.phixelgrafix.com/" target="new" style="background: #C6D607">PHIXELGRAFIX</option>
<option value="http://dailydigital.phixelgrafix.com/" style="background: #FCBC45">OLD-BLOG</option>
<option value="http://www.mesrahosting.net/" style="background: #FF99CC">WEBHOSTING</option>
</select>
</form>
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #15 (permalink)  
Old 09-01-2004, 04:34 PM
mysticmind's Avatar
Super Moderator
 
Join Date: Jun 2001
Location: Mystic Kingdoms
Posts: 2,687
Rep Power: 145
mysticmind will become famous soon enough mysticmind will become famous soon enough
Send a message via Yahoo to mysticmind
ntah lah diorang nih..
ada jalan senang.. jalan susah jugak yang diorang nak..
Last Advice. :

Kalau nak belajar mencoding PHP.. install ajelah easyphp
tapi.. kalau nak jadi Admin System atau nak setup webserver..
study laaa LINUX !!! bukan study nak install bebende lain yang susah dan menyusahkan tuh!

go go go!
__________________
Personal's Blog! - Malaysian Artist!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

<
Similar Threads
Thread Thread Starter Forum Replies Last Post
Looking for MLM Php script masrule Website Programming 0 24-01-2007 01:56 PM
Need Help With My Script marukochan Website Programming 1 07-12-2006 04:52 PM
script nurulmajdi Website Programming 12 16-02-2004 04:03 PM
my script can't run..why? therion Website Programming 7