[Nitro] Nitro: cannot control the current path of a controller when skins are called

Arne Brasseur arne at arnebrasseur.net
Tue Jun 26 17:04:49 EDT 2007


Jimmy Jazz schreef:
> As far as i understood, if a controller is relative to /path it will 
> be the same for the models ( for example, def to_href "article/#@oid" 
> end) it depends on. But that is not always true, for example, if i 
> simply add "require 'src/skins/blog' in run.rb or in 
> src/controllers/blog.rb, the relative pathname for blog.rb family are 
> then mapped to / and not to the current directory /blog according to 
> the "Server.map" mapping.
Jimmy, I'm not sure if I understand your difficulties.

If I understand you correctly, you have a blog model and a related 
controller. You expect a blog model object's to_href method to return a 
link that is mapped to the blog controller, and it's not working. Is 
that where your problem is?

Source tree layout can be pretty much any way you like in Nitro, that 
doesn't matter very much. On the other hand you didn't say much about 
how your classes are laid out. More information could be helpful.

Welcome to Nitro!
(ab)

-- 
Arne Brasseur
http://www.arnebrasseur.net
arne at arnebrasseur.net



More information about the Nitro-general mailing list