1. VARIOUS WAYS OF USING
WordPress
Customizing
BY: NICK LA
www.ndesign-studio.com
2. Big Thanks to WordPress!
N.Design Studio Web Designer Wall
ndesign-studio.com webdesignerwall.com
Best Web Gallery IconDock
bestwebgallery.com icondock.com
3. Why WordPress?
• Easy to learn & use
Good documentation and simple admin panel
• Flexible and dynamic
Create dynamic sites with Template Tags
• SEO friendly
Friendly URL and semantic coding
• FREE!
Free open source + plugins and themes
4. Things You Should Know
• Custom Fields
http://codex.wordpress.org/Using_Custom_Fields
• Conditional Tags
http://codex.wordpress.org/Conditional_Tags
• Query_Posts
http://codex.wordpress.org/Template_Tags/query_posts
• Page Template
http://codex.wordpress.org/Pages
• Finding Good Plugins
http://wordpress.org/extend/plugins
5. How I Use WordPress:
Blog Gallery Shop
bestwebgallery.com
webdesignerwall.com icondock.com
16. Plugin: Custom Write Panel
Save time by using Custom Write Panel plugin to manage posts
Custom Write Panel
http://wordpress.org/extend/plugins/custom-write-panel/
18. Plugin: Theme Switcher
With Theme Switcher, visitors can pick their layout preference
Theme Switcher
http://wordpress.org/extend/plugins/theme-switcher/
Large Preview
Thumbnail Details
20. PHP Include
Use Conditional Tags to dynamically include template file from the “master” theme
<?php if (is_page()) { /*
Theme Name: Details
include ('./wp-content/themes/master/page.php');
*/
} elseif (is_404()) {
include ('./wp-content/themes/master/404.php');
} elseif (in_category(8)) {
include ('./wp-content/themes/master/category-8.php');
} elseif (is_single()) {
include ('./wp-content/themes/master/single.php');
} else {?>
<?php include ('./wp-content/themes/master/header.php'); ?>
<div>. . . display posts . . . </div>
<?php include ('./wp-content/themes/master/sidebar.php'); ?>
<?php include ('./wp-content/themes/master/footer.php'); ?>
<?php }?>
24. Query_Posts
Sample code: query_posts and the loop
index.php
<?php query_posts('showposts=5'); ?>
<?php if (have_posts()) : ?>
<?php while (have_posts()) : the_post(); $loopcounter++; ?>
<?php if ($loopcounter <= 1) { ?>
<div> first post content </div>
<ul class=quot;recent-postquot;>
<?php } else { ?>
<li> last 4 post links </li>
<? } ?>
<?php endwhile;?>
</ul>
<?php else : ?>
...code...
<?php endif; ?>
25. Conditional Tags
If the post is in the free icon category, display the post rating plugin
<?php if (in_category('28')) { ?>
<p>credits</p>
<?php if(function_exists('the_ratings')) { the_ratings(); } ?>
<?php } else { ?>
<p>regular post data</p>
<? } ?>