Old 06-11-2004   #1 (permalink)
Joe
Registered User
 
Joe's Avatar
 
Join Date: May 2004
Location: Warrington, UK
Posts: 187

PHP... Help Needed!

Ok, so I finally got a PHP supporting host, now I want to install a news script but I cant becuase PHP is to much for my little brain...

Basically I upload the files, change the config.php and CHMOD settings like it says but when I want to include it in my page, I cant, I want to include it on my Index.html page but I needs to be Index.php to have the news script on, if that made any sense how do I make this work?



Probibly a simple answer but I cant do it!

Thanks,
Joe.
__________________
I prefer pizza over sex, only because I can get pizza.

Last edited by Joe; 06-11-2004 at 02:35 PM..
Joe is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Old 06-11-2004   #2 (permalink)
Registered User
 
Join Date: Jun 2004
Posts: 90

Try renaming your index.htm file to index.php. You may have to set your default page to then be index.php, but, chances are your host has multiple defaults set up, and the .php one is already supported.

If the file is named .htm, the server won't know to look for any special php code. If renaming doesn't work, you'll have to show us the code you are using to insert the script into your page.
jonbalza is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Old 06-11-2004   #3 (permalink)
Joe
Registered User
 
Joe's Avatar
 
Join Date: May 2004
Location: Warrington, UK
Posts: 187

Already tried renaming and it didnt work

Heres the code It says place on my page...

<?PHP
$static = TRUE;
include("cutenews/show_news.php");
?>


Joe.
__________________
I prefer pizza over sex, only because I can get pizza.

Last edited by Joe; 06-11-2004 at 05:29 PM..
Joe is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Old 06-11-2004   #4 (permalink)
Registered User
 
Join Date: Jun 2004
Posts: 90

Are you getting any errors on the page that is calling that include? or does it just not show up at all?
jonbalza is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Old 06-11-2004   #5 (permalink)
Joe
Registered User
 
Joe's Avatar
 
Join Date: May 2004
Location: Warrington, UK
Posts: 187

No errors on the page, its just blank. (apart from the interface images)

Joe.
__________________
I prefer pizza over sex, only because I can get pizza.
Joe is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Old 06-11-2004   #6 (permalink)
Registered User
 
Join Date: Jun 2004
Posts: 90

Then that's going to make troubleshooting kind of hard. It could be any one of a billion things. Here's a short list to check:

Are you sure you CHMOD-ed ALL the files in the cutenews directory to 777?
Are you sure that's the correct file you are trying to include?
Did you try it without the $static = TRUE line?
Are there any news items to show?
Did you upload everything to the server?
jonbalza is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Old 06-11-2004   #7 (permalink)
Joe
Registered User
 
Joe's Avatar
 
Join Date: May 2004
Location: Warrington, UK
Posts: 187

Quote:
Originally Posted by jonbalza
Are you sure you CHMOD-ed ALL the files in the cutenews directory to 777?
Only the ones it told me to.

Quote:
Originally Posted by jonbalza
Are you sure that's the correct file you are trying to include?
Yes, thats the code it tells you to put.

Quote:
Originally Posted by jonbalza
Did you try it without the $static = TRUE line?
Yep.

Quote:
Originally Posted by jonbalza
Are there any news items to show?
Yes.

Quote:
Originally Posted by jonbalza
Did you upload everything to the server?
Yes.

Wonder why it is not working...

Joe.
__________________
I prefer pizza over sex, only because I can get pizza.
Joe is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Old 06-11-2004   #8 (permalink)
Registered User
 
Join Date: Jun 2004
Posts: 90

Without seeing ALL of your code, I'm pretty much stumped then. Anyone else?
jonbalza is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Old 06-11-2004   #9 (permalink)
Joe
Registered User
 
Joe's Avatar
 
Join Date: May 2004
Location: Warrington, UK
Posts: 187

All of the code for the Index.html page or for the whole of cutenews?

Joe.
__________________
I prefer pizza over sex, only because I can get pizza.
Joe is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Old 06-11-2004   #10 (permalink)
Sheep Worrier
 
Man1c M0g's Avatar
 
Join Date: Sep 2003
Location: Portsmouth, UK.
Posts: 4,105
Blog Entries: 14

Send a message via ICQ to Man1c M0g Send a message via MSN to Man1c M0g Send a message via Skype™ to Man1c M0g
Hmmmmm. Its just a hunch, but try replacing your code in index.php with the following:

Code:
<?PHP
$static = TRUE;
include("http://yourdomain.com/cutenews/show_news.php");
?>
__________________
Man1c M0g is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Old 06-11-2004   #11 (permalink)
Joe
Registered User
 
Joe's Avatar
 
Join Date: May 2004
Location: Warrington, UK
Posts: 187

Will try that but looking at the readme file it says that that is the wrong way to do it, guess I'll look for another news script install that and see if it works.

How do I create a .PHP file, everytime I save my index.html file as a .PHP file in Dreamweaver then upload it, it dosent work.

Joe.
__________________
I prefer pizza over sex, only because I can get pizza.
Joe is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Old 06-11-2004   #12 (permalink)
Lazarus' Child
 
malboroman's Avatar
 
Join Date: Nov 2003
Location: The Netherlands
Posts: 603

Send a message via MSN to malboroman Send a message via Skype™ to malboroman
WHen you upload your index.php, have you also removed your index.html??? If the browser sees two standard pages it might go AWOL...

If you want to use an include it definetly needs to be renamed to index.php.. You can't use PHP in a html file...
__________________


"Only the dead have seen the end of war."

- Plato
malboroman is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Old 06-11-2004   #13 (permalink)
Joe
Registered User
 
Joe's Avatar
 
Join Date: May 2004
Location: Warrington, UK
Posts: 187

Finally I got it working...

And like I said it was something so simple, I was making the wrong page into a .PHP file!

Anyway now that I have done that I just have to stop the horizontal scroll bar in the IFRAME, any ideas?

Thanks for the help everyone!

Joe.
__________________
I prefer pizza over sex, only because I can get pizza.
Joe is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Old 06-11-2004   #14 (permalink)
Registered User
 
Join Date: Jun 2004
Posts: 90

So my very first post was right? Sweet! I thought I was going crazy.

As the the scroll bar, set the table width inside the iFrame to 388, not 408. That should get rid of the scroll bar.
jonbalza is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Old 06-11-2004   #15 (permalink)
Joe
Registered User
 
Joe's Avatar
 
Join Date: May 2004
Location: Warrington, UK
Posts: 187

Yep your first post was right I was just to stupid to notice

Fixed the scrollbar now aswell via the cutenews admin panel settings, Thanks for all your help everyone!

Joe.
__________________
I prefer pizza over sex, only because I can get pizza.
Joe is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Closed Thread

Thread Tools
Display Modes

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
Forum Jump


All times are GMT +1. The time now is 05:57 PM.
Content Relevant URLs by vBSEO 3.2.0

Design & Content © BioRUST 2008 :: PRIVACY STATEMENT :: LEGAL INFORMATION :: ADVERTISING MEDIA KIT