by axew3 » Sun Nov 29, 2020 12:20 am
the way was easy, but there is a problem:
class unreadpost, when the forum page display, do not exist anymore, because reversing things i see that this happen:
when the overall_header.html added code fire, that reload pointing to wordpress page, and that run because direct link to board detected, at this point, phpBB already processed all the code that then, set as read the post, and then when iframe load in WP page, class unreadpost is not existent anymore on DOM. So at moment, i think that better than the proposed solution, there is no solution.
... a solution ever exist.
So may let overall_header.html to not fire, when unread detected, leaving the page to follow to the overall_footer.html code, where hash then is possible to be grabbed: then get the value, assign it to a var, that when passed (with the redirect that will fire at this point), will scroll the page forum to the iframe position, exactly where it need to be. It seem to me there is no other possible solution (without changing something into phpBB php code that process the part on top of all this, that's really not a convenient reliable solution, even if maybe there is a listener that could be used for the scope). The page forum code need to be changed to accomplish with this, to scroll it to the passed value.
The problem is that this solution let the phpbb forum display for a while, because the js redirect done on footer and not header.
the way was easy, but there is a problem:
class [i]unreadpost[/i], when the forum page display, do not exist anymore, because reversing things i see that this happen:
when the overall_header.html added code fire, that reload pointing to wordpress page, and that run because direct link to board detected, at this point, phpBB already processed all the code that then, set as read the post, and then when iframe load in WP page, class unreadpost is not existent anymore on DOM. So at moment, i think that better than the proposed solution, there is no solution.
[b]... a solution ever exist.[/b]
So may let overall_header.html to not fire, when unread detected, leaving the page to follow to the overall_footer.html code, where hash then is possible to be grabbed: then get the value, assign it to a var, that when passed (with the redirect that will fire at this point), will scroll the page forum to the iframe position, exactly where it need to be. It seem to me there is no other possible solution (without changing something into phpBB php code that process the part on top of all this, that's really not a convenient reliable solution, even if maybe there is a listener that could be used for the scope). [strike]The page forum code need to be changed to accomplish with this, to scroll it to the passed value.[/strike]
The problem is that this solution let the phpbb forum display for a while, because the js redirect done on footer and not header.