Searching a word

Hai
I want to search a word in the xml file using ruby
I dont know , how to do that.

Example:
new
hussain.jpg

From this example ,i want to get the hussain.jpg
can any body tell me
Ok

From this example ,i want to get the hussain.jpg
can any body tell me
Ok


Posted via http://www.ruby-forum.com/.

Try this.

str = “new\nhussain.jpg”
str =~ /(.*?)</image>/
p $1

Harry