Skip to content
This repository has been archived by the owner on Feb 16, 2021. It is now read-only.

Use image_url instead of image_path in asset-path.js.erb #31

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

yukas
Copy link

@yukas yukas commented Apr 14, 2015

In our Rails app we have asset host different than the app host.

In Rails asset host can be configured for each environment as such:

config.action_controller.asset_host = "http://assets.someapp.com"

If we use image_path to generate swf url, we will have output like this: "http://www.someapp.com/assets/ZeroClipboard.swf".

What should be is url like this: "http://assets.someapp.com/assets/ZeroClipboard.swf".

If we use image_url instead, it will solve the problem.

* fails to load swf if config.action_controller.asset_host specified
@yukas yukas changed the title Use image_url instead of image_path Use image_url instead of image_path in asset-path.js.erb Apr 14, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant