Best way to embedding Seaside in static HTML?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Best way to embedding Seaside in static HTML?

Ruben Bakker-2

I have some static pages (with navigation) etc. that are served by apache. These pages are designed and published with RapidWeaver. Seaside is used for some forms "inside" the static pages. Therefore I have setup apache to proxy/reverse proxy Seaside.

The "embedding" is done with iFrames:

     <div id="content">

<iframe name="target"
src= "http://mysite.com/seaside/entry_point"
width="620"
height="500"
frameborder="0"
scrolling="auto"
id="target"></ iframe> <!-- End content -->

It works. However, some users experience problems:
- the back key doesn't work correctly
- the seaside app is rendered after the static contents
- some browsers don't support the iframe tag
- Refresh the page doesn't refresh the iframe in some browsers

Is there any better way to achieve the same goal? I know the opposite (seaside on the "outside") would work better, however I do have more static contents and want the static pages to perform as fast and as reliable as possible.
Thanks for your help!
--
Ruben
http://mailplaneapp.com
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Best way to embedding Seaside in static HTML?

Lukas Renggli
> It works. However, some users experience problems:
> - the back key doesn't work correctly
> - the seaside app is rendered after the static contents
>  - some browsers don't support the iframe tag
> - Refresh the page doesn't refresh the iframe in some browsers
>
> Is there any better way to achieve the same goal?

Certainly. I once consulted a project where a Seaside application was
integrated into Typo-3. The trick was to perform a request to Seaside
from PHP, to strip the response to the html-body, to rewrite the
anchors and form actions using regex and to integrate the result into
the Typo-3 template. All in all quite a hack, but it worked really
well and didn't show any of the drawbacks you describe.

Lukas

--
Lukas Renggli
http://www.lukas-renggli.ch
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Best way to embedding Seaside in static HTML?

Ruben Bakker-2

Thanks Lukas, this sounds interesting! I understand the stripping to the html body and including it at some point in the PHP page. I don't understand the anchor and action rewriting, yet: What would be URL? The PHP page with some parameters?

 
On 6/25/07, Lukas Renggli <[hidden email]> wrote:
> It works. However, some users experience problems:
> - the back key doesn't work correctly
> - the seaside app is rendered after the static contents
>  - some browsers don't support the iframe tag
> - Refresh the page doesn't refresh the iframe in some browsers
>
> Is there any better way to achieve the same goal?

Certainly. I once consulted a project where a Seaside application was
integrated into Typo-3. The trick was to perform a request to Seaside
from PHP, to strip the response to the html-body, to rewrite the
anchors and form actions using regex and to integrate the result into
the Typo-3 template. All in all quite a hack, but it worked really
well and didn't show any of the drawbacks you describe.

Lukas

--
Lukas Renggli
http://www.lukas-renggli.ch
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside



--
Ruben
http://mailplaneapp.com
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Best way to embedding Seaside in static HTML?

Lukas Renggli
> Thanks Lukas, this sounds interesting! I understand the stripping to the
> html body and including it at some point in the PHP page. I don't understand
> the anchor and action rewriting, yet: What would be URL? The PHP page with
> some parameters?

Exactly. You need to put the current Seaside parameters in the PHP URL
somewhere. Also you need to replace the URLs in the Seaside response
with the appropriate PHP handler URL. Probably it is possible to do
this directly in Seaside nowadays, something that should be much
simpler than a couple of years ago.

Lukas

--
Lukas Renggli
http://www.lukas-renggli.ch
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside