0
jaydeee's Avatar, Join Date: Aug 2011
Go4Expert Member
Hi!

Thanks to your replies...

I agree that I will have to use both scripts but I do not know what is better for what function. I like for the counter functionality, I think it would be better to JS as I do not like this stored on the DB just starting and ending. For database function/transaction sure it would be PHP.

Thanks again.
0
CarlyFiorina's Avatar
Banned
Hey everyone,

You can also use JavaScript's Alert command to execute a PHP function that has the database routine in it. You can put any PHP code in a PHP function and let JavaScript use it. The only thing you have to remember is to echo something last that the Alert command can use.

Thanks and regards
Carly Fiorina
0
Scripting's Avatar, Join Date: Jun 2010
John Hoder
Quote:
Originally Posted by CarlyFiorina View Post
Hey everyone,

You can also use JavaScript's Alert command to execute a PHP function that has the database routine in it. You can put any PHP code in a PHP function and let JavaScript use it. The only thing you have to remember is to echo something last that the Alert command can use.

Thanks and regards
Carly Fiorina
Well, this is very clever idea ! Thumbs Up !
0
jaydeee's Avatar, Join Date: Aug 2011
Go4Expert Member
sounds a good idea however I'm really new to php and javascript that I hardly figure what you're suggesting, if you could give me the code I want that will be great for me.

thanks.