How to get the keyboard key value with jQuery and run a custom action

This is probably the simplest way to capture the key that the user pressed and execute an action (in this case just a simple console.info). (function() { function customAction() { console.info(“You have pressed an ‘a’ in your keyboard”); } $(window).on(‘keypress’, function(event) { console.log(event.keyCode); // keyCode te da el código de la tecla que presiones if (event.keyCode…

How to get same results when sorting JavaScript arrays in all browsers

The problem: 1) Imagine you have following array in JSON var data = [ { “title”: “Fine Fillers Treatment and Clay De-Activation Agents”, “topic”: “PHP”, “date” : “2014-01-25T01:32:21.170Z”, “url”: “http://www.alex-arriaga.com/session-1-cakephp-framework-for-beginners-in-spanish/” }, { “title”: “How to configure session factory to connect to a DB2 datasource with Hibernate”, “topic”: “Java”, “date” : “2014-02-12T01:32:21.171Z”, “url”: “http://www.alex-arriaga.com/how-to-configure-session-factory-to-connect-to-a-db2-datasource-with-hibernate/” }, {…

Session 6: jQuery for the real world (in spanish)

Would you like to improve your skills in Ajax calls and communicate jQuery with other frameworks like CakePHP?, well if you answered yes, this post is definitely for you. This is the sixth and last video of the first part of an initiative  related with jQuery that I have named jQuery for the real world….

Session 4: jQuery for the real world (in spanish)

So, are you looking for a good course to become a ninja in jQuery programming? well, start this course and at the end of it, you will understand this awesome library and you will be able to create front-end applications from scratch! This is the fourth session of this course, in this video you will…

Session 3: jQuery for the real world (in spanish)

Hi friends! Here is the new session of our jQuery course, enjoy and share the video. This class includes: Creating events in the most optimized way How to use “chaining” Accessing Data attributes (HTML5) Tips about responsive web design with Bootstrap 3 Visit the repository on Github to get all the code: https://github.com/alex-arriaga/jquery-para-el-mundo-real