Ich versuche gerade eine Url als Parameter an eine bestehende Url
anzuhängen, aber leider bekomme ich immer eine Object ID statt der
eigentlichen Url angehängt.
So klappt das mit Open-Uri natürlich nicht ....
@url = Search.new(params[:url])
@details = Hpricot(open("http://localhost:3000/details/#{@url}"))
-> details/#<Search:0x3a56268>
Was habe ich denn falsch gemacht?
--
Mario Schröder | http://www.ironschroedi.com/de/
Office: +49 361 2152062
Phone: +49 34464 62301 Cell: +49 163 27 09 807
http://www.xing.com/go/invite/6035007.9c143c
on 2009-03-02 21:05
on 2009-03-02 21:17
Hallo, Mario! @url ist ein Objekt der Klasse search.Du willst doch sicher nur dessen id: Also einfach @url.id aufrufen (oder to_param). Grüße Nicolai
Please log in before posting. Registration is free and takes only a minute.
Existing account
(Switch to SSL-encrypted connection)
NEW: Do you have a Google/GoogleMail or Yahoo account? No registration required!
Log in with Google account | Log in with Yahoo account
Log in with Google account | Log in with Yahoo account
No account? Register here.