Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Options

Vanilla showing...er..nothing.

2

Comments

  • Options
    (or your session id)
  • Options
    edited February 2006
    hehe. stupid. I didn't look at the code. I thought it was a general workaround. now I don't have a folder. the url is: test.sermo.nl (It's a name based virtual server) What to replace "haliki" with?
  • Options
    Um. Try /?
  • Options
    No good. it does the same thing.
  • Options
    edited February 2006
    Here is the settings.php
    Don't know how you do the nice code block thing, sorry...

    // Database Settings define("dbHOST", "localhost"); define("dbNAME", "sermo_test"); define("dbUSER", "******"); define("dbPASSWORD", "******"); // Path Settings define("agAPPLICATION_PATH", "/srv/www/vhosts/test.sermo.nl/"); define("sgLIBRARY", agAPPLICATION_PATH."library/"); define("agEXTENSIONS", agAPPLICATION_PATH."extensions/"); define("agLANGUAGES", agAPPLICATION_PATH."languages/"); // Application Settings define("agAPPLICATION_TITLE", "Vanilla"); define("agBANNER_TITLE", "Lussumo <strong>Vanilla</strong>"); define("agDEFAULT_STYLE", "styles/vanilla/"); define("agBANNER_TITLE", "Lussumo <strong>Vanilla</strong>"); define("agDEFAULT_STYLE", "styles/vanilla/"); define("agDOMAIN", "test.sermo.nl"); define("agSAFE_REDIRECT", "signin.php?PageAction=SignOut"); define("agDISCUSSIONS_PER_PAGE", "30"); define("agDISCUSSIONS_PER_FEED", "20"); define("agCOMMENTS_PER_PAGE", "50"); define("agSEARCH_RESULTS_PER_PAGE", "30"); define("agCOOKIE_DOMAIN", "test.sermo.nl"); define("agSUPPORT_EMAIL", "lennart@sermo.nl"); define("agSUPPORT_NAME", "Support"); define("agALLOW_NAME_CHANGE", "1"); define("agPUBLIC_BROWSING", "0"); define("agUSE_CATEGORIES", "1"); define("agLOG_ALL_IPS", "0"); // Panel Settings define("agPANEL_BOOKMARK_COUNT", "20"); define("agPANEL_PRIVATE_COUNT", "5"); define("agPANEL_HISTORY_COUNT", "5"); define("agPANEL_USERDISCUSSIONS_COUNT", "5"); define("agPANEL_SEARCH_COUNT", "20"); // Discussion Settings define("agMAX_COMMENT_LENGTH", "5000"); define("agMAX_TOPIC_WORD_LENGTH", "45"); define("agDISCUSSION_POST_THRESHOLD", "3"); define("agDISCUSSION_TIME_THRESHOLD", "60"); define("agDISCUSSION_THRESHOLD_PUNISHMENT", "120"); define("agCOMMENT_POST_THRESHOLD", "5"); define("agCOMMENT_TIME_THRESHOLD", "60"); define("agCOMMENT_THRESHOLD_PUNISHMENT", "120"); define("agCOMMENT_TIME_THRESHOLD", "60"); define("agCOMMENT_THRESHOLD_PUNISHMENT", "120"); define("agTEXT_WHISPERED", "Private"); define("agTEXT_STICKY", "Sticky"); define("agTEXT_CLOSED", "Closed"); define("agTEXT_HIDDEN", "Hidden"); define("agTEXT_BOOKMARKED", ""); define("agTEXT_PREFIX", "["); define("agTEXT_SUFFIX", "]"); // String Formatting Settings define("agDEFAULTSTRINGFORMAT", "Text"); define("agFORMATSTRINGFORDISPLAY", "DISPLAY"); define("agFORMATSTRINGFORDATABASE", "DATABASE"); // Application Mode Constants define("agMODE_DEBUG", "DEBUG"); define("agMODE_RELEASE", "RELEASE"); define("agMODE_UPGRADE", "UPGRADE"); // Registration settings define("agDEFAULT_ROLE", "0"); define("agALLOW_IMMEDIATE_ACCESS", "0"); define("agAPPROVAL_ROLE", "3"); // Application version - Don't change this value or you may have // problems upgrading later. define("agVANILLA_VERSION", "0.9.2.6"); // Note: Vanilla 0.9.2.6 included some extremely important security patches. // If you do not have this version installed, we highly recommend that you replace your old vanilla // files with this version. It is okay to leave all files in the appg folder as they are.

    ok thanx :)
  • Options
    dude... ****** is my password too!

    by the way, start your code blocks with <code> and end with </code>
  • Options
    Also make sure you checked "html" off in the format field.
  • Options
    edited February 2006
    Check this story:

    http://blog.taragana.com/index.php/archive/understanding-_serverphp_self-php_self-_serverrequest_uri-and-_serverscript_name-in-php-and-when-to-use-what/2/

    "$PHP_SELF
    $PHP_SELF is deprecated and should not be used because it will not work without register_globals being enabled. As of PHP 4.2.0 the default for the PHP directive register_globals
    went from on to off."

    Could it be, that since my "register_globals" are off by default, this is causing a problem?

    See the code:
    (library/Utility.Page.class.php)

    $this->SelfUrl = basename(ForceString(@$_SERVER['PHP_SELF'], "index.php"));
  • Options
    is $PHP_SELF still in the code?

    it should be $_SERVER['PHP_SELF'] .
  • Options
    Ow oops. there's is a difference.
    sorry. forget the post! :D
  • Options
    that code should work,.
    if you want to test it, put echo $this->SelfUrl;exit;after that line and see what shows up.
  • Options
    edited February 2006
    sorry, wrong post.
  • Options
    ithcyithcy New
    edited February 2006
    hmmm... try this instead
    echo "PHP_SELF is: " . $this->SelfUrl;

    if nothing shows up then that file, whatever it is, is probably not getting included.
  • Options
    and also view source when it runs to make sure it's not popping up in some non-display area of the page.
  • Options
    edited February 2006
    Ow. sorry. It works. I made a typo.
    I used your first example, and the index page now reads:

    index.php.

    So this means it works right?
  • Options
    Well, I call it a day.
    Time to get some sleep.
    Here is the full error. The one returned by the parser, and
    the one returned by vanilla :)

    Warning: import(controls/index.php): failed to open stream: No such file or directory in /srv/www/vhosts/test.sermo.nl/library/Utility.Page.class.php on line 47 Warning: import(): Failed opening 'controls/index.php' for inclusion (include_path='/usr/share/php') in /srv/www/vhosts/test.sermo.nl/library/Utility.Page.class.php on line 47 A fatal, non-recoverable error has occurred Technical information (for support personel): Error Message: Failed to import file "controls/index.php". Affected Elements: Page.Import();
  • Options
    MarkMark Vanilla Staff
    Hmmm. I tried to look at your http://test.sermo.nl/ url, but it failed to load at all.

    Assuming that the controls/index.php file is there, I'm not really sure what to tell you.

    I guess the next thing I'd try is creating a test page with an include to that file.

    So, in the vanilla root, create test.php with this in it:

    <?php include('controls/index.php'); echo('Did that work?'); ?>

    If *that* fails, then the file definitely isn't there or there is something wacky going on in your php config.
  • Options
    It *did* fail.

    Fatal error: Class discussiongrid: Cannot inherit from undefined class control in /srv/www/vhosts/test.sermo.nl/controls/index.php on line 15

    controls/index.php is there.
    Did I do the permissions correct?
    (wwwrun:www is the apache deamon user)

    -rwxr-xr-x 1 wwwrun www 4914 2005-07-21 22:20 index.php
  • Options
    MarkMark Vanilla Staff
    edited February 2006
    No, that actually included properly. There is a class within controls/index.php that is derived from another class not in that file, so it threw the error.

    Let's try something different. Let's try changing the file's include path to be explicit directly from root.

    In your appg/init_internal.php file, change line 92 from this:

    $Page->Import($Context->ControlFile);

    To this:

    $Page->Import('/srv/www/vhosts/test.sermo.nl/'.$Context->ControlFile);

    If that doesn't work, then let's try changing line 92 to this:

    include('/srv/www/vhosts/test.sermo.nl/'.$Context->ControlFile);

    If either of those work, you'll need to do the same thing in appg/init_external.php.
  • Options
    replacement one yields:

    Notice: Undefined property: ControlFile in /srv/www/vhosts/test.sermo.nl/appg/init_internal.php on line 93 Warning: import(/srv/www/vhosts/test.sermo.nl/): failed to open stream: Permission denied in /srv/www/vhosts/test.sermo.nl/library/Utility.Page.class.php on line 47 Warning: import(): Failed opening '/srv/www/vhosts/test.sermo.nl/' for inclusion (include_path='/usr/share/php') in /srv/www/vhosts/test.sermo.nl/library/Utility.Page.class.php on line 47

    replacement two yields:

    Notice: Undefined property: ControlFile in /srv/www/vhosts/test.sermo.nl/appg/init_internal.php on line 93 Warning: main(/srv/www/vhosts/test.sermo.nl/): failed to open stream: Permission denied in /srv/www/vhosts/test.sermo.nl/appg/init_internal.php on line 93 Warning: main(): Failed opening '/srv/www/vhosts/test.sermo.nl/' for inclusion (include_path='/usr/share/php') in /srv/www/vhosts/test.sermo.nl/appg/init_internal.php on line 93 Warning: Cannot modify header information - headers already sent by (output started at /srv/www/vhosts/test.sermo.nl/appg/init_internal.php:93) in /srv/www/vhosts/test.sermo.nl/library/Vanilla.Session.class.php on line 27

    while the original code returned:

    Warning: import(controls/index.php): failed to open stream: No such file or directory in /srv/www/vhosts/test.sermo.nl/library/Utility.Page.class.php on line 47 Warning: import(): Failed opening 'controls/index.php' for inclusion (include_path='/usr/share/php') in /srv/www/vhosts/test.sermo.nl/library/Utility.Page.class.php on line 47

    So even more errors :)
This discussion has been closed.