Tech, Gaming and Food Enthusiast
Posts tagged AJAX
Ajax callback validation routines with CodeIgniter
Mar 21st
The CodeIgniter Form_Validation library is an extremely useful tool especially the ability to extend all core routines. Some validation requires real time PHP & MySQL processing, for example checking an email against those already registered with your site.
To use a PHP function to return values to the jQuery validate function, the only important theory to understand is that the function needs to echo, not return. Returning values will not send the output to the DOM and so the validation routines will not know what to do with it.
JavaScript – experience enhancer or dictator
Feb 18th
A few days back it nearly ruined both my life and my sanity!
When I first started working as a commercial web developer the first idea that really hit me was the use of JavaScript and AJAX. My first senior developer always ranted on at me about ‘graceful degredation’ and I plodded along, blissfully unaware of the implications of ‘enhancing’ a website using JS.
The main issue that I was missing was that a very very very small percentage of users actually do browse with JavaScript disabled. “WHY WOULD YOU DO THAT?”, I thought. I fought for a long time with the idea that someone would actually purposefully disable a feature which makes browsing 10 times easier.