Yet Another DailyDelicious hack for WordPress
I wanted a nice simple way to mirror my daily bookmarks that I’ve added to [del.icio.us](http://del.icio.us) into [WordPress](http://www.wordpress.org)
Stephen Eyre’s [dailydelicious](http://www.dot-totally.co.uk/dailydelicious.txt) was close, but
not exactly they way I wanted it. He used the RSS feed, but that doesn’t give a good daily cutoff.
So, I present Yet Another Daily Delicious php script: [yadd.php](http://www.nozell.com/marc/blog/data/yadd-1.0.TXT).
It asks for just today’s bookmarks using the published api, parses the XML, generates nicely formatted HTML and creates a WordPress entry.
Here is the writeup from the code:
- - -
This is yadd.php V1.0 by Marc Nozell (marc@nozell.com) based on
Stephen Eyre's dailydelicious
(http://www.dot-totally.co.uk/dailydelicious.txt)
See http://www.nozell.com/blog/ for the latest version of
'yet another daily delicious' (yadd.php)
USAGE:
1) Edit the section below. At the very least use your del.icio.us
username and password ($del_user/$del_password)
2) Put there file somewhere on the server where you run WordPress.
3) Arrange for this page to be hit once a day, say 11:30ish your
local time. del.icio.us seems to track UTC so depending on which
timezone you live in, some bookmarks from your yesterday may show
up. Consider using a simple cronjob that looks like this:
30 23 * * * $HOME/bin/yadd.sh
where yadd.sh looks like this:
#!/bin/bash
curl http://www.yoursite.com/yadd.php
4) In the morning edit the entry if you wish. I've tried to generate
pretty HTML so it will be simple to edit the entry.
THINGS TO KEEP IN MIND
Anyone that hits the URL for this script will cause your current
bookmarks to be dumped into WordPress. Clearly this is not
desirable.
You have some options. The easiest is to keep this URL 'secret'.
Name it something unusual and put it in a non-obvious place.
Remember that if you display your web hit stats, the url will be
exposed. A better solution to use .htaccess to limit access. If
you do that remember to update the url wget uses to include the
username/password, something like this:
curl http://someuser:somepassword@www.yoursite.com/yadd.php
Enjoy,
-marc
Tags: blog, DailyDelicious, General, useful, web
September 27th, 2004 at 7:11 pm
Could this be modified to make the posts on a weekly basis rather than daily?
November 22nd, 2004 at 8:44 pm
that is a great script. got it up and running fine. i want my daily bookmarks to display underneath any posts i make for a specific day, so if i set my cron to hit at, say, 12.01 am, can i make the yadd.php file fetch my links from the previous day? any help appreciated.
November 25th, 2004 at 11:23 pm
[…] he other solutions don’t rely on. Luckily, I stumbled across Marc Nozell’s DailyDelicious Hack that relies on […]
December 30th, 2004 at 3:04 am
[…] (plugin, posts all links once per day…could you set the script to run more often?) YADD (does the same thing, goes thru api inste […]
January 9th, 2005 at 3:32 am
Phrsnant , I think it can be modified that way … but… I would also like to know HOW
January 30th, 2005 at 6:32 pm
Yet Another DailyDelicious Patch
I recently setup up Yet Another DailyDelicious hack (yadd) on stratified. Among all of the daily del.icio.us grabbers, it seemed the easiest to configure and use, and indeed it is. The only problem is that for those of us (all eyes on Zach) who don’…
January 30th, 2005 at 6:34 pm
Yet Another DailyDelicious Patch
I recently setup Yet Another DailyDelicious hack (yadd) on stratified. Among all of the daily del.icio.us grabbers, it seemed the easiest to configure and use, and indeed it is. The only problem is that for those of us (all eyes on Zach) who don’t b…
January 30th, 2005 at 6:49 pm
Extremely useful little script.
I wrote a patch that prevents yadd.php from posting if there are no links for that day. It is available here.
January 31st, 2005 at 12:05 am
[…] der: General blog useful — Marc Nozell @ 7:05 pm
I’ve updated my Yet Another Daily del.icio.us (yadd.php) so it can be c […]
February 7th, 2005 at 7:16 pm
Nice plugin, if you get a chance to develop it, I would really like to see the following:
Make no post at all in the case that there are no daily links - at the moment the plugin makes an empty entry that must be deleted.
If there are a large number of posts (e.g, over a fixed threshold), could the plugin use the more tag, so that we dont get an excessivly long posting on the home page.
February 9th, 2005 at 2:50 pm
Enhanced Daily Del.icio.us plugin
Working with PHP can be a bowel-churning experience; It is one of the most rubbish computer languages ever devised, because it encourages virtually every bad habit a developer could adopt. Its only saving grace is almost ubiquitous integration with Apa…
February 26th, 2005 at 12:50 pm
Daily Delicious and POP3Gateway
I have created a module to grab the last week’s del.icio.us and automatically post them as a blog entry. The idea, and much of the code came from Marc Nozell’s WordPress plugin. I cleaned up the code for Xaraya to handle it just a bit better, and…
March 28th, 2005 at 9:58 am
[…] s heb je enorme bezwaren stel me dan op de hoogte Het update script is voor de liefhebber hier te vinden.
Comments
»
[…]
April 1st, 2005 at 2:32 am
[…] Plugins Database (nice xhtml/javascript interface) (tags: wordpress plugins plugin) Marc Nozell’s mini-blog » Blog Archive » Yet Another Da […]
May 18th, 2005 at 9:53 am
[…] «å‰Šé™¤ï¼‰
Yet Another DailyDelicious hack for WordPress
Yet Another DailyDelicious hack for WordPress ã“れを […]
June 15th, 2005 at 1:59 pm
[…] that this made for an ideal “remaindered links” wordflow. This script, called Yet Another Daily Delicious (YADD), is quite robust in […]
June 16th, 2005 at 3:47 am
[…] looking for (or, dare I to mention, write) the appropriate script. The one was available here. With small modifications I guess it will do the […]
July 1st, 2005 at 12:31 pm
[…] uicklinks for 2005-07-01
Posted on Friday, July 1st, 2005 at 1:18 pm in Quicklinks
Yet Another DailyDelicious Uses a cronjob to get the d […]
August 22nd, 2005 at 5:13 pm
[…] daily bookmarks that I’ve added to del.icio.us into WordPress" // posted by t.a.l. @ 11:53 PM Comments: Post a Comment <<Home […]
August 23rd, 2005 at 7:11 am
it seem like the script is broken due to delicious api issue ?
August 29th, 2005 at 11:58 am
I get the following errors:
Warning: fopen(): URL file-access is disabled in the server configuration in /home/.jargon/lazopolis/yet.anotherblog.net/yadd.php on line 106
Warning: fopen(http://…@del.icio.us/api/posts/get?dt=2005-08-29): failed to open stream: no suitable wrapper could be found in /home/.jargon/lazopolis/yet.anotherblog.net/yadd.php on line 106
Warning: fread(): supplied argument is not a valid stream resource in /home/.jargon/lazopolis/yet.anotherblog.net/yadd.php on line 113
Any idea on what’s wrong?
August 29th, 2005 at 1:41 pm
lazopolis,
It looks like from the writeup in the manual page for fopen (http://us2.php.net/fopen) that is could be a configuration issue.
-marc
September 10th, 2005 at 2:46 am
[…] Along the way, I stumbled over a link to Yet Another DailyDelicious hack for WordPress at Marc Nozell’s blog. It’s been a long time since I talked with Marc, back when he was active at RootsWeb. It was extremely nice to run across him again. […]
September 26th, 2005 at 12:12 pm
[…] Aquest script s’encarrega de copiar al wordpress totes les entrades que s’hagi fet durant el dia a del.icio.us! L’he modificat de manera que ho faci com a mi m’interessa (en català , eliminant informació no necessà ria i adaptant-lo al servidor) i ja està rulant! […]
October 18th, 2005 at 4:56 pm
I just modified the script to use the CURL libraries instead of fopen and fread. It seems to work fine. My host (Dreamhost) doesn’t allow the fopen() libraries any longer. This is what I came up with after a couple of hours hacking at it.
I’ll probably take another look at it tonight and see if I can make it skip days it detects no entries. I believe this can be done by pulling a die() if the XML string does not contain a </posts> in it.
For example, I created my del.icio.us account today. If I look at yesterday’s date for the string, I get the following returned:
<posts dt=”20051017″ tag=”" user=”chiieddy”/>
Nothing else.
BTW, for those who are asking about changing the date, for yesterday just change this line:
$date = mktime(0,0,0,$today[’mon’], $today[’mday’], $today[’year’]);
New line should read:
$date = mktime(0,0,0,$today[’mon’], $today[’mday’]-1, $today[’year’]);
For those wanting a whole week, you’d have to create a recursive function to do so, the del.icio.us API only recognizes a single date at time. You’d have to set your cronjob to run weekly and then cycle through all the days of the week.
October 18th, 2005 at 5:01 pm
del.icio.us
I’ve signed up for a del.icio.us account which allows me to mark links as I find them. This will allow me to quickly mark pages I want to come back to and share them as well. Once a day, this blog will update with the day’s links. I&#…
October 19th, 2005 at 8:20 am
Marc -
Does the line:
$del_showlink = true;
(whether or not to show the link to your del.icio.us account) actually work? I can’t find any subsequent code in the php file using this variable.
October 22nd, 2005 at 11:26 am
del.icio.us Script Update
Good morning. The del.icio.us script I’ve been working on has been updated again. It now does the following…
…
November 14th, 2005 at 11:44 am
[…] Here is my small contribution to the wonderful world of Wordpress : WP-cron YADD is an integration of YADD into WP-cron architecture. By this mean, no more hassle writing shell scripts and using system cron table. Instead … well, instead, nothing to do ! To install, put it in your plugins directory, provided YADD and WP-cron are installed, it will simply work. […]
November 15th, 2005 at 2:12 am
[…] (YADD) hack for WordPress and a Cron job every night. Don’t get me started… Listen to this article| […]
November 15th, 2005 at 7:33 am
I get the following error message:
Any idea what’s wrong?
November 15th, 2005 at 7:34 am
I’m using Elana’s modified version, by the way. But I get the same error message using the original version, only with a different line number for obvious reasons.
November 15th, 2005 at 7:41 am
Never mind, I got it working. It seems I had a typo in the location of my Wordpress location.
Thanks for a great hack!
November 21st, 2005 at 4:03 pm
[…] FeedBurner already gives some of these services. You can easily “mix” your blog news, with your Flickr photostream and your del.icio.us bookmarks. You can even mix them in different ways, say gather all your weekly del.icio.us bookmarks in one single post in the new feed generated. Or you could create your own “video channel” of videos indexed by Yahoo! and tagged with a certain keyword, like “funny”, or “football”. Or automatically post your del.icio.us bookmarks as a single post in your blog on a daily basis using yadd. Or combine a GeoRSS blog feed with geo-tagged Flickr images. Or upcoming.org events with rsswether.com… […]
November 21st, 2005 at 4:26 pm
[…] FeedBurner already gives some of these services. You can easily “mix” your blog news, with your Flickr photo stream and your del.icio.us bookmarks. You can even mix them in different ways, say gather all your weekly del.icio.us bookmarks in one single post in the new feed generated. Or you could create your own “video channel” of videos indexed by Yahoo! and tagged with a certain keyword, like “funny”, or “football”. Or automatically post your del.icio.us bookmarks as a single post in your blog on a daily basis using yadd. Or combine a GeoRSS blog feed with geo-tagged Flickr images. Or upcoming.org events with rsswether.com… […]
November 29th, 2005 at 4:46 am
[…] Nozell, rhymes with Oh Hell » Blog Archive » Yet Another DailyDelicious hack for WordPress (tags: del.icio.us wordpress tools) […]
December 12th, 2005 at 7:43 pm
[…] Nozell, rhymes with Oh Hell » Blog Archive » Yet Another DailyDelicious hack for WordPress (tags: webtips) […]
December 13th, 2005 at 4:00 am
[…] Nozell, rhymes with Oh Hell » Blog Archive » Yet Another DailyDelicious hack for WordPress (tags: wordpress del.icio.us delicious plugin php plugins blog) […]
December 13th, 2005 at 7:38 pm
[…] Yet Another DailyDelicious hack for WordPress This is another way to get daily del.icio.us links into Wordpress. It asks for just today’s bookmarks using the published api, parses the XML, generates nicely formatted HTML and creates a WordPress entry. (tags: wordpress del.icio.us plugins hacks) […]
December 15th, 2005 at 12:53 am
[…] Here’s how I do it Sorry to disappoint you Steve, it’s 50% automatic and 50% human labor. If you’re wondering why my link posts look different, it’s because I’m using a more complex way of doing this instead of the Daily Del.icio.us posts technique I mentioned last month. My method isn’t for the faint-hearted as it involves the Yet Another Daily Delicious (YADD) hack (secured) for WordPress and a unix cron job every night. I didn’t explain beyond this previously, but this is the link posting workflow: […]
December 20th, 2005 at 5:23 pm
Thanks.
WFM (Works For Me) WordPress on a remote server
December 25th, 2005 at 12:40 am
[…] Yet Another DailyDelicious hack for WordPress a nice simple way to mirror my daily bookmarks that I’ve added to del.icio.us into WordPress (tags: wordpress 2Do plugin del.icio.us) […]
December 25th, 2005 at 2:22 am
[…] Yet Another DailyDelicious hack for WordPress a nice simple way to mirror my daily bookmarks that I’ve added to del.icio.us into WordPress (tags: 2Do, del.icio.us, plugin, wordpress) […]
January 1st, 2006 at 12:18 pm
[…] Nozell, rhymes with Oh Hell » Blog Archive » Yet Another DailyDelicious hack for WordPress I’m toying around with pulling in a “daily del.icio.us” feature into my blogging. We’ll see where that goes. (tags: del.icio.us) […]
January 4th, 2006 at 6:42 pm
[…] As with previous Wordpress upgrades this one was also painless. My ‘Yet Another Daily Delicious‘ and ‘Yet Another Weekly Delicious‘ continue to work also. I’ve not yet restored the style sheet header (this one) or added back some of the other doodads. […]
January 8th, 2006 at 11:28 pm
[…] Yet Another DailyDelicious hack for WordPress (tags: blog wordpress tools) […]
January 16th, 2006 at 11:56 pm
[…] Na een zoektocht met Google vond ik een php-script van Nozell, Yet Another DailyDelicious (yadd), waarmee je dagelijks een overzicht van je del.icio.us bladwijzers kunt laten publiceren. Het script wordt door de server op een vast tijdstip uitgevoerd, dus je hebt er verder geen omkijken meer naar en toch dagelijks automagisch een bericht op je blog. […]
March 6th, 2006 at 1:43 pm
[…] Nozell, rhymes with Oh Hell » Blog Archive » Yet Another DailyDelicious hack for WordPress – Tagged as: del.icio.us delicious […]
March 15th, 2006 at 1:38 pm
I’m having trouble setting up a chronjob to do this… I’ve googled for instructions on chronjobs, but I’m having trouble finding anything relevant. Am I understanding this right:
Put the script in the same directory as WP on my server
Also create a file called yadd.sh and put it there as well
Set a chron job to yadd.sh
I tried this and it didn’t seem to do anything.
Any help would be appreciated.
If it helps, my host is 1and1.com
March 15th, 2006 at 1:46 pm
Chronjob help?…
Another plea for help from my readership:
I’m trying to use this WordPress hack to import my del.icio.us bookmarks in WP: YADD.
I’m having trouble figuring out how to setup the chronjob right. If anyone could help me out, or at least point…
March 15th, 2006 at 2:22 pm
Try searching for ‘cron’ (not ‘chron’) or ‘crontab’. Wikipedia’s Crontab page does a good
job of describing it. Also check your man pages (eg: man -k cron)
March 15th, 2006 at 2:51 pm
OK thanks… just to make sure, I am supposed to create a text file called yadd.sh on my server, correct? All told, I should have yadd.php, yadd.sh, and a crontab file?
March 25th, 2006 at 12:59 am
[…] Yet Another DailyDelicious hack for WordPressã“れをやã£ã¦ã¿ã‚ˆã†ã¨æ€ã£ã¦ã„ã‚‹ã®ã§ã™ãŒãƒ»ãƒ»æ€ã†ã ã‘ã§æ™‚é–“ãŒãªã„。 […]
March 27th, 2006 at 12:28 am
[…] Yet Another DailyDelicious hack for WordPress A complex hack for Delicious to create a daily post for WordPress (tags: blogging hack) […]
April 18th, 2006 at 5:10 pm
[…] Cannot Access Web Address – Tagged as: restricted unfiled Nozell, rhymes with Oh Hell » Yet Another DailyDelicious hack for WordPress – Tagged as: del.icio.us plugin wordpress The Several Habits of Wildly Successful del.icio.us Users » Slacker Manager – Tagged as: del.icio.us howto tips Spinning the Election – Tagged as: spintactics EasyBib: Free Automatic Bibliography Composer - MLA and APA formatting – Tagged as: tools writing Google Calendar – Tagged as: google del.icio.us tag cloud v1.0 » nickbouton.com – Tagged as: del.icio.us plugin wordpress WordPress › Error – Tagged as: dugg Wired News: The Man Behind Scrambled Hackz – Tagged as: music […]
May 3rd, 2006 at 1:27 am
[…] این طوری Ùقط لازم است من زنده باشم Ùˆ هر روز در اینترنت چرخ بخورم Ùˆ علامت بزنم! بعد ساعت بیست Ùˆ سه Ùˆ پنجاه Ùˆ نه دقیقه یکی می‌آید اینجا Ùˆ تولید Ù…ØØªÙˆÛŒ می‌کند! قابل توجه کسانی Ú©Ù‡ به Ú©Ùگیرشان به ته دیگ خورده.  […]
May 18th, 2006 at 10:42 am
Please take a look at http://blog.del.icio.us/blog/2006/05/feel_secure.html in del.icio.us blog.
May 27th, 2006 at 5:39 am
[…] è¿™é‡Œè¿˜æœ‰å‡ ç¯‡del.icio.us è¿›é˜¶åº”ç”¨çš„æ–‡ç« ï¼Œæ¬¢è¿Žé˜…è¯»ï¼š Yet Another Daily Delicious The Several Habits of Wildly Successful del.icio.us Users Firefox del.icio.us bookmarklet […]
May 27th, 2006 at 7:46 am
Great post and I’ve introduced into my teamblog.
May 29th, 2006 at 8:23 pm
[…] You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your ownsite. […]
June 16th, 2006 at 11:09 am
[…] Yet Another DailyDelicious hack for WordPress (tags: wordpress Tools plugin del.icio.us blogging) […]
June 17th, 2006 at 10:26 am
[…] Nozell, rhymes with Oh Hell » Yet Another DailyDelicious hack for WordPress (tags: delicious wordpress blogging) […]
June 17th, 2006 at 10:27 am
[…] Nozell, rhymes with Oh Hell » Yet Another DailyDelicious hack for WordPress (tags: delicious wordpress blogging) […]
June 22nd, 2006 at 8:13 am
[…] Nozell, rhymes with Oh Hell » Yet Another DailyDelicious hack for WordPress Not tried yet (tags: blog Del.icio.us hacks php tech wordpress) […]
July 30th, 2008 at 8:40 pm
[…] DailyDelicious hack Yet Another DailyDelicious hack for WordPress […]
October 10th, 2008 at 2:30 am
[…] Nozell, rhymes with Oh Hell » Blog Archive » Yet Another DailyDelicious hack for WordPress (tags: wordpress plugin del.icio.us blogging) Posted in del.icio.us | […]
October 17th, 2008 at 5:12 am
[…] Nozell, rhymes with Oh Hell » Blog Archive » Yet Another DailyDelicious hack for WordPress (tags: wordpress del.icio.us plugin) […]