CMS.txt Notes

http://d.interjc.net/cms.txt/ – Japanese?

Basic Setup

/* -------- Notes -------- */
index: home
note_1: The Options Array ($o in _parseWebsite) allows for changing the default index page.
note_2: Creating your own section for notes.
note_3:
_parsePanel
_parseWebsite
_parseNavigation
_parsePage
_htmlAllNavigation

// Parcing Flow //

_replace('content',$page,$theme);
$theme=preg_replace('/(href|src)="\.\./','$1="'.'themes/'.$current['opts']['theme'],$theme); // Replace ancher and image URLs that have .. with themes/

foreach($p['html'] as $a=>$b)
	_replace($a,$b,$theme);

foreach($current['opts'] as $a=>$b)
	if(is_string($b))
		_replace($a,$b,$theme);

foreach($p['website']['opts'] as $a=>$b)
	if(is_string($b))
		_replace('site-'.$a,$b,$theme);

1. Replace CONTENT tag in the theme template with the page template.
2. Replace HTML (navigation-sitemap, navigation-breadcrumb, navigation-level-1, navigation-siblings, navigation-level-2, navigation-children) tags in theme content.
3. Replace current page options that are string tags in theme content.
4. Replace website options that are string tags in theme content. 

Array
(
    [website] => Array
        (
            [name] => VTech Hospitality
            [opts] => Array
                (
                    [missing] => 404
                    [theme] => vtech
                    [template] => index.html
                    [name] => VTech Hospitality
                    [vtech] => hospitality
                    [index] => index
                )

            [page] => index
            [index] => index
        )

    [sitemap] => Array
        (
            [index] => Array
                (
                    [name] => Home
                    [deep] => 0
                    [opts] => Array
                        (
                            [name] => Home
                        )

                    [current] => 1
                    [selected] => 1
                )

            [products] => Array
                (
                    [name] => Products
                    [deep] => 0
                    [opts] => Array
                        (
                            [name] => Products
                            [hidden] => 1
                        )

                )

            [analog_phones] => Array
                (
                    [name] => Analog Phones
                    [deep] => 0
                    [opts] => Array
                        (
                            [name] => Analog Phones
                        )

                    [kids] => Array
                        (
                            [all_analog_phones] => Array
                                (
                                    [name] => All Analog Phones
                                    [deep] => 1
                                    [opts] => Array
                                        (
                                            [name] => All Analog Phones
                                        )

                                )

                            [lobby] => Array
                                (
                                    [name] => Lobby
                                    [deep] => 1
                                    [opts] => Array
                                        (
                                            [name] => Lobby
                                        )

                                )

                        )

                )

            [voip_phones] => Array
                (
                    [name] => VoIP Phones
                    [deep] => 0
                    [opts] => Array
                        (
                            [name] => VoIP Phones
                        )

                )

            [accessories] => Array
                (
                    [name] => Accessories
                    [deep] => 0
                    [opts] => Array
                        (
                            [name] => Accessories
                        )

                )

            [why_vtech] => Array
                (
                    [name] => Why VTech
                    [deep] => 0
                    [opts] => Array
                        (
                            [name] => Why VTech
                        )

                )

        )

    [current] => Array
        (
            [name] => Home
            [deep] => 0
            [opts] => Array
                (
                    [missing] => 404
                    [theme] => vtech
                    [template] => index.html
                    [name] => Home
                    [vtech] => hospitality
                    [index] => index
                )

            [current] => 1
            [selected] => 1
        )

    [html] => Array
        (
            [navigation-sitemap] => <ul class="level-1"><li class="level-1 selected current"><a class="level-1 selected current" href="./"><span>Home</span></a></li><li class="level-1"><a class="level-1" href="./analog_phones"><span>Analog Phones</span></a><ul class="level-2"><li class="level-2"><a class="level-2" href="./all_analog_phones"><span>All Analog Phones</span></a></li><li class="level-2"><a class="level-2" href="./lobby"><span>Lobby</span></a></li></ul></li><li class="level-1"><a class="level-1" href="./voip_phones"><span>VoIP Phones</span></a></li><li class="level-1"><a class="level-1" href="./accessories"><span>Accessories</span></a></li><li class="level-1"><a class="level-1" href="./why_vtech"><span>Why VTech</span></a></li></ul>
            [navigation-breadcrumb] => <a class="level-1 selected current" href="./"><span>Home</span></a>
            [navigation-siblings] => 
            [navigation-level-1] => <ul class="level-1"><li class="level-1 selected current"><a class="level-1 selected current" href="./"><span>Home</span></a><li class="level-1"><a class="level-1" href="./analog_phones"><span>Analog Phones</span></a><li class="level-1"><a class="level-1" href="./voip_phones"><span>VoIP Phones</span></a><li class="level-1"><a class="level-1" href="./accessories"><span>Accessories</span></a><li class="level-1"><a class="level-1" href="./why_vtech"><span>Why VTech</span></a></ul>

            [navigation-children] => <ul class="level-1"><li class="level-1 selected current"><a class="level-1 selected current" href="./"><span>Home</span></a><li class="level-1"><a class="level-1" href="./analog_phones"><span>Analog Phones</span></a><li class="level-1"><a class="level-1" href="./voip_phones"><span>VoIP Phones</span></a><li class="level-1"><a class="level-1" href="./accessories"><span>Accessories</span></a><li class="level-1"><a class="level-1" href="./why_vtech"><span>Why VTech</span></a></ul>
        )

)