take only some charachter from string js code example Example: straforma in string js var x = new String("Una nuova stringa");