Penultimate class tonight was illuminating – and it wasn’t the result of the caffeine overload during the day. Thanks to Lucy, Hezzie and Cristen for some really useful, ‘lightbulb moment’ tips that will assist me getting this project to bed.
So, first Lucy is going to send me her Javascript email validation code, and I thought I should post the link to the code I used for the booking form on my site – here it is, hopefully a few people might find it useful.
It’s straightforward code to apply and does validate the email address on the server-side, but it’s a bit slow, and the ‘email failure’ message comes up in a separate, boring old white screen, just as the ‘congrats your email worked’ message does. I think I could tolerate the boring old white screen if the email worked, but not if the email didn’t work, so I’ll give the client-side validation with Javascript a go.
Having said that of course, with only one week to go I’ll may have to set it aside and work on client-side email checking post-assignment due-date. And in any case I’ve got some familiarity with Javascript through the alert boxes I’ve created for the ‘Links’ in the Resources page and with the Longtail JW FLV player for the video, so it’s not the worst outcome overall.
Also, my CSS validation problems may be solved. I had completely forgotten Viveka mentioning in an earlier class that there is a bit of a hack around to get CSS3 properties to validate – remember my curvy borders on menu items? Thanks again gals! It’s apparently some code you insert in the header of the html, but preliminary investigations have yielded nothing. Zip.
I’ll do some more looking around and see if I can find this in my notes and try and get this working. If anyone else can remember the code – and where it needs to be placed – please let me know!
However as I mentioned in my last post (deep breath), I can live with CSS2 properties and the menu looking a bit boxy for the purposes of the assignment. C’est la vie.
(Just as an aside, is anyone finding it hilarious how obsessive this process can get? To think that I have a bit of an unnatural attachment to curvy corners?! Who would have thought, eh?)
Another thing I thought I should mention, as I did in my presentation this evening, YouTube tutorials really got me out of a hole last week – I mentioned this only briefly in an earlier post, but here is the tutorial that saved my life on the JW player problems I was having. The words from Pete from work are also echoing in my ears – “the machine is dumb, you have to tell it where to look”. Those words and the video tutorials got that particular issue sorted. It was a different in file names between the supplied files for the player, and the file name automatically included in the player’s wizard. It was one of those blink and you’ll miss it things.
My plans to get this project happening in the real world are going to mean many more hours in front of my computer, but I think it will be worth the trouble. I’m going to learn Joomla, the fabbo open-source CMS that I’ve used a little for work, but I want to get to know it better. If anyone’s interested, here’s a great page in the Joomla documentation that is the how-to bible for web troglodytes like myself. And I’ll also be getting to know the Mac platform – I’m going to get to know TextMate and Filezilla and hopefully Photoshop. Lucky it’s winter…
And the last, crucial thing? Getting the content, early. I now have a really solid understanding of the frustration developers have without the finalised content to include in designs. The content will often determine the overall look of the site and it’s really important to have that in place, particularly with images. Loading up dummy content adds anywhere from 30-50% more time onto a project I reckon, which you as a developer don’t want the hassle with and certainly clients don’t want to wear the extra cost involved.
June 1, 2010 at 11:57 pm
Hi Claire,
So there are a couple of things i was going to send you, let me just flick through my trusty red notebook…
1. Form validation
As with all of these things I’m sure there are a million different ways to do it and so I hope I don’t confuse things unneccessarily, but this is my set-up:
There are a couple of components to the validation I’m using –
1.in my section, i’ve got a link to the jquery library:
And to a specific validation plugin:
I downloaded the validation plugin from here: http://bassistance.de/jquery-plugins/jquery-plugin-validation/ and saved it to my server (i have kept all of my javascript/jquery files in a ‘script’ folder, but you don’t have to do that).
Then you need to add ” class=”required” ” or ” class=”required email” ” to each of the text input areas.
Finally “call” the validation script with this code:
$(document).ready(function(){ $("#contactform").validate(); });Note that “#contactform” is your form ID.
I don’t know if I’ve totally confused you by now, but I followed (with some amended steps) this tutorial: http://www.raymondselda.com/php-contact-form-with-jquery-validation/
2. I was also going to get back to you about CSS3 – good news. There is a CSS3 profile you can select from the W3C CSS Validator service (http://jigsaw.w3.org/css-validator/#validate_by_uri). Just choose “More options” and then select “CSS 3″ from the drop-down menu. I checked with Oanh and she said that it is totally fine to use this. Otherwise, if you don’t use this profile, she said to document CSS3 as the reason for non-validation.
I think that’s all. If there’s anything else you want just get my on the blog. I’ll let you know if I have any success with getting a nice message from my contact form.
June 2, 2010 at 3:19 pm
Thanks heaps Lucy – definitely will give all this a go. I owe you a drink, if not a three-course dinner!