About 23,673 results: "mysql_query"
Page 2 of 50
Filter Results
Sources
Languages
Filter Results
Try Search On







  1. 	$sSQL = "SELECT * FROM cart WHERE cartCompleted=0 AND cartSessionID='" .  session_id() . "'";
  2. 	$result = mysql_query($sSQL) or print(mysql_error());
  3. 			$sSQL .= " OR (cartCompleted=0 AND cartDateAdded<'" . date("Y-m-d H:i:s", time()-($delAfter*60*60*24)) . "')";
  4. 		$result = mysql_query($sSQL) or print(mysql_error());
  5. 			}
  6. 			if($delAfter != 0) mysql_query("DELETE FROM orders WHERE ordID IN (" . $delcart . ")") or print(mysql_error());
  7. 			mysql_query("DELETE FROM cart WHERE cartID IN (" . $delstr . ")") or print(mysql_error());
  8. 			mysql_query("DELETE FROM cartoptions WHERE coCartID IN (" . $delstr . ")") or print(mysql_error());
  9. 		}
  10. 		$sSQL = "SELECT cartProdID,SUM(cartProdPrice*cartQuantity) AS thePrice,SUM(cartQuantity) AS sumQuant,pSection,COUNT(cartProdID),pExemptions,pTax FROM products INNER JOIN cart ON cart.cartProdID=products.pID WHERE cartCompleted=0 AND cartSessionID='" . $thesessionid . "' GROUP BY cartProdID,pSection,pExemptions,pTax";
  11. 		$cdresult = mysql_query($sSQL) or print(mysql_error());
  12. 			$sSQL = "SELECT SUM(coPriceDiff*cartQuantity) AS totOpts FROM cart LEFT OUTER JOIN cartoptions ON cart.cartID=cartoptions.coCartID WHERE cartCompleted=0 AND cartSessionID='" . $thesessionid . "' AND cartProdID='" . $cdrs["cartProdID"] . "'";
  13. 			$cdresult2 = mysql_query($sSQL) or print(mysql_error());
  14. 					$sSQL = "SELECT topSection FROM sections WHERE sectionID=" . $thetopts;
  15. 					$result2 = mysql_query($sSQL) or print(mysql_error());


  1. 	$sql = "SELECT pass FROM users WHERE pass = '" . $pass . "' AND user = '" . $user ."' AND user_level = 9 ";
  2. 	$res = mysql_query($sql);
  3. 	$sql = "SELECT pass FROM users WHERE pass = '" . $pass . "' AND user = '" . $user ."' AND user_level = 2 ";
  4. 	$res = mysql_query($sql);
  5. 	$sql = "UPDATE users SET pass = '" . $new_password . "' WHERE user = '" . $user . "'";
  6.  	$res = mysql_query($sql);
  7. 	$sql = "SELECT user FROM users WHERE user = '" . $user ."' ";
  8. 	$res = mysql_query($sql);
  9. 	$sql = "UPDATE users SET last_active = '" . $last_active . "' WHERE user = '" . $user . "' ";
  10. 	$res = mysql_query($sql);
  11. 	$sql = "UPDATE env_settings SET site_url = '" . $url . "', admin_name = '" . $admin_name . "', admin_email = '" . $admin_email . "', site_mode = '" . $site_mode . "', listings_per_page = " . $listings_per_page . ", users_per_page = " . $users_per_page . ", listings_stored_path = '" . $listings_stored_path . "', users_stored_path = '" . $users_stored_path . "', site_name = '" . $site_name . "', description = '" . $description . "', keywords = '" . $keywords . "', site_lang = '" . $site_lang . "', site_template = '" . $site_template . "' ";		
  12. 	$res = mysql_query($sql);
  13. 	$sql = "DELETE FROM users WHERE id = " . $id . ""; 
  14. 	$res = mysql_query($sql);
  15. 	$sql = "UPDATE users SET user = '" . $user . "', email = '" . $email . "', first_name = '" . $first_name . "', last_name = '" . $last_name . "', phone = '" . $phone . "', alt_phone = '" . $alt_phone . "', fax = '" . $fax . "', address = '" . $address . "', city = '" . $city . "', state = '" . $state . "', zip = '" . $zip . "', user_level = '" . $user_level . "', admin_notes = '" . $admin_notes . "'  WHERE id = " . $id . "";		
  16. 	$res = mysql_query($sql);


  1. 	// Check last heartbeat and make sure it was more than X seconds ago
  2. 	$watchdog_heartbeat_active = mysql_result(mysql_query("SELECT * FROM `main_loop_status` WHERE `field_name` = 'watchdog_heartbeat_active' LIMIT 1"),0,"field_data");
  3. 	{
  4. 		mysql_query("UPDATE `main_loop_status` SET `field_data` = '" . time() . "' WHERE `main_loop_status`.`field_name` = 'watchdog_last_heartbeat' LIMIT 1");
  5. 		// Set loop at active now
  6. 		mysql_query("UPDATE `main_loop_status` SET `field_data` = '1' WHERE `main_loop_status`.`field_name` = 'watchdog_heartbeat_active' LIMIT 1");
  7. 	// Are we to remain active?
  8. 	$loop_active = mysql_result(mysql_query("SELECT * FROM `main_loop_status` WHERE `field_name` = 'watchdog_heartbeat_active' LIMIT 1"),0,"field_data");
  9. 		// Set the working status of 2
  10. 		mysql_query("UPDATE `main_loop_status` SET `field_data` = '2' WHERE `main_loop_status`.`field_name` = 'watchdog_heartbeat_active' LIMIT 1");
  11. //*****************************************************************************************************	
  12. 		$script_loop_active = mysql_result(mysql_query("SELECT * FROM `main_loop_status` WHERE `field_name` = 'main_heartbeat_active' LIMIT 1"),0,"field_data");
  13. 		$script_last_heartbeat = mysql_result(mysql_query("SELECT * FROM `main_loop_status` WHERE `field_name` = 'main_last_heartbeat' LIMIT 1"),0,"field_data");
  14. 
                        
  15. 
                        
  16. 		$script_loop_active = mysql_result(mysql_query("SELECT * FROM `main_loop_status` WHERE `field_name` = 'generation_heartbeat_active' LIMIT 1"),0,"field_data");
  17. 		$script_last_heartbeat = mysql_result(mysql_query("SELECT * FROM `main_loop_status` WHERE `field_name` = 'generation_last_heartbeat' LIMIT 1"),0,"field_data");









Back to Top