« Home « Chủ đề Thiết kế web với wordpress

Chủ đề : Thiết kế web với wordpress


Có 40+ tài liệu thuộc chủ đề "Thiết kế web với wordpress"

Hướng dẫn tạo themes cho wordpress part 9

tailieu.vn

Let's look at some of the important ones and the interesting things you can do with only a few characters of code.. Comments on blog posts are generally left by a person with an opinion on the post in question.. One of the easiest and most useful modifications to make to your post comment listings is to separate these two...

Hướng dẫn tạo themes cho wordpress part 10

tailieu.vn

Using the Text widget for custom sidebar content Including a dynamic sidebar in your theme Including multiple dynamic sidebars in your theme Setting the default widgets for a sidebar in your theme Positioning multiple sidebars in your theme by using CSS Styling the appearance of sidebars in your theme by using CSS. Showing asides in the sidebar by using the...

Hướng dẫn tạo themes cho wordpress part 11

tailieu.vn

You can add your own placeholder content or default widgets by adding the relevant code just below the dynamic_sidebar function in a sidebar.php file. In the following example, the Archives widget has been added as a default widget, and will show the 15 most recent posts:. Setting the default widgets for a sidebar in your theme. Your theme may have...

Hướng dẫn tạo themes cho wordpress part 12

tailieu.vn

The Widget Logic plugin should appear in the Manage Plugins list. Click on the Activate link for this plugin. A message should appear at the top of the page verifying that the plugin is now activated. Now, if you visit the Active area of your Manage Plugins screen, you should see it listed, as seen in the next screenshot:. Drag...

Hướng dẫn tạo themes cho wordpress part 13

tailieu.vn

For the sake of remaining simple, this page template will only display a simple string. Directly after the piece of markup that you added earlier, insert the following code:. Hello World!. <h1 style="text-align:center;">Hello World!</h1>. Inside of the body is a single heading element that reads Hello World. Pat yourself on the back! You've just created your first custom page template....

Hướng dẫn tạo themes cho wordpress part 14

tailieu.vn

</div>. <?php get_sidebar. <?php get_footer. You can now use your Taxonomies page templatẹ Go and create a new page in the WordPress administrative area, and make sure that it uses the Taxonomies page templatẹ If you need more information on how to do this, see the recipe Creating a simple page templatẹ Visit your newly-created pagẹ You should see output...

Hướng dẫn tạo themes cho wordpress part 15

tailieu.vn

<?php. <?php get_sidebar. <?php get_footer. When this page template is used, the book's title will be displayed as the main heading and will be followed by an ordered list of chapter titles and excerpts. If you've added your content correctly, and selected the Table of Contents page template for your main book page, you should be seeing something similar to...

Hướng dẫn tạo themes cho wordpress part 16

tailieu.vn

One of the most important things for your theme to get right when it comes to displaying media is also one of the easiest. it is one of the easiest things to account for.. Then, insert the following class declarations:. Be on the look-out for other similar tags. As an example, see how similar code was commented out in the...

Hướng dẫn tạo themes cho wordpress part 17

tailieu.vn

results in the following HTML:. The only requirement for this recipe is that you are working on a modern WordPress theme that works with WordPress 2.8 or 2.9.. First, we need to create the attachment template. The basic attachment template that we are going to create must be called attachment.php . Open attachment.php , and insert the following template code:....

Hướng dẫn tạo themes cho wordpress part 18

tailieu.vn

In this chapter, we will cover:. Dynamically displaying the author's name and linked e-mail ađress Listing all of the published authors on a site. You will need a theme that already has an author.php file created, such as Sandbox from plaintxt.org , or you can create your own basic author.php theme file by ađing the code provided in this recipẹ....

Hướng dẫn tạo themes cho wordpress part 19

tailieu.vn

You need to have a basic theme containing a functions.php file, and a sidebar file such as sidebar.php created for this recipe. You also need to know where you would like to place the listing of the most discussed authors. First, we need to create a custom template tag. Open or create your theme's functions.php file, and define the function...

Hướng dẫn tạo themes cho wordpress part 20

tailieu.vn

When you call wp_enqueue_script , you're taking advantage of one of several JavaScript- specific functions included with WordPress. Some of the others include wp_register_. The wp_enqueue_script function accepts the following parameters: $handle , $src. Earlier in our example we used the following function to call a simple JavaScript file:. wp_enqueue_script( 'my-theme', get_bloginfo('stylesheet_. '/js/my-theme.js'. When you call wp_enqueue_script , you must...

Hướng dẫn tạo themes cho wordpress part 22

tailieu.vn

<table class="form-table">. <th scope="row"><label for="custom-theme-header-color">. <?php _e('Header Color. ?></label></th>. name="custom-theme-header-color". id="custom-theme-header-color". value="<?php echo esc_attr( $settings[. 'header-color. <p class="submit">. <?php wp_nonce_field( 'custom-theme-save-options. name="custom-theme-save-options". id="custom-theme-save-options". value="<?php _e( 'Save. This file contains all of the code necessary for the theme options page.. Open or create your theme's functions.php file and insert the following code:. if (!class_exists('My_Theme. class My_Theme. function My_Theme(). add_theme_page(__('My Theme. __('My...

Hướng dẫn tạo themes cho wordpress part 23

tailieu.vn

Then, you hook to admin_init to process and save the custom options present on the custom admin page. Finally, you hook to the init hook to enqueue the custom CSS stylesheet the user has selected.. You should see a My Theme link, as shown in the following screenshot:. Now, click on the My Theme link under the Appearance menu heading....

Hướng dẫn tạo themes cho wordpress part 24

tailieu.vn

wp-admin/menu.php: 10 msgid "Dashboard". Add a comment to the readme file of your theme about the availability of the PO file, and specifying that your theme is prepared for translation and localization. You may also want to add an additional readme file in your translation folder that describes the purpose of the PO file.. functions.php file or header.php file, so...

Hướng dẫn tạo themes cho wordpress part 25

tailieu.vn

In this chapter, we will cover:. Adding a skip navigation link for usability. Centering your site's layout in the browser window Setting up a randomly-rotating header image Making theme components drag-and-drop Creating a global toolbar for your theme Creating tabbed navigation for your theme. To solve this problem, you'll rely on a simple technique that has been around for quite...

Hướng dẫn tạo themes cho wordpress part 26

tailieu.vn

The following screenshots show a random header image:. You make the function available throughout your theme by creating it in the functions.php file that WordPress loads as part of its startup process.. After these conditions are verified, PHP opens the header-images directory and iterates over each file in the directory. are excluded because they have special meanings in the context...

Hướng dẫn tạo themes cho wordpress part 27

tailieu.vn

function wptc_save_user_cat_order($wp). if( isset( $_POST['save-user-cat-order. setcookie('user-cat-. global $user_cat_order;. $user_cat_order = unserialize(stripslashes($_COOKIE['user-cat- order']));. $user_cat_order = is_array($user_cat_order. $user_cat_order : false;. global $user_cat_order,$current_categories;. $user_cat_order = $current_categories;. stop:wptc_user_cat_order, items:'div.piece',. function wptc_user_cat_order(event,ui. 'save-user-cat-order':1,. 'user-cat-order':$(this).sortable('serialize'). You need to have a basic theme constructed and, for the best experience, you need to have separated your header elements out into header.php. The toolbar on that site allows users...

Hướng dẫn tạo themes cho wordpress part 28

tailieu.vn

Finally, you included this component into your header.php file so that it shows across every page of your site. One of the easiest visual clues that you can offer your users is that of active and inactive tabs.. Your index.php file should look something like the following:. <?php. <div id="content">. <div <?php post_class('post-container. <h2 <?php post_class('post-title. <?php the_title. <div <?php...

Hướng dẫn tạo themes cho wordpress part 21

tailieu.vn

Go to http://jqueryui.com/themeroller/ and begin clicking on the color pickers and other tools on the left-hand side of the page to customize the widgets (including a tabbed box) that appear on the right. You can also click on the Gallery link to choose from an already-designed theme. After playing with several of the options, your screen should look similar to...