Old 30-03-2007, 07:05   1 links from elsewhere to this Post. Click to view. #1 (permalink)
karloff
Junkie[scum]
 
karloff's Avatar
 
Join Date: Oct 2006
Location: location, location
Posts: 1,647
php inlcude prob

edit: seo reasons

Last edited by karloff : 30-05-2007 at 07:13.
  Reply With Quote
Old 30-03-2007, 10:22   #2 (permalink)
.simplestick
By the power of greyskull
 
.simplestick's Avatar
 
Join Date: Sep 2006
Location: Canada
Posts: 39
often times you can get wack characters when working in UTF-8 Unicode, check to see if you editor is reading the document as such.
  Reply With Quote
Old 30-03-2007, 11:40   #3 (permalink)
karloff
Junkie[scum]
 
karloff's Avatar
 
Join Date: Oct 2006
Location: location, location
Posts: 1,647
that doesn't seem to be a problem, any other suggestions?
  Reply With Quote
Old 30-03-2007, 16:44   #4 (permalink)
Beagle2
Registered User
 
Join Date: Mar 2007
Posts: 14
It looks like it's something in the banner_and_links.php file.

Are you able to post that file up? Or at least everything above where it outputs <div class="banner">
  Reply With Quote
Old 30-03-2007, 16:58   #5 (permalink)
karloff
Junkie[scum]
 
karloff's Avatar
 
Join Date: Oct 2006
Location: location, location
Posts: 1,647
edit: seo reasons

Last edited by karloff : 30-05-2007 at 07:13.
  Reply With Quote
Old 30-03-2007, 18:10   #6 (permalink)
wolve
Web Designer
 
Join Date: Mar 2007
Location: Yorkshire
Posts: 41
Try replacing:
Code:
<?php include('banner_and_links.php');?>

with:
Code:
<?php require('banner_and_links.php');?>

Also, with you not having any script embeded within banner_and_links it could actually be saved with a .html extention.
  Reply With Quote
Old 30-03-2007, 19:24   #7 (permalink)
karloff
Junkie[scum]
 
karloff's Avatar
 
Join Date: Oct 2006
Location: location, location
Posts: 1,647
Quote:
Originally Posted by wolve
Try replacing:
Code:
<?php include('banner_and_links.php');?>

with:
Code:
<?php require('banner_and_links.php');?>

Also, with you not having any script embeded within banner_and_links it could actually be saved with a .html extention.
can't alter code till i'm in work on mon, will try that then. i inherited the site and was going to change the doc to .html from .php but didn't have time
  Reply With Quote
Old 30-03-2007, 21:22   #8 (permalink)
gk
geek
 
gk's Avatar
 
Join Date: Oct 2006
Location: *.everywhere
Posts: 204
Send a message via ICQ to gk Send a message via AIM to gk Send a message via MSN to gk Send a message via Yahoo to gk
require and include do the exact same thing except require will terminate the script and produce and error.

My suggestions maybe try deleting everything before and including:
Code:
<div class="banner">

The retype it. It's possible someone inadvertently added some odd character codes to the file. ie alt+some random numbers or some stupid thing like that.

or

if you don't execute and php in the included file and is just html you could try file(), readfile(), file_get_contents(), fread(). they all do pretty much the same thing reading a file to a string or array.
  Reply With Quote
Old 31-03-2007, 04:49   #9 (permalink)
freelancr
Web Developer
 
freelancr's Avatar
 
Join Date: Oct 2006
Location: UK
Posts: 1,979
Send a message via MSN to freelancr
change the extension of the include to .html and load it up in your browser so you can do a "view source" or whatever to see if it is a php issue or there is just a duff character in there.

If you then find where that character is and delete all the whitespace before and after it, and rewrite a bit of the html around it, then you may find it was just some random typo.
  Reply With Quote
Old 31-03-2007, 06:36   #10 (permalink)
karloff
Junkie[scum]
 
karloff's Avatar
 
Join Date: Oct 2006
Location: location, location
Posts: 1,647
cheers guys, i'll test on mon and let you know
  Reply With Quote
Old 30-05-2007, 07:15   #11 (permalink)
karloff
Junkie[scum]
 
karloff's Avatar
 
Join Date: Oct 2006
Location: location, location
Posts: 1,647
could a mod please alter wolves post which includes the email address?

pretty please
  Reply With Quote
Reply


LinkBacks (?)
LinkBack to this Thread: http://www.designerstalk.com/forums/programming/24936-php-inlcude-prob.html
Posted By For Type Date
php inlcude prob This thread Refback 08-04-2007 19:20

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

Advanced Search


Contact Us - Web Design Forums - Archive - Top
Search Engine Optimization by vBSEO 3.0.0 RC8