Not signed in (Sign In)

Vanilla 1.1.10 is a product of Lussumo. More Information: Documentation, Community Support.

    • CommentAuthorbluerob
    • CommentTimeDec 22nd 2005
     
    Hey, I saw this bug report before. I saw something about surpressing it, but when tried to research the problem...it really didn't get my anywhere...


    if you could just take a look at my gallery...its for my family photo album.

    http://www.jtlarkinsfamily.com/album/

    you'll notice this pops up at the top and

    Notice: Undefined index: level in /home/overflow/public_html/album/gallery.php on line 37


    and this lone of text right above the album.

    Notice: Undefined variable: rss_link in /home/overflow/public_html/album/gallery.php on line 634

    Just any help with this would be much appreciated.

    thanks so much.
    • CommentAuthorddejong
    • CommentTimeDec 22nd 2005 edited
     
    http://ca3.php.net/error_reporting

    By downgrading the error_level at runtime (at the top of your script), you can supress those errors. PHP is almost in debug mode, telling you there is no "level" defined. (It's not actually a "debug" mode, but a very high error level -- right now it's at "e_notice", which makes PHP rather chatty). Shut it up with:
    error_reporting(E_WARNING);

    Alternatively, you could add:

    if(!isset($_GET[level]) { $_GET[level] = "collections"; }

    That would assign it if there were no level found in the $_GET array.

    Either way, both should solve the problem, though I prefer the former, as there isn't anything actually wrong with the code; given the way Plogger is written, $level being undefined is perfectly acceptable. There's a concern that undefined variables would cause "variable poisoning", but with $level the default switch case would catch any malicious/misintended $level attempts.

    Either way, it should go before any of your Plogger calls. If Plogger gets to line 34 before you change the runtime error reporting, it will still complain -- so kill it first thing.

    HTH,
    Derek
    • CommentAuthorbluerob
    • CommentTimeDec 24th 2005
     
    that worked excellent.

    I must say.... i looked around on the web for a script like this for days. This was exactly what I was looking for. so customizable with my layout and not a hassel to install.

    why can't more services be like this one :(

    thanks a lot for the support and script

    ;)

    merry xmas