Replacing filename with a Regex in JavaScript -


I need to change a button using javascript by using reggeks and wondering how to do it. I know how to get to the source of the button, but I have to add the file name and add some text to "short" or "-next", depending on two options which can be toggled here Different file names are given:

  /images/button.png/images/button-next.png   

Any help would be greatly appreciated.

one insert before the last point, you do

  results = subject. Location (/(?=\.[^.]+$)/ g, "-next");   

To remove a -next before the last point:

  result = topic. Location (/ - Next (? ^ ^ ^.] + $) / G, "");    

Comments