-
-
Notifications
You must be signed in to change notification settings - Fork 214
Preparing your v1.x themes for v2.x
Moc edited this page Mar 31, 2013
·
5 revisions
Themes developed for v1.x of e107 will continue to work using v2.x. However, to get the most out of v2.x, we suggest the following changes be made to bring your theme up to the new v2.x standards.
- Replace $HEADER and $FOOTER with $HEADER['default'] and $FOOTER['default']
- Replace any occurrences of $CUSTOMHEADER and $CUSTOMFOOTER with $HEADER['custom'] and $FOOTER['custom']
- If your theme contains links to external social pages such as facebook, twitter, youtube or google+, use the core definitions for them. ie. XURL_FACEBOOK, XURL_TWITTER, XURL_YOUTUBE, XURL_GOOGLE.
- Remove any reference to $CUSTOMPAGES and place them inside theme.xml in the layouts section.
<layout name='custom' title='Custom Pages'> <custompages>FRONTPAGE</custompages> <custompages>/forum/</custompages> </layout>
- If you have used index.php in your $CUSTOMPAGES list, use FRONTPAGE instead (see above)
- The function theme_head() has been deprecated. Instead, use either e107::css() or e107::js() to include what you require in the header. (see bootstrap or other new core theme for examples)
- Shortcodes need to be set to UPPERCASE in all occurrences in your theme.php file. ($register[] and everywhere else in theme.php)
e107 v2.x