Ruby on rails 自定义数组在rails视图中显示不好
我有一个自定义的字符串URL数组,我将其添加到图像标签中,如下所示:Ruby on rails 自定义数组在rails视图中显示不好,ruby-on-rails,ruby,ruby-on-rails-3,Ruby On Rails,Ruby,Ruby On Rails 3,我有一个自定义的字符串URL数组,我将其添加到图像标签中,如下所示: <%= @attachment.each do |att| %> <div> <%= image_tag att %> </div> <% end %> 图像显示正确,但我在图像下面看到以下垃圾: [”http://localhost:8090/download/attachments/884794/DSC_0006.NEF?
<%= @attachment.each do |att| %>
<div>
<%= image_tag att %>
</div>
<% end %>
图像显示正确,但我在图像下面看到以下垃圾:
[”http://localhost:8090/download/attachments/884794/DSC_0006.NEF? 版本=1&修改日期=1343685834627“http://localhost:8090/download/attachments/885137/Sunflower.gif?version=1&modificationDate=1343720588175", "http://localhost:8090/download/attachments/885140/Spiked.gif?version=1&modificationDate=1343720548736"]将第一个标签更改为awesome,以及如何在该标签上创建链接?因此,当单击图像时,它会转到一个url?是否也可以传递另一个参数,例如我可以在控制器中使用的pageid?这些数据来自外部xmlrpc调用,因此我不能使用rails提供的功能,或者我可以将数据保存到一个伪rails模型中,并像普通rails模型一样使用它吗?