Jump to content

Linkpoint cc processing help


jrobles

Recommended Posts

I am trying to insert the form data before I post the form to the linkpoint site. I tried making the action="" then set the header location to the linkpoint site after the data is entered into the but i get headers already sent errors.

 

if (!isset($_POST['Submit']))
{echo"
<form action='' method='post'>
blah
blah
blah
</form>";}
else
{INSERT blah into blah;
header("Location: www.linkpointcentral.com/blah/blah ")
} 

 

 

 

How can I insert into my db before the form is posted to the linkpoint url?

Link to comment
Share on other sites

You're not supposed to output ANY data before sending another header. Make sure there is no echo statement or whitespace before the opening <?php tag. If you must use the header after outputting data to the browser, than put this at the top of your code, ob_start

<?php
ob_start(); //Start output buffer

 

This will fix the headers already sent error, but should be seen as a bandaid rather than a solution.

Link to comment
Share on other sites

Thanks for the help, I figured out a work-around that happy with. The form action is set to "". When the user submits the form the data is entered then a confirmation shows where the user can doublecheck their info then hit submit. The second form sends the data to the payment gateway.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.