Hi guys, I am new to this ajax idea and read a lot of tutorials, but I haven´t find what works for me.
Basically, I need a button (in let´s say product_info.php) whose onclick will call up a php-and-mysql function.
I would like to have my ajax function in product_info.php call a php-and-mysql function *inside* the same product_info.php.
I don´t really like the idea presented in most tutorials, where a new php file is created, because:
(1) the user of my shop can access this php file since it´s linked to the button, and
(2) I tried but have errors connecting to database even with correct username, password, etc.
If anyone has a better and more simple idea than ajax, please let me know!! Thanks in advance!