Scott Longberry wrote:
> On Jan 18, 2007, at 7:37 AM, Johan Sundström wrote:
>
>   
>> On 1/18/07, David Huynh <[EMAIL PROTECTED]> wrote:
>>     
>>> Hi Scott,
>>>
>>> That iframe is used to detect when the user presses the Back and  
>>> Forward
>>> buttons of the browser so that undo/redo can be supported. What  
>>> kind of
>>> problem is it causing you?
>>>       
>> Probably not Scott's problem, but one I have encountered on my own in
>> intrusive composition scenarios: when __history__.html is loaded into
>> a frame from a site where it does not exist, and where the error page
>> contains javascript code which breaks free of frames (such as if(
>> window != top ) top.location = location;), this wreaks havoc, shutting
>> down Exhibit and anything else along with it.
>>
>> It would be useful having the option of specifying somehoe that
>> Exhibit first try to load the history page via SimileAjax, ensuring
>> that it is the history page it expects, before loading it into the
>> iframe. Or, doing away with loading an external file at all, if
>> possible.
>>
>> -- 
>>  / Johan Sundström, http://ecmanaut.blogspot.com/
>>
>> _______________________________________________
>> General mailing list
>> [email protected]
>> http://simile.mit.edu/mailman/listinfo/general
>>     
>
> My problem actually lies in the fact that I am using Ruby on Rails to  
> write my site and am using Exhibit underneath this application layer  
> for display purposes. Rails uses routing to determine which  
> application controller should handle an incoming request. So, what  
> happens in my case is that the page requests the __history__.html  
> file from the directory that created the Exhibit view and Rails  
> interprets that as a request to the controller and passes in the  
> history file name as a parameter to the controller. The controller is  
> actually expecting an id for lookup in the database by default, so it  
> assumes that I want to look up __history__.html and isn't all that  
> happy about the results.
>
> I found in the code how to turn off the history iFrame and have done  
> so as a temporary fix. However, the history feature is pretty nice  
> and I would like to eventually turn it back on. I will take a look at  
> the routing configuration for Rails and see if there is a way to tell  
> the application that a request for the particular filename should be  
> a proxy to somewhere else.
>
> However, I do like Johan's suggestion of doing away with the external  
> file if at all possible. Or, at least make it a configurable option  
> to tell Exhibit where to look for the file.
>   
There is a way to tell Exhibit (actually, SimileAjax) where to look for 
that file. See

    http://static.simile.mit.edu/ajax/api/scripts/history.js

You need to set

    SimileAjax.History.historyFile = "/where/you/want/the/file/to/be.html";

before the history gets used. If you want to turn the history off 
completely, set

    SimileAjax.History.enabled = false;

David

_______________________________________________
General mailing list
[email protected]
http://simile.mit.edu/mailman/listinfo/general

Reply via email to