'Successfully added' links don't exist

Post your Click counter digestion problems here
Post Reply
ObscureWarumono
Posts: 4
Joined: Thu Aug 09, 2007 7:04 pm

'Successfully added' links don't exist

Post by ObscureWarumono »

Script URL: room304.shattered-serenity.net/ccount/
Version of script: 1.1
Hosting company: Surpass Hosting
URL of phpinfo.php: ?
URL of session_test.php: ?
What terms did you try when SEARCHING for a solution: 'Admin panel', 'Clicks', 'Links', read the README and tutorial provided

Hello!
Just when I thought I had this figured out, I ran into a problem.. I'm trying to count clicks on the 'Preview' link of a layout, and it doesn't seem to be working even after doing a CHMOD on the php scripts (not doing this gave me an error message before, but that part is fixed).
The page with the link on it is: http://room304.shattered-serenity.net/l ... yspace.php
The page I'm linking to and counting clicks on is: http://room304.shattered-serenity.net/l ... eview.html


Everything seems to work okay, and I even get this message..
New link successfully added!
A new link with ID 1 has been successfully added.
To count clicks on this link use this URL:
http://room304.shattered-serenity.net/c ... k.php?id=1
instead of the old one:
http://room304.shattered-serenity.net/l ... eview.html

..when I add the link.

However, when I 'Click to continue", the link isn't shown in the admin panel. Instead I get:
Link statistics
Not counting any links. Use the form below to add new links to be counted.


I added the Javascript code between the <head> and </head> tags, and am pretty sure I'm using the right codes to display the number of counts (currently showing up as 'undefined'). When I click on the link http://room304.shattered-serenity.net/c ... k.php?id=1, it says that ID doesn't exist. Can you please tell me what might be wrong?

Thanks for reading, and any help is greatly appreciated! ^_^
Klemen
Site Admin
Posts: 10116
Joined: Fri Feb 11, 2005 4:04 pm

Post by Klemen »

Your clicks.txt file seems empty, check on your server if it really is. Try adding a new link and see if it remains empty?

Could be a problem with clicks.txt file permissions, is chmod set to 666?

Also upload phpinfo.php to your server and post a link here. You will find phpinfo.php in the "READ THIS BEFORE POSTING A NEW QUESTION" post.
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
ObscureWarumono
Posts: 4
Joined: Thu Aug 09, 2007 7:04 pm

Post by ObscureWarumono »

clicks.txt is empty, stays that way even after adding a new link, and chmod is set to 666.

The phpinfo link is
http://room304.shattered-serenity.net/c ... hpinfo.php
Klemen
Site Admin
Posts: 10116
Joined: Fri Feb 11, 2005 4:04 pm

Post by Klemen »

If CHMOD is correct it's possible your host doesn't allow writing to files (phpinfo doesn't show any errors though). Try uploading this file to the ccount folder, open in browser and paste the results you get:
http://www.phpjunkyard.com/extras/ids_test.zip
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
ObscureWarumono
Posts: 4
Joined: Thu Aug 09, 2007 7:04 pm

Post by ObscureWarumono »

http://room304.shattered-serenity.net/c ... s_test.php
I got..

The ids.txt file is not writable
Reading file... the value is set to: 0
Changing the value to: 1
Ok, trying to read again...the value is set to: 1
Works fine!
Klemen
Site Admin
Posts: 10116
Joined: Fri Feb 11, 2005 4:04 pm

Post by Klemen »

That's funny - it shows the file as not writable, but you can still write to it? Not really sure what to tell you here, you can try asking your host why files chmoded to 666 show up as "not writable" in php.
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
ObscureWarumono
Posts: 4
Joined: Thu Aug 09, 2007 7:04 pm

Post by ObscureWarumono »

Ah, okay. Maybe they'll know what's going on with it, especially if I give a link to the thread of the steps we tried. Hopefully I'll get it working if the host can somehow change a setting, or do something different if there's any hidden option.

Thanks so much for your help and time! ^-^
Post Reply