0

I'm trying to create Anchor tags using values in my DB for the name. That way it's easy for me to call them from another page.

<a name="<%= sailing_class.sort_order %>"</a>

But the value from sailing_class.sort_order never appears.

All help is greatly appreciated. I'm on Rails 3.2

Scott S.
  • 749
  • 1
  • 7
  • 26

1 Answers1

1

You're missing a > (closing <a), so the html is not vaild, and an anchor should be with an id attribute instead of name . Try

<a id="<%= sailing_class.sort_order %>"></a>
Community
  • 1
  • 1
Baldrick
  • 23,882
  • 6
  • 74
  • 79
  • You should accept the answer then (the check at the left of the answer), and you should do so also for your other questions. – Baldrick Jan 05 '13 at 19:15