I think your <img src='' width="50" height="75"></img> is wrong
you can writen it like this : <img src='' width="50" height="75"></img>
 
<%=%>  evaluate the ruby _expression_., this can return result of the _expression_.
<%%> ddeclare ruby _expression_ or statement.
 
2006/5/18, Ben Lisbakken <[EMAIL PROTECTED]>:
I am only 3 days into rails, so please excuse the stupid question.

I am trying to access my database named Movies.  I am using a table
named movie.  I would like to pull the table entry with field
vname=rawr, and then take this entry's field vpic, and use that vpic
(assume its a url to an image) to display an image.

To begin with, I am having problems with displaying an image with
html + ruby.  In my index.rhtml I have two lines:
<% @pic = 'http://www.showfly.net/img/1.jpg' %>
<img src='' width="50" height="75"></img>

And it doesn't display the image.  What did I do wrong?  How do I
make the @pic be the url that i did a search for in my database?

Thank you,
Ben
_______________________________________________
Rails-spinoffs mailing list
Rails-spinoffs@lists.rubyonrails.org
http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs

_______________________________________________
Rails-spinoffs mailing list
Rails-spinoffs@lists.rubyonrails.org
http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs

Reply via email to