結果 : javascript substring before last occurrence of character