比如说我有以下数据需要传输到Action页面在A页面通过form表单的post提交数据到Action
goods[0][code]=3 goods[0][name]=fds goods[0][price]=1000 goods[1][code]=3 goods[1][name]=fdsfd goods[1][price]=2000
那么现在的问题是在Action如何才能获取这一系列的数值?
小伙看你根骨奇佳,潜力无限,来学PHP伐。
Use composite objects to map
Submit the form content into a JSON string on the client, such as:
{ goods: [ good: { code: 3, name: 'fds', price: 1000 }, ... ] }
Use Jackson or GSON on the server side to restore the JSON string to an object.
Use composite objects to map
Submit the form content into a JSON string on the client, such as:
Use Jackson or GSON on the server side to restore the JSON string to an object.