includes.php file is empty, why?

Ask questions, request features, or just complement us about our software and services.
Post Reply
mphare
Posts: 7
Joined: Tue Nov 30, 2004 9:25 am
Location: Texas

includes.php file is empty, why?

Post by mphare »

I've used <url>/catcher.php?debug=<username>
and gotten all the debug messages, including where it creates an includes.php file if it doesn't exist in the directory.

But there is no data written to the includes.php file.

Doing a little debugging on my own, I dumped the value of count($server)

Code: Select all

$cnt = count($server);
console_out($cnt);
and I'm getting 0. This blocks all access to the code that writes the data to the includes.php file inside the nested 'if' statements.
(I only have one server)

rtb seems to be working otherwise. I can connect through the web interface and see the song history.

Why is my number of servers 0 when it should be 1?
- - - - - - - - - - - - -
- me
GnuPG Key fingerprint = 1AD4 726D E359 A31D 05BF ACE5 CA93 7AD5 D8E3 A876
User avatar
Jay
Will work for food (Administrator)
Posts: 3020
Joined: Mon Jan 14, 2002 12:48 am
Location: Next Door
Contact:

Post by Jay »

how many servers are you monitoring?
- Jay
mphare
Posts: 7
Joined: Tue Nov 30, 2004 9:25 am
Location: Texas

Post by mphare »

and I'm getting 0. This blocks all access to the code that writes the data to the includes.php file inside the nested 'if' statements.
(I only have one server)
I wondered if having only 1 would index to 0, but the code is written that there must be at least a 1 for the cout to allow the code to run.

Code: Select all

	$list_size = count($server);
	@include($includes_path."includes.php");

	$data="<?php\r\n";

	for($i=0; $i < $list_size; $i++){

		$server_vars=array('ip', 'type', 'listeners', 'max_listeners', 'bitrate', 'status', 'desc', 'current_song');

		for($j=0; $j < count($server_vars); $j++){

			$data.="\$server[$i]['$server_vars[$j]']=";

			$data.='\''.$server[$i][$j].'\';';

			$data.="\r\n";

			$rtb_array[$i][$server_vars[$j]] = $server[$i][$j];

		}

	}

If $list_size isn't at least 1, then the code is never executed.
So, I assume having only 1 server would result in $list_size (count($server) being set to 1.

But it's set to 0

[/u]
- - - - - - - - - - - - -
- me
GnuPG Key fingerprint = 1AD4 726D E359 A31D 05BF ACE5 CA93 7AD5 D8E3 A876
mphare
Posts: 7
Joined: Tue Nov 30, 2004 9:25 am
Location: Texas

Post by mphare »

BTW, the other thing is my rtb says "Error Conecting to Log Site" at the bottom of the window. I do not have "I have a log service account" checked in the options.

I put a rtb_log("Start") message at the top of the catcher.php script and it never gets called. I'm beginning to believe the catcher is never called by rtb.
- - - - - - - - - - - - -
- me
GnuPG Key fingerprint = 1AD4 726D E359 A31D 05BF ACE5 CA93 7AD5 D8E3 A876
mphare
Posts: 7
Joined: Tue Nov 30, 2004 9:25 am
Location: Texas

Post by mphare »

Maybe it has something to do with my secure server (Apache running with mod_ssl). Will rtb work on a https:// connection?
- - - - - - - - - - - - -
- me
GnuPG Key fingerprint = 1AD4 726D E359 A31D 05BF ACE5 CA93 7AD5 D8E3 A876
mphare
Posts: 7
Joined: Tue Nov 30, 2004 9:25 am
Location: Texas

Post by mphare »

That was it... mod_ssl.

I installed another instance of Apache, listening to a different port and without mod_ssl. I pointed rtb to that port and it's working.

Thanks for the help!
- - - - - - - - - - - - -
- me
GnuPG Key fingerprint = 1AD4 726D E359 A31D 05BF ACE5 CA93 7AD5 D8E3 A876
User avatar
Jay
Will work for food (Administrator)
Posts: 3020
Joined: Mon Jan 14, 2002 12:48 am
Location: Next Door
Contact:

Post by Jay »

ah, I may look into adding SSL support then. But yea, currently there is none.
- Jay
mphare
Posts: 7
Joined: Tue Nov 30, 2004 9:25 am
Location: Texas

Post by mphare »

I run mod_ssl because it was a challange to compile Apache and OpenSSL for MSWindows and get it all to work. I don't really need it, but it's cool to have.

I don't know if others run ssl or not. I guess this is the first time this has come up, so maybe it's not a high priority.

Thanks!
- - - - - - - - - - - - -
- me
GnuPG Key fingerprint = 1AD4 726D E359 A31D 05BF ACE5 CA93 7AD5 D8E3 A876
mphare
Posts: 7
Joined: Tue Nov 30, 2004 9:25 am
Location: Texas

Post by mphare »

[removed, duplicate post]
- - - - - - - - - - - - -
- me
GnuPG Key fingerprint = 1AD4 726D E359 A31D 05BF ACE5 CA93 7AD5 D8E3 A876
Post Reply