scriptygoddess

13 Aug, 2003

Include lines count

Posted by: Jennifer In: Lessons learned

Just ran into an interesting problem and wanted to post this here in case anyone else ever hits the same snag – hopefully I'll save you a headache.

I was recently helping someone out with cookies on their site. By all appearances – the cookie WAS being set (I made a "test" page that did nothing but call the cookie – and it worked fine), but when I tried to call it from their site, something wasn't working…

It turned out that they had a php include which looked like this:

<? include "<$MTBlogURL$>/includepage.php"; ?>

And while this basically worked – the page was included, and no specific errors were generated – it did cause a number of problems. One of the problems being that cookies weren't being called or recognized. But many other PHP things were working fine on the page.

Changing the includes to use the full server path fixed the problem. (By "full server path" I mean it kind of looked like: "/home/youraccount/public_html/myblog/includefile.php")

2 Responses to "Include lines count"

1 | Phil

August 13th, 2003 at 10:01 pm

Avatar

WOW!!!! That's a great tip. Who would do something like that? *wink*

Ok, fine it was me.

2 | Jennifer

August 13th, 2003 at 10:11 pm

Avatar

LOL! Well – at least we learned something about includes! 😀 I'm actually very surprised by what it did – with it SORT OF working… usually it works or it doesn't (and spits errors out all over the place)… With it SORT OF working – it's really hard to pin point what the problem is…

Featured Sponsors

Genesis Framework for WordPress

Advertise Here


  • Scott: Just moved changed the site URL as WP's installed in a subfolder. Cookie clearance worked for me. Thanks!
  • Stephen Lareau: Hi great blog thanks. Just thought I would add that it helps to put target = like this:1-800-555-1212 and
  • Cord Blomquist: Jennifer, you may want to check out tp2wp.com, a new service my company just launched that converts TypePad and Movable Type export files into WordPre

About


Advertisements