Facebook LIKE button |
Post Reply | Page <12 |
Author | |
TrekLightGear
Newbie Joined: 24-April-2007 Location: Boulder, CO Status: Offline Points: 4 |
Post Options
Thanks(0)
|
Sean - Curious to hear what you find out. I really hope there's a way to get it to work with the SEO product pages, it works great for everything else but obviously the product pages are the ones we want people to Like!!
|
|
Seth Haber
|
|
joshs
Newbie Joined: 07-April-2009 Location: Utah Status: Offline Points: 14 |
Post Options
Thanks(0)
|
here is a marketing idea that needs some sort of confirmation app.
Give discounts based on friend count. For example 1000 friends - %10 off with a wall post. "TrekLightGear.com just hooked me up with this x product!" Picture attached. The app would allow the moderator to set discounts or give coupons based on friend network size. More friends equals more exposure equals more "word of mouth" advertising. |
|
Josh Shirley
josh@windsurfutah.com |
|
RedLeafDev
Certified ProductCart Developers Joined: 12-January-2010 Location: Portsmouth, NH Status: Offline Points: 28 |
Post Options
Thanks(0)
|
Try this (it has worked for us on numerous sites):
1) Go here to get the code for the button: http://developers.facebook.com/docs/reference/plugins/like
2) Paste the code into the viewPrdC (or L or O) page.
3) Make a simple modification to the code where it starts like.php?href=...
Place as the URL the site followed by the product as such: http://[site url]/productcart/pc/viewPrd.asp?idproduct=<%=pIdProduct%>
And test...
Amy
|
|
Vincent
Newbie Joined: 23-October-2010 Status: Offline Points: 2 |
Post Options
Thanks(0)
|
For SEO enabled site I had to use a quick fix using the Replace function.
Based on Sean@WMS code example, thank you Sean. With the SEO enabled on the site the original link was like the one shown below which created an error 404 while using the facebook link back to the site: Example: http://www.yoursite.com/productcart/pc/404.asp?404;http://www.yoursite.com/productcart/pc/Blue-Pinpoint-3p3.htm I realized then the pattern with the recurring first half of the URL which created the error. I then just decided to use a replace function to get rid of it as it is always the same string. replace(strLikeURL,"http://www.yoursite.com/productcart/pc/404.asp?404;","") Here is the final version I implemented on one of my ProductCart Site using SEO (in ViewProdC.asp). Sean Thanks again. <% Dim strLikeURL If Request.ServerVariables("HTTPS") = "ON" Then strLikeURL = "https://" Else strLikeURL = "http://" End If strLikeURL = strLikeURL & Request.ServerVariables("SERVER_NAME") strLikeURL = strLikeURL & Request.ServerVariables("SCRIPT_NAME") If Len(Request.ServerVariables("QUERY_STRING") & "") > 0 Then strLikeURL = strLikeURL & "?" & Server.HTMLEncode(Request.ServerVariables("QUERY_STRING")) end if strLikeURL = replace(strLikeURL,"http://www.yoursite.com/productcart/pc/404.asp?404;","") %> <script src="http://connect.facebook.net/en_US/all.js#xfbml=1"></script><fb:like href="<%=strLikeURL%>" layout="button_count"></fb:like> At the end I find myself with the appropriate URL, based on the example above, it will then return http://www.yoursite.com/productcart/pc/Blue-Pinpoint-3p3.htm Note that it is very important to use the SERVER.HTMLEncode()function while using the request object to obtain querystring values: Server.HTMLEncode(Request.ServerVariables("QUERY_STRING")) If not, you will then open your site to XSS vulnerabilities which will also affect the PCI Compliance of productcart. Maybe not the best coding practice but it worked for me. Edited by Vincent - 10-November-2010 at 1:38am |
|
ProductCart
Admin Group ProductCart Team Joined: 01-October-2003 Status: Offline Points: 135 |
Post Options
Thanks(0)
|
FYI: We recently added an article to the ProductCart WIKI on how to add a Facebook LIKE button
http://wiki.earlyimpact.com/how_to/add_facebook_like_button_ecommerce_store |
|
Post Reply | Page <12 |
Tweet
|
Forum Jump | Forum Permissions 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 |