I have a string that has a value that I want to be in quotes. Following is the text which I currently have:
text = "#{value1} has viewed your #{value2}"
I want value2
to be in quotes. I want:
text = ""#{value1} has viewed your "#{value2}""
How can I implement this? Any help will be appreciated.
text = %Q|#{value1} has viewed your "#{value2}"|
text = "#{value1} has viewed your \"#{value2}\""
or even:
text = "#{value1} has viewed your" '"' "#{value2}" '"'