Tools for Modifying Theme Files


WordPress makes it easy for you to customize your blog's theme and to make it truly your own. You do this by making changes to the theme's template files.

There are two ways to modify theme files: with the Theme Editor or with a text editor.

The Theme Editor

The Theme Editor, which is built into WordPress, allows you to make changes to writable files with your Web browser. You simply log into your WordPress blog and access the Theme Editor administration panel (Figure 20). Select the theme you want to modify, make changes, and save them.

Figure 20. The Theme Editor offers a Web-based interface for modifying your theme's template files.


There are several benefits to using the Theme Editor:

  • You can use the Theme Editor to edit theme files from any computer with an Internet connection.

  • No special software is requiredother than a Web browser.

There are drawbacks to using the Theme Editor, too:

  • The Theme Editor can only edit existing and installed theme files. You cannot create a new theme file or folder and then edit it.

  • If you make an error while editing with the Theme Editor, you have to remember what you did and manually fix it.

Text editors

You can also use a text editor to edit theme template files (Figure 21). This offers the flexibility of editing the file on your own computer, with a software tool well-suited for the task.

Figure 21. In this example, we're using TextWrangler on a Macintosh to edit the index.php file. Text editors like this one have features such as code coloring and indentation that make them good tools for editing code.


Of course, to edit a theme file on your computer, you have to get it there. There are two ways to do that:

  • Use an FTP client to download the file you want to edit. When you're finished editing it, use the FTP client to upload it back to the server.

  • Use the FTP capabilities built into the text editor to open the file on the server. Then, after making changes to the file, simply save it; it's automatically saved back to the server. Keep in mind that not all text editors include this feature.

Tips

  • Be sure to use a plain text editor and not a word processor. Word processors, like Microsoft Word and even TextEdit, can introduce additional characters into a text documentcharacters that can wreak havoc with your code.

  • Appendix C provides some information about using text editors, including instructions for opening text files on a server with two different text editor programs.





WordPress 2. Visual QuickStart Guide
WordPress 2
ISBN: 0321450191
EAN: 2147483647
Year: 2004
Pages: 142

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net