Speedy84 Posted November 3, 2008 Share Posted November 3, 2008 is there a way to activate a function by using "onclick" or "onchange" in a dropdown menu? something like this <option onclick="<?php function(); ?>">Text</option> Quote Link to comment https://forums.phpfreaks.com/topic/131161-activate-function-in-how/ Share on other sites More sharing options...
Adam Posted November 3, 2008 Share Posted November 3, 2008 PHP is parsed before the server loads.. So calling functions on events like that is impossible without using JavaScript and AJAX to create a 'http request'. Google ajax for more info! Adam Quote Link to comment https://forums.phpfreaks.com/topic/131161-activate-function-in-how/#findComment-680998 Share on other sites More sharing options...
Adam Posted November 3, 2008 Share Posted November 3, 2008 PHP is parsed on the server before the web page loads ** Quote Link to comment https://forums.phpfreaks.com/topic/131161-activate-function-in-how/#findComment-681004 Share on other sites More sharing options...
Speedy84 Posted November 3, 2008 Author Share Posted November 3, 2008 thanks adios.. got some reading to do Quote Link to comment https://forums.phpfreaks.com/topic/131161-activate-function-in-how/#findComment-681008 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.