Ok, with a quick dirty hack I have achieve my goal :
Instead of myCollection[id][myField]
I give to the get_field_name
‘s function something like this : collection][id][field
.
So the generated code became :
name="widget-pricetable-ibsciss-widget[2][box][1]Widget : html 2 dimensional array doesn't work"
And my array just look perfect now :
array(3) {
["title"]=> string(12) "Global title"
["box"]=> array(2) {
[0]=> array(2) {
["title"]=> string(6) "title1"
["price"]=> string(6) "price1"
}
[1]=> array(2) {
["title"]=> string(6) "title2"
["price"]=> string(6) "price2"
}
}
["box_title"]=> string(9) "Box title"
}
PS : only for information purpose this is the get_field_name method from WordPress :
function get_field_name($field_name) {
return 'widget-' . $this->id_base . '[' . $this->number . '][' . $field_name . ']';
}