JavaScript Разделите строку на две части
var str = "How are you doing today?";
var res = str.split();
var str = "How are you doing today?";
var res = str.split();
var someString = "A04.3 A new Code";
var index = someString.indexOf(" "); // Gets the first index where a space occours
var id = someString.substr(0, index); // Gets the first part
var text = someString.substr(index + 1); // Gets the text part