Matthew Trevino's Scarform
this.isn't.it.

Plugins to do amazingly simple things

It really kind of amazes me the amount of work people will go through to avoid work. For instance, plugins that do very simple things.

Let’s remember for a moment that Wordpress is written in php and that one small set of files is enough to run the entire front-end.

So let’s say that somewhere within the index.php file of the site, you place on single bit of code. If you’re running a layout where single post views, archive views, and the main page all look the same then chances are pretty good that whatever you placed there will appear everywhere.

Keeping that in mind, let’s go on a run-through of two types of plugins that do exactly that – as well as the code to just do it yourself.


Buy Me a Beer – (or any Paypal donation type plugins.

What these plugins are good for are placing within the loop of single post page views a line of code that does something very simple: combines a donation link and the permalink to the post in question.

1
Like what you just read? Why not <a href="https://www.paypal.com/cgi-bin/webscr?cmd=_xclick&business=YOUR_PAYPAL_EMAIL&amount=&return=&item_name=Donation+for+<?php the_title(", "); ?>">buy me a drink</a>?

Submit it – (or any plugin that allows a user to submit a single post to any social bookmarking site, like Digg and the like).

Like the Paypal plugins, this too inserts a simple link that includes your permalink into all single post (or main page) views.

1
<br /><p>share | <a href="http://myweb2.search.yahoo.com/myresults/bookmarklet?u=<?php the_permalink() ?>" target="_blank">+ Yahoo</a> | <a href="http://www.google.com/bookmarks/mark?op=add&bkmk=<?php the_permalink() ?>" target="_blank">+ Google</a> | <a href="http://www.furl.net/storeIt.jsp?u=<?php the_permalink() ?>">+ Furl</a> | <a href="http://www.spurl.net/spurl.php?title=Learn+to+write+your+own+articles&url=<?php the_permalink() ?>" target="_blank">+ Spurl</a> | <a href="http://del.icio.us/post?&url=<?php the_permalink() ?>" target="_blank">+ Del.icio.us</a> | <a href="http://digg.com/submit?phase=2&url=<?php the_permalink() ?>" target="_blank">+ Digg</a> | <a href="https://favorites.live.com/quickadd.aspx?marklet=1&mkt=en-us&url=<?php the_permalink() ?>" target="_blank">+ Live</a> | <a href="http://blogmarks.net/my/new.php?title=<?php the_title(); ?>&url=<?php the_permalink() ?>" target="_blank">+ Blogmarks</a>

Code for Yahoo, Google, Furl, Spurl, Del.icio.us, Digg, Live, and Blogmarks.


And while I’m really not trying to go into a complete tutorial on this type of thing (or put any hard working plugin makers out of work) it would just seem that what the Wordpress community needs more of are plugins that do more complex things that most of us don’t want to find out how to do on our own (or don’t have the time) instead of the ones that really only take a few minutes to set up ourselves.




required



required - won't be displayed


Your Comment:

Posted: July 3rd 2007
Category: Code Snippets
Tags: , , , ,

…and you’re not getting it.  Sorry to disappoint.

Previous Entry

Did you know that if you were to perform a search for “Wordpress”, you would get more results than for “Jesus”?

Currently, Wordpress ranks in at 151,000,000 results (returned in 0.10 seconds).

And apart from “Jesus”, it’s apparently more popular a phrase than “Satan”, “President Bush”, “Anime”, and “the beatles” (who, coincidentally are not “bigger than Jesus”).

Next Entry

Archives
Categories