Skip to main content

Several Ways To Add HTML Accessories To Your Blog

If you have a malicious or misbehaving gadget in your blog, one of the easiest blog cleanups is removal of a malicious HTML gadget.

Unfortunately, this does not work, for every gadget on every blog. Depending upon how a gadget is installed, malicious code may, or may not, be visible - and if visible, may, or may not, be easily removable.

There are four ways to install accessories and gadgets, onto a blog.

  1. Add into the template, using "Edit HTML".
  2. Add into new posts, using the dashboard post template.
  3. Add into an existing HTML gadget, by editing the gadget.
  4. Add into a new HTML gadget.

The third is preferable, if only to isolate each gadget being added - and make it more easily maintainable.

Add into the template, using "Edit HTML".

For non visible code, the Template Editor will always be the most "logical" installation process.

Many accessories come with installation instructions.

Copy the code here, find the "<Body>" (or "</Body>") tag in your template editor, and paste after (or before) the tag. Then, Save - and test your change.

So simple to do, but so easy to mess up. Or have you never had a broken or scrambled template?

And if the code added becomes malicious later, it's can be a pain to use "Edit HTML" when you're stressed (the blog is redirecting, you have angry readers, ...).

Add into new posts, using the dashboard post template.

When code is added to the blog template, using the Template page "Edit HTML", the code addition takes place immediately. When code is added to the dashboard post template (using Settings - "Posts, comments and sharing" - "Post Template"), the code addition takes place as each new post is published.

A corresponding difference is experienced, when code is removed. Deletion of code from the blog template takes place immediately. Deletion of code from the dashboard post template takes place as each new post is published. To remove dashboard post template content from existing posts, each post must be individually edited.

Add into an existing HTML gadget, by editing the gadget.

Some people put all of their accessories, of a given type, into one HTML gadget. Maybe the code for each gadget will go into separate cells in a table structure (for visible gadgets), maybe it will simply be separated using "<br />" tags.

Either way, you can identify the problem gadget - when the time comes - but you have to edit the gadget, find the malicious code, delete the malicious code, and Save the gadget. Then, you see if you did not damage the remaining code, that you need to keep?
Oops, I did not mean to delete that tag!

All of this, again, when you're stressed (the blog is redirecting, you have angry readers, ...). Stress == Mistakes, and more stress.

Add into a new HTML gadget.

This takes extra work, in the beginning. You have to add a new HTML gadget, position the new gadget using Layout, make sure that the new gadget does not affect the other gadgets, ...

But extra work, in the beginning, gives less work, when you're stressed.
Just login to Blogger as a blog administrator, click on the link immediately below, then click on "Remove".
Isn't that so much easier?

Just be sure to add an HTML gadget, from Basics - and remember to edit the gadget, in HTML mode.

The bottom line.

It's easier, and more logical, to add code directly, using "Edit HTML". And, it keeps the code base more compact.

But if you ever have to remove code, quickly, having each code module isolated as a separate HTML gadget is way, way easier.

You'll find out, one day - if you ignore me, now.

Comments

Popular posts from this blog

Custom Domain Migration - Managing The Traffic

Your blog depends upon traffic for its success.

Anything that affects the traffic to your blog, such as any change in the URL, affects the success of your blog. Publishing the blog to a custom domain, like renaming the blog, will affect traffic to your blog. The effects of the change will vary from blog to blog, because of the different traffic to every different blog.Followers. People who find your blog because of recommendations by other people.Search engines. Robotic processes which methodically surf your blog, and provide dynamic indexing to people who search for information.Subscribers. People who read your content from their newsfeed reader, such as the dashboard Reading List.Viewers. People who read your content from their browser.No two blogs are the same - and no two blogs will have the same combinations of traffic sources.

Stats Components Are Significant, In Their Own Context

One popular Stats related accessory, which displays pageview information to the public, is the "Popular Posts" gadget.

Popular Posts identifies from 1 to 10 of the most popular posts in the blog, by comparing Stats pageview counts. Optional parts of the display of each post are a snippet of text, and an ever popular thumbnail photo.

Like many Stats features, blog owners have found imaginative uses for "Popular Posts" - and overlook the limitations of the gadget. Both the dynamic nature of Stats, and the timing of the various pageview count recalculations, create confusion, when Popular Posts is examined.