#apache #archlinux #asterisk #centos #debian #gentoo #haskell #kde #kubuntu #lisp #math #mysql #perl #python #ruby-lang #rubyonrails #suse #ubuntu #vim #wikipedia 0 1 2 3 4 5 6 7 8 9 
Top Prev 7406 7407 7408 7409 7410 7411 7412 7413 7414 7415 7416 7417 7418 7419 7420 7421 7422 7423 7424 Next

#rubyonrails

<tpope> controllers are dynamic
<nasr100> ya i know
<tpope> so really, you just want a route to a controller action
<nasr100> right
<nasr100> but the rails framework maps xyx_controller.rb to www.myapp.com/xyz/
<nasr100> what i want is just the www.myapp.com
<nasr100> so how would i name the file, map the file, basically make it work. etc....
<halorgium> nasr100: read the config/routes.rb thanks
<nasr100> halogrium: ya,. i did
<nasr100> answer isn't in there
<halorgium> did you see the 'default route' ?
<tpope> yes it is
<nayte> I can't seem to retrieve the ID of the logged in user using session[:user].id
<nayte> Whats the proper way to do it?
<nayte> (using login_generator)
<tpope> session[:user_id], no?
<halorgium> nayte: don't store the model in the session
<tpope> login_generator is ooold
<nasr100> yes i did see the default route
<tpope> we need a good way to warn people to steer away
<nasr100> but again this still has to go through a controller
<nasr100> that has a name in the url path
<nayte> halorgium: Ok -- I'll remember that. I think it did it by default, as I sure didn't do it on purpose. :-)
<tpope> you said you wanted to go through a controller
<nayte> Thanks fellas.
<tpope> if you just want an index.html
<halorgium> nasr100: please tell me you haven't forgotten to remove the index.html
<tpope> edit public/index.html
<tpope> it's that simple
<halorgium> tpope: obviously not :(
<nasr100> ok guys, i'll try to be more clear
<halorgium> answer these 2 questions:
<halorgium> 1) what uri are you going to be requesting?
<halorgium> 2) what do you want to show at this uri?
<nasr100> ok cool
<nasr100> 1) say the app is myapp.com...so the request url would be myapp.com
<nasr100> 2) i want the dynamic index page rendered...NOT the static html
<wangslanger> rm index.html
<nasr100> so i want it to go through the controller
<wangslanger> vim routes.rb
<nasr100> i have
<nasr100> ok
<halorgium> nasr100: http://myapp.com/ is a uri, not myapp.com ....
<nasr100> sorry..i was being lazy..you got the idea
<halorgium> no
<halorgium> i really didn't
<halorgium> assume nothing
<halorgium> please
<nasr100> ok so vim routes.rb
<halorgium> you said < nasr100> ok guys, i'll try to be more clear

Previous Page  Next Page

Search ircarchive.info