Discussion This is just part of my code. Can someone help? I need it to post into the database but its not working. everything else is working fine escept for that."<select style='width:58%' id= 'selections' name='selections[]' class='selections' multiple='multiple'></select> <input id='clearselections' type='button' value='Clear All Selections' onclick= 'clearvalues()'> <?php $mysqli = new mysqli('localhost', 'USERNAME', 'PASSWORD', 'DATA_BASE'); $stmt = $mysqli->prepare( 'INSERT INTO Entries (wp_usermeta) VALUES ('wp_usermeta'.'meta_key'); $stmt->bind_param( 's', $POST['selections']); $stmt->execute(); $mysqli->close(); ?> <script type='text/javascript'> function clearvalues() { $('select#selections option').remove(); } </script> <script src='/public_html/wp-content/plugins/pmpro-customizations/bower_components/jquery/dist/jquery.min.js'></script> <script src='/public_html/wp-content/plugins/pmpro-customizations/bower_components/select2/dist/js/select2.min.js'></script> <script type='text/javascript'> $(document).ready(function() { $('#selections').select2();} </script>" 1 points ortegafamilyen 8 years ago 3 comments
"<select style='width:58%' id= 'selections' name='selections[]' class='selections' multiple='multiple'></select> <input id='clearselections' type='button' value='Clear All Selections' onclick= 'clearvalues()'>