Match returning a string instead of object
Posted
by Pablo
on Stack Overflow
See other posts from Stack Overflow
or by Pablo
Published on 2010-03-22T07:02:49Z
Indexed on
2010/03/22
7:11 UTC
Read the original article
Hit count: 358
This simple regex matching returns a string instead of an object on every browser but the latest firefox...
text = "language. Filename: My Old School Yard.avi. File description: File size: 701.54 MB. View on Megavideo. Enter this, here:"
name = text.match(/(Filename:)(.*) File /);
alert(typeof(name));
as far as i know this the match function is suppose to return an object (Array). Has anyone come across this issue?
© Stack Overflow or respective owner