Hi I'm very new to rails and came up with this issue. I need your help. Please.
Activeadmin parses the code as raw text so i used<%= raw(@classroom.body) %>
in my show.erb to unescape the html tags. but i figured this is the reason why it escapes the ruby video_tag.
I checked out the activeadmin arbre but didn't understand it. i also tried using html video tags but for some reason it shows the video template but doesn't connect to the video file in app/assets/videos.
But when I parse the HTML code directly in the show.erb, the video works perfectly.
The video file can be found in app/assets/videos/Heather.mp4
<%= video_tag "Heather.mp4", :controls => true %>
The first picture is how it looks like in the web browser The second is the html code in active admin The third is my show.erb file
The raw
method produces raw HTML, not raw ERB. You won't be able to parse your <%= %>
tags from there.
Reference the Rails Docs for raw