Thread: phpberrystats
View Single Post
Old 05-01-2007, 03:45 PM   #9 (permalink)
blubyu
Thumbs Must Hurt
 
blubyu's Avatar
 
Join Date: Jun 2005
Model: 7520
Carrier: nextel
Posts: 116
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by jibi View Post
Also, I *rarely* use the Options page, but I started thinking about a localized (or LDAP to AD usergroup auth) admin section that enabled that option (yes, thinking way outside the box). Anyhow, on 0.0.9, there's an "issue" with the options.php page (in PHP 5.2.1 + IIS 5.2/6.0). I get these errors:

Code:
PHP Notice: Use of undefined constant On - assumed 'On' in C:\Inetpub\wwwroot\stats-dev\options.php on line 84 PHP Notice: Use of undefined constant Off - assumed 'Off' in C:\Inetpub\wwwroot\stats-dev\options.php on line 137 PHP Notice: Use of undefined constant Off - assumed 'Off' in C:\Inetpub\wwwroot\stats-dev\options.php on line 199 PHP Notice: Undefined offset: 8 in C:\Inetpub\wwwroot\stats-dev\options.php on line 248 PHP Notice: Undefined offset: 8 in C:\Inetpub\wwwroot\stats-dev\options.php on line 252 PHP Notice: Undefined offset: 9 in C:\Inetpub\wwwroot\stats-dev\options.php on line 263 PHP Notice: Undefined offset: 9 in C:\Inetpub\wwwroot\stats-dev\options.php on line 267 PHP Notice: Undefined offset: 10 in C:\Inetpub\wwwroot\stats-dev\options.php on line 248 PHP Notice: Undefined offset: 10 in C:\Inetpub\wwwroot\stats-dev\options.php on line 252 PHP Notice: Undefined offset: 11 in C:\Inetpub\wwwroot\stats-dev\options.php on line 263 PHP Notice: Undefined offset: 11 in C:\Inetpub\wwwroot\stats-dev\options.php on line 267 PHP Notice: Undefined offset: 12 in C:\Inetpub\wwwroot\stats-dev\options.php on line 248 PHP Notice: Undefined offset: 12 in C:\Inetpub\wwwroot\stats-dev\options.php on line 252 PHP Notice: Undefined offset: 13 in C:\Inetpub\wwwroot\stats-dev\options.php on line 263 PHP Notice: Undefined offset: 13 in C:\Inetpub\wwwroot\stats-dev\options.php on line 267 PHP Notice: Undefined offset: 14 in C:\Inetpub\wwwroot\stats-dev\options.php on line 248 PHP Notice: Undefined offset: 14 in C:\Inetpub\wwwroot\stats-dev\options.php on line 252 PHP Notice: Undefined offset: 15 in C:\Inetpub\wwwroot\stats-dev\options.php on line 263 PHP Notice: Undefined offset: 15 in C:\Inetpub\wwwroot\stats-dev\options.php on line 267 PHP Notice: Undefined offset: 16 in C:\Inetpub\wwwroot\stats-dev\options.php on line 248 PHP Notice: Undefined offset: 16 in C:\Inetpub\wwwroot\stats-dev\options.php on line 252 PHP Notice: Undefined offset: 17 in C:\Inetpub\wwwroot\stats-dev\options.php on line 263 PHP Notice: Undefined offset: 17 in C:\Inetpub\wwwroot\stats-dev\options.php on line 267 PHP Notice: Undefined offset: 18 in C:\Inetpub\wwwroot\stats-dev\options.php on line 248 PHP Notice: Undefined offset: 18 in C:\Inetpub\wwwroot\stats-dev\options.php on line 252 PHP Notice: Undefined offset: 19 in C:\Inetpub\wwwroot\stats-dev\options.php on line 263 PHP Notice: Undefined offset: 19 in C:\Inetpub\wwwroot\stats-dev\options.php on line 267 PHP Notice: Undefined offset: 20 in C:\Inetpub\wwwroot\stats-dev\options.php on line 248 PHP Notice: Undefined offset: 20 in C:\Inetpub\wwwroot\stats-dev\options.php on line 252 PHP Notice: Undefined offset: 21 in C:\Inetpub\wwwroot\stats-dev\options.php on line 263 PHP Notice: Undefined offset: 21 in C:\Inetpub\wwwroot\stats-dev\options.php on line 267
To fix, find each of these three instances:
Code:
    echo On;}
    else {
        echo Off ;} ?></b>
Change to:
Code:
    echo 'On' ;}
    else {
        echo 'Off' ;} ?></b>
Find both instances of:
Code:
<? if ($columns[$i]==1) { ?>
and:
Code:
<? if ($columns[$i]==0) { ?>
Change to:
Code:
<? if ($columns[0]) { ?>
and:
Code:
<? if ($columns[1]) { ?>
I'm not sure if the latter parts are correct ($i is never specified when defining $columns, assuming I'm reading it correctly.. hehe), but the top part is 'technically' correct with the addition of the single-quotes.
I have Notice errors turned off on my server This must be why they don't show up for me. I will turn them on, make your changes and then test to make sure they still work.

I did get the dynamic columns done and they seem to work great. I will try and get that code uploaded tonight or tomorrow. Oh I also added the Agent ID.
Offline   Reply With Quote