While I was experimenting with Windows Live Writer 2011 I started to wonder about using jQuery. After a bit of trial and error I figured it out.
BTW, jQuery's rounded corner plug-in on this page didn't work in Internet Explorer 9 Release Candidate. It turns out that IE9 wouldn't use a script that started with "https://" but works with "http://" okay.
First, log-in to your blog and go to the Design section. Click on Edit Html on the Design tab.
In the HTML Edit window go to the
<!-- end outer-wrapper –> comment. Just above there are two
</div></div> tags. Between
</div></div> and
<!-- end outer-wrapper –> comment enter the following:
1: <script src='http://ajax.aspnetcdn.com/ajax/jQuery/jquery-1.5.min.js' type='text/javascript'/>
2: <script type='text/javascript'>
3: $(document).ready(function () { 4: var tag = "[Your selector go here like #content-wrapper]";
5: $(tag).[Your jQuery Function]();
6: });
7: </script>
I ran into problems using the jQuery selector after the $ so I just created a variable and that solved the problem. Also, there’s other CDNs (Content Delivery Networks) like Google you can use in Place of Microsoft’s. You can see an older post that tells why I use a CDN.
You can look at the source of this page to see how I use the jQuery Corners plugin.
Happy computing…
Technorati Tags:
jQuery,
Blogger,Writer 2011