Search found 94 matches

by revocause
Mon Jun 25, 2007 2:30 pm
Forum: PHP - Code
Topic: turning database fetched values into $variables?
Replies: 60
Views: 18582

being rude? asking a question , only to get jumped by as many as can pile on for humiliation frenzy. L O L i felt that was pretty rude in my opinion. but feel free. Interpretation of my state of mind , i wasnt being rude. and 'looking at watch' comment. that was a joke. But it appears some o nthe fo...
by revocause
Mon Jun 25, 2007 2:13 pm
Forum: PHP - Code
Topic: turning database fetched values into $variables?
Replies: 60
Views: 18582

Forget it, I've figured it out myself. It was a simple line of code that for some reason I was so caught up in other bigger code, that i was brain farting on it. The code i was looking for was quite simply. $_SESSION['quantity'] = $row['quantity']; uhh... thanks for your 'help' in remembering that o...
by revocause
Mon Jun 25, 2007 2:07 pm
Forum: PHP - Code
Topic: turning database fetched values into $variables?
Replies: 60
Views: 18582

ok, simpler question then is, if you fetch data from databse . if you then turn that data into variable you can use on your page. example: <?php if(isset($_POST['product_main'])) { $sql = "SELECT quantity, baseprice, weight FROM b1_product WHERE id = " . $_POST['product_main']; $res = mysq...
by revocause
Mon Jun 25, 2007 12:12 pm
Forum: PHP - Code
Topic: turning database fetched values into $variables?
Replies: 60
Views: 18582

I'm not the type of person that likes things to be done for me. : ) so technically, I dont want you typing my code. I'm a bit of a control freak programmer , I like to do the programming and do it in a way that makes sense to me, not to someone else. But there are times when youre missing something,...
by revocause
Mon Jun 25, 2007 11:27 am
Forum: PHP - Code
Topic: turning database fetched values into $variables?
Replies: 60
Views: 18582

I'm impressed.
but youre still not seeing it.
by revocause
Mon Jun 25, 2007 11:11 am
Forum: PHP - Code
Topic: turning database fetched values into $variables?
Replies: 60
Views: 18582

Your code of // store session data $_SESSION['data'] = 'value'; the value is going to be dynamic. It cant be set as a constant. and by using $_SESSION['quantity'] =""; wont pass what ever the value becomes. probably because that value is empty. Also by using if(isset) . when the page reloa...
by revocause
Mon Jun 25, 2007 10:42 am
Forum: PHP - Code
Topic: turning database fetched values into $variables?
Replies: 60
Views: 18582

Yeah , Patrickg . That wouldve been my first steps . Seeing as how this forum for beginners isn't the best source for answers sometimes. It seemsto be more of a forum where they tell you = "we know that answer , but you dont.. why dont you go look for it yourself. " I'm not a total beginne...
by revocause
Mon Jun 25, 2007 10:17 am
Forum: PHP - Code
Topic: turning database fetched values into $variables?
Replies: 60
Views: 18582

Great, thats the purpose of my question. and how do i pass that? as I assumed that since it was placed into SESSION it would store it on that reload if its using an if(isset). If i knew what that line of code was to pass that variable, I'm assuming i wouldnt be here asking. Is there a way to make th...
by revocause
Mon Jun 25, 2007 10:07 am
Forum: PHP - Code
Topic: turning database fetched values into $variables?
Replies: 60
Views: 18582

I know there isnt any select menu names 'quantity1' but there is a variable. $quantiy1 = $quantity; the variable $quantity1 exists because im using it on my page 1 and its echoing out. quantity1 is obviously a newly created variable , but its value is dynamic because its set by the user selections. ...
by revocause
Mon Jun 25, 2007 9:31 am
Forum: PHP - Code
Topic: turning database fetched values into $variables?
Replies: 60
Views: 18582

So if i take $row out of the SESSION completely. and if i make it like this : <?php session_start(); if (isset($_POST['product_main'] )) { $_SESSION['quantity1'] = (isset($_POST['quantity1'])) ? $_POST['quantity1'] : ""; } ?> and if i use sessions on a new page to try to pick that up . by ...
by revocause
Mon Jun 25, 2007 9:14 am
Forum: PHP - Code
Topic: turning database fetched values into $variables?
Replies: 60
Views: 18582

But even after the select menu is selected, and the submit button used, your way of using SESSION returns the error now , instead of reloading the page. Now when I open the page, it opens normal, then i make selections and push the submit button. and it returns only = " there is no $row defined...
by revocause
Mon Jun 25, 2007 9:04 am
Forum: PHP - Code
Topic: turning database fetched values into $variables?
Replies: 60
Views: 18582

That made it so that it wont work now. Before, it was working ..except posting that warning. Now its only saying = " there is no $row defined here" but yet there should be, becaus eits fetching those values from the database, because it was just echoing them 10 minutes ago. Thats the probl...
by revocause
Mon Jun 25, 2007 8:35 am
Forum: PHP - Code
Topic: turning database fetched values into $variables?
Replies: 60
Views: 18582

Thats a select menu . a specific type of select menu that saves the user selections if they come back to the page or when page reloads. When they select an option within that 'product_main' select menu, it them uses the value of that option as the database ID number to a product. it then only fetche...
by revocause
Mon Jun 25, 2007 8:25 am
Forum: PHP - Code
Topic: turning database fetched values into $variables?
Replies: 60
Views: 18582

right, so whats the way around that?

I need the SESSION to carry the 'quantity' variables without the warning.
by revocause
Mon Jun 25, 2007 8:01 am
Forum: PHP - Code
Topic: turning database fetched values into $variables?
Replies: 60
Views: 18582

feyd | Please use , and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color] I edited ...