On 12/29/05, John Smith <john.smith@sherwoodmechanical.com>
wrote:> I have been using PHP for quite a bit and am beginning to learn more
> about RoR. One thing I used to to in PHP scripts (views in particular)
> was to have a tag such as:
>
> <base href="http://<?php echo
$_SERVER[''HTTP_HOST''] .
> $_SERVER[''SCRIPT_NAME'']; ?>" />
>
> so that URL rewriting would not throw off the paths to images, css, etc.
>
> Is there an equivalent way to do this in RoR?
Lucky for you, as long as you use the HTML helpers (image_tag,
stylesheet_link_tag, etc.) the URLs are created automatically such
that setting the <base> for your pages is unnecessary.
> Thanks,
>
> John
Sincerely,
Tom Lieber
tom@alltom.com
http://AllTom.com/