<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[FrontAccounting forum — User Theme]]></title>
		<link>https://frontaccounting.com/punbb/viewtopic.php?id=6631</link>
		<atom:link href="https://frontaccounting.com/punbb/extern.php?action=feed&amp;tid=6631&amp;type=rss" rel="self" type="application/rss+xml" />
		<description><![CDATA[The most recent posts in User Theme.]]></description>
		<lastBuildDate>Wed, 04 Jan 2017 04:23:35 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: User Theme]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=27325#p27325</link>
			<description><![CDATA[<p>You can use either a hard coded approach (Quick and Dirty) or change the encoding of all the php files to be in the utf-8 character set.</p>]]></description>
			<author><![CDATA[null@example.com (apmuthu)]]></author>
			<pubDate>Wed, 04 Jan 2017 04:23:35 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=27325#p27325</guid>
		</item>
		<item>
			<title><![CDATA[Re: User Theme]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=27314#p27314</link>
			<description><![CDATA[<p>Thanks&nbsp; @APMuthu.</p><p>I actually added it to lang/installed_languages.inc to lang/installed_languages.inc as follows.&nbsp; But it does not work since the language is used before a user is logged in, therefore the user_theme() does not work here. The reason of using the user_theme() is when dashboard theme is used and the encoding is utf-8, some of the wordings (legends, headers) on the charts or tables disappeared.&nbsp; The missing wordings will show up when the encoding is set to &quot;iso-8859-1&quot;.&nbsp; Would you suggest any other work around where I could use utf-8 to handle my chinese character inputs and it does not affect the dashboard charts...&nbsp; Thank you.</p><p><span style="color: blue"><br />include_once($path_to_root . &quot;/includes/current_user.inc&quot;);</span></p><br /><p><span style="color: blue">//$themename=user_theme();<br />$themename=&quot;dashboard&quot;;</span></p><p><span style="color: blue">if ($themename==&#039;dashboard&#039;)<br />{<br />$encoding_0=&quot;iso-8859-1&quot;;<br />//$encoding_0=&quot;utf-8&quot;;<br />}<br />else<br />{<br />$encoding_0=&quot;utf-8&quot;;<br />//$encoding_0=&quot;iso-8859-1&quot;;<br />} </span></p><br /><p><span style="color: blue">$installed_languages = array (<br />&nbsp; 0 =&gt; <br />&nbsp; array (<br />&nbsp; &nbsp; &#039;code&#039; =&gt; &#039;C&#039;,<br />&nbsp; &nbsp; &#039;name&#039; =&gt; &#039;English&#039;,<br />&nbsp; &nbsp; &#039;encoding&#039; =&gt; $encoding_0,&nbsp; &nbsp; </span></p><p><span style="color: blue">&nbsp; ), </span></p>]]></description>
			<author><![CDATA[null@example.com (mark0300)]]></author>
			<pubDate>Mon, 02 Jan 2017 05:37:11 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=27314#p27314</guid>
		</item>
		<item>
			<title><![CDATA[Re: User Theme]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=27305#p27305</link>
			<description><![CDATA[<p>You need to be logged in as the said user before it can get it.</p><p>The said function is defined in lines 489-493 of <strong>includes/current_user.inc</strong><br /></p><div class="codebox"><pre><code>function user_theme()
{
    return isset($_SESSION[&quot;wa_current_user&quot;]) ?
        $_SESSION[&quot;wa_current_user&quot;]-&gt;prefs-&gt;get_theme() : &#039;default&#039;;
}</code></pre></div>]]></description>
			<author><![CDATA[null@example.com (apmuthu)]]></author>
			<pubDate>Sun, 01 Jan 2017 17:43:29 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=27305#p27305</guid>
		</item>
		<item>
			<title><![CDATA[User Theme]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=27289#p27289</link>
			<description><![CDATA[<p>Hi,</p><p>Is there a function that I could use to retrieve the current user&#039;s theme?</p><p>I have found user_theme(), but the value retrieve does not seem to be correct.</p><p>Here is the code:<br /><em><span style="color: blue"><br />include_once($path_to_root . &quot;/includes/current_user.inc&quot;);</span></em></p><p><span style="color: blue"><em>$themename=user_theme();</em></span></p><p><span style="color: blue"><em>if ($themename==&#039;dashboard&#039;)<br />{</p><p>echo &quot;this is dashboard&quot;;</p><p>}<br />else<br />{<br />echo &quot;this is not dashboard&quot;;<br />} <br /></em></span></p><br /><p>Could someone advise?</p><p>Thank you.</p><p>/Mark</p>]]></description>
			<author><![CDATA[null@example.com (mark0300)]]></author>
			<pubDate>Fri, 30 Dec 2016 11:43:13 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=27289#p27289</guid>
		</item>
	</channel>
</rss>
