Blogger provides a single XML template file which you can use to edit and customize your blog. It is one of the most important template file presented in XML format. Editing this file allows you to configure size of headers, footers and the widths of content and sidebar. It allows you to polish minor details of your blog.
The template editor comes in handy when you want to make changes to your blog that are impossible from the layout options. Changes such as stylesheet style changes, enabling post thumbnails, changing size of the post thumbnails, etc can be easily configurable. You can also add javascript codes to the XML file that would run once the page loads. You can also add HTML snippets and codes to add some elements to your blog. The power of this single XML file for blogger templates is great.
You can find this template file under Template > Edit HTML link.
Important Steps to Take before Editing a Blogger Template XML File
Back up the file. You can do it by:
- Template > Edit HTML
- Select all the code by clicking on the code box and then pressing CTRL + A on your keyboard.
- Copy all the code [CTRL + C] and paste it [CTRL + V] in your favorite file editor.
- Save the file
To edit the XML file:
- The default editor from Blogger works great.
- Use the buttons such as “Jump to Widget” to directly jump to the part of the template code without having to scroll or search.
- “Format Template” button to format the spacing of the code so that it is easily readable.
Using External Editors:
- While maintaining another back up, copy all the codes of the template.
- Paste the code to external file editors such as Sublime Text 2, Notepad++ etc.
- Save the file as .xml file.
- Use additional features from those advanced text editors such as code highlighting, auto-complete etc.
- Once you are done making the changes copy and paste it back to the default code editor and then save. I find this method much easier.
No Comments