Displaying 20 results from an estimated 3000 matches similar to: "relative_url_root and problems with CSS url()"
2007 Oct 11
2
relative_url_root and javascript_include_tag
Hi. In my environment.rb, I have:
ActionController::AbstractRequest.relative_url_root = "/foobar"
In my layout, I have:
<%= javascript_include_tag :defaults %>
Question 1:
I am getting an error:
ActionController::RoutingError (no route found to match
"/javascripts/prototype.js" with {:method=>:get}):
When I remove the relative_url_root, everything works great.
2006 Aug 15
0
Using config.action_controller.asset_host with ActionController::AbstractRequest.relative_url_root
I''m looking for some help with an issue I''m having using an external
asset host. I''ve got the lines below in my environments/development.rb
file.
# Enable serving of images, stylesheets, and javascripts from an asset server
config.action_controller.asset_host = "http://assets.example.com"
#make rails think it lives in /app
2009 Jul 20
1
CSS issue when using SubUri and Passenger
I am testing another application in local
in my environment.rb I wrote
config.action_controller.relative_url_root = "/elnino"
config.action_controller.asset_host = "http://opticoaching.local"
I defined correctly the vhost (I have already odne it for another app
which is running well...)
<VirtualHost *:80>
ServerName opticoaching.local
DocumentRoot
2005 Dec 04
3
Relative URL
I''m trying to use a non default webserver with Rails and succesfully
does this by calling the disptacher directly, by setting the environment
variables: REQUEST_URI and SCRIPT_NAME
My problem is that the relative path is incorrect when I identify myself
as anything else than apache. In request.rb the @@relative_url_root is
only set when the webserver is apache. Is this default wanted
2006 Mar 07
13
hosting multiple rails apps in one webroot?
It''s actually REALLY easy with lighttpd on linux.
Two apps...
Myserver.com/code/ => /apps/code/
Myserver.com/test/ +> /apps/test/
Each application needs this in the environment.rb
/apps/code/config/environment.rb
ActionController::AbstractRequest.relative_url_root = "/code"
/apps/test/config/environment.rb
ActionController::AbstractRequest.relative_url_root
2010 Jul 08
0
Rails3 -- Replacement for ActionController::Base.relative_url_root?
I have a post on stackoverflow which outlines the problem I am having:
http://stackoverflow.com/questions/3181746/what-is-the-replacement-for-actioncontrollerbase-relative-url-root
In short, I ported a rails 2.x to rails3 and started getting a
deprecation warning for using
ActionController::Base.relative_url_root. I switched to using
config.action_controller.relative_url_root and while any
2006 Jun 21
3
multiple apps one virtual host one domain
I''m trying to achieve the following:
Having a development server that runs multiple rails apps running wihout
creating a different virtual host for each apps.
my documentRoot is therefore /var/rails for my whole config
http://myserver/app1/controller/action -> (/var/rails/app1/...)
http://myserver/app2/controller/action -> (/var/rails/app2/...)
I''m under apache 1.3
mod
2008 Jan 31
2
Facebooker and file_column
Facebooker URL Rewriter stuff overloads ActionController::AbstractRequest.relative_url_root, causing a conflict with the plugin file_column and possibly other utilities. file_column constructs image URLs using the server host and relative_url_root
This is not related to the sandbox patch I added to the rewriter. Facebooker overloaded relative_url_root before I touched it.
I''ve
2009 May 06
0
Setting config.action_controller.relative_url_root isn't working
Hi everyone,
I''m trying to set the "config.action_controller.relative_url_root"
config value but it isn''t working:
config.action_controller.relative_url_root = "/de"
When i try to view the http://localhost:3000/de page it gives me a
"Routing Error", but if I try http://localhost:3000/ it works
perfectly. Any idea about what this might be?
-
2009 Mar 26
0
Error On relative_url_root
I''m attempting to mash together Adva CMS'' Fckeditor and the Fckeditor
plugin provided by Scott Rutherford.
http://blog.caronsoftware.com/2008/6/21/fckeditor-plugin-0-5-1-released
The Scott''s plugin has a controller than handles the Fckeditor file
upload and browse, but it errors out on the following lines.
def upload_directory_path
uploaded =
2006 Jan 04
1
[BUG?] image_tag
i''ve got the latest ruby and rails on this box and am seeing that image_tag
will turn something like
/foo/bar.jpg
into
/foo/foo/bar.jpg
in the following situation:
/ror/foo/public
/var/www/html/foo -> /var/ror/foo/public/
image_tag("/foo/bar.jpg")
this is exactly how compute_public_path is written to work:
def compute_public_path(source, dir, ext)
2006 Mar 06
7
Set base url?
I have an application running on a Lighttpd instance which is proxied by an
Apache server. It seems to work fine but my urls are incorrect: all urls
reference / which is not where my application runs at the Apache server.
How do I set the base url of a Rails application?
My Apache has the following proxy rules:
ProxyPass /hieraki http://localhost:3001
ProxyPassReverse /hieraki
2006 Mar 07
0
setting relative_url_root for static files in webrick
Hi,
I am using webrick and want my application not be available on
http://localhost:3000/ but http://localhost:3000/rails.
So I found out I can set
ActionController::AbstractRequest.relative_url_root = "/rails"
in environment.rb.
This works for controllers without further modifications. But for the
static files, I have to put a "rails" directory into the public
directory, and
2007 Feb 08
2
cannot set ENV['RAILS_RELATIVE_URL_ROOT']
i am on lighttpd now, and i cannot set
cannot set enviroment variable:
i added this line to enviroment.rb, but it doesn not work!!
ENV[''RAILS_RELATIVE_URL_ROOT''] = ''something''
links on my page are ok, but all links to images, stylesheets etc are
broken, (because relative_url_root returns ''''), what else can I do?
thanks. f.
--
Posted via
2006 Aug 31
2
Url rewriting for random urls
Hello,
I have discovered the good use of stylesheet_link_tag and
javascript_include_tag (I''m still learning) and it is very useful because I
have to use the relative_url_root way.
Now I wonder how I can use that for other URLs. I want a background image
for a table cell so I have to write something like:
<td align=''right'' valign=''bottom''
2006 Jul 10
7
Rails app in a subdirectory via Mongrel
I''m trying to make Mongrel the default web server for Typo, but I''m running
into a problem. Is there an easy way to run a Rails app in a subdirectory (
http://foo/blog instead of http://foo/) with Mongrel? For most apps, I''d
just change routes.rb to include the prefix that I wanted, but that won''t
really work with Typo--I''d rather not require a few
2009 Apr 06
2
URL issue localhost/mongrel vs remote-server/apache
Hi all
I have a small issue I ma trying to solve (at least to understand..)
I am testing an app on my remote_server (w Apache/Passenger) in a
sub_URI, without any problem (I tested also the same app, locally w
Apache too)
in my environment.rb , I have initialized
config.action_controller.relative_url_root = "/my_subURI"
config.action_controller.asset_host =
2006 Jan 14
2
file_column, ActionMailer, and tests
Hi,
Say I have a model Event that has a file_column called ''pdf''.
I want to send out emails that contain the URL for the pdf file that''s
associated with the Event. I also want to test the emails, so I''d
need to be able to get at the URL for the pdf inside my unit tests.
I don''t see how I can use url_for_file_column in this situation.
Doing <%=
2008 Nov 26
3
fckeditor_textarea
hi, i am currently using rails version 2.2.2.
and using fckeditor_textarea.
here is the code:
<%= fckeditor_textarea(:emailcontent,:body, {:toolbarSet => ''Basic'',
:width => ''100%'', :height => ''100%''}) %>
where emailcontent is the model(object) name,
and body is method.
but it''s not working,however
2013 Mar 10
2
css url paths when moving it to a different folder
Hey. Its simple quation, but have litle problem with this.
Its my path for css - assets/content/stylsheets/my.css
Its path picture for background url - assets/images/picture.gif
I do the following in my.css background: transparent
url(../../images/picture.gif).
but the path is not correct, the image is not found. I tried with one
../ and easy images/picture.gif. Not work. When i add picture in