Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1095769
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T00:10:41+00:00 2026-05-17T00:10:41+00:00

Here is the home page for the popular jquery-plugin galleria . I need to

  • 0

Here is the home page for the popular jquery-plugin galleria. I need to insert the download link to the right bottom corner for the active image. Now there is available statistic like (3/10), which indicates the current number from list.
Maybe someone already did this. What is the fastest way?


UPD: using the gearsdigital’s idea I wrote the code:

var gallery = Galleria.get(0);

gallery.bind(Galleria.IMAGE, function(e) {
    imgHandle = e.imageTarget;
    console.log(imgHandle);
    console.log(imgHandle.attr('href'));
    //$('.galleria-counter').append('<a href="'+imgHandle.attr('src')+'">Download</a>');
});

The first log line shows up something like:

<img width="584" height="438" src="http://....jpg" style="display: block; position: relative; left: 0px; top: -4px; opacity: 1;">

But how to get the src location, I see the error that attr function isn’t available.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T00:10:42+00:00Added an answer on May 17, 2026 at 12:10 am

    I would try to get the current Source-Attribute from the current image and append this as link.

    //Untested. This is just a suggestion :)
    currentImageSource = $('.galleria-image img').attr('src');  
    $('.galleria-counter').append('<a href="'+currentImageSource+'">Download</a>');
    

    But a link like this will open the image separatly and not download ordinary. If you want a “real” Download you have to put this image in an zip archive.

    $('.galleria-counter').append('<a href="'+currentImageSource+'.zip">Download</a>');
    

    This will produce something like that: http://www.example.com/galleria/img/mygreatimage.jpg.zip

    Works for me:

    <!DOCTYPE html>
    <html>
        <head>
            <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
            <title>Example</title>
            <script type="text/javascript" src="http://code.jquery.com/jquery-1.4.2.min.js"></script>
    
            <script type="text/javascript">
                $(document).ready(function() {
    
                    currentImageSource = $('.container img').attr('src');  
                    $('.placeholder').append('<a href="'+currentImageSource+'">Download</a>');
    
                });
    
            </script>
        </head>
    
        <body>
            <div class="container">
                <h2>Get img src</h2>
                <img src="http://www.duba.at/wp-content/uploads/2007/08/bild_0570000.jpg" witdh="200" height="220"/>
            </div>
    
            <div class="placeholder">
                <h2>Append Here</h2>
            </div>
    
        </body>
    </html>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

File: /home/USER/DIR/a http://www.here.is.a.hyper.link.net/ /home/USER/DIR/b http://www.here.is.another.hyper.link.net/ Need to remove all the odd lines in this
I have a div on my home page which uses a jQuery plugin called
We have a news roller here http://www.businesseventsydney.com.au/home-page-test.cfm in the right nav column. It works
Here are the tabs in the master page: <nav> <ul id=menu> <li><%: Html.ActionLink(Home, Index,
Here is my jQuery code: $.get('/Home/GetList', function(data) { debugger; $('#myMultiSelect').val(data); }); Here is my
I have this hyperlink called SEND in a ASP page called Home and here
I have created a new template phtml file 2columns-right-home.phtml for home page of my
I am using the SlidesJS plugin to create a slideshow on my home page.
How can I have the active link highlighted when clicked but keep the home
Ok, I have a wordpress theme installed here (www.sullivansuccesscoaching.com/home ...we need the /home because

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.