Welcome Guest, Not a member yet? Register   Sign In
ask about onchange and onclick php
#2

[eluser]Nisha S.[/eluser]
PHP is a server side scripting language and cannot be called directly from client side. You can write a javascript with the function name and inside you can call php function by calling the relevant URL.

[removed]
function here()
{
alert("hello");
// call the url to executes the funcion. Given pattern below for codeigniter. Use ajax if you don't want to redirect to another page.
[removed] = "http://www.yourwebsite.com/controller/function";
}
[removed]


Messages In This Thread
ask about onchange and onclick php - by El Forum - 07-02-2012, 07:41 PM
ask about onchange and onclick php - by El Forum - 07-02-2012, 11:44 PM
ask about onchange and onclick php - by El Forum - 07-03-2012, 12:03 AM
ask about onchange and onclick php - by El Forum - 07-03-2012, 12:14 AM



Theme © iAndrew 2016 - Forum software by © MyBB