Quantcast
Channel: Recent Discussions — DataTables forums
Viewing all articles
Browse latest Browse all 82037

Insert data in other table

$
0
0

Hi,
I have this function

function insertLinkTable ( $db, $action, $id, $values ) {
    $db->insert( 'vardisp', array(
        'movid' => $id ,
        'matid' => $row['materiale_id']
    ) );
}

I want to save in a different table (a link table)

I call the function in this way

->on( 'postCreate', function ( $editor, $id, $values, $row ) {
        insertLinkTable( $editor->db(), 'create', $id, $values );}

The result is that i insert $id but i can't fine the way to insert materiale_id because is indefined.
I try in other way $materiale_id, $_POST['materiale_id'] and so on.
But don't run.

Any idea?
Tx a lot


Viewing all articles
Browse latest Browse all 82037

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>