• I’ve been struggling the past couple of days with Alex King’s plugin, Since Last Visit (v2.2). Step 3 of the README calls for the following line in the HEAD section:
    <?php require(bloginfo('url;').'/wp-content/plugins/wp-last-visit.php?type=js'); ?>
    I simply could not get this to work. I ended up with a bunch of errors, and I would post them except they are not on my screen now. Something about not being able to find the wp-last-visit.php file. I downloaded the WP package Alex offers (with all the plugins preinstalled) and found he was using the following line in the index.php file:
    <script type="text/javascript" src="<?php bloginfo('url'); ?>/wp-content/plugins/wp-last-visit.php?type=js"></script>
    I used this line for step 3 of the install and now I’m not getting any errors, but nothing from SLV shows up on the page. Not the “so many posts/comments since your last visit” banner, nor do any of the “new” graphics display after new posts and comments are put on. (Remaining steps in REAME followed meticulously, and compared with Alex’s WP package)
    I do notice a lot of cookies, though. I cleared all the cookies for my site, and then visited just my main page and counted 8 cookies from wplastvist on my site. Is this normal? Before I cleared the cookies there were 22 of them.
    So obviously the plugin is active, its just not displaying anything on the page. Can anyone help me out here? I’ve done a lot of searching and reading but haven’t found anything helpful … yet. Thanks.

Viewing 15 replies - 16 through 30 (of 55 total)
  • Changed that line in slv .

    At the top of last visit.php there is these instructions

    If your
    // site is accessible by multiple subdomain names, like “example.com”
    // and “www.example.com”, then set $domain to “.example.com”

    // By default, we’ll try to derive them from the site url defined
    // in the Base Settings options:
    $urlinfo = parse_url($siteurl);

    $path = $urlinfo[‘path’];
    $domain = $urlinfo[‘host’];

    The last line
    $domain = $urlinfo[‘host’];
    Should I change that to
    $domain = $urlinfo[‘somethin-tropical.epaulv.com’];

    Yes – it’s worth a go.
    Someone who knows more about paths could better advise, but one of the two lines there is definitely causing the problem.

    Done… still the same

    The line here has me concerned

    Warning: Cannot modify header information – headers already sent by (output started at /home/vanderwe/public_html/somethin-tropical/wp-content/plugins/wp-last-visit.php:274) in

    Seems to be trying to modify the head after it is already modified possible by the template?

    That line curently says 274 – I saw it change when I refreshed the page. Some whitespace has crept in at the end.
    Scroll down to the bottom of the file, put the cursor between the ? and the > then press and hold DELETE, release, press > and save.

    lol now it is 273

    Hmmm……that error we can come back to.
    It’s the way the file is looking two directories out (the ../../ ) that is breaking it first. That is probably a setting in one of the two lines you have menioned above.
    It may take a bit of trial and error, so keep a record of what you have tried and where.
    So….to kick of, what values have you tried ?

    ok i have removed any whitespace…

    As for values – is that regarding the ../../wp-blog…. part?

    With this
    include(“../wp-blog-header.php”);
    we get this
    Warning: main(../wp-blog-header.php): failed to open stream: No such file or directory in…….

    With this
    include(“/wp-blog-header.php”);
    we get this

    Warning: main(): open_basedir restriction in effect. File(/wp-blog-header.php) is not within the allowed path(s): (/home/vanderwe/:/usr/lib/php:/usr/local/lib/php:/tmp) in /home/vanderwe/public_html/somethin-tropical/wp-content/plugins/wp-last-visit.php on line 53

    Warning: main(/wp-blog-header.php): failed to open stream: Operation not permitted in /home/vanderwe/public_html/somethin-tropical/wp-content/plugins/wp-last-visit.php on line 53

    Warning: main(): open_basedir restriction in effect. File(/wp-blog-header.php) is not within the allowed path(s): (/home/vanderwe/:/usr/lib/php:/usr/local/lib/php:/tmp) in /home/vanderwe/public_html/somethin-tropical/wp-content/plugins/wp-last-visit.php on line 53

    Warning: main(/wp-blog-header.php): failed to open stream: Operation not permitted in /home/vanderwe/public_html/somethin-tropical/wp-content/plugins/wp-last-visit.php on line 53

    Warning: main(): Failed opening ‘/wp-blog-header.php’ for inclusion (include_path=’.:/usr/lib/php:/usr/local/lib/php’) in /home/vanderwe/public_html/somethin-tropical/wp-content/plugins/wp-last-visit.php on line 53

    Do you use IRC ? It will be quicker to get help there clever guys in there you know)..

    “The last line
    $domain = $urlinfo[‘host’];
    Should I change that to
    $domain = $urlinfo[‘somethin-tropical.epaulv.com’];”
    Is that where you changed things ?

    With this
    include(“somethin-tropical.epaulv.com/wp-blog-header.php”);
    we get this
    pretty much the same thing

    No I removed mIRC some time ago

    I changed the
    $domain = $urlinfo[‘somethin-tropical.epaulv.com’];”
    and it is still the same.

    The changes posted were
    if (isset($wplastvisit_output)) { // will output stuff for the HTML source
    switch ($wplastvisit_output) {
    case “javascript”:
    include(“somethin-tropical.epaulv.com/wp-blog-header.php”);

    This last line that origonally said ../../wp-blog-header.php

    ok that fixed the first one.

    I returned the
    $domain = $urlinfo[‘host’];
    and changed the ../../wp-blog…. to
    include(“https://somethin-tropical.epaulv.com/wp-blog-header.php&#8221;);

Viewing 15 replies - 16 through 30 (of 55 total)
  • The topic ‘Struggling with Since Last Visit’ is closed to new replies.