Etomite Community Forums: Wish: Snippet to post etomite page url to social networks - Etomite Community Forums

Jump to content


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Wish: Snippet to post etomite page url to social networks Rate Topic: -----

#1 User is offline   cathode 

  • Etomite Staff
  • Icon
  • Group: Staff
  • Posts: 648
  • Joined: 21-November 05
  • Location:Indiana, U.S.

Posted 24 June 2009 - 04:15 PM

I'd love to have a snippet that you could add to a template that would display icons and properly-formatted links to allow a viewer to one-click post the page to digg, reddit, facebook, etc. Just like the WordPress sociable plugin. (http://yoast.com/wordpress/sociable/)

I think this would be extremely simple.

Generated links examples would be like this (depending on the individual site's submission link format):


#2 User is offline   cathode 

  • Etomite Staff
  • Icon
  • Group: Staff
  • Posts: 648
  • Joined: 21-November 05
  • Location:Indiana, U.S.

Posted 24 June 2009 - 04:17 PM

View Postcathode, on Jun 24 2009, 12:15 PM, said:

I'd love to have a snippet that you could add to a template that would display icons and properly-formatted links to allow a viewer to one-click post the page to digg, reddit, facebook, etc. Just like the WordPress sociable plugin. (http://yoast.com/wordpress/sociable/)

I think this would be extremely simple.

Generated links examples would be like this (depending on the individual site's submission link format):


If any programmer wants to team up to build this, I'll do the images, output markup, and the CSS :)

#3 User is offline   mikef 

  • Loves Etomite Forums!
  • PipPipPipPip
  • Group: Member
  • Posts: 1,544
  • Joined: 30-August 05
  • Gender:Male
  • Location:Cheshire, UK
  • Interests:Photography, Gardening for Wildlife

Posted 24 June 2009 - 04:46 PM

View Postcathode, on Jun 24 2009, 05:17 PM, said:

If any programmer wants to team up to build this, I'll do the images, output markup, and the CSS :)

something like this?
$returntext=<<<SBM
<div id="socialBookMarks"> 
<h3>Bookmark with:</h3> 
<ul>
<li class="delicious"> 
<a id="delicious" title="Post this story to Delicious" href="http://del.icio.us/post?url=$url&amp;title=$title">Delicious</a> 
</li>
<li class="digg"> 
<a id="digg" title="Post this story to Digg" href="http://digg.com/submit?url=$url&amp;title=$url">Digg</a> 
</li>
<li class="reddit"> 
<a id="reddit" title="Post this story to reddit" href="http://reddit.com/submit?url=$url&amp;title=$title">reddit</a> 
</li>
<li class="facebook"> 
<a id="facebook" title="Post this story to Facebook" href="http://www.facebook.com/sharer.php?u=$url">Facebook</a> 
</li>
<li class="stumbleupon"> 
<a id="stumbleupon" title="Post this story to StumbleUpon" href="http://www.stumbleupon.com/submit?url=$url&amp;title=$title">StumbleUpon</a> 
</li>
</ul>
</div>
SBM;

need to pass url and title as parameters, though for most uses these could easily be derived using makeurl and the title field directly.

This post has been edited by mikef: 24 June 2009 - 04:49 PM


#4 User is offline   cathode 

  • Etomite Staff
  • Icon
  • Group: Staff
  • Posts: 648
  • Joined: 21-November 05
  • Location:Indiana, U.S.

Posted 24 June 2009 - 04:57 PM

View Postmikef, on Jun 24 2009, 12:46 PM, said:

something like this?
$returntext=<<<SBM
<div id="socialBookMarks"> 
<h3>Bookmark with:</h3> 
<ul>
<li class="delicious"> 
<a id="delicious" title="Post this story to Delicious" href="http://del.icio.us/post?url=$url&amp;title=$title">Delicious</a> 
</li>
<li class="digg"> 
<a id="digg" title="Post this story to Digg" href="http://digg.com/submit?url=$url&amp;title=$url">Digg</a> 
</li>
<li class="reddit"> 
<a id="reddit" title="Post this story to reddit" href="http://reddit.com/submit?url=$url&amp;title=$title">reddit</a> 
</li>
<li class="facebook"> 
<a id="facebook" title="Post this story to Facebook" href="http://www.facebook.com/sharer.php?u=$url">Facebook</a> 
</li>
<li class="stumbleupon"> 
<a id="stumbleupon" title="Post this story to StumbleUpon" href="http://www.stumbleupon.com/submit?url=$url&amp;title=$title">StumbleUpon</a> 
</li>
</ul>
</div>
SBM;

need to pass url and title as parameters, though for most uses these could easily be derived using makeurl and the title field directly.


Awesome... let me see what I can do with it...

#5 User is offline   cathode 

  • Etomite Staff
  • Icon
  • Group: Staff
  • Posts: 648
  • Joined: 21-November 05
  • Location:Indiana, U.S.

Posted 24 June 2009 - 06:30 PM

I am 99% there...
Example: http://n-vent.com/audio-player.html

Just need to know how to produce the site name (for LinkedIN)... Mike, do you know that one? I could not find it in documentation...

#6 User is offline   cathode 

  • Etomite Staff
  • Icon
  • Group: Staff
  • Posts: 648
  • Joined: 21-November 05
  • Location:Indiana, U.S.

Posted 24 June 2009 - 07:13 PM

View Postcathode, on Jun 24 2009, 02:30 PM, said:

I am 99% there...
Example: http://n-vent.com/audio-player.html

Just need to know how to produce the site name (for LinkedIN)... Mike, do you know that one? I could not find it in documentation...



Turns out it's $etomite->config['site_name']

(thanks Ralph)

#7 User is offline   cathode 

  • Etomite Staff
  • Icon
  • Group: Staff
  • Posts: 648
  • Joined: 21-November 05
  • Location:Indiana, U.S.

Posted 24 June 2009 - 07:18 PM

All done- I'll post this snippet once I have triple-checked everything.

#8 User is offline   cathode 

  • Etomite Staff
  • Icon
  • Group: Staff
  • Posts: 648
  • Joined: 21-November 05
  • Location:Indiana, U.S.

Posted 24 June 2009 - 07:50 PM

Final snippet posted here: http://www.etomite.c...?showtopic=8495

#9 User is offline   DeanC 

  • Etomite Administrator
  • Icon
  • Group: Admin
  • Posts: 4,702
  • Joined: 08-June 04
  • Gender:Male
  • Location:United Kingdom

Posted 25 June 2009 - 11:21 AM

Take a look at the Twitter snippet I converted that you could also implement.. TweetThis

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users