Horje
js split last occurence Code Example
js split last occurence
  var lastIndex = src.lastIndexOf('.');

  // Add the string before the last .
  // Return updated string, this will update the src attribute value
  return src.substr(0, lastIndex) + '-fx' + src.substr(lastIndex);




Javascript

Related
javascript how to create an array from 1 to 100 Code Example javascript how to create an array from 1 to 100 Code Example
change object key name javascript es6 Code Example change object key name javascript es6 Code Example
javascript check if elements of one array are in another Code Example javascript check if elements of one array are in another Code Example
413 payload too large nodejs Code Example 413 payload too large nodejs Code Example
es6 forEach Code Example es6 forEach Code Example

Type:
Code Example
Category:
Coding
Sub Category:
Code Example
Uploaded by:
Admin
Views:
9