Error message and secruity image not always showing.

Dr. GBooky is here to help you with your guestbook problems ...
Post Reply
Octane
Posts: 5
Joined: Sat Mar 10, 2007 3:34 pm

Error message and secruity image not always showing.

Post 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.
Klemen
Site Admin
Posts: 10116
Joined: Fri Feb 11, 2005 4:04 pm

Post 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.
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
Octane
Posts: 5
Joined: Sat Mar 10, 2007 3:34 pm

Post 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.
Klemen
Site Admin
Posts: 10116
Joined: Fri Feb 11, 2005 4:04 pm

Post 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!
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
Octane
Posts: 5
Joined: Sat Mar 10, 2007 3:34 pm

Post by Octane »

Still not working. But I'm not sure if SmartFTP is letting me CHMOD the file.
Klemen
Site Admin
Posts: 10116
Joined: Fri Feb 11, 2005 4:04 pm

Post 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.
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
Octane
Posts: 5
Joined: Sat Mar 10, 2007 3:34 pm

Post 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.
Klemen
Site Admin
Posts: 10116
Joined: Fri Feb 11, 2005 4:04 pm

Post 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.
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
Octane
Posts: 5
Joined: Sat Mar 10, 2007 3:34 pm

Post 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.
Klemen
Site Admin
Posts: 10116
Joined: Fri Feb 11, 2005 4:04 pm

Post by Klemen »

Haven't used a free host in 5 years so I can't be of much help there :wink:
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
Post Reply