fix scroll for iframe (that will be also included on 1.6.5)

Post a reply


This question is a means of preventing automated form submissions by spambots.
Smilies
:D :) ;) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :!: :?: :idea: :arrow: :| :mrgreen: :geek: :ugeek:

BBCode is ON
[img] is ON
[url] is ON
Smilies are ON

Topic review
   

If you wish to attach one or more files enter the details below.

Maximum filesize per attachment: 1 MiB.

Expand view Topic review: fix scroll for iframe (that will be also included on 1.6.5)

Re: fix scroll for iframe (that will be also included on 1.6.5)

by Goofkop » Sat Mar 11, 2017 9:40 am

I just wait for the update. Great work, really like your plugin.

fix scroll for iframe (that will be also included on 1.6.5)

by axew3 » Fri Mar 10, 2017 11:15 pm

i'm just over for a while preparing next coming 1.6.5 release, that will resolve also the scroll to top for iframe on all phpBB links onclick events:

open page-forum.php (or whatever you named it)

search for:

Code: Select all

 if (w3all_pass_login_out == true) {
    window.location.replace('".$w3allhomeurl."/index.php/".$wp_w3all_forum_folder_wp."/'); 
   }
immediately after add this:

Code: Select all

   var w3all_kk  = (w3all_passed_url.indexOf('viewtopic.php') > -1);
   if (w3all_kk == false) {
    window.scrollTo(0, 200);
  }
The page forum will be updated with the above code, and will remove all others calls to:

Code: Select all

window.scrollTo(0, 200);
Adding the above code without removing others calls to window.scrollTo, should return same result, so if like to resolve before 1.6.5, just add this in the while to your page-forum.php-

It has already been added into this running install.
Finally, i've discover it is more easy to remove the scroll behavior for events where it need to not fire, that are only few, instead the contrary!

Top