I create an array from here. This is my Ajah or jQuery basket. Even he got confused.
Arrays.push(thisID); var t = $('.cart-total span').html(); t = Number(t) + Number(qiymet) $('.cart-total span').html(t.toFixed(2)); $('#total-hidden-charges').val(t.toFixed(2)); $('#left_bar .cart-info').append('<div class="shopp" id="each-' + thisID + '"><span class="label">' + mal_name + '</span><span style="float:left;width:102px;border-right-width: 2px;border-right-style: solid;border-right-color: #ccc;"><span class="az"></span><span class="mal_say">1</span> ' + eded + '<span class="cox"></span></span><span class="price"><em>' + qiymet + '</em> man.</span><span class="endir"><input type="text" id="end" size="3" style="height:8px; font-size:11px; margin-top:-6px;"/> man.</span><span class="hesab" id="hesab"><em>' + qiymet + '</em> man.</span><img src="img/remove.png" class="remove" /><br class="all" /></div>');
and in the array just as .label is being pushed, this is the type of product name, the guys in my array are not the correct mine.
$('#save').livequery('click', function () { var newarr = new Array(); arr = $('.label'); for (i = 0; i < arr.length; i++) newarr.push($(arr[i]).html()); alert(newarr); $.post('save.php', { arr: newarr }, function (data) { $('#result').html(data); }); });
Help me please.
Here is my pkhp, which takes an array.
<? if (isset($_POST['arr'])) { echo '<div id="iframe"> <div class="shopp"> <span class="label">'.$_POST['arr'].'</span> <span class="mal_sayi">5 kletka</span> <span class="mal_umum_qiymet">цена</span> <span class="endir">скидка</span> <span class="hesab">сумма</span> <br class="all" /> </div><br> </div>'; } ?>
I accept the array, but I can not cram into the loop, only one item is displayed. If it is possible to shove without an array, all this is in the database, how?