WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] How to create custom post formating in wordpress? (3 posts)

  1. peterson.julia
    Member
    Posted 4 years ago #

    Hi I would like to ask how I can customize post using css in wordpress. Do I have to create some template file, or adding tags in index.php in LOOP will do? Or can it be done some other way. Is there some file which can be edited?

  2. script2see
    Member
    Posted 4 years ago #

    Check out the following article from Nathan Rice about creating single post templates:

    http://www.nathanrice.net/blog/wordpress-single-post-templates/

    Nathan has simplified his original code so that it now only encompasses one line of PHP that you would add to functions.php in WordPress.

    You'll have to create some specific CSS for your post template after adding the PHP to the functions file, but you'll find the process to be fairly straightforward. The end result is a drop-down menu from which you can select your post templates.

  3. alchymyth
    Forum Moderator
    Posted 4 years ago #

    if you want to customise a single post in a special way - most themes use the post ID in the html tags around a post to give it an individual html id (for instance <div id="post-456">) which you can use to style specially in style.css.

    if you want to style posts in general, look into the html code in your browser when you view your blog, and identify the html tags surrounding the post. then style them in the style.css of your theme

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.