Jump to content

get last position in the string


robert_gsfame

Recommended Posts

I have this, assume that var input is dynamic where i can change at anytime i want

 

var input="my name is james from canada x";

i really wish to remove the x from the var input.....in php i can use substr($mystring,"",-1)

and i will get my name is james from canada

 

how can i do this in javascript...

Link to comment
https://forums.phpfreaks.com/topic/196022-get-last-position-in-the-string/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.