<input type="checkbox" value="1,1" name="x" />
<input type="checkbox" value="2,2" name="x" />
<input type="checkbox" value="3,3" name="x" />
<input type="checkbox" value="4,4" name="x" />
<input type="checkbox" value="5,5" name="x" />
<input type="checkbox" value="6,6" name="x" />
<input type="checkbox" value="7,7" name="x" />request.Form["x"] 的时候 默认 的分割符号是,
我 想换符号 不知道该怎么做?? 把分割符号换掉
有没有办法?
<input type="checkbox" value="2,2" name="x" />
<input type="checkbox" value="3,3" name="x" />
<input type="checkbox" value="4,4" name="x" />
<input type="checkbox" value="5,5" name="x" />
<input type="checkbox" value="6,6" name="x" />
<input type="checkbox" value="7,7" name="x" />request.Form["x"] 的时候 默认 的分割符号是,
我 想换符号 不知道该怎么做?? 把分割符号换掉
有没有办法?
<input type="checkbox" value="2|2" name="x" />
<input type="checkbox" value="3|3" name="x" />
<input type="checkbox" value="4|4" name="x" />
<input type="checkbox" value="5|5" name="x" />
<input type="checkbox" value="6|6" name="x" />
<input type="checkbox" value="7|7" name="x" />if(request.Form["x"]!=null){
string []arrayStr=request.Form["x"].ToString().Split(",");}
Regex r = new Regex("[,|_;]");//把涉及到的分割符写入[,|_;]中括号里
string[] s = r.Split("1,2");