Page 1 of 1

Error message and secruity image not always showing.

Posted: Sun Mar 25, 2007 12:10 pm
by Octane
Script URL: http://home.ripway.com/2004-2/68535/gbook/gbook.php
Version of script: 1.5
Hosting company: Ripway
URL of phpinfo.php: http://h1.ripway.com/ukdirtriders/gbook/phpinfo.php
URL of session_test.php: http://h1.ripway.com/ukdirtriders/gbook ... n_test.php
http://h1.ripway.com/ukdirtriders/gbook ... _test2.php
What terms did you try when SEARCHING for a solution:

Write your message below:
When I go to view the guestbook I'm getting this ERROR: You have been permanently banned from this guestbook!. I then delete the ip from the banned_ip.txt and I can then view it for a while. When I go back to it on a different day I get the error message again. Other people I think can view it but they say the secruity image doesn't show up for them. But sometimes it has showen up for me and other times it hasn't. Tried it in firefox and internet explorer.

Posted: Sun Mar 25, 2007 2:04 pm
by Klemen
You have problems with sessions - and I mean some strange problems.

Your sessions sometimes work and sometimes not:
1. clear your temporary internet files
2. open session_test.php
3. click the continue link to go to session_test2.php

Now if you refresh the session_test2.php page several times you will sometimes get "FALSE" and sometimes "TRUE". This means your sessions work sometimes and sometimes not and this is causing problems.

Why is this happening? Not sure, but it has something to do with your host. My guess would be they have either overloaded servers or almost full C:/Windows/temp folder.

So your best bet would be to find another host, but you can try something else and see if it helps:
1. upload a blank banned_ip.txt
2. create a new folder in your gbook folder. Name it "session_data" and make sure it's writable
3. open gbook.php in Notepad and after lines 32-33

Code: Select all

error_reporting(E_ALL ^ E_NOTICE);
define('IN_SCRIPT',true);
add this:

Code: Select all

session_save_path('/ukdirtriders/gbook/session_data');
so it looks like this:

Code: Select all

error_reporting(E_ALL ^ E_NOTICE);
define('IN_SCRIPT',true);
session_save_path('/ukdirtriders/gbook/session_data');
4. Save changes, upload to the server and test.

If that doesn't work you can try

Code: Select all

session_save_path('\\192.168.0.16\webfiles\files\2004-2\68535\gbook');
and see if it makes a difference.

If THAT doesn't work then I'm not sure what else will.

Posted: Sun Mar 25, 2007 4:50 pm
by Octane
Tried that and now I can see the guestbook each time, but when I go to sign guestbook page it has warning messages on it.

Posted: Sun Mar 25, 2007 7:22 pm
by Klemen
How about

Code: Select all

session_save_path('session_data');
or

Code: Select all

session_save_path('\\192.168.1.16\webfiles\files\2004-2\68535\gbook\session_data');
?

Make sure the session_data folder is writable by the script!

Posted: Mon Mar 26, 2007 6:58 pm
by Octane
Still not working. But I'm not sure if SmartFTP is letting me CHMOD the file.

Posted: Mon Mar 26, 2007 7:54 pm
by Klemen
You're on Windows server and CHMOD doesn't work on windows. You will need to ask your host if they can set write permissions for the session_data folder for you.

Posted: Tue Apr 03, 2007 7:51 pm
by Octane
Well I asked them if they could do this for me but havent heard anything from them. But I can session data save in the folder.

Posted: Tue Apr 03, 2007 8:15 pm
by Klemen
Well support isn't something one would usually expect from free hosts...

Unless you can get those sessions working properly you will have problems with GBook and any PHP script that uses sessions, can't help you there.

Posted: Mon Apr 09, 2007 11:54 am
by Octane
Do you know of any good free web hosts that the script would work on? Ive got the cutenew script on the host I'm using at the moment and that works ok. An older version of the gbook script worked ok but the secruity image would not always show.

Posted: Mon Apr 09, 2007 6:26 pm
by Klemen
Haven't used a free host in 5 years so I can't be of much help there :wink: