cloudsoup

no soup, no clouds

Archive for the ‘wordpress’ tag

There’s something about Drupal…

leave a comment

There’s something about Drupal that makes me feel disinclined to post blog updates. Just one more page to hurdle before you’re into an edit box, perhaps that’s all it is.

So. WordPress again then

Written by David

March 1st, 2010 at 11:05 pm

Posted in Science and Technology

Tagged with ,

WordPress 2.0

leave a comment

WordPress 2.0 release candidate – 3, I think – is out and due to be announced as the first release of WP2 and this is it.

I’ve trashed my budding theme because I believe WP2 has all sort of new hooks and variables that will impact on plugins and themes. Haven’t had time to find out more yet.

I wish the default theme wasn’t quite so nasty.

New theme coming soon and new podcast too.

Written by David

December 27th, 2005 at 12:36 pm

Posted in Uncategorized

Tagged with

Curse of Typepad, delicious, Yahoo

leave a comment

This is currently the state of del.icio.us:

del.icio.us is down for emergency maintenance. we’ll be back as soon possible.

After being bought out by Yahoo. Similarly, as soon as Six Apart announced their deal with Yahoo, their Typepad service went down for 18 hours.

I don’t get the Typepad proposition, anyhow. Putting aside Mark Pilgrim’s contention (Freedom 0) that the utility of non-free software approaches zero, the pricing seems unattractive.

Currently, Typepad services are pitched at three levels, costing $4.95 per month for a single hosted blog with one author to $14.95 per month for ‘multiple’ authors and unlimited blogs.

My hosting – the excellent Dreamhost – costs $7.95 per month for unlimited domain names, unlimited WordPress blogs with single-click installs, unlimited MySQL databases, single-click install for phpBB, Gallery. MediaWiki, Mambo and other applications, support for Perl, PHP and Ruby on Rails, Telnet / SSH access to the server, free domain name registration and just about the best reputation for a low-cost hosting service I’ve come across. That’s Dreamhost. If you sign up to them, mention me – cloudsoup – it’ll take some money off my bill. Or sign up to them anyway, I can’t praise them enough.

I suppose Yahoo might buy Typepad. They’ve being making a few peculiar purchases and strange hirings recently.

Written by David

December 19th, 2005 at 8:41 am

WordPress Gallery Plugin

leave a comment

cat/jess1Geoff Hutchinson has produced a WP plugin for gallery images. Useful.

I’ve made a change to the plugin.

I think there was a small typo in the function wpgallery_link. The original function was:

function wpgallery_link($album, $photo, $link_class=’gallery-link’, $image_class=’gallery-image’, $img_alt=’’, $link_title=’’) {

and I amended this to

function wpgallery_link($album, $photo, $link_class=’gallery-link’, $img_class=’gallery-image’, $img_alt=’’, $link_title=’’) {

and then changed:

<img src=”‘.ALBUM_BASE.’/’.$album.’/’.$photo.’.thumb.jpg”‘.$image_class.$img_alt.’ /></a>

to

<img src=”‘.ALBUM_BASE.’/’.$album.’/’.$photo.’.thumb.jpg”‘.$img_class.$img_alt.’ /></a>

and now everything’s working fine. I’d like to change the code a bit to better manage alt and title tags.

sea/bigsur3Geoff illustrates the use of his plugin with one of his photos of Big Sur on the Calfornian coast south of Monterray. Here’s mine, taken from what look like almost the same spot.

Written by David

December 25th, 2004 at 2:48 am

Posted in Uncategorized

Tagged with ,

Weblog, WordPress, RSS

leave a comment

In the course of trying to tidy up cloudsoup a little I noticed that my RSS feeds’ contents weren’t formatted nicely in my News Reader – SharpReader. Not a Sharpreader problem it turns out, but (I think) a WordPress problem.

My RSS description node content is being converted to safe tokens by output-escaping, rather than being wrapped in a CDATA tag. According to the RSS spec, encoding HTML within a CDATA Section in the description is perfectly permissable but there seems to be no option in the default WordPress wp-rss2.php file, the PHP code that does the job of creating the RSS – no parameter that can be passed in the WordPress function.

If you choose to syndicate the full post of your weblog post in your RSS feed then the RSS is built like this:

<description>
<?php the_excerpt_rss(get_settings(’rss_excerpt_length’), 0) ;>
</description>
<content:encoded>
<![CDATA[<?php the_content('’, 0, ‘’) ?>]]>
</content:encoded>

whereas if you choose only an excerpt, the RSS gets built like so:

<description>
<?php the_excerpt_rss(get_settings(’rss_excerpt_length’), 0) ?>
</description>

and the function the_excerpt_rss doesn’ t take a parameter that stops all encoding transformations.

The unwanted upshot of this is that, for example, a post I’d like to see looking like this in my RSS:

  • CrashBonsai » toy cars and miniature trees collide
  • BBC NEWS | Wales | Royal seal of approval for Wales Millenium Centre » That’s a relief then
  • Sushi Eating HOWTO »…

actually looks lke this:

CrashBonsai » toy cars and miniature trees collide BBC NEWS | Wales | Royal seal of approval for Wales Millenium Centre » That’s a relief then Sushi Eating HOWTO »…

Which is not good. The WordPress Wiki’s entry on the_excerpt_rss says that I should be able to impose minimal filtering so I think my problem is being caused by the fact that I don’t have an excerpt, only a post body to most posts – and WordPress is doing another conversion on my behalf.

I could always replace the function, the_excerpt_rss with the_excerpt – which isn’t encoded by default. But when I try that, although the content is not tokenised, I still can’t see my del.icio.us lists properly.

The correct, WordPress solution would be to create a WordPress plugin. Until I do that, this is a quick-and-dirty way. The temporary solution is to make a small change to the file wp-rss2.php, amending

<description>
<?php the_excerpt_rss(get_settings(’rss_excerpt_length’), 0) ?>
</description>

to

<description>
<![CDATA[<?php the_excerpt_rss(get_settings(’rss_excerpt_length’), 3) ?>]]>
</description>

and then to make another amendment to the function get_the_excerpt in the file template-functions-post.php. Simply comment out the line :

$output = strip_tags($output);

That seems to be working now for my RSS feed (which, incidentally, I’ve burned through FeedBurner). I’ll need to test it a little first to make sure everything’s still working properly.

Written by David

December 5th, 2004 at 5:51 pm

Posted in Uncategorized

Tagged with , , ,

del.icio.us and WordPress: not there yet

leave a comment

Now cloudsoup remaindered links are being maintained via del.icio.us we need a way to integrate them into the weblog.

Solution so far is a quick and dirty call using the Magpie PHP RSS Parser and a cron job on the server. Better still would be to use the del.icio.s api (link location will change soon) and make calls for a specific date – and to cross-reference to other del.icio.us items using the same, or close, categories. We’ll be working on it soon.

There’s a possiblity of automatically building automated ontologies by exploring categorisations made of the same link by different people, and then of those categories applied to other links. Iy should be possible to build an entire semantic classification of del.icio.us links and by implication, of anything that’s interesting. Hmmm

Written by David

November 30th, 2004 at 10:46 am

Posted in Uncategorized

Tagged with , , ,

Weblog updates

leave a comment

Trying to change the look of this weblog a bit. I’ve installed Photo Matt’s Asides, to give inline remaindered links like Kottke’s and I’m revamping the stylesheets.

I’d like to write a plugin – although I might have to hack the files – to give separate RSS feeds for the bulk of the content and the remaindered links. And I’d like to manage the remaindered links without having to use Matt’s buffering-and-regular-expression trick. And I’m hacking around with the gallery too.

Also, don’t want the front page processing to include remaindered links in its count of items appearing…

Things might look odd for a while.

Written by David

October 30th, 2004 at 6:44 pm

Posted in Uncategorized

Tagged with

WordPress Update

leave a comment

WordPress 1.2 is out and the upgrde on cloudsoup took a little over 20mins because, for some reason, the first FTP didn’t work properly. Everything sorted now.

Some features of WordPress 1.2

  1. Sub-categories: Categories can be arranged hierarchically and infinitely deep. Multiple categories combined with sub-categories gives WordPress the most comprehensive taxonomy system of any blogging software available.
  2. OPML Export and Import: You can import and export OPML to systems like Bloglines or desktop aggregators like NetNewsWire and FeedDemon.
  3. Automatic Thumbnail Creation System: WordPress has a refined upload feature that automatically creates thumbnails any size you want.
  4. Encrypted passwords and cookies: All passwords in the database and password cookies are encrypted, ensuring maximal security.
  5. New plugin architecture: The new plugin architecture simplifies modifying or extending WordPress features. Plugins can now hook into nearly every action WordPress does.
  6. Localization of WordPress and Unicode support: The efforts put into internationalizing WordPress have borne fruit, and now you can adapt WordPRess to work in your native language. Several translations are already available.
  7. Advanced comment moderation: You can now fine-tune your moderation filters in a manner very similar to blacklists for other weblog tools. There is also mass-editing of comments, which makes it a snap to delete hundreds of comments with the click of a button, if necessary.
  8. Post preview: Near-instant previews while writing or editing articles help you proofread and make improvements before finally presenting your work of art to the world.
  9. RSS and LiveJournal Importers: The new RSS import script is the closest thing to an universal importer. It allows you to import entries from Radio weblogs even other blogging tools that we may not support specifically. The LiveJournal importer finally lets you have a full blooded self-hosted weblog without losing all your old LiveJournal posts.
  10. Unlimited update services: Now you can define multiple weblog change monitoring services to be pinged when you post.
  11. Directory flexbility: Now you can have all the WordPress files in one directory and the weblog in a higher level directory.

Written by David

May 25th, 2004 at 4:36 pm

Posted in Uncategorized

Tagged with

First WordPress Hack

leave a comment

This weblog was moved from MoveableType to WordPress just a few days ago and we’ve already created our first hack.

The hack sits in the my-hacks.php file and implements a function to return a list of the {n} most recently posted items. Here it is:


function get_recent_posts($limit = 10) {
   global  $wpdb, $tableposts;
   $list = \"<ul>n\";
   $rows = $wpdb->get_results(\"
         SELECT ID, post_title, post_date,
         post_name FROM $tableposts
         WHERE post_status = 'publish'
         ORDER BY post_date DESC
         LIMIT 1, \".$limit);
   foreach($rows as $row){
      $list .= \"<li><a href=\"\".get_permalink($row->ID) .
            \"\">\" . $row->post_title . \"</a></li>n\";
   }
   $list .= \"</ul>n\";
   echo($list);
}
	

Feel free to use it yourselves.

Written by David

May 16th, 2004 at 5:28 pm

Posted in Uncategorized

Tagged with ,