WordPress.org

Ready to get started?Download WordPress

Forums

[Plugin: NextGEN Gallery]: Removing link to image file from Image Browser page (7 posts)

  1. mfuchs
    Member
    Posted 5 years ago #

    Hi all,

    I am using NextGEN Gallery to display the image browser page as galleries on my blog. Everything works fine.

    However, the image on the image browser page actually links to the image file. I would like to remove that link but didn't find out where to do that.
    Could anybody point me to the right PHP file to edit in order to remove that link?

    Thanks a lot,
    Martin

  2. mfuchs
    Member
    Posted 5 years ago #

    Could anybody maybe help with this?

  3. bee dudler
    Member
    Posted 5 years ago #

    Hi,
    i think you should take advantage of the new template functionality http://nextgen.boelinger.com/templates/ for keeping your changes after update of ngg. In your case make a copy of the image browser rename it, change it to your needs, put as told in the link above.

    best regards
    bee

  4. kasxx
    Member
    Posted 4 years ago #

    I am facing the same problem...Anyone who know if it is possible to fix it by changing nggfunctions or imagebrowser?

  5. nieohne
    Member
    Posted 4 years ago #

    Hi, to remove the link replace the following code in the imagebrowser.php file :

    orig:
    <div class="pic"><?php echo $image->href_link ?></div>

    replace with:
    <div class="pic"><?php echo $image->imageURL ?></div>

  6. Hélio Cristóvão
    Member
    Posted 4 years ago #

    However, the image on the image browser page actually links to the image file. I would like to remove that link but didn't find out where to do that.

    Exactly what I was looking for. Great.
    I´ll try it out.

    I would like to remove the link to the original image file, but also modify it and link - when clicking the image - back to the imagebrowser gallery. That would be really nice.
    Thanks.

  7. kasxx
    Member
    Posted 4 years ago #

    @ heliocristovao - I think this is what you are looking for:

    orig:
    <div class="pic"><?php echo $image->href_link ?></div>

    replace with:

    <div class="pic"><a href="<?php echo "?album=3&gallery=". $image->galleryid ."&nggpage=". ceil($image->number/9) ?>">
    <img src="<?php echo $image->imageURL ?>" /></a></div>

    If you just would like to remove the link, just replace:

    <div class="pic"><?php echo $image->href_link ?></div>

    with:
    <div class="pic"><img src="<?php echo $image->imageURL ?>" /></div>

Topic Closed

This topic has been closed to new replies.

About this Topic