cant get php scripts to run on my web pages

 
Post new topic   Reply to topic    Aprelium Forum Index -> PHP
View previous topic :: View next topic  
Author Message
crazymazey
-


Joined: 22 Sep 2003
Posts: 35

PostPosted: Thu Oct 02, 2003 9:37 am    Post subject: cant get php scripts to run on my web pages Reply with quote

i'm fairly new to php and abyss.
i know its probably something simple.
i,ve installed php to the word using the help in abyss.
but whenever i add a script in the webpage using
<?PHP include ("name of php script.php"); ?>
nothing happens i'm not sure if thats right and i'm not sure were i should put the php script.

please help as this is frustrating

i,ve got everything else working ok
including

myphpadmin
phpbb2
php advanced guestbook
nukephp

but cant seem to get this simple thing top work
_________________
Back to top View user's profile Send private message Send e-mail Visit poster's website
aprelium
-


Joined: 22 Mar 2002
Posts: 6800

PostPosted: Sat Oct 04, 2003 1:15 pm    Post subject: Re: cant get php scripts to run on my web pages Reply with quote

Test that PHP works fine by using the script:

Code:

<?php
     phpinfo();
?>


If this script works, check your other code for possible paths issue. Otherwise, give us more information about your issue.
_________________
Support Team
Aprelium - http://www.aprelium.com
Back to top View user's profile Send private message Send e-mail
Kent
-


Joined: 12 Jan 2003
Posts: 137

PostPosted: Sun Oct 05, 2003 8:56 am    Post subject: Reply with quote

try <?PHP include ('name of php script.php'); ?> instead of <?PHP include ("name of php script.php"); ?> also remember that if the page your calling is not in the same dir as the page you want to embed this php page into you need to put the entire http://yoururl.com/pagefolder/whatever in the include statement... most windows installs of php make the include statement dig into the php/include/ folder rather than your web server folders.... hope this helps out a little. :roll:
Back to top View user's profile Send private message
crazymazey
-


Joined: 22 Sep 2003
Posts: 35

PostPosted: Sun Oct 05, 2003 12:05 pm    Post subject: Reply with quote

i'm just testing with this simple script ip.php
as you can see if you visit http://crazymazey.kicks-ass.org/ip.php
the script works.i've put the ip.php script in the htdocs folder in the abyss directory. and i've tried to embed the following scripts into a webpage index.html to test it

<?PHP include ("http://crazymazey.kicks-ass.org/ip.php"); ?>

<?PHP include ('http://crazymazey.kicks-ass.org/ip.php'); ?>

<?PHP include ('ip.php'); ?>

<?PHP include ("ip.php"); ?>

but none seem to work.
i'm using frontpage.

i also did the script info.php
http://crazymazey.kicks-ass.org/info.php

and this works

i know this is something simple that i am missing but i'm lost.
_________________
Back to top View user's profile Send private message Send e-mail Visit poster's website
aprelium
-


Joined: 22 Mar 2002
Posts: 6800

PostPosted: Tue Oct 07, 2003 12:10 am    Post subject: Reply with quote

If you embed some PHP code in a .html file, nothing will happen. The .html file is never processed by the PHP interpreter, it is directly sent to browser.

You should rename your index.html to be index.php in order to have the PHP commands processed.
_________________
Support Team
Aprelium - http://www.aprelium.com
Back to top View user's profile Send private message Send e-mail
crazymazey
-


Joined: 22 Sep 2003
Posts: 35

PostPosted: Tue Oct 07, 2003 11:52 am    Post subject: THANKS Reply with quote

:? i knew it was something simple
and it was

cheers guys
i dont know what i'd do without you
_________________
Back to top View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    Aprelium Forum Index -> PHP All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB phpBB Group