© copyright 2002 by Marc Barrot.
|
|
|
|
|
Sunday, April 14, 2002 |
The Road To W3C Validation
In my never ending quest for better cross browser / cross platform compatibility (I still haven't solved the radioScan JavaScript issue), I tried to achieve full HTML 4.01 and CSS 2.0 compatibility as defined by the W3C validators.
s l a m now proudly proclaims its W3C standards allegiance, but it took a lot more work than I expected.
The only benefit so far is that s l a m pages load noticeably faster in Mozilla.
My most common mistake: all IMG tags must must have an ALT="description" attribute to be HTML 4.01 compliant. I had neglected this in most of the pictures included in my posts.
Second most common mistake: the & is a reserved HTML character, it defines an entity. It cannot be used anywhere in a non entity definition role, including in the cgi part of url links. I had to replace all http://blabla/cgi?p1=foo&p2=bar kind of links by http://blabla/cgi?p1=foo&p2=bar.
Third common mistake: for some reason, I had used a (much deprecated) NOSHADOW attribute to the HR tag, which doesn't work in HTML 4.01 since all attributes must have arguments between quotes (noshadow="noshadow" might have worked).
And now for the fun part: I had to do a little strictly 'non-kosher' tweaking of the radio.root and weblogdata.root tables, since some of the code and data called from Radio publishing templates is not HTML 4.01 compatible.
- system.verbs.builtins.radio.html.commentLink:
Replaced &p by &p in the definition of commentPageUrl. - system.verbs.buitins.radio.weblog.render:
Changed &c by &c if adrblog^.prefs.flCommentLinksEnabled in bodytext for the commentCount script tag. - In weblogData.root:
In the archiveLinkImgTag string, added an alt="Permalink" attribute to the img tag. In itemPermaLinkImgTag, modified the calling macro like this: <%radio.macros.imageref ("images/woodsItemLink.gif", "", "", "", "", \"Permalink")%>. - And for good measure, I added an alt="Permalink" attribute to the img tags in system.verbs.buitins.radio.data.strings.archiveLinkImg and system.verbs.buitins.radio.data.strings.itemPermaLinkImg. They are apparently used at initialization from default settings.
Last, I modified (again) my googlebox macro, replacing &q by &q in the search link associated with the Google img.
Ok, the very last one for my Reiter friend: In system.verbs.builtins.radio.data.staticSite.template, the ImageTag variable should include 2 ampersand tags instead of 2 & in the cgi link.
6:05:34 PM Google It!
|
|
MacOS and Office Posting
Pointing at alternate ways of posting to weblogs from Microsoft Office running MacOS.Dave is up after midnight pointing at work Simon Fell is doing with SOAP, the Blogger API, the Google API and Microsoft Word. My heart sinks a bit knowing that the stuff he's done will only work on Windows. (Please correct me if I'm wrong on that. ;-) [Jakes Brainpan] Well, this specific case is Windows only, but there's no reason for it to be, I thought XML-RPC & SOAP support was baked into Mac's these days, and I guess the Mac version of Office is similarly scriptable.[Simon Fell]
Well, while it's not on my current to-do list (still struggling with javascript and browser compatibility), I'll point to a few possible ways of doing the same thing when running MacOS X:- Microsoft Office X fully supports Visual Basic, some of Simon;s code is probably directly re-usable.
- Better yet, Office is also fully scriptable with AppleScript.
- Starting with MacOs X 10.1, AppleScript comes with SOAP support.
- If you're allergic to AppleScript, you can always rely on Paul Kulchenko's SOAP::Lite Perl module, since Darwin comes with a fully functionnal Perl 5.6 distribution. All you need is a little VB glue.
If I were to use the blogger and metaBlogger APIs to post to s l a m, I think I'd rather do it from the the Calendar window of Microsoft Entourage.
Calendar Events have titles, descriptions, and categories as well as date/time stamps. Office's spelling checker works from the description part of the event window. Events are easy to track by date and category, approximating the Radio interface.
10:23:10 AM Google It!
|
|
|
|
last updated: 10/21/02; 12:17:02 AM.
Currently subscribed to: Here's how this works.
|