Welcome Guest Search | Active Topics | Sign In | Register

Can I place a live paypal button into a pdf Options
trader1
Posted: Monday, June 13, 2011 10:01:50 PM
Rank: Newbie
Groups: Member

Joined: 6/13/2011
Posts: 1
Hi Guys Im new to all this stuff. Just a question can you place a live paypal button into a pdf?

Regards
eo_support
Posted: Tuesday, June 14, 2011 9:54:08 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
Hi,

Yes. You can do that. You will need to have the button image in your file and then have a PdfLink object on top of that button object that points to the button Url. You can get both from PayPal (the button Url is the "email link" PayPal gives to you when you create a button).

Once you have both, you can render it to the PDF file either with HTML to PDF interface or PDF Creator interface.

if you use HTML to PDF feature (this is the easy way), you HTML should be something like this:

Code: HTML/ASPX
<a href="https://www.paypal.com/cgi-bin/webscr?
     cmd=_s-xclick&hosted_button_id=your_button_id">
   <img src="https://www.paypalobjects.com/en_US/i/
       btn/btn_buynowCC_LG.gif" border="0" />
</a>


Note you will need to replace the button Url (the href part) and the image Url (the src part) with your actual button Url and image Url. Also the above code intentionally breaks the Url into multiple lines so that it's easier to read. In your code you should put them all in a single line.

If you use PDF Creator interface, you will need to load the image into a System.Drawing.Image object, then create an AcmImage object for PDF rendering. After that you will create a PdfLink object based on the AcmImage object. Please see PDF Creator documentation for more details.

Thanks!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.