From 49d5cbbf48bbf5b762a4f932e79a93fdaf519316 Mon Sep 17 00:00:00 2001 From: Oliver Davies Date: Sun, 3 May 2015 18:55:38 +0100 Subject: [PATCH] Trailing and extra spaces --- ...10-07-07-add-taxonomy-term-multiple-nodes-using-sql.md | 8 ++++---- source/_posts/2010-08-11-better-photo-gallery-1.md | 2 +- source/_posts/2010-10-22-better-photo-gallery-21.md | 2 +- source/_posts/2010-11-04-regular-expressions-search.md | 2 +- source/_posts/2014-05-06-thanks.md | 2 +- source/index.md | 2 +- 6 files changed, 9 insertions(+), 9 deletions(-) diff --git a/source/_posts/2010-07-07-add-taxonomy-term-multiple-nodes-using-sql.md b/source/_posts/2010-07-07-add-taxonomy-term-multiple-nodes-using-sql.md index 8e04b9bb..bfeda95c 100644 --- a/source/_posts/2010-07-07-add-taxonomy-term-multiple-nodes-using-sql.md +++ b/source/_posts/2010-07-07-add-taxonomy-term-multiple-nodes-using-sql.md @@ -14,9 +14,9 @@ tags: In preparation for my Blog posts being added to [Drupal Planet](http://drupal.org/planet), I needed to create a new Taxonomy term (or, in this case, tag) called 'Drupal Planet', and assign it to new content to imported into their aggregator. After taking a quick look though my previous posts, I decided that 14 of my previous posts were relevant, and thought that it would be useful to also assign these the 'Drupal Planet' tag. -I didn't want to manually open each post and add the new tag, so I decided to make the changes myself directly into the database using SQL, and as a follow-up to a previous post - [Quickly Change the Content Type of Multiple Nodes using SQL](/blog/change-content-type-multiple-nodes-using-sql). +I didn't want to manually open each post and add the new tag, so I decided to make the changes myself directly into the database using SQL, and as a follow-up to a previous post - [Quickly Change the Content Type of Multiple Nodes using SQL](/blog/change-content-type-multiple-nodes-using-sql/). -**Again, before changing any values within the database, ensure that you have an up-to-date backup which you can restore if you encounter a problem!** +**Again, before changing any values within the database, ensure that you have an up-to-date backup which you can restore if you encounter a problem!** The first thing I did was create the 'Drupal Planet' term in my Tags vocabulary. I decided to do this via the administration area of my site, and not via the database. Then, using [Sequel Pro](http://www.sequelpro.com), I ran the following SQL query to give me a list of Blog posts on my site - showing just their titles and nid values. @@ -27,13 +27,13 @@ SELECT title, nid FROM node WHERE TYPE = 'blog' ORDER BY title ASC; I made a note of the nid's of the returned nodes, and kept them for later. I then ran a similar query against the term_data table. This returned a list of Taxonomy terms - showing the term's name, and it's unique tid value. ~~~sql -SELECT NAME, tid FROM term_data ORDER BY NAME ASC; +SELECT NAME, tid FROM term_data ORDER BY NAME ASC; ~~~ The term that I was interested in, Drupal Planet, had the tid of 84. To confirm that no nodes were already assigned a taxonomy term with this tid, I ran another query against the database. I'm using aliases within this query to link the node, term_node and term_data tables. For more information on SQL aliases, take a look at . ~~~sql -SELECT * FROM node n, term_data td, term_node tn WHERE td.tid = 84 AND n.nid = tn.nid AND tn.tid = td.tid; +SELECT * FROM node n, term_data td, term_node tn WHERE td.tid = 84 AND n.nid = tn.nid AND tn.tid = td.tid; ~~~ As expected, it returned no rows. diff --git a/source/_posts/2010-08-11-better-photo-gallery-1.md b/source/_posts/2010-08-11-better-photo-gallery-1.md index c1284d6e..23b8cc16 100644 --- a/source/_posts/2010-08-11-better-photo-gallery-1.md +++ b/source/_posts/2010-08-11-better-photo-gallery-1.md @@ -17,7 +17,7 @@ Recently, I converted a client's static HTML website, along with their Coppermin Over the next few posts, I'll be replicating the process that I used during the conversion, and how I added some additional features to my Drupal gallery. -To begin with, I created my photo gallery as described by [Jeff Eaton](http://www.lullabot.com/about/team/jeff-eaton) in [this screencast](http://www.lullabot.com/articles/photo-galleries-views-attach), downloaded all my client's previous photos via FTP, and quickly added them into the new gallery using the [Imagefield Import](http://drupal.org/project/imagefield_import) module (which I mentioned [previously](/blog/quickly-import-multiples-images-using-imagefieldimport-module)). +To begin with, I created my photo gallery as described by [Jeff Eaton](http://www.lullabot.com/about/team/jeff-eaton) in [this screencast](http://www.lullabot.com/articles/photo-galleries-views-attach), downloaded all my client's previous photos via FTP, and quickly added them into the new gallery using the [Imagefield Import](http://drupal.org/project/imagefield_import) module (which I mentioned [previously](/blog/quickly-import-multiples-images-using-imagefieldimport-module/)). When I compare this to the previous gallery, I can see several differences which I'd like to include. The first of which is the number of photos in each gallery, and the date that the most recent photo was added. diff --git a/source/_posts/2010-10-22-better-photo-gallery-21.md b/source/_posts/2010-10-22-better-photo-gallery-21.md index dc04261c..26f103bf 100644 --- a/source/_posts/2010-10-22-better-photo-gallery-21.md +++ b/source/_posts/2010-10-22-better-photo-gallery-21.md @@ -5,7 +5,7 @@ slug: create-better-photo-gallery-drupal-part-21 tags: - drupal --- -Today, I realised that I hadn't published the code that I used to create the total figures of galleries and photos at the top of the gallery (I said at the end of [Part 2](/blog/create-better-photo-gallery-drupal-part-2 "Create a Better Photo Gallery in Drupal - Part 2") that I'd include it in [Part 3](/blog/create-better-photo-gallery-drupal-part-3 "Create a Better Photo Gallery in Drupal - Part 3"), but I forgot). So, here it is: +Today, I realised that I hadn't published the code that I used to create the total figures of galleries and photos at the top of the gallery (I said at the end of [Part 2](/blog/create-better-photo-gallery-drupal-part-2/ "Create a Better Photo Gallery in Drupal - Part 2") that I'd include it in [Part 3](/blog/create-better-photo-gallery-drupal-part-3/ "Create a Better Photo Gallery in Drupal - Part 3"), but I forgot). So, here it is: ~~~php Twitter and LinkedIn, and you can view his code on Drupal.org and GitHub.