Its because i have SESSIONS using newly created variables that are 'child' variables that are dependent on select menu variables.
so say for example you have a select menu that has 2 options.
option 1 = quantity
option 2 = price
and if you make a $new_variable that does something like
(example)
Code: Select all
$new_variable = $quantity * $price;assuming the quantity and price $variables are already created.
But then what happens is, if you use a regular SESSION like as example:
Code: Select all
<?php
session_start();
if (isset( $_POST['quantity'], $_POST['price'])) {
$_SESSION['quantity'] = $_POST['quantity'];
$_SESSION['price'] = $_POST['price'];
----> $_SESSION['new_variable'] = $_POST['new_variable'];
}
?>When i put that in. The Warning/error shows.
It will work and actually pass the data and everything, but it puts that Warning on the page and thats no good.
So , how can I pass this variable as its doing, but do it in a way that warning/error wont pop up across the page?
I'm considering only passing the top level raw data, and doing the math functions on other pages. That would sorta suck.
So is there a simple way to pass that data? or does the math have to be done on each new page with the raw data from select menu values?