I want to add a multitheme support to my CMS website, but I don't know how can I do it in a professional way.
My system differs PHP and HTML codes completely. For example:
test.php file
Code: Select all
LoadTemplate('test.tpl', array('MSG1' => 'Merhaba, 'MSG2' => 'Blahblah));
test.tpl file
Code: Select all
<h2><&MSG1></h2>
<h3><&MSG2></h3>
Additionally, users can change their THEME path via configuration file.
config.php
Code: Select all
$config['THEME_PATH'] = 'theme/theme_1/';
My question is;
How can I add multitheme support in the most professional way?
For example, if I add theme_2, theme_3 and so on, I will have to define MSG3 if I ever add it on ALL theme files.
I am going to have 30+ theme support so it will be really complicated in the future.
How multitheme support can be handled professionally? I never used Wordpress and so on. How do they handle it?
Will be glad if you help,
Thanks.