MyBB Community Forums
[Rejected] [Issue] Default theme template output in xmlhttp.php?action=get_buddyselect - Printable Version

+- MyBB Community Forums (https://community.mybb.com)
+-- Forum: Development (https://community.mybb.com/forum-161.html)
+--- Forum: MyBB 1.8 Development (https://community.mybb.com/forum-165.html)
+---- Forum: 1.8 Bugs and Issues (https://community.mybb.com/forum-157.html)
+----- Forum: Rejected (https://community.mybb.com/forum-184.html)
+----- Thread: [Rejected] [Issue] Default theme template output in xmlhttp.php?action=get_buddyselect (/thread-157658.html)



[Issue] Default theme template output in xmlhttp.php?action=get_buddyselect - Johnny S - 2014-08-17

After revamping private_send template i have noticed that buddy select popup content remains the same even if xmlhttp_buddy template contains completely different code (divs instead of tables). Once i have looked at source code i have noticed that that template (xmlhttp_buddy) still outputs default template content. After looking at  xmlhttp.php?action=get_buddyselect default theme template content was still there (regardless of what content was in xmlhttp_buddyselect in my custom theme). Basically: regardless what theme user has selected in UserCP  xmlhttp.php?action=get_buddyselect will output xmlhttp_buddy template content from the theme that is set as default.


RE: [Issue] Default theme template output in certain areas (xmlhttp_buddy) - Johnny S - 2014-08-17

After digging around in xmlhttp.php i have made following edit (same code is used in global.php - beta 3)

xmlhttp.php line 79 - 89

from


// Load basic theme information that we could be needing.
if($loadstyle == "def='1'")
{
if(!$cache->read('default_theme'))
{
 $cache->update_default_theme();
 }
$theme = $cache->read('default_theme');
}
$theme = @array_merge($theme, my_unserialize($theme['properties']));

to
// Load basic theme information that we could be needing.
if($loadstyle == "def='1'")
{
	if(!$cache->read('default_theme'))
	{
		$cache->update_default_theme();
	}
	$theme = $cache->read('default_theme');
}
else 
{
	$query = $db->simple_select('themes', 'name, tid, properties, stylesheets', $loadstyle, array('limit' => 1));
	$theme = $db->fetch_array($query);
}

$theme = @array_merge($theme, unserialize($theme['properties']));



RE: [Issue] Default theme template output in xmlhttp.php?action=get_buddyselect - Eldenroot - 2014-08-17

Johnny - dont you wanna fix and make a pull request for all your issues? You made about 5 or more thread with working solution... it needs to be just pulled to mybb git. It needs some discussion with MyBB dev team - coordinate work and make a decision - 1.8.0 or 1.8.1?


RE: [Issue] Default theme template output in xmlhttp.php?action=get_buddyselect - Jones H - 2014-08-17

I reported this already and made a PR for it Wink


RE: [Issue] Default theme template output in xmlhttp.php?action=get_buddyselect - Johnny S - 2014-08-17

Quote:Johnny - dont you wanna fix and make a pull request for all your issues? You made about 5 or more thread with working solution... it needs to be just pulled to mybb git. It needs some discussion with MyBB dev team - coordinate work and make a decision - 1.8.0 or 1.8.1?

It's not up to me to decide if a issue is going to be pushed on github or it will be labeled for 1.8 or 1.8.1. If a PR for opened issue is opened and that issue is labeled with 1.8.1 that request won't be included in 1.8.

@Jones H just saw your issue on github https://github.com/mybb/mybb/issues/1208

This thread can be closed (or junked).