Pagination Does Not Work Correctly

Admiror Gallery is free extension for Joomla! 1.6. Joomla! 1.7 and Joomla! 2.5 based websites. Admiror Gallery is all in one, a simple and instant solution for rendering image gallery from folder with images, but very flexible and adaptable.
Post Reply
Message
Author
johnsonmktg
Posts: 2
Joined: Mon Dec 10, 2012 4:30 pm

Pagination Does Not Work Correctly

#1 Post by johnsonmktg »

I have installed the Gallery, and set it up with pagination. However, the links to additional pages of each gallery simply direct to the home page. http://centralfloridaweddinggroup.com/i ... to-gallery How do I get the pagination to point to the next page of the album instead of going to the home page?

Admiror Gallery 5 - Fundraising Campaign

User avatar
Vasiljevski
Developer
Developer
Posts: 1258
Joined: Sat Aug 14, 2010 9:31 pm
Location: Novi Sad, Serbia
Contact:

Re: Pagination Does Not Work Correctly

#2 Post by Vasiljevski »

Well I see what the problem is. Code needed, for pagination to work, is not included in your page.
In your output HTML there should be something like this:

Code: Select all

<script type="text/javascript">
            function AG_form_submit_1(galleryIndex,paginPage,albumFolder,linkID) {

            var AG_URL="/joomla258/index.php/gallery?AG_MK=0&AG_form_paginInitPages_1=1&AG_form_albumInitFolders_1=parks/landscape&AG_form_scrollTop=171&AG_form_scrollLeft=0&AG_MK=0";
            var split = AG_URL.split("AG_MK=0");
            if(split.length==3){
                AG_URL = split[0]+split[2];
            }
            var char = AG_URL.charAt((AG_URL.length)-1);
            if ((char != "?") && (char != "&"))
            {
                AG_URL += (AG_URL.indexOf("?")<0) ? "?" : "&";
            }
            AG_URL+="AG_MK=0&";

            AG_jQuery(".ag_hidden_ID").each(function(index) {

                var paginInitPages=eval("paginInitPages_"+AG_jQuery(this).attr('id'));
                var albumInitFolders=eval("albumInitFolders_"+AG_jQuery(this).attr('id'));

                if(AG_jQuery(this).attr('id') == 1){
                    var paginInitPages_array = paginInitPages.split(",");
                    paginInitPages_array[galleryIndex] = paginPage;
                    paginInitPages = paginInitPages_array.toString();
                    var albumInitFolders_array = albumInitFolders.split(",");
                    albumInitFolders_array[galleryIndex] = albumFolder;
                    albumInitFolders = albumInitFolders_array.toString();
                }
                AG_URL+="AG_form_paginInitPages_"+AG_jQuery(this).attr('id')+"="+paginInitPages+"&";
                AG_URL+="AG_form_albumInitFolders_"+AG_jQuery(this).attr('id')+"="+albumInitFolders+"&";
            });

            AG_URL+="AG_form_scrollTop"+"="+AG_jQuery(window).scrollTop()+"&";
            AG_URL+="AG_form_scrollLeft"+"="+AG_jQuery(window).scrollLeft()+"&";

            AG_URL+="AG_MK=0";

            window.open(AG_URL,"_self");

            }
            </scrip
Do you, maybe have, some plugin that cleans the HTML code? Or some option in you template to disable adding <script> element?
Help Admiror Gallery become even better,
give us a review on JED

johnsonmktg
Posts: 2
Joined: Mon Dec 10, 2012 4:30 pm

Re: Pagination Does Not Work Correctly

#3 Post by johnsonmktg »

I don't have a plugin or module that does that that I'm aware of... but i think i'm just going to turn off the pagination anyway and decrease the number of photos in each album... the number of photos is causing the site to load extremely slowly.

User avatar
Vasiljevski
Developer
Developer
Posts: 1258
Joined: Sat Aug 14, 2010 9:31 pm
Location: Novi Sad, Serbia
Contact:

Re: Pagination Does Not Work Correctly

#4 Post by Vasiljevski »

You could divide images into albums, I don't know if that is acceptable for you but its just an idea to consider ;)
Help Admiror Gallery become even better,
give us a review on JED

Post Reply