Not signed in (Sign In)

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

    • CommentAuthorcderring
    • CommentTimeAug 7th 2009
     
    Greetings all,
    Hoping I can get some guidance on an issue I am seeing in my Plogger install.
    When browsing the album, the "Collections" link does not take visitors back to ../PhotoAlbum/index.php. I would assume that it is supposed to strip off the characters after index.php so that the visitor get sent back to the root of the photo album, but in my case it leaves everything on after the .php (../index.php?level=picture&id=2)
    Now I know next to nothing about php scripting, but I follow directions REALLY well.
    Will some one please point me in the right direction to change the behavior of the "Collections"

    Thanks,
    Chad
    •  
      CommentAuthorxiphias
    • CommentTimeAug 13th 2009
     
    I'm having a simular problem with my installation of Plogger 1.0-RC1 svn601. I've installed plogger in /plogger and I'm calling plogger from Joomla in a wrapper.
    The links generated in Plogger all point to the root eg. ?level=picture&id=1 for a medium image view, ?level=album&id=1 for a album or ?level=collection&id=1 for an collection.
    This should be the same path as /plogger/plogger.php. When I follow a link in Plogger my site is loaded into the iframe.

    On an other site i'm running Plogger 1.0 beta 3.0 and it had a simular problem generating index.phpimages/.... like stated above. I found something on the forum for this but this looks different from the new setup of svn601.

    Any help is welcome.
    •  
      CommentAuthorxiphias
    • CommentTimeAug 13th 2009
     
    Well, think I found something for 1.0-RC1-601, in plog-load-config.php go to line 66 and you'll see:
    $config['baseurl'] = 'http://'.$_SERVER['HTTP_HOST'].$url_parts['path'];

    Line 86 and 100 have
    $config['baseurl'] = 'http://'.$_SERVER['HTTP_HOST'].substr($_SERVER['PHP_SELF'], 0, strrpos($_SERVER['PHP_SELF'], '/')).'/';

    I changed line 66 to what lines 86 and 100 have and my gallery seems to work ok now.
    • CommentAuthorcderring
    • CommentTimeAug 13th 2009
     
    Well I'm not sure which version I'm running.
    I looked in plog-load-config.php and did not find the line "$config['baseurl'] = 'http://'.$_SERVER['HTTP_HOST'].$url_parts['path'];"
    Here are the $config['baseurl'] lines and their line number that I found:
    Line 29: $config["baseurl"] = $url_parts["path"];
    Line 42: $config["baseurl"] = "http://".$_SERVER["HTTP_HOST"]. substr($_SERVER["PHP_SELF"],0,strrpos($_SERVER["PHP_SELF"],"/")) . "/";
    Line 46: if (substr($config["baseurl"],-6) == "admin/") {
    Line 47: $config["baseurl"] = substr($config["baseurl"],0,-6);

    Like I said, my php skills are laking, but line 42 (on my server) looks just like xiphias server.
    Should I replace my line 29 with my line 42?

    Thanks
    • CommentAuthorcderring
    • CommentTimeAug 21st 2009
     
    Bump
    • CommentAuthorcderring
    • CommentTimeOct 11th 2009
     
    Anyone?
    Here is what my current plog-load-config looks like
    <?php

    // this file will load all the configuration elements from the database
    // and place them into a global associative array called $config

    $config = array();
    $thumbnail_config = array();

    $plog_basedir = dirname(__FILE__).DIRECTORY_SEPARATOR;

    require_once($plog_basedir."plog-globals.php");
    require_once($plog_basedir."plog-functions.php");
    require_once($plog_basedir."plog-config.php");
    connect_db();


    $query = "SELECT * FROM `".TABLE_PREFIX."config`";
    $result = mysql_query($query) or die(mysql_error() .'

    '.$query);

    if (mysql_num_rows($result) == 0){
    die("No config information in the database.");
    }

    $config = mysql_fetch_assoc($result);

    $config["basedir"] = $plog_basedir;

    $url_parts = parse_url($_SERVER["REQUEST_URI"]);
    $config["baseurl"] = $url_parts["path"];

    $config["embedded"] = 0;

    // try to figure out whether we are embedded (for example running from Wordpress)
    // on windows/apache $_SERVER['PATH_TRANSLATED'] uses "/" for directory separators,
    // __FILE__ has them the other way, realpath takes care of that.
    if (dirname(__FILE__) != dirname(realpath($_SERVER["PATH_TRANSLATED"])) && strpos($_SERVER["PATH_TRANSLATED"],"admin") === false) {
    $config["embedded"] = 1;
    // disable our own cruft-free urls, because the URL has already been processed
    // by WordPress
    $config["use_mod_rewrite"] = 0;
    } else {
    $config["baseurl"] = "http://".$_SERVER["HTTP_HOST"]. substr($_SERVER["PHP_SELF"],0,strrpos($_SERVER["PHP_SELF"],"/")) . "/";
    }

    // remove admin/ from the end, if present .. is there a better way to determine the full url?
    if (substr($config["baseurl"],-6) == "admin/") {
    $config["baseurl"] = substr($config["baseurl"],0,-6);
    }

    $config["theme_url"] = $config["gallery_url"]."themes/".basename($config["theme_dir"])."/";
    $config['charset'] = 'utf-8';
    $config['version'] = 'Version 3.0 Beta';

    // charset set with HTTP headers has higher priority that that set in HTML head section
    // since some servers set their own charset for PHP files, this should take care of it
    // and hopefully doesn't break anything

    if (!headers_sent()){
    header('Content-Type: text/html; charset=' . $config['charset']);
    }

    $query = "SELECT * FROM `".TABLE_PREFIX."thumbnail_config`";
    $result = mysql_query($query) or die(mysql_error() .'

    '.$query);

    if (mysql_num_rows($result) == 0){
    die("No thumbnail config information in the database.");
    }

    $prefix_arr = array(1 => '',2 => 'lrg-',3 => 'rss-',4 => 'tn-');

    while($row = mysql_fetch_assoc($result)) {
    $thumbnail_config[$row['id']] = array(
    'filename_prefix' => $prefix_arr[$row['id']],
    'size' => $row['max_size'],
    'timestamp' => $row['update_timestamp'],
    'disabled' => $row['disabled']);
    }

    // debugging function
    function display_uservariables(){
    foreach ($config as $keys => $values) {
    echo "$keys = $values
    ";
    }
    }

    if (!isset($_SESSION["plogger_sortby"])){
    $_SESSION["plogger_sortby"] = $config['default_sortby'];
    }

    if (!isset($_SESSION["plogger_sortdir"])){
    $_SESSION["plogger_sortdir"] = $config['default_sortdir'];
    }

    if (!isset($_SESSION["plogger_details"])){
    $_SESSION["plogger_details"] = 0;

    }

    ?>

    My collections link on the webpages does still not link back to the root.
    Take a look at what I'm talking about by visiting http://www.vp4association.com/PhotoAlbum/
    • CommentAuthorokayteds
    • CommentTimeOct 19th 2009
     
    is the problem solved cderring , i too have the same problem now, any help wd be appreciated
    • CommentAuthorcderring
    • CommentTimeOct 23rd 2009
     
    No the collections link still does not work.
  1.  
    I also have a collection links proplem, not sure though if it is due to the fact that my collections have now gone to 2 pages?

    If i go directly into one of my plogger albums from a webpage link that is fine (http://www.geulogy.com/introdis-snakeplissken.html clicking on "Look at DIS!" in menu on left hand side). For example http://www.electricyouniverse.com/eye/index.php?level=album&id=116 takes me directly to that album. From there clicking on the clicking on that albums collection title takes me to collection page http://www.electricyouniverse.com/eye/index.php?level=collection&id=26 and they work fine from there.

    I then click on collections and it takes me to http://www.electricyouniverse.com/eye/index.php and clicking on any collection on page 1 works as normal.

    As soon as i go to page 2 of my collections the url changes to http://www.electricyouniverse.com/eye/&plog_page=2 and now i can not access the collection on this page. When i click on it the url is http://www.electricyouniverse.com/eye/&plog_page=2 and nothing happens, i can not access the collection or albums in there.

    And now when i go back to page 1 the url changes to http://www.electricyouniverse.com/eye/&plog_page=1 and i can not access any of the collections. Clicking on any collection gives me a url of http://www.electricyouniverse.com/eye/&plog_page=1?level=collection&id=30 but all this does is change the url but i keep on the index page.

    Please ask if you need any other information to help you or me with this and thanks for any help with this matter.
  2.  
    It certainly appears to be the page 2 URL thing. I reduced the collections down to one page and it works fine but as soon as i increase to 2 pages of collections the 2nd page collections do not work. Even though you click on them you can not view the albums, although the URL changes, you stay on the same page.
    •  
      CommentAuthorsidtheduck
    • CommentTimeOct 28th 2009
     
    Lightning slow,

    We just released a new stable version of Plogger last night, Plogger 1.0-RC1. You should download that version and upgrade your current version to see if that fixes your "Collections" link issue.