Changes from trunk/include/xpress_render.php at r26 to include/xpress_render.php at r1
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
include/xpress_render.php
r26 r1 35 35 } 36 36 37 // get sidebar rendaring38 function get_sidebar_rander($name = null)39 {40 $templates = array();41 if ( isset($name) )42 $templates[] = "sidebar-{$name}.php";43 44 $templates[] = "sidebar.php";45 46 $link= locate_template($templates, false);47 if ('' == $link)48 $link = get_theme_root() . '/default/sidebar.php';49 50 ob_start();51 require($link);52 $sidebar = ob_get_contents();53 ob_end_clean();54 return $sidebar;55 }56 57 37 // < body > tag is pulled out from the header of html contents. 58 38 function get_body($contents) 59 39 { 60 $xpess_config = new XPressME_Class();61 40 $pattern = "<body[^>]*?>(.*)<\/body>"; 62 41 preg_match("/".$pattern."/s", $contents, $body_matches); 63 42 $body = $body_matches[1]; 64 65 if (!$xpess_config->is_theme_sidebar_disp){66 $side_panel = get_sidebar_rander();67 $body = str_replace($side_panel,'',$body);68 }69 43 return $body; 70 44 }
Note: See TracChangeset
for help on using the changeset viewer.