Forum moderator: bigblog |
uCoz Community For Webmasters Custom Solutions New page auto load when scrolling down |
New page auto load when scrolling down |
VZ, I well give a try on $MODULE_ID$.
-------------------------------------------------------- I think this url '/$MODULE_ID$/0-' is for publ module only. since 0- is publ entry. This is the whole url of an entry: 41-1-0-307 41- <<-- category ID 1- 0- <<-- publ entry 307- <<--entry ID and I'm sure of it. 1F4BF3B
Post edited by Cyberdasm - Friday, 2017-01-20, 7:07 AM
|
I think this url '/$MODULE_ID$/0-' is for publ module only. since 0- is publ entry. I tried it out on Photos. It works but I do not know on how many pages. In addition it worked out on the main page of the file catalog module. Would need a little modification for Videos, it appears it would work on the Publisher module as well. to make it work on the video module change this Code nextik = $("#selector").find(".swchItem:contains('»')").attr('href'); to Code nextik = $("#selector").find(".swchItem:contains('»')").attr('onclick').toString(); Hit that "Thanks" button. :)
In life there's ALWAYS limits but do not plan above them. Post edited by VZ - Friday, 2017-01-20, 7:11 AM
|
Cyberdasm, http://flatdesign101.cf/photo/
Hit that "Thanks" button. :)
In life there's ALWAYS limits but do not plan above them. |
This is the whole url of an entry: 41-1-0-307 41- <<-- category ID 1- 0- <<-- publ entry 307- <<--entry ID and I'm sure of it. Yes it is. However, I played around with the page selectors and at least two sections and 2 categories in one section. Hit that "Thanks" button. :)
In life there's ALWAYS limits but do not plan above them. |
VZ, I see you trigger the pagination in my case I trigger the url...
Kudos for improving the script. Maybe I'm to narrow minded since I only stick on the url. +1 rep. Added (2017-01-20, 7:32 AM) Yes it worked in publ module. since the get is 'publ/0-'+num 1F4BF3B
Post edited by Cyberdasm - Friday, 2017-01-20, 7:24 AM
|
VZ, on your demo page the script works so well..but i dont know why on mine its taking forever to load another page. I dont know whats happening here...could you help please...... The photo mopdule
Added (2017-01-21, 7:04 AM) Systems developer
|
VZ, on your demo page the script works so well..but i dont know why on mine its taking forever to load another page. I dont know whats happening here...could you help please...... The photo mopdule Added (2017-01-21, 7:04 AM) --------------------------------------------- Click here and see whats happening. Nothing at all.... sad sad The problem is with my updated script. It should work really good on the home page. Since this is the category/section page it takes the last number from $URI_ID$...I will see if I can get it fixed. Since the that category has an ID of 80 it takes only 0 from it because its the last digit. Change Code <?substr($URI_ID$,-1)?> to Code <?substr($URI_ID$,5)?> Added (2017-01-23, 1:06 AM) --------------------------------------------- Code <div id="conter">$BODY$</div> <div class="selector" id="selector" style="display:none">$PAGE_SELECTOR$</div> <script type="text/javascript"> if ($("#selector").find(".swchItem:contains('»')").text() == '»') { $("#selector").after('<div id="nextCont" class="input_submit alt"><div class="u_pos"></div></div>'); }; $(window).scroll(function() { if($(".u_pos").length != 0) { if($('.u_pos').position().top-$(window).scrollTop() < 1000) { Conte.to() } } }); Conte = { to:function(){ $("#nextCont").html('<div align="center"><img src="/.s/img/icon/ajsml.gif" border="0" /></div>'); nextik = $("#selector").find(".swchItem:contains('»')").attr('href'); if(nextik !=undefined) { <?ifnot($PAGE_ID$ == "main" || $PAGE_ID$ == "main_page" )?> num = nextik.split(/\s*-\s*/)[1]; <?else?> num = nextik.match(/\d/); <?endif?> $.get('/$MODULE_ID$/<?ifnot($PAGE_ID$ == "main")?><?substr($URI_ID$,5)?><?else?>0<?endif?>-'+num, function(next){ $("#conter").append( $("#conter", next).html() ); $("#selector").html( $("#selector", next).html() ); $("#nextCont").html('<div class="u_pos"></div>'); if ($("#selector", next).find(".swchItem:contains('»')").html() == null) { $("#nextCont").fadeOut(); }; }); } } } </script> Hit that "Thanks" button. :)
In life there's ALWAYS limits but do not plan above them. Post edited by VZ - Monday, 2017-01-23, 1:07 AM
|
VZ, please provide me your paypal email. Looks like you have solved all the problems in my life So how i can i make this code work on the page of users entries and search results plus the blog, news and video module as well?
Systems developer
|
VZ,
The problem is with my updated script. It should work really good on the home page. Since this is the category/section page it takes the last number from $URI_ID$...I will see if I can get it fixed. Since the that category has an ID of 80 it takes only 0 from it because its the last digit. I don't quite understand on where did you get the 80. Could you please explain a little bit about it? 1F4BF3B
|
Cyberdasm, i think the 80 is the category ID of the cat link i provided.
Quote Click here and see whats happening. Nothing at all.... sad sad Systems developer
|
I don't quite understand on where did you get the 80. Could you please explain a little bit about it? paypal: paypal.me/nmaksymchuk 80 comes from his category/section id, the demo he provided http://u.to/6NeqDw Update: Didn't realize soldier devil has answered the question. Added (2017-01-23, 9:13 PM) --------------------------------------------- Blog: page-0-cid/sid Code <div id="conter">$BODY$</div> <div class="selector" id="selector" style="display:none">$PAGE_SELECTOR$</div> <script type="text/javascript"> if ($("#selector").find(".swchItem:contains('»')").text() == '»') { $("#selector").after('<div id="nextCont" class="input_submit alt"><div class="u_pos"></div></div>'); }; $(window).scroll(function() { if($(".u_pos").length != 0) { if($('.u_pos').position().top-$(window).scrollTop() < 1000) { Conte.to() } } }); Conte = { to:function(){ $("#nextCont").html('<div align="center"><img src="/.s/img/icon/ajsml.gif" border="0" /></div>'); nextik = $("#selector").find(".swchItem:contains('»')").attr('href'); if(nextik !=undefined) { <?ifnot($PAGE_ID$ == "main" || $PAGE_ID$ == "main_page" )?> num = nextik.split(/\s*-\s*/)[1]; <?else?> num = nextik.match(/\d/); <?endif?> $.get('/$MODULE_ID$/'+num+ '-0-<?ifnot($PAGE_ID$ == "main")?><?substr($URI_ID$,5)?><?else?>0<?endif?>/', function(next){ $("#conter").append( $("#conter", next).html() ); $("#selector").html( $("#selector", next).html() ); $("#nextCont").html('<div class="u_pos"></div>'); if ($("#selector", next).find(".swchItem:contains('»')").html() == null) { $("#nextCont").fadeOut(); }; }); } } } </script> Hit that "Thanks" button. :)
In life there's ALWAYS limits but do not plan above them. Post edited by VZ - Monday, 2017-01-23, 9:14 PM
|
VZ, sorry was off. Please accept payments i am getting errors. The last code you provided does not seem to work in the blog module. If at all i would make it work for the blog and site news plus video...actually all modules. That would be great.
Systems developer
|
| |||