在ecshop的购物流程页,商品列表加一个复选框,并实现与之相对应功能的代码

WBOY
Release: 2016-06-23 13:22:40
Original
960 people have browsed it


回复讨论(解决方案)

我在flow.dwt中加入了复选框,代码如下图所示:

结果如下图所示:


求与之对应的复选框的功能???

你不是都写好了吗?

你不是都写好了吗?



我是把样式写好了,但是没有与之对应的功能,我想知道与之对应的功能怎么搞。

比如删除,点击的时候获取goods_id 也就是这个复选框的值,用ajax把这个id传到你的php,然后删除。

比如删除,点击的时候获取goods_id 也就是这个复选框的值,用ajax把这个id传到你的php,然后删除。



这个我能理解,选择与取消全选,或选择一个,或者两个的怎么识别。这个ecshop我还是去年用过的,好久没有用了,现在突然不知道怎么下手了,多谢朋友能抽时间回答我的问题

<?phpif (isset($_POST['submit'])){	print_r($_POST['select']);}?><form action='' method=post><input name="select[]" type="checkbox" value="goods_id_1" /><input name="select[]" type="checkbox" value="goods_id_2" /><input name="select[]" type="checkbox" value="goods_id_3" /><input name="select[]" type="checkbox" value="goods_id_4" /><input type=submit name=submit></form>
Copy after login
Copy after login

<?phpif (isset($_POST['submit'])){	print_r($_POST['select']);}?><form action='' method=post><input name="select[]" type="checkbox" value="goods_id_1" /><input name="select[]" type="checkbox" value="goods_id_2" /><input name="select[]" type="checkbox" value="goods_id_3" /><input name="select[]" type="checkbox" value="goods_id_4" /><input type=submit name=submit></form>
Copy after login
Copy after login




thank you

请问 楼主怎么实现 该功能的啊 

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!