METHOD ONE:
function logo_main() { ?>
<a href="index.php"><img class="main_logo" src="wp-content/themes/gopartybuzz/library/images/logo.png" alt="Go Party Buzz" /></a>
<ul id="category_menu">
<?php wp_list_categories('orderby=name&title_li=&depth=1&show_count=0&use_desc_for_title=1&child_of='.NULL); // Null is used to keep from showing subcats ?>
</ul>
<div id="searchform">
<form id="searchform" method="get" action="<?php bloginfo('home') ?>">
<div>
<input id="s" class="textInput" name="s" type="text" value="Search..." onfocus="if (this.value == 'Search...') {this.value = '';}" onblur="if (this.value == '') {this.value = 'Search...';}" size="28" />
</div>
</form>
</div><!--#searchform-->
<?php }
METHOD TWO:
function childtheme_create_doctype($content) {
$content = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">';
$content .= "\n";
$content .= '<html xmlns="http://www.w3.org/1999/xhtml"';
return $content;
}
Keep in mind these are two different functions that have different outputs but what im trying to illustrate is the difference int he style of functions one uses a variable to hold data and then returns it for output while the other simply has the proper HTML in it... So which is more proper?Efficient? Faster?


Sign In
Create Account


Back to top









