Jump to content

PHP shopping cart not updating qtys in ie8 and ff 5.0


tdeez173

Recommended Posts

I am new to php but I have followed a book to create a shopping cart, which works in ie 7 and ff 3.0.10, but not in ie 8 and ff 5.0. Just the qtys do not update in ie 8 and ff 5.0. I would appreciate and help you could offere I have googled for hours trying diffrenent solutions.

 

Here is the code for my change qtys script.

<?php

session_start();

 

include('tlc_Sc_scrts/tlc_sc_fns.php');

$conn = db_connect();

mysql_select_db ( 'tdeez173300', $conn);

  $sessid = session_id();

 

if (isset($_POST['mod_s'])){

$mod_s = $_POST['mod_s'];

}

if (isset($_POST['mod_h'])){

$mod_h = $_POST['mod_h'];

}

if (isset($_POST['mod_f'])){

$mod_f = $_POST['mod_f'];

}

if (isset($_POST['hidden_ch'])){

$hidden_ch=$_POST['hidden_ch'];

}

if (isset($_POST['menu_id'])){

$menu_id=$_POST['menu_id'];

}

 

$query2 = "SELECT * FROM temp_data_table WHERE carttemp_hidden='$hidden_ch'";

$results2 = mysql_query($query2) or (mysql_error());

 

$query_act =  "update temp_data_table set carttemp_qty_s='$mod_s', carttemp_qty_h='$mod_h', carttemp_qty_f= '$mod_f' where carttemp_session='$sessid' and carttemp_menu_id='$menu_id'";

$results_act = mysql_query($query_act) or die(mysql_error());

header("location: shoppingCart.php?action=change");

Link to comment
Share on other sites

Here is my shopping cart code

 

<?php

session_start();

 

include('tlc_Sc_scrts/tlc_sc_fns.php');

$conn = db_connect();

mysql_select_db ( 'tdeez173300', $conn);

  $sessid = session_id();

 

if (isset($_POST['mod_s'])){

$mod_s = $_POST['mod_s'];

}

if (isset($_POST['mod_h'])){

$mod_h = $_POST['mod_h'];

}

if (isset($_POST['mod_f'])){

$mod_f = $_POST['mod_f'];

}

if (isset($_POST['hidden_ch'])){

$hidden_ch=$_POST['hidden_ch'];

}

if (isset($_POST['menu_id'])){

$menu_id=$_POST['menu_id'];

}

 

$query2 = "SELECT * FROM temp_data_table WHERE carttemp_hidden='$hidden_ch'";

$results2 = mysql_query($query2) or (mysql_error());

 

$query_act =  "update temp_data_table set carttemp_qty_s='$mod_s', carttemp_qty_h='$mod_h', carttemp_qty_f= '$mod_f' where carttemp_session='$sessid' and carttemp_menu_id='$menu_id'";

$results_act = mysql_query($query_act) or die(mysql_error());

header("location: shoppingCart.php?action=change");

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.