Bulk Import to Form

I am trying to replace about 30 codes used in a field in one of my forms. I would prefer to bulk import or replace rather than copying and pasting 30 times.

When I go to functions.php I find relevant code

> function check_student_code_for_evaluation_form() {
> global $wpdb;
> $sql = "SELECT * FROM evaluation_forms_student_codes WHERE studentcode = '" . $_POST['studentcode'] . "'";
> $rows = $wpdb->get_results($sql);
>
> if(empty($rows)) {
> echo "invalid";
> die();
> }
>
> foreach ($rows as $row_data) {
> if ($row_data->used) {
> echo "used";
> }
> else {
> echo "valid";
> }
> }
> die();
> }
>
> add_action('wp_ajax_nopriv_ldr_check_student_code_for_evaluation_form', 'check_student_code_for_evaluation_form'); // for not logged in users
> add_action('wp_ajax_ldr_check_student_code_for_evaluation_form', 'check_student_code_for_evaluation_form');

I then went over to phpmyadmin and while I see a table with the name from this code, I don’t see any entries to edit. I’m assuming these codes reside in a table somewhere on my site?

Hello,

I would be glad to assist you.

To discuss further in detail kindly reach me at garry@cisinlabs.com or Skype me: cis.garry

Looking forward for your response.

Thanks

Garry

Hello @dmwesq
PM sent, please check.
Regards,
Trish

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.