ROR and Thickbox

Hi there,

I'm trying at present to get thickbox (and jqeury) work with ROR.

Well.. the first step I made was adding the javascripts of thickbox and jqeury to my controller:

<script type="text/javascript" src="/javascripts/jquery.js"></script>
  <script type="text/javascript" src="/javascripts/thickbox.js"></script>

Then I added the following line to jqeury.js at the bottom:


Now, I had to replace all $() in thickbox.js with jQuery()... a simple find and replace made it...

Now, I wanted to test it out and added the following code to one of my rhtml's:

<a href="<%= url_for_file_column("adimage", "image") %>" title="<%= @adimage.displayname %>" class="thickbox">
<%= image_tag url_for_file_column("adimage", "image","thumb") %></a>

This code works so far... a modal windows gets opened but the image doesn't gets displayed... and I found the erorr. The browser tries to fetch the url with a randon number at the end

(example): URL+random=656565655

My app tells me then, that this url couldn't be found.. if I remove the random-stuff it works.. but well.. thickbox adds me this random-string to the url... when I remove this url, thickbox doesn't work anymore.

Does anyone know a fix for this problem ?? maybe a url-rewrite or something similar ??

Bye and thanx for reading,