If you are not registered or logged in, you may still use these forums but with limited features. Show recent topics
  [Search] Search   [Hottest Topics] Hottest Topics   [Members]  Member Listing   [FAQ]  FAQ 
[Register] Register / 
[Login] Login 
Daily Counter 1.1  XML
Forum Index » Support Forum
Author Message
Funky Monk
Beginner

Joined: 14/08/2003 13:10:14
Messages: 20
Location: Ballynahinch, Northern Ireland
Offline

Hi,

I have installed Daily Counter 1.1, which works fine on the home page. But I also have pages in folders such as: day_centres/introduction.php.

When I try to use the counter on a page within a folder I get an error such as:


Warning: fopen(./ip.txt): failed to open stream: Permission denied in /home/barrr/public_html/counter.class.php on line 50

Warning: flock(): supplied argument is not a valid stream resource in /home/barrr/public_html/counter.class.php on line 51

Warning: fwrite(): supplied argument is not a valid stream resource in /home/barrr/public_html/counter.class.php on line 63

Warning: flock(): supplied argument is not a valid stream resource in /home/barrr/public_html/counter.class.php on line 64

Warning: fclose(): supplied argument is not a valid stream resource in /home/barrr/public_html/counter.class.php on line 65

Warning: fopen(./total_visits.txt): failed to open stream: Permission denied in /home/barrr/public_html/counter.class.php on line 85

Warning: fwrite(): supplied argument is not a valid stream resource in /home/barrr/public_html/counter.class.php on line 86

Warning: fclose(): supplied argument is not a valid stream resource in /home/barrr/public_html/counter.class.php on line 87

Warning: fopen(./daily.txt): failed to open stream: Permission denied in /home/barrr/public_html/counter.class.php on line 100

Warning: fwrite(): supplied argument is not a valid stream resource in /home/barrr/public_html/counter.class.php on line 101

Warning: fclose(): supplied argument is not a valid stream resource in /home/barrr/public_html/counter.class.php on line 102

Do I have to install the script again within each folder or should I just alter the path to the script? I tried altering the path but I can't get it to work. Perhaps I'm doing something wrong.
[WWW]
Anonymous



did you cmod the .txt files to 666
Anonymous



Yes, I did. As I said, it works fine on a page such as index.php, but not on a file in a folder such as ../day_centres/index.php.
Anonymous



is the path correct?
Funky Monk
Beginner

Joined: 14/08/2003 13:10:14
Messages: 20
Location: Ballynahinch, Northern Ireland
Offline

Perhaps not. If my path to the script from a file index.php is:

<?php
include ("./config.inc.php");
if ($COUNT_CFG['use_db']) {
include ("./mysql.class.php");
}
include ("./counter.class.php");
$counter = new dcounter();
$visits = $counter->show_counter(); /* Returns an associative array */

?>

What should it be in a file /day_centres/index.php ??
[WWW]
Auron
Expert
[Avatar]

Joined: 23/06/2003 22:02:17
Messages: 1053
Offline

You've got to change the path for each page so it points to the CORRECT location. It will be different between folders/directories but the same within those folders/directories.

Auron

Visit my site @ www.ragnaru.com
Adv. Poll Install Guide NOW BACK ONLINE! (And also rather out of date I would of thought)
[Email] [WWW]
Funky Monk
Beginner

Joined: 14/08/2003 13:10:14
Messages: 20
Location: Ballynahinch, Northern Ireland
Offline

Thanks, but you could probably guess from all the posts today I'm well aware that the paths are different. The only thing that I don't know is HOW to do that. Well, I do, as I've changed the path many times in other scripts, but I've spent the whole day on setting up this script and I'm frankly tired of doing it! I've been over and over this and I've tried every path I know.

Can someone please tell what the path should be in this directory?? Before I go mad or need to get glasses from looking at the screen too much.

Thanks. I'd really appreciate it. I'm really under pressure to get this project up and running.
[WWW]
Auron
Expert
[Avatar]

Joined: 23/06/2003 22:02:17
Messages: 1053
Offline

All you need to do is find the full server path to the file you want to include and then copy that to all the files you need it in. With using the full server path to it you can't go wrong it will always find the right script.

Auron

Visit my site @ www.ragnaru.com
Adv. Poll Install Guide NOW BACK ONLINE! (And also rather out of date I would of thought)
[Email] [WWW]
Anonymous



Warning: main(): stream does not support seeking in /home/nightowl/public_html/plumb/index.php on line 44

Warning: main(): stream does not support seeking in /home/nightowl/public_html/plumb/index.php on line 48

Fatal error: Cannot instantiate non-existent class: dcounter in /home/nightowl/public_html/plumb/index.php on line 50

i keep on getting that msg.. what's that all about? what should i do?
pls HELP me

thanks
Anonymous



Hello,

I want to use Daily Count 1.1. for my site(s).

To use it, i followed the instructions in the readme file, but couldn't get the script to work for me, rather when i load the page, the code appears on the actual web page.. ?

I want to use mysql db also.

Someone help me with instructions how to install it ??

Thank you for ur time.
Auron
Expert
[Avatar]

Joined: 23/06/2003 22:02:17
Messages: 1053
Offline

If your using the php version the page you include it on has to have the extension *.php otherwise if its *html or *.htm it will just output the code as text.

To: Funky Monkey...
When a path has ./config.inc.php that means in the same directory as index.php.
Make sure you have chmod'ed all the files correctly.

Auron

Visit my site @ www.ragnaru.com
Adv. Poll Install Guide NOW BACK ONLINE! (And also rather out of date I would of thought)
[Email] [WWW]
 
Forum Index » Support Forum
Go to:   
Based on the open source JForum