PHP gets the number of product_id and relative IDs of the order
<?phpforeach($val->groupresults (2) as $key 2=$val 2):?> <trclass= "Evedata" shoppingcartid= "<?=$val 2->id?> "Productid=" <?=$val 2->product ()->id?> "freightid=" <?=$val 2->product ()->freight_id?> "> <td width=" 10% "><a href=" <?=$val 2->product ()->strurl ()?> "target=" _blank ">$val 2->strpic ()?> "class= "Img75"/></a></td> <td width= "33%" > <a href= "<?=$val 2->product ()->strurl ()?> "target=" _blank "><?=$val 2->product ()->title?></a><br/> <?phpif($val 2->shop ()->isvip ()):?> <a href= "javascript:void (0)" title= "VIP merchant"class= "SHOP_ICO_VIP" ></a> <?phpendif;? > <?phpif($val 2->product ()->is_24h>0):?> <a href= "javascript:void (0)" title= "<?=$val 2->product () Delivery within->is_24h?> hours "class= "shop_ico_24h" ></a> <?phpendif;? > <?phpif($val 2->product ()->is_aftermarket>0):?> <a href= "javascript:void (0)" title= "after-sales protection"class= "Shop_ico_baozhang" ></a> <?phpendif;? > <?phpif($val 2->product ()->is_7goodsreturn>0):?> <a href= "javascript:void (0)" title= "<?=$val 2->product ()->is_7goodsreturn?>+ days "class= "Shop_ico_7" ></a> <?phpendif;? > <?phpif($val 2->product ()->is_15renew>0):?> <a href= "javascript:void (0)" title= "<?=$val 2->product ()->is_15renew?>+ days for new "class= "Shop_ico_15" ></a> <?phpendif;? > <?phpif($val 2->product ()->is_wholesale>0):?> <a href= "javascript:void (0)" title= "wholesale"class= "Shop_ico_pifa" ></a> <?phpendif;? > </td> <td width= "13%" > <iclass= "I_gray" > Model: </i><?=$val 2->attrimodel ()->title?><br/> <iclass= "I_gray" > Category: </i><?=$val 2->attricategory ()->title?> </td> <td><bclass= "Eveunitprice" ><?=$val 2->product ()->price?>a<?=$val 2->product ()->id?></b></td> <td> <input type= "text"class= "num evenum" shoppingcartid= "<?=$val 2->id?> "Value=" <?=$val 2->number?> "/><br/> <iclass= "I_gray" > Stock: </i><?=$val 2->product ()->inventorysurplus ()?> </td> <td><iclass= "I_16red Eveprice" ><?=$val 2->pricesum ()?></i></td> <?phpif($key 2==0):?> <td rowspan= "3" >Way:<select name= "Logistics_type" onchange= "Freightprice ()" > <option value= "1" > Pickup </option> <option value= "2" > Shipping </option> </select> <br/>Fees:<spanclass= "Evelogisticsprice" >0.00</span> </td> <?phpendif;? > </tr>
Ways to get jquery
/* get the Product ID and number of products */ var data=[]; $ ('. Evedata '). each (function(k,v) { var tmp = { ' prodcut_id ': $ (this). attr (' ProductId '), ' Count ': $ (this). Find ('. Evenum '). Val (), }; Data. push (TMP); }); Param. Product = data;
Get the order product_id and the number of orders