I want to extract the mailto value from the given string and also want to remove the html tag at the same time.
ex -> "<mailto:demomail@gmail.com|demomail@gmail.com> helo<p> bye </p>"
output -> demomail@gmail.com helo bye
If I use this -> gsub(/<[^>]*>/,'')
output -> helo bye
If I use this -> ActionView::Base.full_sanitizer.sanitize(html_string, :tags => %w(img br p), :attributes => %w(src style))
output -> helo bye
Can you suggest me how can i get my expected output?
expected output -> demomail@gmail.com helo bye