Page Index Toggle Pages: [1] 2 3 4 Send TopicPrint
Very Hot Topic (More than 25 Replies) Social Bookmarks V0.3 for YaBB 2.5 (Read 16713 times)
Derek Barnstorm
God Member
*****
Offline



Posts: 1146
Location: Warwickshire
Joined: Mar 23rd, 2008
Gender: Male
Social Bookmarks V0.3 for YaBB 2.5
Mar 1st, 2011 at 9:37pm
Print Post  
Social Bookmarks V0.3

Description:
-----------------
This Mod will add a Social Bookmarking system to your forum to display bookmark links at the bottom of the Message View. You can add/edit/delete/order bookmarks from the Admin Center. I've included a few bookmarking sites as an example.

Note: The bookmark icons that I've included are part of Komodo Media's Social Media Mini Icon Pack.

Screenshots:
------------------
Message View:


Admin Center - BoardMod Mods - Social Bookmarks:




Demo:
----------
http://ibrainstorm.net/modemos/forum/YaBB.pl?num=1291344117

Installation:
----------------
1) Modify YaBB files using BoardMod or manually.
2) Upload modified files to your server in ASCII mode.
3) Upload BookmarkSettings.pl, Bookmarks.lng and Bookmarks.txt to their relevant directories in ASCII mode.
4) Upload the Bookmarks folder to the ModImages directory in Binary mode.
5) Go into Admin Center => BoardMod Mods => Social Bookmarks to configure the settings.

Files to edit:
-----------------
AdminIndex.pl
Admin/AdminSubList.pl
Admin/ManageTemplates.pl
Admin/ModList.pl
Languages/English/Admin.lng
Languages/English/Display.lng
Languages/English/Error.lng
Sources/Display.pl
Templates/default/Display.template
Templates/yabb21/Display.template

Zip package:
-----------------
Social_Bookmarks_V0_3.mod
cgi-bin/yabb2/Admin/BookmarkSettings.pl
cgi-bin/yabb2/Languages/English/Bookmarks.lng
cgi-bin/yabb2/Variables/Bookmarks.txt
html_root/yabbiles/Modimages/Bookmarks/***.png

History:
------------
0.1 - First Release - 1st March 2011
0.2 - Tidied up syntax - 6th March 2011
0.3 - Added maximum characters in subject option - 7th March 2011
« Last Edit: Mar 7th, 2011 at 1:25pm by Derek Barnstorm »  

Social_Bookmarks_V0_3.zip ( 29 KB | Downloads )
Back to top
 
IP Logged
 
Fps_Brian
Full Member
***
Offline



Posts: 130
Location: Beach Haven
Joined: Aug 14th, 2008
Gender: Male
Re: Social Bookmarks V0.1 for YaBB 2.5
Reply #1 - Mar 2nd, 2011 at 4:14pm
Print Post  
Very nice mod, everyone should have this!
  

www.omgot.org
65+ mods installed
Back to top
IP Logged
 
Derek Barnstorm
God Member
*****
Offline



Posts: 1146
Location: Warwickshire
Joined: Mar 23rd, 2008
Gender: Male
Re: Social Bookmarks V0.1 for YaBB 2.5
Reply #2 - Mar 2nd, 2011 at 5:43pm
Print Post  
Thanks Brian.
  
Back to top
 
IP Logged
 
Derek Barnstorm
God Member
*****
Offline



Posts: 1146
Location: Warwickshire
Joined: Mar 23rd, 2008
Gender: Male
Re: Social Bookmarks V0.2 for YaBB 2.5
Reply #3 - Mar 6th, 2011 at 7:19pm
Print Post  
Fixed a few silly syntax and grammar mistakes. V0.2 attached to the first post.

Changes are in:

BookmarkSettings.pl
Bookmarks.lng
Display.pl
  
Back to top
 
IP Logged
 
ayjay
New Member
*
Offline


Code Moron

Posts: 30
Joined: Jan 13th, 2009
Re: Social Bookmarks V0.2 for YaBB 2.5
Reply #4 - Mar 7th, 2011 at 11:59am
Print Post  
Hi Derek, nice mod, thanks!
I just installed it, really smooth and easy to configure and it's appearing on all my threads now.

The only gotcha I have found is that Twitter seems to be truncating the URL off the end.

If in Firefox I right-click the Twitter icon at the end of a thread all the information is there (Subject - URL) and the URL is formatted with the correct "%20" but twitter only shows the subject for some reason.


Ok, just had a brain wave before hitting "post" here...

Maybe the subject + URL was too long?
...and it is!

So now for a feature request, any chance of truncating the subject to the first 50-60 chars and then it will leave the URL intact.

As a workaround I have put the URL before the subject in the Twitter config and it appears to be fine on the long subject posts.
  
Back to top
 
IP Logged
 
Derek Barnstorm
God Member
*****
Offline



Posts: 1146
Location: Warwickshire
Joined: Mar 23rd, 2008
Gender: Male
Re: Social Bookmarks V0.2 for YaBB 2.5
Reply #5 - Mar 7th, 2011 at 12:35pm
Print Post  
Hi ayjay,

ayjay wrote on Mar 7th, 2011 at 11:59am:
So now for a feature request, any chance of truncating the subject to the first 50-60 chars and then it will leave the URL intact.

Yes, of cause.

Is this a normal thing for bookmarking sites to do then - limit how many characters you are allowed in the subject?

Maybe if I make it an Admin option to choose how many characters you want to be displayed - what do you think?
  
Back to top
 
IP Logged
 
ayjay
New Member
*
Offline


Code Moron

Posts: 30
Joined: Jan 13th, 2009
Re: Social Bookmarks V0.2 for YaBB 2.5
Reply #6 - Mar 7th, 2011 at 12:46pm
Print Post  
I think it's only Twitter that will give that grief as it has a 140 char limit.

I also just noticed that Facebook grabs the forum Meta tag "Description" as well as the subject.  The gotcha there is that will be the same for all posts from the forum.  (I'm still testing that one)

**update**
Yep, the Facebook one does grab the forum meta tag for Description.


  
Back to top
 
IP Logged
 
Derek Barnstorm
God Member
*****
Offline



Posts: 1146
Location: Warwickshire
Joined: Mar 23rd, 2008
Gender: Male
Re: Social Bookmarks V0.3 for YaBB 2.5
Reply #7 - Mar 7th, 2011 at 1:29pm
Print Post  
Okay, I've added a character limit to the subject now. Changes are in:

BookmarkSettings.pl
Bookmarks.lng
Display.pl

V0.3 attached to the first post.

ayjay wrote on Mar 7th, 2011 at 12:46pm:
I also just noticed that Facebook grabs the forum Meta tag "Description" as well as the subject.  The gotcha there is that will be the same for all posts from the forum.  (I'm still testing that one)

Mmm, I don't really know if I can do a lot about that I'm afraid. You'll have to let me know your findings once you've finished testing...
  
Back to top
 
IP Logged
 
ayjay
New Member
*
Offline


Code Moron

Posts: 30
Joined: Jan 13th, 2009
Re: Social Bookmarks V0.2 for YaBB 2.5
Reply #8 - Mar 7th, 2011 at 1:50pm
Print Post  
Speedy!

I installed it and its truncating every Twitter subject to just "..." even when there are enough of the 140 chars left over.
  
Back to top
 
IP Logged
 
Derek Barnstorm
God Member
*****
Offline



Posts: 1146
Location: Warwickshire
Joined: Mar 23rd, 2008
Gender: Male
Re: Social Bookmarks V0.3 for YaBB 2.5
Reply #9 - Mar 7th, 2011 at 1:56pm
Print Post  
Ah, I should have mentioned that you'll need to re-save the settings - you should find it's alright then...
  
Back to top
 
IP Logged
 
ayjay
New Member
*
Offline


Code Moron

Posts: 30
Joined: Jan 13th, 2009
Re: Social Bookmarks V0.3 for YaBB 2.5
Reply #10 - Mar 7th, 2011 at 2:09pm
Print Post  
It's the same I'm afraid.
Even tried removing v0.3 and installing it again with the same results.

Still get "..." for the subject.
  
Back to top
 
IP Logged
 
Derek Barnstorm
God Member
*****
Offline



Posts: 1146
Location: Warwickshire
Joined: Mar 23rd, 2008
Gender: Male
Re: Social Bookmarks V0.3 for YaBB 2.5
Reply #11 - Mar 7th, 2011 at 2:19pm
Print Post  
You have saved the settings here (see image)?



What does your Variables/BookmarkSettings.txt look like? It should look something like this:

Code
Select All
###############################################################################
# BookmarkSettings.txt (Social Bookmark configurations)			     #
###############################################################################

$en_bookmarks = 1; # Enable Social Bookmarks
$bm_subcut = 50; # Maximum characters in subject
$bm_boards = "general\,\ test\,\ testboard"; # Select the boards which Social Bookmarks will be swown in

1; 

  
Back to top
 
IP Logged
 
ayjay
New Member
*
Offline


Code Moron

Posts: 30
Joined: Jan 13th, 2009
Re: Social Bookmarks V0.3 for YaBB 2.5
Reply #12 - Mar 7th, 2011 at 2:45pm
Print Post  
Derek Barnstorm wrote on Mar 7th, 2011 at 2:19pm:
What does your Variables/BookmarkSettings.txt look like?


Not like yours above!
So I removed the file, tried again and got the same result.

Then I removed both the bookmark.txt and BookmarkSettings.txt, removed the mod, checked to make sure it was removed, added it again and BINGO, I can now see the "Maximum characters in subject:" option in the Admin Center.  A save and my bookmarksettings.txt looks like yours now.

I can only guess it was a board mod quirk with the remove/add of this mod.

Tested as working perfectly with long subject lines in Twitter now.

FYI - The Facebook quirk with it grabing the meta tag looks like a function of facebook and I agree, looks like there is little you could do about that short of writing a mod that grabs key words from a thread and injects them into the meta tags for Facebook and search engines to find... but that would be a request in a different thread.
Wink

Excellent work (as always) Derek, thanks!
  
Back to top
 
IP Logged
 
Derek Barnstorm
God Member
*****
Offline



Posts: 1146
Location: Warwickshire
Joined: Mar 23rd, 2008
Gender: Male
Re: Social Bookmarks V0.3 for YaBB 2.5
Reply #13 - Mar 7th, 2011 at 2:52pm
Print Post  
Strange. Glad you got it working anyway.

And thanks for the feedback and testing...
  
Back to top
 
IP Logged
 
ayjay
New Member
*
Offline


Code Moron

Posts: 30
Joined: Jan 13th, 2009
Re: Social Bookmarks V0.3 for YaBB 2.5
Reply #14 - Mar 7th, 2011 at 2:58pm
Print Post  
I can only think that I didnt copy something across initially with v0.3 but I then did copy it across when I reinstalled it the second time.

I would put this one down to user error and not something you or Boardmod did.

Grin
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: [1] 2 3 4
Send TopicPrint