• Gear
  • Shots
  • Photo Craft
  • Video
  • Wide Angle
  • Support
  • New Stuff
  • More
Support SmugMug Customization How to add a PayPal shopping cart to your site!

FAQtoid

Ever wanted to create an Avatar? Creating an Avatar!

Searching Dgrin with Google Searching with Google

Dgrin Challenges

Congratulations to the Winner of DSS #130 (Hot or Cold), Memol..

The next Dgrin Challenge DSS #131 (Music) is open for entries through June 24th, 2013 at 8:00pm PDT.

As always, we look forward to your participation but please do take a moment to read through the rules before posting your entry.

Past DSS Challenge Winners, DSS Challenge Rules, and other important DSS Challenge information is here.

Need some help with Accessories?

Tutorials

Ever find yourself wondering just how someone managed to create an image using different effects?

Here are three simple tutorials we hope will encourage you to try something new.

The Hot Seat

A lifelong interest in landscape photography has led Eyal Oren to make a study of his adopted hometown of Marblehead, MA. As you can see, his dedication is paying off!

Africa!

Dgrinners Harryb, Pathfinder, and others joined Andy Williams and Marc Muench on Safari in East Africa recently. Here are some awesome threads to check out!

 
Thread Tools Display Modes
Page 18  of  18
Old Sep-03-2011, 02:22 AM
#341
TalkieT is offline TalkieT
Major grins
Quote:
Originally Posted by romansolar View Post
hello everybody,

i am looking for help, i added code for paypal buy now button within caption of image. I would like to use same code for every image within my galleries. BUt how should i know which image is my customer buying? some simple solution for this please? dont need shopping cart, just one buy now button for all images

thank you
CHeck out this thread... http://www.dgrin.com/showthread.php?...=setpaypalform

Cheers - Neil G
__________________
--
http://www.nzsnaps.com (talkiet.smugmug.com)
Old Sep-04-2011, 09:21 PM
#342
romansolar is offline romansolar
Big grins
thanks,will do
Old Sep-24-2011, 08:17 AM
#343
shioti is offline shioti
Big grins
I was able to make my first set of paypal button work but now I need another set. Here is what I did:


<div id="paypalButtonSet" style="display:none;" class="paypalButton">
<form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post" onSubmit="setPaypalForm(this)" >
<input type="hidden" name="add" value="1">
<input type="hidden" name="cmd" value="_cart">
<input type="hidden" name="business" value="manuelhng@gmail.com">
<input type="hidden" name="item_name" value="">
<input type="hidden" name="amount" value="">
<input type="hidden" name="no_shipping" value="0">
<input type="hidden" name="no_note" value="1">
<input type="hidden" name="currency_code" value="USD">
<input type="hidden" name="lc" value="US">
<input type="hidden" name="bn" value="PP-ShopCartBF">

<select ID="paypalSelect" name="photoselection">
<option selected value="10">High Resolution Single Digital Download ($10)</option>
<option selected value="200">High Resolution Album Digital Download ($200)</option>

</select>


<input ID="paypalBuy" type="image" src="https://www.paypalobjects.com/en_US/i/btn/btn_cart_LG.gif" border="0" name="submit" alt="Buy">
<img alt="" border="0" src="http://mhngphotography.smugmug.com/photos/i-PMRKLSP/0/L/i-PMRKLSP-L.png" width="1" height="1">
</form>
<form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input ID="paypalView" type="image" src="http://mhngphotography.smugmug.com/photos/i-DfZS2PW/0/L/i-DfZS2PW-L.gif" border="0" name="submit" alt="View Cart">
<input type="hidden" name="cmd" value="_cart">
<input type="hidden" name="business" value="manuelhng@gmail.com">
<input type="hidden" name="display" value="1">
</form>
</div>


<div id="paypalButtonSet2" style="display:none;" class="paypalButton2">
<form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post" onSubmit="setPaypalForm(this)" >
<input type="hidden" name="add" value="1">
<input type="hidden" name="cmd" value="_cart">
<input type="hidden" name="business" value="manuelhng@gmail.com">
<input type="hidden" name="item_name" value="">
<input type="hidden" name="amount" value="">
<input type="hidden" name="no_shipping" value="0">
<input type="hidden" name="no_note" value="1">
<input type="hidden" name="currency_code" value="USD">
<input type="hidden" name="lc" value="US">
<input type="hidden" name="bn" value="PP-ShopCartBF">

<select ID="paypalSelect2" name="photoselection2">
<option selected value="20">Single Image Download ($20)</option>

</select>


<input ID="paypalBuy2" type="image" src="https://www.paypalobjects.com/en_US/i/btn/btn_cart_LG.gif" border="0" name="submit" alt="Buy">
<img alt="" border="0" src="http://mhngphotography.smugmug.com/photos/i-PMRKLSP/0/L/i-PMRKLSP-L.png" width="1" height="1">
</form>
<form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input ID="paypalView2" type="image" src="http://mhngphotography.smugmug.com/photos/i-DfZS2PW/0/L/i-DfZS2PW-L.gif" border="0" name="submit" alt="View Cart">
<input type="hidden" name="cmd" value="_cart">
<input type="hidden" name="business" value="manuelhng@gmail.com">
<input type="hidden" name="display" value="1">
</form>
</div>

--------------------------

The first set works perfectly but the 2nd paypal buttons is not working properly. I keep getting and error saying must enter a value more than zero. and also I dont know why it is appearing on the left side rather that on the right?

Please help.



http://mhngphotography.smugmug.com/O...594978_5Kb8ZPK - the one with the problem

http://mhngphotography.smugmug.com/O...400110_mwbGRB7 - the good one.

thank you in advance
Old Oct-15-2011, 04:26 AM
#344
Abbeycrombie is offline Abbeycrombie
Beginner grinner
Hello! Is anyone still helping out with this? I have checked some links to others within the thread and I don't see any PayPal utilization so I'm wondering if people just gave up on it? I'd like to be able to do this for local orders.

No help needed anymore at this point. Found what I needed!

Last edited by Abbeycrombie; Oct-15-2011 at 06:04 AM. Reason: I was able to find my answer within the thread.
Old Nov-26-2011, 12:06 PM
#345
56Kruiser is offline 56Kruiser
Major grins
Issues with my customization
I used the code from the OP page. I am currently setting the button up to use the Paypal sandbox for testing.

When using the code from OP, with only mods being AUD to USD and AU to US, I get an error about "Enter am amount > 0". I found reference from a couple others in this thread on that, but I didn't come away with a solution.

My test gallery with this is here.

Here is the current code that is there:

Code:
<html>
<div id="paypalButtonSet" style="display:none;" class="paypalButton">
<form target="paypal" action="https://www.sandbox.paypal.com/cgi-bin/webscr" method="post" onSubmit="setPaypalForm(this)" >
  <input type="hidden" name="add" value="1">
  <input type="hidden" name="cmd" value="_cart">
  <input type="hidden" name="business" value="rogere_1322255166_biz@gmail.com">
  <input type="hidden" name="item_name" value="">
  <input type="hidden" name="amount" value="">
  <input type="hidden" name="no_shipping" value="0">
  <input type="hidden" name="no_note" value="1">
  <input type="hidden" name="currency_code" value="USD">
  <input type="hidden" name="lc" value="US">
  <input type="hidden" name="bn" value="PP-ShopCartBF">
 
  <select ID="paypalSelect" name="photoselection">
    <option selected value="10.00">Product Option 1</option>
    <option value="20.00">Product Option 2</option>
  </select>
 
  <input ID="paypalBuy" type="image" src="http://www.shuttermaster.co/photos/i-CKMrJFX/0/L/i-CKMrJFX-L.png" border="0" name="submit" alt="Buy">
  <img alt="" border="0" src="https://www.paypal.com/en_US/i/scr/pixel.gif" width="1" height="1">
</form>
<form target="paypal" action="https://www.sandbox.paypal.com/cgi-bin/webscr" method="post">
  <input ID="paypalView" type="image" src="http://www.shuttermaster.co/photos/i-TjGVpW3/0/L/i-TjGVpW3-L.png" border="0" name="submit" alt="View Cart">
  <input type="hidden" name="cmd" value="_cart">
  <input type="hidden" name="business" value="rogere_1322255166_biz@gmail.com">
  <input type="hidden" name="display" value="1">
</form>

</div>
</html>
So, I went to the Paypal Dev site and created a button, which has a bit further functionality, code shown below, which appears to work with Paypal. But I have the following problems with it.
  • Does not have the SmugMug specific variables in it
  • There is a section to add other variables, but when I add them, the do not show in the code
  • It is not positioned correctly on the page

I think that some of the things associated with the button generated in Paypal are kept in their server and associated with my account. I'm not sure about that, but I got that impression, and especially given that some of the things that should identify who I am as a seller doesn't seem to be in their code. Probably has to do with 'hosted button' in the code.

Here is the code from PayPal:

Code:
<form target="paypal" action="https://www.sandbox.paypal.com/cgi-bin/webscr" method="post">
<input type="hidden" name="cmd" value="_s-xclick">
<input type="hidden" name="hosted_button_id" value="C5CJUG83HQW84">
<table>
<tr><td><input type="hidden" name="on0" value="Select Item to Purchase">Select Item to Purchase</td></tr><tr><td><select name="os0">
	<option value="Photo 1">Photo 1 $149.00 USD</option>
	<option value="Photo 2">Photo 2 $139.00 USD</option>
	<option value="Photo 3">Photo 3 $129.00 USD</option>
</select> </td></tr>
<tr><td><input type="hidden" name="on1" value="Select Finish">Select Finish</td></tr><tr><td><select name="os1">
	<option value="Sheer Glossy">Sheer Glossy </option>
	<option value="Sheer Satin">Sheer Satin </option>
	<option value="White High Gloss">White High Gloss </option>
	<option value="White Satin">White Satin </option>
</select> </td></tr>
</table>
<input type="hidden" name="currency_code" value="USD">
<input type="image" src="https://www.sandbox.paypal.com/en_US/i/btn/btn_cart_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online!">
<img alt="" border="0" src="https://www.sandbox.paypal.com/en_US/i/scr/pixel.gif" width="1" height="1">
</form>
If I could figure out how to get the additional options from the code just above added to the code from this thread, I may have a workable option.

Any help appreciated.
__________________
http://www.shuttermaster.co
Old Nov-27-2011, 08:19 AM
#346
ravenly98 is offline ravenly98
Big grins
After 18 pages of this thread, still not there
I am wanting to give the option for clients to purchase a gift certificate by clicking on a paypal button and selecting their amount. I only want the purchase option to appear here: http://eclecticallyforyou.smugmug.co...0031098_V8Ddt7 for the time being. I had created a paypal button on the paypal website, with a dropdown menu of amounts, but when I paste the code into the album description, I just get words with no button or links. The code provided by paypal is:

<form action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input type="hidden" name="cmd" value="_s-xclick">
<input type="hidden" name="hosted_button_id" value="65FLQNVSV3V6Y">
<table>
<tr><td><input type="hidden" name="on0" value="2012 Session Options">2012 Session Options</td></tr><tr><td><select name="os0">
<option value="SPECIAL! Standard Session">SPECIAL! Standard Session $73.00 USD</option>
<option value="Standard Session">Standard Session $88.00 USD</option>
</select> </td></tr>
<tr><td><input type="hidden" name="on1" value="Recipient's Name">Recipient's Name</td></tr><tr><td><input type="text" name="os1" maxlength="200"></td></tr>
</table>
<input type="hidden" name="currency_code" value="USD">
<input type="image" src="https://www.paypalobjects.com/en_US/i/btn/btn_buynowCC_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online!">
<img alt="" border="0" src="https://www.paypalobjects.com/en_US/i/scr/pixel.gif" width="1" height="1">
</form>

I really don't want it to appear on my homepage or in any other galleries; and I don't have a custom header. What am I not seeing/doing? Thanks in advance!

Lindsey
www.eclecticallyforyou.smugmug.com
Old Nov-29-2011, 06:29 AM
#347
56Kruiser is offline 56Kruiser
Major grins
Lindsey

I am finding zero help on Paypal buttons here on the forum. I've been struggling for 3 days, making changes, etc, to try to get mine to work. Even posted another thread.

I may have a some information that will help you. One thing that may be a problem for you is that you are using a hosted button. Below is text from an email I got from Paypal on issues I was having, which was becuase the button was hosted by Paypal. That means some of the code was stored at Paypal's site. Give this a try:

Quote:
create unhosted button

1. Go to the button designer page on the PayPal website and log in to your PayPal account.
2. Click on the Merchant Services Tab and select the button type you want to use.
3. Click create the button type you wish to use.
4. Enter your information to customize the button to your needs.
5. Click Step 2 and uncheck the "Save button at PayPal"
6. Click "Create Button."
7. Click "Remove code protection"
8. Click "Select Code" to select the button code.

Copy and paste the button code into your own web page code.
I hope this helps.

Roger
__________________
http://www.shuttermaster.co
Old Nov-29-2011, 07:09 AM
#348
56Kruiser is offline 56Kruiser
Major grins
OP Code Incorrect...
Well, I finally found this post that has corrected code. I paste it in instead of the code on the OP, and it works. What does not work is that I do not get details in the email. But I can go into Paypal and get the details there.

So...be sure to use the code from the linked post above.

David...I can't answer your question. But one thing I am doing is I am adding the Paypal HtmL intended for the Header code into the Gallery Description on those galleries that I want to have Paypal available for. This allows me to customize per gallery. And actually, I don't plan to have very many galleries with Paypal.
__________________
http://www.shuttermaster.co
Old Nov-29-2011, 07:11 AM
#349
56Kruiser is offline 56Kruiser
Major grins
OP code in the original thread incorret...
Rereading through the original thread, I came upon this thread, which has correct Java, and other code for the Paypal setup.

I am making progress.
__________________
http://www.shuttermaster.co
Old Dec-02-2011, 10:30 AM
#350
ravenly98 is offline ravenly98
Big grins
Still lost, 56Kruiser, but thank you. I am going to try creating a new thread to see if someone responds. I just want the ability to allow a paypal button into a gallery description, and I'm not getting there. Thank you again though :)
__________________
Lindsey Driscoll
Website: www.eclecticallyforyou.smugmug.com
Facebook: www.facebook.com/Eclecticallyforyou
Old Dec-02-2011, 03:00 PM
#351
56Kruiser is offline 56Kruiser
Major grins
Quote:
Originally Posted by ravenly98 View Post
Still lost, 56Kruiser, but thank you. I am going to try creating a new thread to see if someone responds. I just want the ability to allow a paypal button into a gallery description, and I'm not getting there. Thank you again though :)
OK. I tried another thread and never got a response. Not sure why response on this is not good. All other support here is great.

I am pretty close. Think I have it working, based on the thread I linked you to. When I get satisfied it is working, I'll post here what I am using.
__________________
http://www.shuttermaster.co
Old Dec-02-2011, 05:06 PM
#352
ravenly98 is offline ravenly98
Big grins
Thank you! Much luck to you ;)
__________________
Lindsey Driscoll
Website: www.eclecticallyforyou.smugmug.com
Facebook: www.facebook.com/Eclecticallyforyou
Old Jan-16-2012, 10:31 AM
#353
Jimmymac1 is offline Jimmymac1
Beginner grinner
Headwrecked
Hi guys,i have followed this thread but cannot nail down a solution,all very complicated.My smugmug page is http://jimmymccormackphotography.smugmug.com/ .It would be great if someone can take a look and help me out.I have added a paypal button to 2 of these galleries,1 to my national novice gallery.it has a dropdown pricelist.However when i Select a picture it grays out the button and i cannot select the picture to buy.the 2nd paypal button is on my experiment gallery and it allows me to buy a pic,the pic appears on the right bigger than the rest(thumbnails)i have another question.Can someone buy more than one picture(I seem to be unable) and how does the money get to me.Also how do I find out what pictures I have to get developed.Pardon my ignorance as i am stumped now and about to pull the plug

Please help me,Rgds Jimmy Mac
Old Apr-18-2012, 08:12 PM
#354
MomaZunk is offline MomaZunk
pro lurker
MomaZunk's Avatar
My Working Pay Pal Implementation
So here is my implementation of paypal.
I hope this helps. It took me quite sometime over the summer to work this out, and I am just back to using it for another project. It is really pretty simple, but when you are not a coder, just a cut-n-paster like me, those little semi-colons can get yah.

  • It goes in the gallery description only. The javascript is all right here between the script tags. I modify the javascript based on the gallery where I want to use PP.
  • I do not use the alignment stuff that was supposed to be pasted in the Top javascript, referenced earlier in this thread. I fiddled around quite abit with the alignment.
  • I turn off printing, and use the smugmug view only, but these are not requirements.
  • The code below also has the customContactButton mod discussed in this forum. I cannot find the reference right now.
  • I have a pro account.
  • Please note this may not work with the new version of the galleries to be rolled out later this year.

Steps:
1. Copy this code into Notepad on you computer
2. Change the areas that are green.
-Modify your text and your phone number
-Business code is your unique number from paypal
-Sales tax (I just use a flat rate as most of my business is local)
-Shipping (you could add another pull down for selections, but that is not included here
-Your options
-The gallery name that will appear in teh shopping cart (note the filename is picked up from the page)
3. The areas in pink are optional.
-Your own buttons for the cart
-What you want to call your comment for the item in your cart.
4. Copy all of the code and paste it into your gallery description, and save. You will have to reload your page to make it fully functional.
5. Save your notepad file for future reference.

This code also works with the minicart option discussed here. But I cannot get my minicart.js location on google sites recognized, and I am still working on this enhancement, but that is another thread.




Code:
<html>
  <div class="myTitle">

  </div>     <!-- closes myTitle div -->
  <table summary="Calendars" align="right" cellspacing="15">
    <tbody>
      <tr>
        <td>
  <p align="right">If you have any questions, you may contact me by <a href="/" onclick="return false;" class="customContactButton">email</a> or phone at <font color="yellow">999-999-9999</font>. 
</p>          
          </br>
        </td>
        <td align="left">
          <div id="paypalButtonSet" class="paypalButton">
            <form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post" onclick=getContinueShoppingURL(this.form)>
              <input ID="paypalView" type="image" src="https://www.paypalobjects.com/en_US/i/btn/btn_viewcart_SM.gif" height = 20 border="0" name="submit" alt="View Cart">
              <input type="hidden" name="cmd" value="_cart">
              <input type="hidden" name="business" value="ABCDEFGHIJKLM">
              <input type="hidden" name="display" value="1">
            </form>
            <form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post" onSubmit="setCalendar(this)" onclick=getContinueShoppingURL(this)>
              <input ID="paypalBuy" type="image" src="https://www.paypalobjects.com/en_US/i/btn/btn_cart_LG.gif" height = 20 border="0" name="submit" alt="Buy">
              <img alt="" border="0" src="https://www.paypal.com/en_AU/i/scr/pixel.gif" width="1" height="1"><input type="hidden" name="add" value="1">
              <input type="hidden" name="cmd" value="_cart">
              <input type="hidden" name="business" value="ABCDEFGHIJKLM">
              <input type="hidden" name="item_name" value="">
              <input type="hidden" name="amount" value="">
              <input type="hidden" name="shipping" value="">
              <input type="hidden" name="tax_rate" value="8.25">
              <input type="hidden" name="no_shipping" value="0">
              <input type="hidden" name="no_note" value="1">
              <input type="hidden" name="currency_code" value="USD">
              <input type="hidden" name="lc" value="US">
              <input type="hidden" name="shopping_url" value="">
                <table align="right">
                  <tr>
                    <td><input type="hidden" name="on0" value="">
                    </td>
                    <td>
                      <select ID="paypalSelect" name="photoselection"> Select Item
                        <option value="1.00">X - (1) 4x6 $1.00</option>
                        <option value="1.00">Y - (1) 5x7 Team $1</option>
                        <option value="1.00">A - (1) 8x10 Memory Mate $1</option>
                        <option value="1.00">B - (1) 8x10 Team $1</option>
                        <option value="1.00">C - (1) 8x10 Ind $1</option>
                      </select>
                    </td>
                  </tr>
                <tr>
                    <td>
                      <input type="hidden" name="on2" value="Note: ">Note:   
                    </td>
                    <td>
                      <input type="text" name="os2" maxlength="200">
                    </td>
                  </tr>
                </table>
            </form>

          </div>
        </td>
      </tr>
    </tbody>
  </table>
<script type="text/javascript">
function getContinueShoppingURL(form){
// -- Get the href of the currently displayed webpage --
form.shopping_url.value = window.location.href;
}
</script>

<script>
// ========================================*/
// == Paypal shopping functionality ==*/
// ========================================*/
function setCalendar(form) {

i = form.photoselection.selectedIndex;
sPhotoType = form.photoselection.options[i].text;
sPhotoPrice = form.photoselection.options[i].value;

urlToImage = sPhotoType + " Gallery Reference: " + photoInfo[ImageID]['fileName'];

form.item_name.value = urlToImage;
form.amount.value = sPhotoPrice;

i = form.os1.selectedIndex;
sshipcost = form.os1.options[i].value;
sshiptype = form.os1.options[i].text;

form.shipping.value = sshipcost;
form.on1.value = sshiptype;
}
</script>
</html>
__________________
Dee Zunker

Website Blog
Facebook Twitter Google+
Old Apr-19-2012, 10:50 AM
#355
Foques is offline Foques
He who caN
Foques's Avatar
I'm curious.. am I the only one baffled with the fact that Smug has been promoting workarounds instead of just establishing a relationship with a pay pal?..
__________________
Arseny.
My FlickR
My Site
My Facebook
Old Apr-24-2012, 07:21 AM
#356
Taivefoto is offline Taivefoto
Big grins
It would be creat! I am shooting in EU. I like Smugmug but it is so difficult to use it in EU. Now here are currencies as € and £ and printing possibility in UK. The problem is I have to set my prices anyway in $. I´ll wait the day when i can set prices in currencie what i use (€ at the moment, soon also in £) and use Paypal to my clients. So far i do not have any point to set my prices here.
__________________
www.taivefoto.com
Old Aug-08-2012, 07:29 PM
#357
Sarah Lynn is offline Sarah Lynn
Beginner grinner
Quote:
Originally Posted by Foques View Post
I'm curious.. am I the only one baffled with the fact that Smug has been promoting workarounds instead of just establishing a relationship with a pay pal?..
No you are not alone! I am wondering the same thing!
Page 18  of  18
Tell The World!  

Thread Tools
Display Modes

Posting Rules  
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump