Plugin polls, POST poll in database
-
Hi everyone,
I need to use (or do) a plugin to create polls, any visitor of the site will have the oportunity to answer the question, but i need to take some information about the person answering the poll (age, gender, etc). In this moment I’m adapting the wp-polls plugin to my needs, but i don’t know how to save the poll created by the administrator in the database. Specify, in the part when verify the POST option in the form.
My code in the form button to submit is:
<p style=”text-align: center;”><input type=”submit” name=”do” value=”Agregar encuesta” onclick=”validarCampos();” class=”button-primary” />
And i verify the POST method in:
if(!empty($_POST[‘do’])) {
// Decide What To Do
switch($_POST[‘do’]) {
// Add Poll
case ‘Agregar encuesta’:
//HERE should be the code for saving in the databaseSo, somebody have an example or plugin or something to help me?
Thanks
Josue
- The topic ‘Plugin polls, POST poll in database’ is closed to new replies.