Multivariables on Custom-Events functions

QuestionsMultivariables on Custom-Events functions
Andre asked 10 years ago

Dear Abu,
In the example of custom-events, the function of update_client is called like this:

$e["on_insert"] = array("add_client", null, false);

function update_client($data)
{
command here
}

The above sample is use 1 variable. But how to call the function that use 2 variebles?

For example:

function update_client($data, $var2)
{
command here
}

1 Answers
Abu Ghufran answered 10 years ago

The $data in argument is an array, that contains all posted data from grid's add/edit forms.

Still if you wish to pass additional data (hidden vars), you can create some virtual column (non-db) in grid and set default values in it and make it hidden.

Hope it help.

Your Answer

17 + 17 =

Login with your Social Id:

OR, enter

Attach code here and paste link in question.
Attach screenshot here and paste link in question.



How useful was this discussion?

Click on a star to rate it!

Average rating 0 / 5. Vote count: 0

No votes so far! Be the first to rate it.

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?