Page 1 of 1

php gurus

Posted: Thu Nov 23, 2006 12:50 am
by raw
My brother's website used to be hosted and I lost the host along with the content and the database. I've re-created the database (it was a simple one) to the best of my ability but I'm having problems with the dynamic pages actually working.

For example: http://www.cobrakid.com/content.php?page=latest_info

It doesn't actually do anything. In my apache2 log I only get this
File does not exist: /<location>/page=latest_info, referer: http://www.cobrakid.com/headline.php?page=latest_info

No content displays on the page and nothing actually works. I'm sure I compiled everything right on my Gentoo machine but still no dice.

If you want to give me a hand, I'll give you shell access and I'd like to be involved in the debugging.

Thanks in advance.

Posted: Thu Nov 23, 2006 9:33 pm
by Foo
Turn on the php error outputs in PHP.ini and you should get back some helpful error messages when you attempt to access the pages.

From the apache log it looks like that's a straightforwards templating/bounce script that pulls other documents up and displays them, but from the error it's giving I think there's an incompatibility between your PHP build and the script, because it looks to be seeking a file which is literally titled "page=latest_info", which isn't logical.

Also, the side might have been using a customised 404 script that makes the site rely on pages not existing so that it can redirect via script to the right area of the side (it's a bit hard to explain), and that would require some apache reconfiguration.

I'd love to help but I'm busy up until the weekend. In the unlikely event you can't find someone else before then gimme a shout.

Posted: Thu Nov 23, 2006 11:16 pm
by raw
Thanks for the tips Foo. The error logging I think is on and I wasn't running any custom 404 pages. Basically, brisk did the graphics and elk did the php and database work. It isn't anything too complex but there's something with my apache2 or php setup which is bombing this. The error logs aren't too clear as to what the issue is.

Re: php gurus

Posted: Fri Nov 24, 2006 8:04 am
by ^misantropia^
raw wrote:File does not exist: /<location>/page=latest_info, referer: http://www.cobrakid.com/headline.php?page=latest_info
Were you or are you using mod_rewrite to rewrite request URLs on the fly, or is headline.php redirecting through a header('Location: somewhere_else') command?

Posted: Fri Nov 24, 2006 2:31 pm
by raw
Actually, 4days got me hooked up and working. The only issue I have left is debugging the news script since I'm sure the mysql field types are wrong.

Posted: Fri Nov 24, 2006 4:00 pm
by raw
Once again, 4days owned it for me again.

THANKS A TON DUDE!

Posted: Sat Nov 25, 2006 5:23 pm
by corpse
What is the advantaage of using php over plain html?