Well, I thought that the difference between writeln/write would correct the problem. I didn't realize that the page source prior to being displayed on the browser still shows the javascript link and it's up to the browser to display the number output by the script. I guess you could call that my first lesson in javascript. I still think that document.write is the best thing to use here.
So, essentially, I am trying to get the value from the javascript to update my products, ie:
update products set products_quantity = '[output from javascript]' where products_id = '2234567';
Instead of getting a number from the javascript, when I view the page source, I just get the javascript link which doesn't insert into a mysql integer cell very well :)
Is it feeble for me to continue to try to get the javascript to give me something useful for this purpose (from the client side, anyway)? Would I need to write the output of the javascript to a file and then read out the file to update the database? Just using the javascript to update 25 products on a page already adds quite a lot of overhead to the display of the page, so writing to a file and reading out of it wouldn't be feasible.
I'm new to javascript, but fairly well versed in php/mysql. Just trying to provide some feedback here to help things along.
--
Rick