Wednesday, April 25, 2007

Progress Bars

Woo hoo! I am so excited that I made a progress bar that works. It only took me about 2 hours and a dozen or so different internet resources. I took a little info here and there and copied code from a couple of different sites and I got progress bars!

For the rest of you out that want to add progress bars to your blog, this is how I did it (I am by no means a techy or a computer geek but hopefully I can make this clear for you). These instructions are for the new Blogger, I have no idea if they will work with other blog servers.

Important Note: Every [ and ] noted below must be replaced with <> respectfully in order for your code to work. I find it easiest to cut and paste the code into Microsoft Word and perform the find and replace action under the Edit tab.

1. Log into your blogger acount.

2. Go to Layout.

3. Click on the Edit HTML tab.

4. IMPORTANT: Click on the Download Full Template before you go any further. This will save your excisting template to your hard drive in case your changes don't work.

5. Cut this:
[link href='css/style.css' rel='stylesheet' type='text/css'][style type='text/css']

.prog-border {
height: 15px;
width: 205px;
background: #fff;
border: 1px solid silver;
margin: 0;
padding: 0;}

.prog-bar {
height: 11px;
margin: 2px;
padding: 0;
background: #C9DDEC;}
[/style]
[/link]

6. Scroll down until you get the first entry of
[head]
(This only about 8 lines into the HTML text)

7. Paste what you cut in #5 above below [head] and above [b:include data='blog' name='all-head-content'/]

8. Click SAVE TEMPLATE

9. Now click on PAGE ELEMENTS under the LAYOUT tab

10. Select add new ADD A NEW PAGE ELEMENT from the side bar.

11. Select HTML/JavaScript.

12. Paste the following into the content box:
[ul]
[li]Name of your project here:: percent complete here%[/li][div class="prog-border"] [div style="width: 85%;" class="prog-bar"] [/div][/div]
[/ul]

13. For each project you want to post just repeat from [il] to [/div]. Besure you have [ul] at the very beginning of your HTML and [/ul] at the very end. These do not need to be repeated for eahc project.

14. You change the color of border and your bar by going to Visibone's Color Lab and changing the code background in #5 above.

I hope this works for you and makes it easier that what I had to do. My references are: Man Bites Hollywood, Knitticisms, Blogger Help

9 comments:

Lucy said...

Hi Knitterbug - This is very interesting - I particularly like the Flickr badge and have composed one. I know how to organise the cut and paste thing but how do I go about placing it on the right-hand side beneath the "view my complete profile" bit????? It's a bit late in the day here Downunder so I'm going to try it out on Saturday morning(won't be online tomorrow(Friday our time)Thanks a bunch - you are very clever to have compiled the tutorial - my brain is somewhat overloaded at the moment!!

Knitterbug said...

Lucy,

If you cut and paste #5 into the Edit HTML template, it should automatically appear in your sidebar.

Lucy said...

It is I again!It's either me or Flickr!!I cut and paste the flickr badge code into Edit HTMLbelow head and above b) but I got an unable to preview your template message stating that the reference to entity zg_person_id must end with the ';'delimiter - seriously frustrating!!I even tried entering your link etc code first but apparently something was not well-formed (maybe its my brain (ha ha)Any suggestions (excepting give up!! LOL)will be gratefully received!!Thanks

Knitterbug said...

Lucy,

The Flickr badge is different than the progress bars. Click on "what is this?" at the bottom of my Flickr badge. It will take you to Flickr and allow you to create a badge. You want to use the flash badge if you want your photos to rotate like mine do. Hope this helps you.

Lucy said...

Thanks for your patience Knitterbug - I did actually create a badge before all this turmoil - it's just that it won't preview on the EditHTML because various aspects of the code aren't well-formed!!Some (;)delimiters were missing and I fixed those but finally was told that content of elements must consist of well-formed character data or markup!!I think Flickr may be at fault here with a faulty code - I have sent them an email about it so we'll see what happens next!! Thanks again!!

Lucy said...

I have finally worked out what I was doing wrong - no fault of Flickr's - just my lack of rational thinking!! Well one learns something new everyday and I am so pleased with myself!!Thanks for your patience and help!!Happy Knitting!

James said...

Wow, thanks for the tip! I am amazed at how fast you get your knitting done as well! You're blog is great!

knittin gin said...

OMG! Thank you for the progress bars how-to! I've been struggling with trying to follow other instructions I've found that seemed straightforward enough - but they just didn't work. Your directions were so simple and easy to do and it actually worked the first time! It should be really easy to update them too. Now I'm just going to have fun playing around with the color and style.
Thanks again!

zippiknits...sometimes said...

Nice Hack, Knitterbug. The easiest one I've seen.