正規表現の助けが必要
var s = "left=123,top=345,width=123, height= 34, center=yes, help=no,resizable=yes, status=now";
すべてのパラメーターを取得する必要があります (名前 -> 値)
このようにしてみました/(\w+)\s?=(\S+)[\s|,]/
結果:
array(3) {
[0] =>
array(3) {
[0] =>
string(28) "left=123,top=345,width=123, "
[1] =>
string(12) "center=yes, "
[2] =>
string(23) "help=no,resizable=yes, "
}
[1] =>
array(3) {
[0] =>
string(4) "left"
[1] =>
string(6) "center"
[2] =>
string(4) "help"
}
[2] =>
array(3) {
[0] =>
string(22) "123,top=345,width=123,"
[1] =>
string(4) "yes,"
[2] =>
string(17) "no,resizable=yes,"
}
}