# Loadind a swf flash animation placed in the public directory

**URL:** <https://www.ruby-forum.com/t/loadind-a-swf-flash-animation-placed-in-the-public-directory/106307>\
**Category:** Rails\
**Created:** [June 8, 2007, 10:53am UTC](https://www.ruby-forum.com/t/loadind-a-swf-flash-animation-placed-in-the-public-directory/106307 "2007-06-08T10:53:47Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [June 8, 2007, 10:53am UTC](https://www.ruby-forum.com/t/loadind-a-swf-flash-animation-placed-in-the-public-directory/106307/1 "2007-06-08T10:53:47Z")

</div>

Hello everyone,

I am trying to include a swf flash animation in a view with this code  
in the rhtml file :

* * *

 -------------

… where ‘flash/entrance\_hall.swf’ is placed in the public directory.

It seems that rails interprets it as a link to a controller (named  
HomeController in this example) since this error is launched :  
ActionController::RoutingError (no route found to match “/home/flash/  
entrance\_hall.swf” with {:method=\>:get}):

Since \<%= image\_tag ‘file’ %\> is necessary to replace the html version  
of ![]() I was wondering if there was a flash\_tag  
that could tell rails my ‘flash/entrance\_hall.swf’ is not a call to a  
controller.

Or maybe there is another solution, may anyone help me ?

Thanks,  
Guillaume

---

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [June 8, 2007, 2:33pm UTC](https://www.ruby-forum.com/t/loadind-a-swf-flash-animation-placed-in-the-public-directory/106307/2 "2007-06-08T14:33:22Z")

</div>

I’ve found on another what was wrong : the swf file has to be located  
with absolute path '/‘flash/entrance\_hall.swf’ and not ‘flash/  
entrance\_hall.swf’ (/ at the beginning missing).

Guillaume
