Forum Replies Created

Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter Scoobiefan

    (@scoobiefan)

    url_vars_handler() on the third page puts the request_uri into an array and passes just the argument, in this case /walk/success/1/ activates the freebies code.

    Thread Starter Scoobiefan

    (@scoobiefan)

    Ok, here is the code. These snippets are located in functions.php, with changed shortcode and function names. If they are names already used by WP, then it is accidental and a change I made just recently. Both pages only contain the shortcode I have pasted here.

    Totals page calculates shows the totals, and determines if they are free (sponsored) people. If they are, and have not chosen to donate money making their total 0, then they just go to the confirmation page where it moves just free people over, and then delete the rest.
    If they need to enter a credit card, then they go to a separate page that takes in that information, and the paid people get moved out of the temp table.

    On the Totals Page, after entering information on the first page (which then adds the info to the database and redirects to the totals page), the information shows up just fine, and is in the database. If I refresh, the information shows up on the page again, but is then deleted from the database. If I refresh a second time, the information does not show up anymore. If I comment out the shortcode definition for the Confirmation Page, I do not have this problem.

    So somehow the second page is executing the third page’s shortcode, or really the whole third page (since I included the post number), but only on a refresh. Using WP_DEBUG does not log any of the DB calls for getting the free people or the delete. It’s like a ghost page.

    Thread Starter Scoobiefan

    (@scoobiefan)

    I wrote that code. It is in the functions.php file.

    Thread Starter Scoobiefan

    (@scoobiefan)

    I want this resolved as soon as possible, so I am just going to paste my code in here.

    Here is Page 2’s shortcode definition and function:

    add_shortcode('thetotals', 'totals');

    [ 725 lines of code moderated, that’s just way too much. For that many lines of code please use pastebin.com instead. ]

    I had ajax=false, and would get the warnings at the top of the page when an error happened or when the confirmation message was shown (they go to a confirmation page now)

    I set ajax=false and it shows up for a brief second below the submit button, but only if the form is a success. If the card does not go through, I do not see these messages.

    Thank you for making an error that would definitely be seen turn into an error that might be seen.

    Tried to do some editing with no success. If I figure it out I’ll make sure to post something.

Viewing 5 replies - 1 through 5 (of 5 total)