I have a ruby string like
@t3= ["", "Overview", "<span>Risks</span>", "<span>Scrumbler</span>", "Roadmap"]
return from the database i want to get it into the array but it doesnot get it as array
I try to dp the following but it doesnot work.
<% @t=@t3.tr('[]', '').split(',').map(&:to_s) %>
How can I do that?
Yes I solved it by using.
<% @t=@t3.tr('[]', '').split(',').map! {|item| item.to_s.strip } %>
Thanks