Jump to content

jmpetre

New Members
  • Posts

    1
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

jmpetre's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. OK, let me preface this by saying that I am not a PHP programmer, but I need to hack this code snippet that was given to me. I have a php invoicing program running on my webserver, and I want to insert this piece of code into the invoices so my customers can pay via PayPal: <?php $amount = number_format($row->total_with_tax - $row->amount_paid, 2, '.', ''); $link = urlencode("https://www.paypal.com/cgi-bin/webscr?cmd=_xclick&currency_code=USD&business=$companyInfo->primary_contact_email&amount=$amount&item_name=$row->name - Invoice $row->invoice_number"); echo "<p>Pay the balance using PayPal - <a href='$link'>Click Here</a></p>"; ?> The problem is, when I click on the link this generates, it tacks the link on like a relative link. It looks like this: http://www.abc.com:8080/index.php/invoices/view/https://www.paypal.com/cgi-bin/webscr%3Fcmd%3D_xclick%26currency_code%3DUSD%26business%3Dadmin@abc.com%26amount%3D0.00%26item_name%3DJane+Doe+-+Invoice+6 Is there something wrong with the code snippet? Any help is greatly appreciated. Thank you. Jesse
×
×
  • 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.