The future is here? 1

Posted by Steve Longdo Fri, 07 Jul 2006 02:59:00 GMT

I just saw about rb2js over at _why's site. Is it the beginning or end of times?

This is exciting in a way that Google's Web Tool Kit isn't. Specifically writing idomatic Ruby is always going to be more enjoyable and less lines of code than working in the devil's language.

(Okay that might be too harsh, Java is like a little demon compared to .NOT)

Lightbox V2 integration with Typo...

Posted by Steve Longdo Tue, 23 May 2006 11:31:00 GMT

It was brought to my attention that I didn't post a lot of detail about integrating Typo with Version 2 of lightbox. I'll attempt to correct that with a quick write up.

Start by downloading the most recent lightbox release. From here we will want to copy the images that are distributed with it into our Typo installation's public/images folder.

Next up is the javascript file and the stylesheet. I have made some slight modifications to the originals to make the image paths non-relative and the additon of links that show in the caption portion of the light box. Grab the following javascript file and put it in your public/javascripts directory. Then get the css file and put it in your public/stylesheets directory.

Final step for usage is to place a couple of lines in your active theme's layout/default.rhtml. Under the <%= page_header %> line place the following two lines:
<%= javascript_include_tag "lightbox-modded"  %>
<%= stylesheet_link_tag "/stylesheets/lightbox" %>
This should get you up and running with lone imgs
<img src="..." rel="lightbox"/>
and/or groups of imgs
<img src="..." rel="lightbox[groupName]"/>
<img src="..." rel="lightbox[groupName]"/>

When XML is binary you have a XMLHttpRequest problem... 1

Posted by Steve Longdo Wed, 19 Apr 2006 23:55:00 GMT

Lesson learned the hard way on this one. I have been working with the FCKEditor and getting a strange error specifically:
Error: this.DOMDocument has no properties
Source: /javascripts/fckeditor_gecko_2.js
Line: 22
After pounding my head into my laptop for awhile and putting some whitespace into that file I figured out that I was getting a null response from the XMLHttpRequest for the fckstyles.xml file.

I tried loading it directly from the browser and was promped to save the file to disk. Normally it would open in the browser. Why would it think the XML file is binary? The xml mime-type mapping was removed from the Typo lighttpd.conf file. File this one under "want to know how to keep an idiot busy for hours"... *sigh*
Make sure that your lighttpd.conf has a mapping for XML if you are doing anything with XML.
mimetype.assign = (  
  ...
  ".txt"        =>  "text/plain",
  ".xml"        =>  "text/xml"
)

Older posts: 1 2 3 ... 5