Like button! - Posted (3028 Views)
Average Member
Andy Humm
Posts: 908
908
I have had a good search here but fail to find any info if a like button has been developed for the forum. Ideally with a counter to the responses as we see on Facebook. Happy New Year folks
 Sort direction, for dates DESC means newest first  
 Page size 
Posted
Forum Admin
HuwR
Posts: 20611
20611
I have been toying with implementing a topic rating for the .net version, but still musing over a few ideas at the moment
Posted
Junior Member
Torborg
Posts: 109
109
Nice smile
Posted
Advanced Member
Carefree
Posts: 4224
4224
OK - let's put this one to bed, shall we? This is limited to topics only, since you cannot link directly to a reply without adding an additional mod. To add an active FB "like" button to your topic, here's what you need to do. If you do NOT want it connected to FB, I'd suggest the "Thanks" mod instead.
"topic.asp"
Code:

Look for the following lines (appx 630-634):

if (AdminAllowed = 1 or Reply_MemberID = MemberID) then
if (Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status <> 0) or (AdminAllowed = 1) then
Response.Write "  <a href=""JavaScript:openWindow('pop_delete.asp?" & ArchiveLink & "mode=Reply&REPLY_ID=" & Reply_ReplyID & "&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "')"">" & getCurrentIcon(strIconDeleteReply,"Delete Reply","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
end if
' DEM --> Start of Code added for Full Moderation

Above those, insert these:

' ## Like Below
If Request.ServerVariables("HTTPS") <> "off" Then
Response.Write "<iframe align=""absmiddle"" src=""https://www.facebook.com/plugins/like.php?href=" & strForumURL & "topic.asp?TOPIC_ID=" & TOPIC_ID & ";layout=button&action=like&show_faces=false&share=false"" scrolling=""no"" frameborder=""0"" style=""border:none; overflow:hidden; height:17px;"" allowTransparency=""true""></iframe>"
Else
Response.Write "<iframe align=""absmiddle"" src=""http://www.facebook.com/plugins/like.php?href=" & strForumURL & "topic.asp?TOPIC_ID=" & TOPIC_ID & ";layout=button&action=like&show_faces=false&share=false"" scrolling=""no"" frameborder=""0"" style=""border:none; overflow:hidden; height:17px;"" allowTransparency=""true""></iframe>"
End If
' ## Like Above
You Must enter a message