I’ve left it a little late in the day to start this week’s update and I’m struggling through a horrid cold so I’m going to aim to be a little more concise than usual. I had a few meetings this week, the first with Jean Anderson on Tuesday. The main focus of the meeting was how I can engage more with postgraduate research students, which is something listed in my job description that I haven’t really done much about yet. Jean was able to give me some very useful pointers that I will follow up on in due course. I also met with Flora this week, and we spent an hour or so going through some of the code she has been having difficulty migrating to the new Historical Thesaurus server. We managed to make some good progress and I think it was really useful for Flora to be able to bounce some ideas off another techie person. I also attended Jane Stuart Smith’s meeting to discuss the SCS web pages in relation to the REF. This was quite a lengthy meeting but it was very useful to be a part of it and some important decisions with regards to the website were made. I also spent a bit of time before the meeting going through the web pages and creating a document containing some recommendations.
I spent a fair bit of time this week on Burns related matters. What with today being Burn’s Night the projects were wanting some updates made to the websites in the run-up to the big day (or night, I suppose). The changes to the ‘Song & music’ pages that I had implemented locally on my PC before Christmas needed to be rolled out to the public website, which meant updating some of the underlying code on the server. I’d previously made notes about the changes I’d implemented on my local PC but somehow I had managed to lose them, which made the process slightly trickier. However, I got there in the end and now there are individual songs for each page and songs can be played directly from the browser rather than having to be downloaded. I also advised on creating a feedback form for the Burns conference (and subsequent events), exploring a few options such as SurveyMonkey before deciding to go with the University’s own web form processor, which proved effective enough for the needs of the team. Also this week I spent a few hours creating the site structure for the ICOS2014 conference. Now that the structure is in place it will be possible for the organisers to manage the addition of content to the structure themselves.
Finally this week I contacted Marc and Alison regarding a couple of possible bids that we had previously discussed and we will hopefully be able to start writing these bids soon.
I spent the bulk of this week continuing with the development of ARIES and I’m please to say I have now completed a first draft of both the App and the Web versions, which can currently be accessed at these (temporary) URLs:
I did a fair bit of testing of the app this week too, tweaking functionality here and there and also improving the design and layout in certain areas. For example, previously all links had no ‘hover’ or ‘active’ states which meant users didn’t really have any feedback that their link tapping had been noted by the app (until after a few seconds’ delay the required page loaded). Now that I’ve added an ‘active’ state the links highlight as soon as they’re tapped and stay highlighted until the next page loads, which is much better. I also improved the automatic page scrolling used in the exercises. When the user taps a ‘check results’ button the page now nicely scrolls to the ‘results’ section of the page, and in the ‘Further Punctuation’ exercise when the user taps the ‘next stage’ button the page scrolls to the instructions for that stage.
After completing the app I moved onto the web version, which is a University of Glasgow branded ‘T4-esque’ (but not actually T4) website. As with the ‘Readings’ website, one single template file is used to provide the wrapper round the pages and the contents of each page is held in a ‘fragment’ script that is pulled in whenever the relevant page ID is passed. The actual content of the pages is about 99% identical to the App version, although some changes have been made to make the pages work better on a computer, using a mouse. I’ve updated the CSS slightly so that page elements fit in better with T4, and I’ve used Jquery tabs rather than my own tabs in the ‘Basic Punctuation’ section as this is approach looks and behaves a lot better within the T4 design.
I’ve now tested the versions using Firefox, Chrome and IE in Windows and all appears to be working fine. I did run into a bit of a problem with (can you guess?) IE to start with, due to IE8 on XP and earlier changing all tags from lower to upper case behind the scenes. Some of my exercise processing logic was based around the content of buttons, and I was foolishly pulling in and comparing the full HTML contents of the buttons – e.g. <em>.</em>. As IE8 was converting such tags to <EM>.</EM> the wrong results were appearing. Since noticing that I’ve updated the scripts so that the plain text of the buttons is analysed instead, which is a much better approach.
Now that I’ve completed ARIES I will move onto one of the three remaining ‘priority’ applications that need redevelopment – ‘English Grammar’, ‘Essentials of Old English’ and ‘Basics of English Metre’.
For the rest of the week I tackled a few more outstanding items on my ‘to do’ list. I had an email based chat with Flora regarding her problems migrating the Thesaurus code to the new server. I gave her a few pointers which I hope will be useful and we might meet up next Thursday for me to have a look at things. I also looked again at the idea for a tablet version of Bess of Hardwick and emailed Alison to see if there was anything I could do with regards to putting a bid together. I also contacted Jean to see whether she would like to have a meeting again soon.
I also spent some time towards the end of the week attempting to fix a problem with the Scottish Corpus website that Wendy had emailed me about. There were some occasions when the text of a document wasn’t being displayed on the page, even though it should have been. The plain text version was working, and I discovered that the HTML version was also working so long as the user hadn’t come directly from a search. The reason was that there was a problem with the search phrase highlighting part of the document script. The script uses regular expressions to find terms to highlight while ignoring things such as punctuation and line breaks. Unfortunately the function used in the script (preg_replace_callback) breaks when it encounters high-numbered UTF-8 characters and in such cases returns nothing, failing silently.
I spent some time trying to find an alternative to preg_replace_callback, or a way to make this function work with the UTF-8 characters but I’ve not had any success as of yet so for the time being I have updated the script so that if an empty string is returned from the function then the page reverts to displaying the non-highlighted version of the text. It’s not ideal as the highlighting is a really nice feature, but it does mean that highlighting continues to work in all the places it previously worked and any documents that were previously breaking now at least show their text. I will keep a record of this issue and will try to find an alternative in future. There is some talk of PHP’s UTF-8 handling being greatly improved in the next major release so that could help things.
I’m pleased to announce that the Christmas chocolate mountain has now been completely flattened, although achieving this Herculean feat did involve eating an entire Chocolate Orange whilst I was working from home on Wednesday, which wasn’t very sensible, or indeed enjoyable for the last few segments at least.
Back to work after a thoroughly enjoyable two weeks off for Christmas, and still the Christmas chocolate mountain has yet to be completely devoured. It is at least getting smaller, as my waistline gets bigger.
I spent the start of this week getting back into the swing of things after the holidays, completing such tasks as getting through the email backlog and planning what to focus on in the New Year. After that was sorted the bulk of the rest of the week was spent continuing with the development of the ARIES app, which I had begun in the run-up to Christmas.
As I mentioned in my previous post, I had implemented a nice little drag and drop feature for placing words in sentences, which I managed to put to good use in the ‘Apparent Problems’ page of the ‘Apostrophe’ section. I was really happy with how this was working, but then over Christmas I managed to get my hands on an Android based tablet running the Chrome browser. In this browser my drag and drop failed to work properly: Drag an element down and the whole page starts scrolling up, making it impossible to complete the exercise. The annoying thing is that in Chrome (made by Google) the drag and drop is broken whereas using Android’s built-in browser (also made by Google) on the same device the drag and drop works! This was most frustrating and it was back to the drawing board for this section yet again.
I don’t have regular access to all the major smartphone and tablet operating systems which makes testing things rather tricky. I probably could have found a way to fix the Chrome drag and drop issue but lack access to the hardware to do so. It was primarily for this reason that I decided to abandon drag and drop entirely and revert to a more old fashioned approach for adding text to a box: simply tap the text to make it appear in the box rather than dragging and dropping. It’s less satisfying to use, but works equally as well (and is probably quicker). You can try out the new version here: http://www.arts.gla.ac.uk/STELLA/briantest/aries/the-apostrophe-3-apparent-problems.html and if you’re interested in trying out the ‘broken’ draggable version you can see it here: http://www.arts.gla.ac.uk/STELLA/briantest/aries/the-apostrophe-3-apparent-problems-draggable.html.
By the end of the week I had added all the content to the ARIES site, although I’m still in the middle of developing the biggest and most complex exercise (see below). All the exercises (apart from the big one) are now complete, although I’m not altogether happy with one or two of them. For example the exercise on this page: http://www.arts.gla.ac.uk/STELLA/briantest/aries/spelling-2-confusing-pairs.html would really have benefitted from the drag and drop functionality. Instead you have to first select the word you want to use, then click on the gap to place it. It works perfectly well, but it’s slightly clunky.
The big exercise that I’m still working on is the ‘Test Yourself’ exercise in the ‘Further Punctuation’ section. In the original site a two paragraphs of text are presented without any punctuation and users have to update the text by editing it in a text box (see http://www.arts.gla.ac.uk:8180/aries/test_yourself.jsp). This approach isn’t suitable for mobile devices as it would be a real chore to tap on parts of existing text then find the right character to add in. Instead I decided to break up each exercise into three sections, using techniques I’d already developed for previous, shorter exercises.
In stage 1 the user adds in quotation marks by tapping once on a word to add quotes to the start, twice to add quotes to the end, three times to have quotes at the beginning and end, and a fourth time to remove quotes. Users can attempt this as many times as required until they get it right, or they can skip to the second stage.
In stage 2 the user must add in full stops, capital letters, commas, exclamation marks and question marks using the same method as I developed for the ‘Basic Punctuation’ section. Users can tap on a word to make the initial letter upper or lower case and by tapping on the dotted square following a word the user can cycle through the punctuation options. As with the first stage, users can try this section as many times as they wish or can skip to the final stage. Note that the correct placement of quotation marks is displayed in the text in Stage 2 whether the user got them all correct in Stage 1 or not.
In the final stage the user must add apostrophes where applicable, again using functionality I developed in an earlier section. The text is presented at double size as in this stage users need to tap on individual letters rather than words. Tapping on a letter adds (or removes) an apostrophe after the letter. The correct placement of punctuation and capital letters is used in Stage 3 no matter what the user supplies in Stage 2.
I’ve just about finished the three stages for the first exercise and you can try it here: http://www.arts.gla.ac.uk/STELLA/briantest/aries/further-punctuation-6-test-yourself.html. I still need to do some final validation in Stage 3 and present the user with suitable feedback, and remove the ‘proceed to next stage’ button which isn’t needed. I then need to ensure the code works for the second exercise, which will take a little bit of time. After that the mobile version of ARIES will be completed and I will move on to the web version.
Also this week I gave some feedback to Carole Hough and Daria Izdebska regarding a website for the ICOS 2014 conference, which I hope was useful.
That was all for this week. Next week I will continue with ARIES and will implement the required changes to the Burns website, if the required content is provided next week.