[Catalyst] setting/getting session data from within tests

Daniel McBrearty danielmcbrearty at gmail.com
Mon Jun 5 23:54:33 CEST 2006


I can see your point, I think - need to think about this. Thank you.

what happens to the catalyst routing though when you have uri :

http://www.example.net/fr/some_controller/some_action

instead of :

http://www.example.net/some_controller/some_action

An auto acton in the route to get the language out of the uri? and all
actions have to match on a regex?
or is there a simpler way?


On 6/5/06, A. Pagaltzis <pagaltzis at gmx.de> wrote:
> * Daniel McBrearty <danielmcbrearty at gmail.com> [2006-06-05 21:10]:
> > what's the advantage of using the uri?
>
> F.ex., the page content can be cached; if it changes based on
> state in a cookie, that's not possible. The server never needs to
> consult the DB to find which version of a page the user wants:
> it's right there in the URI the user requested.
>
> > and what happens when the user closes the browser and comes
> > back an hour later? why should they select again?
>
> You do let them save a preference on the server. But the only
> case that this needs to be consulted is for requests to the `/`
> homepage. All other pages on the server live in namespaces where
> the URI states the language and regular URI dispatch returns the
> proper thing.
>
> Since `/` itself is always only a redirect, it's also likely that
> users will bookmark something like `example.net/en/` or
> `example.net/br/`, so their "configuration" is right there in
> their bookmark. Obviously they don't need to choose again.
>
> The less state is stored implicitly in the server, and the more
> of it is made explicit in the URI, the easier the entire thing is
> to test, cache, distribute, etc.
>
> Regards,
> --
> Aristotle Pagaltzis // <http://plasmasturm.org/>
>
> _______________________________________________
> Catalyst mailing list
> Catalyst at lists.rawmode.org
> http://lists.rawmode.org/mailman/listinfo/catalyst
>


-- 
Daniel McBrearty
email : danielmcbrearty at gmail.com
www.engoi.com : the multi - language vocab trainer
BTW : 0873928131



More information about the Catalyst mailing list