The WEBSITE & WEBLOG
belonging to Richard Sweeney

*

JavaScript: how to select the first word(s) in a sentence

Recently I had to figure out a way to select the first 2 words in a sentence using JavaScript. I wanted to wrap them in a class so that I could give them some additional CSS styling. I figured it’d be mad easy, but it took a little bit of head scratching until I figured out at least one way to do it.

I’ve got an HTML element with an ID of ‘niceText’ that I’m looking to grab. I’ll save the …

Read the full entry »

How to split your WordPress posts into two columns

The other day, whilst merrily making a website for an ensemble called Tesserae, I needed to figure out how to display my posts in 2 columns, side by side. In this case, the posts were a custom post type biographies that I used to display the various members biographies on the site.

It wasn’t hard to do, here’s the code I used to display half of the posts:

<?php // Get the number of posts in the custom post type ‘biographies’
$count = wp_count_posts( …

Read the full entry »

jQuery mobile events firing multiple times and what to do about it

I’m currently working on my very first iPhone app. I decided I’d build it in HTML5, CSS3, JavaScript and wrap it up all cosy and warm with the amazing PhoneGap. I also decided early on to use jQuery mobile as my framework for the project, because I’m so familiar with jQuery itself. It’s been quite a ride so far and I’ve learnt a LOT!

I soon found out that dynamic content and jQuery mobile is not the easiest of pairings, but I …

Read the full entry »

A suggested fix for the dreaded FOUT

As a keen typography fan I tend to rely heavily on the use of web fonts for my sites. I generally use Typekit to deliver my fonts, but it does tend to take a little while for the browser to download and display my beautiful fonts.

I noticed that if I simply place the typkit required script tags in the header of my site, it will block my site from loading until the font(s) have been downloaded, leaving visitors with a blank …

Read the full entry »

Easy PayPal Custom Fields Plugin

I’ve just my first WordPress plugin that uses custom fields to make creating a PayPal button super-easy.

I wanted to learn more about PHP and the inner workings of WordPress and I also needed a solution for my clients to add PayPal functionality to their sites without having to remember complicated shortcode syntax. Whilst shortcodes in WP are a fantastic feature and are easy to implement for the developer, I find they can often confuse my clients who often can’t even …

Read the full entry »

Obbligato bass instruments in 17th century Italian instrumental chamber music

Today, it’s practically a given that the continuo part in 17th century Italian instrumental chamber music will be doubled by a bowed bass (or other bass) instrument. Is there any evidence to support this practise?

In 17th century Italian music, the continuo instrument is often unspecified, but where it is specified (for example in the books of Castello) it is the organ, and where another instrument is suggested it is the harpsichord, or spinetta.

Whilst I don’t think it sounds bad to have …

Read the full entry »

Open historical music blog

I’m in the process of planning a website where people can freely share knowledge and musings on all aspects of historical performance. All would be welcome to contribute and all articles free to access for all.

Articles don’t have to be as strictly written as for say a masters, PHD etc and ‘musings’ or thoughts on whatever floats your boat – as long as it relates to historical performance – would be welcome. Articles would also be freely commented upon by …

Read the full entry »

An 18th century theorbo

Choosing the right continuo instrument for the job is something that I have spent a large amount of time thinking about and a revelation about a (relatively) new theorbo has prompted me to write down some of my thoughts and observations about this very subject.

The first lute I owned was a 13 course ‘baroque’ lute in d minor tuning. As it was the only instrument I had in the beginning, I learnt to play both solo repertoire and continuo on …

Read the full entry »

‘The best way of play’

Around 13 years ago after my end-of-year recital as a student studying classical guitar in Dublin I ceremoniously cut off the fingernails on my right hand. I had decided to become a lutenist! I preferred the music, there was more of it and the possibility of far more social music making made my choice an easy one.

Approximately 5 years ago, I decided let the nails on my right hand grow. Was I intending to take up the guitar once more …

Read the full entry »

Non-interpretation of baroque music

Something I’ve been thinking about for some time is the aspect of interpretation in baroque music. Todays big stars are conductors, directors, singers and musicians – all interpreters of baroque music. But how different this is to the 18th century! There were singers and musicians who were stars of course, but the famous directors of the 18th century also wrote and performed their own music. They didn’t have to ‘interpret’ it, they just played it!

With today’s famous directors and conductors …

Read the full entry »

WordPress 3.0 custom queries, post types and taxonomies

There’s been a few really great articles recently published about the new custom posts features in the WordPress 3 Beta, most notably Justin Tadlock’s excellent article and an equally enlightening post on wpengineer.com. I’ve had some fun experimenting a little with the new possibilities opened up to me with this new functionality but I very quickly came up with a problem that took quite a bit of head scratching to solve, namely how to filter my query to a custom …

Read the full entry »

website 3.0

I’m delighted to welcome you to the third version of richardsweeney.com!

The typography is based on a few 17th century books that are important sources for my work with historical performance and that have kept me good musical company over the years. John Dowland’s ‘varietie of lvte lessons’ (published 1610) was of particular interest to me, the typography is beautiful, not to mention the music!

I had been planning to start writing a blog for a while now and having worked a …

Read the full entry »

Callino Quartet Website redesign

I’ve just launched my redesign of the Callino Quartet’s website!

The original site was not in any way ugly, but it was a pain for the quartet to keep updated and looked a little dated. The code was butt-ugly and needed a complete overhaul. I used WordPress as a CMS (Content Management System) for the site and rewrote the code using standards compliant xHTML & CSS (with the exception of a few CSS3 additions) plus a little PHP and a dash …

Read the full entry »

Everything you’ve always wanted to know about the theorbo but were afraid to ask

As a theorbo player I get asked lots of questions about my instrument.

Questions like:

What is it?
Where does it come from?
How many strings does it have?
Do you play all of them?
How is it tuned?
Why is it so long?
How, exactly, do you play it?
Was it a usual member of a baroque orchestra?
Do you ever wish you played the flute?

I do try to answer all these questions as I get asked, but for those of you who didn’t get a chance to ask, …

Read the full entry »