Merchant Affiliate Program

Support Forum
It is currently Thu Nov 23, 2017 6:00 pm

All times are UTC - 6 hours




Post new topic Reply to topic  [ 4 posts ] 
Author Message
PostPosted: Thu Jun 01, 2006 11:04 pm 
Offline
Site Admin

Joined: Mon Mar 29, 2004 3:56 pm
Posts: 114
To integrate MyGiftList with a site that uses ecarsoft.com for e-commerce, cut and paste the "Add to MyGiftList" HTML code below after the Add to Cart HTML code but before the </form> tag in your web page.

Remember to change "Your Affiliate ID" below to your MyGiftList Affiliate ID and "Your Store Name" below to the name of your store.


Code:
<!-- BEGIN MyGiftList Code -->
<!--  Add this code before the </form> end tag for the Add to Cart button -->
<!--  change "Your Affiliate ID" below to your MyGiftList Affiliate ID -->
<!--  change "Your Store Name" below to the name of your store -->

<BR>
<input type="image" onclick='javascript:ecartsoftMGLpopup(this.form,"Your Affiliate ID","Your Store Name","ecartsoft");return false;' src="http://images.mygiftlist.com/gif/AddtoMyGiftList7e.gif" width=68 height=26 border=0 alt="Click to Add to MyGiftList!">
<script language=javascript>
function ecartsoftMGLpopup(f, refsource, storename, cartname) {
   var giftPrice = "";
   var giftName = "";
   var giftDescription = "";
   var m;
   var u = "";
   var n;
   
   if (f) {
      for (var i = 0; i < f.elements.length; i++) {
         if (f.elements[i].name.substr(0,7) == "option^" ) {
            m = f.elements[i].selectedIndex;
         n = f.elements[i].name.substr(7,200)
         n = n.replace(/[0-9]/gi,"");
            if (m > -1) {
                u = u + n + "=" + f.elements[i].options[m].text + ", ";
            } else {
                u = u + n + "="  + f.elements[i].value + ", ";
         }
         }
         if (f.elements[i].name.substr(0,8) == "quantity" ) {
            u = u + "Quantity=" + f.elements[i].value + ", ";
       }
         if (f.elements[i].name.substr(0,16) == "item_description" ) {
            u = u + f.elements[i].value + ", ";
       }
         if (f.elements[i].name.substr(0,10) == "item_price" ) {
            giftPrice = f.elements[i].value;
       }
         if (f.elements[i].name.substr(0,9) == "item_name" ) {
            giftName = f.elements[i].value;
      }
      }
   }

   if ( u != "" ) {
      u = u.substr(0, u.length-2);
      u = "I would like these options: " + u;
      giftDescription = u + ".  " + giftDescription;
   }

   u = "http://www.mygiftlist.com/register_gift.asp?refSource=" + escape(refsource) + "&giftURL=" + escape(document.URL) + "&giftName=" + escape(giftName) + "&giftRetailer=" + escape(storename) + "&giftCart=" + escape(cartname) + "&giftPrice=" + escape(giftPrice) + "&giftDescription=" + escape(giftDescription);
   var mgl = window.open(u,"MGL","width=700,height=500,top=60,left=100,resizable,scrollbars");
}
</script>

<!-- End MyGiftList Code -->


Top
 Profile  
 
PostPosted: Mon Feb 16, 2009 4:57 pm 
Offline

Joined: Mon Feb 16, 2009 4:52 pm
Posts: 2
I copied the tag and put it into my button code before the </form>
And now my items are being charged $25 extra on shipping charges, yikes!


Top
 Profile  
 
PostPosted: Tue Feb 17, 2009 4:49 pm 
Offline
Site Admin

Joined: Mon Mar 29, 2004 3:56 pm
Posts: 114
We visited your site and couldn't find a page with the problem.

Can you post a link here?


Top
 Profile  
 
PostPosted: Tue Feb 17, 2009 4:52 pm 
Offline

Joined: Mon Feb 16, 2009 4:52 pm
Posts: 2
admin wrote:
We visited your site and couldn't find a page with the problem.

Can you post a link here?


Thanks, I figured it out. I placed the code in the <p> tag of the shopping cart button right before the </form>
Once I moved it just outside of the </p> tag, it worked fine.
Thanks!


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC - 6 hours


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group