Page 2 of 2

Re: Patches V3 code: page-forum.php, overall_footer.html and overall_header.html JS code

Posted: Sat Jan 05, 2019 7:34 pm
by axew3
Ok xray after have been noticed about what was going on wrongly and better to report this to be clear on procedure ... he had in
phpBB ACP
under option Security settings
option: Allow "Remember Me" logins:
it was set to NO.
But this option need to be set as YES or when user login no cookie will be released, nor recognized if presented, so logout will fire on both cms: phpBB because not will recognize the eventually released on wp login by the plugin, and WordPress because no valid phpBB found.
It has been added on installation procedure.

except this,
the overall_header.html and overall_footer.html v3 JS code has been patched because it was hard for all to access ACP when iframe activated, and for several other reasons:
now the code has been changed to:
when phpBB admin ACP link clicked, new page will be opened if clicked within iframe.
when acp page, login or ACP admin, accessed via direct url, equally, it will be opened as called, external, no redirect to iframe will fire.
That will make the situation more clear and useful for all.

Re: Patches V3 code: page-forum.php, overall_footer.html and overall_header.html JS code

Posted: Tue Jan 08, 2019 5:08 pm
by axew3
the page-forum.php forum (1.9.4) for v3 code has been patched (over last patch):
I’m go to apply something into a site and i see that there is still a little problem on code:
on this actual fix, after applied overall_header.html code, when you right/click/open new tab/window (and only on right click) to open a link like FAQ link, the code will fail because:
the code will append index.php and the url will become something like this:
https://192.168.1.5/forum/app.php/help/faq/index.php
and with index.php appended in this kind of url phpBB will answer page not found.
To avoid this (maybe this code can be better but actually work without big changes) the code should be changed into this:

Code: Select all

if( strlen($w3all_url_to_cms) == strlen(get_option( 'w3all_url_to_cms' )) OR strlen($w3all_url_to_cms) == strlen(get_option( 'w3all_url_to_cms' )) + 1 )
{
// Fix by @tlagren
// bug -> https://wordpress.org/support/topic/problem-using-iframe-feature-with-https/
$w3all_url_to_cms .= (substr($w3all_url_to_cms, -1) == '/' ? '' : '/index.php');
}
now should be any kind of passed url compatible and when FAQ like (app) links passed, or SEO url passed, the result will be fine. The fix has been committed on repo for the file page-forum.php