close ad
Install the LAtest Updates to Work with CC 2017 and CC 2018
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Link to Dynamic Page

Thread began 3/11/2011 4:41 pm by bill173836 | Last modified 5/17/2011 4:01 pm by bill173836 | 4049 views | 12 replies |

bill173836

Link to Dynamic Page

I need the Facebook aspect of the Social Media Toolkit to post a dynamic link. As it currently is it's showing the current page. I rewrote part of the script and it appears to work for the email and some of the other links but Facebook only shows the current page. Here is what I wrote maybe I've missed something.

<?php $host = 'http://www.talkofthetowncoupons.com/merchantinformation.php?merchantPID='; ?>
<?php $cpnnum = $row_rsAllCoupons['MerchantPID']; ?>
<?php $url = "$host" . "$cpnnum"; ?>

This added the link and proper info to the $url session variable.

You can see what I've done at auto.php

Thanks

Sign in to reply to this post

Jason ByrnesWebAssist

to add dynamic attributes to the share link, click the folder icon next to URL in the Share wizard, select your page, then click the parameters button.

set the name of the paramter to merchantPID then click the lightning bolt icon next to value and select the MerchantPID column from your recordset.

Sign in to reply to this post

bill173836

I tried this and everything seems to work except the Facebook link which is still showing the link as the origin page which in this case is cleaningservices.php

Here is the code.

<div class="wasocial">
<div class="icons"> <a name="fb_share" type="icon" href="http://www.facebook.com/sharer.ph?u=<?php echo urlencode('http://talkofthetowncoupons.com/merchantinformation.php?merchantPID='); ?><?php echo $row_rsAllCoupons['CMerchantPID']; ?>" title="Facebook"></a>
<script src="http://static.ak.fbcdn.net/connect.php/js/FB.Share" type="text/javascript"></script>
</div>
<div class="icons">
<div id="custom-tweet-button"> <a href="http://twitter.com/share?url=<?php echo urlencode('http://talkofthetowncoupons.com/merchantinformation.php?merchantPID='); ?><?php echo $row_rsAllCoupons['CMerchantPID']; ?>" target="_blank" title="Tweet"></a> </div>
</div>
<div class="icons">
<script type="text/javascript">
(function() {
var s = document.createElement('SCRIPT'), s1 = document.getElementsByTagName('SCRIPT')[0];
s.type = 'text/javascript';
s.async = true;
s.src = 'http://widgets.digg.com/buttons.js';
s1.parentNode.insertBefore(s, s1);
})();
</script>
<!-- Icon Button -->
<a class="DiggThisButton DiggIcon" href="http://digg.com/submit?url=<?php echo urlencode('http://talkofthetowncoupons.com/merchantinformation.php?merchantPID='); ?><?php echo $row_rsAllCoupons['CMerchantPID']; ?>"></a> </div>
<div class="icons"> <a href="#" onclick="window.open('http://reddit.com/submit?url=<?php echo urlencode('http://talkofthetowncoupons.com/merchantinformation.php?merchantPID='); ?><?php echo $row_rsAllCoupons['CMerchantPID']; ?>')"> <img src="webassist/social/icons/reddit.png" alt="submit to reddit" border="0" title="Reddit" /> </a> </div>
<div class="icons">
<script src="http://www.stumbleupon.com/hostedbadge.php?s=4&r=<?php echo urlencode('http://talkofthetowncoupons.com/merchantinformation.php?merchantPID='); ?><?php echo $row_rsAllCoupons['CMerchantPID']; ?>"></script>
</div>
<div class="icons"> <a title="Post to Google Buzz" class="google-buzz-button" href="http://www.google.com/buzz/post?url=<?php echo urlencode('http://talkofthetowncoupons.com/merchantinformation.php?merchantPID='); ?><?php echo $row_rsAllCoupons['CMerchantPID']; ?>" data-admin-site="true" data-button-style="normal-button"></a>
<script type="text/javascript" src="http://www.google.com/buzz/api/button.js"></script>
</div>
<div class="icons"> <a href="http://www.delicious.com/save" onclick="window.open('http://www.delicious.com/save?v=5&noui&jump=close&url='+('<?php echo urlencode('http://talkofthetowncoupons.com/merchantinformation.php?merchantPID='); ?><?php echo $row_rsAllCoupons['CMerchantPID']; ?>')+'&title='+encodeURIComponent(document.title), 'delicious','toolbar=no,width=550,height=550'); return false;"> <img src="webassist/social/icons/delicious.png" alt="Delicious" id="delicious" title="Delicious" /></a> </div>
<div class="icons"> <a href="mailto:?subject=Talk Of The Town Coupons&body=Checkout this coupon link: http:www.talkofthetowncoupons.com/merchantinformation.php?merchantPID=<?php echo $row_rsAllCoupons['CMerchantPID']; ?>"><img src="webassist/social/icons/mail.png" title="Mail" /></a> </div>
<div class="icons"> <a href="#"><img src="webassist/social/icons/favorites.png" onclick="addBookmark(document.title, '<?php echo urlencode('http://talkofthetowncoupons.com/merchantinformation.php?merchantPID='); ?><?php echo $row_rsAllCoupons['CMerchantPID']; ?>')" title="Bookmarks" /></a> </div>
</div>

Sign in to reply to this post

Dani Chankhour

This is a bug that will be fixed in the next dot release. To fix this issue, please replace the facebook html with this code:

<div class="icons"> <a name="fb_share" type="icon" href="#" onclick="window.open('http://www.facebook.com/sharer.php?u=<?php echo urlencode('http://localhost/test/untitled.php'); ?>', 'Facebook', 'toolbar=0,status=0,width=626,height=436'); return false;" title="Facebook"> <img src="webassist/social/icons/facebook.png" width="16" height="16" /> </a> </div>


make sure to replace the url with the url you want to use.

let me know if you have any other questions.

Sign in to reply to this post

bill173836

Thanks, That seemed to resolve the dynamic link issue. The next issue is when Facebook tries to create a comment it's choosing random images to post as a thumbnail. Now do set the image and description text. It's currently choosing older description text.

Sign in to reply to this post

Dani Chankhour

Sorry, but I'm not sure I understand the issue you are having with facebook comments.

do you have a link that you can send that could help me better understand the issue.

thanks.

Sign in to reply to this post

bill173836

Here is the link:

auto.php

What is happening is that if you click the Facebook icon on any one of the coupons then it brings up a Post to Profile window with the correct link. But here is where I'm having the problem the Post page allows you to choose a Thumbnail. On the coupon I chose it gave me 6 thumbnails to choose from. I don't want to use any of the choices I'm given. I want to define the image it chooses (for example the clients' logo).

Thanks.

Sign in to reply to this post

Dani Chankhour

Facebook usually scan the page and picks random images to choose from. If you want to choose the thumbnail, try adding this to the head of your page:

<link rel="image_src" type="image/jpeg" href="http://www.domain.com/path/icon-facebook.gif" />


Facebook will then choose that image as a thumbnail.

Sign in to reply to this post

bill173836

I've tried that and it completely ignores it and shows 6 other images. If I can't get it to show the right image is there a way to turn it off?

Sign in to reply to this post

Dani Chankhour

I can't see a way to turn off thumbnail.

Try removing this property "type="image/jpeg"" from the meta tag.

Sign in to reply to this post
loading

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...