lastIndexOf(
  string,      要查找的字符串
  int         (可选)开始查找位置,不能大于被查找字符串长度
)

返回值:找到>=0, 未找到-1




示例:

var s = "abcdef"; s.lastIndexOf("ef"); 返回:4