Friday , 17 November 2017
Home / Tag Archives: all (page 3)

Tag Archives: all

Path API – Advanced JavaScript Tutorial

Path API

The path API allows you draw custom shapes with paths.  You can create some really complex shapes and drawings with this API as it comes with powerful methods. Lines Clear your script and add this bit of code. [crayon-5a0f4d2ec5bb2310554804/] So, we first set up the stroke color and set it’s with to 2 pixels. Now, we can start drawing some …

Read More »

Canvas – Advanced JavaScript Tutorial

Canvas

Since the introduction of HTML5, the <canvas> tag has grown a great amount of popularity. The <canvas> element allows you to draw graphics onto the document with JavaScript. To get started, let’s update our document to this. [crayon-5a0f4d2ec70fb165559676/] The very first thing we must do is create <canvas> tags. This is where all our graphics will be placed. You MUST …

Read More »

Text Fields – Advanced JavaScript Tutorial

Text Fields

In this tutorial, we’ll focus on text fields in our forms. There a couple of events, properties and methods to make working with forms easier. Selecting Text Let’s update our document to this. [crayon-5a0f4d2ec79bc674185554/] Alright, let’s clear out our script and add this bit of code. [crayon-5a0f4d2ec79c8256875791/] In our third line, we use a method called select(). This method will …

Read More »

Form Events – Advanced JavaScript Tutorial

Form Events

If you’ve seen my JavaScript tutorial series, then you already know how to work with forms. In this tutorial, we’ll talk a little more about form events  and how to manipulate them with JavaScript. Setting Up The Document Let’s update the body tags to this. [crayon-5a0f4d2ec7fea491212106/] We just have a basic form with some input fields. You should remember that …

Read More »

Event Management – Advanced JavaScript Tutorial

Event Management

This tutorial is based around event management. Just like anything else, creating events takes up memory. Creating multiple events can really slow the performance of your website. Let’s take a look at a couple of ways to still have all the events you want while still keeping your site running in tip top shape! Let’s update the body tags in …

Read More »

Device Events – Advanced JavaScript Tutorial

Device Events

Smartphones and tablets are devices that are frequently used to browse websites. JavaScript now has a couple of events for hand held devices.  For this tutorial, you’ll need to have a mobile phone. I’ll be using the Iphone for this tutorial. Feel free to skip this tutorial if you don’t have a device handy. Orientation The orientationchange event fires when …

Read More »

Keyboard Events – Advanced JavaScript Tutorial

Keyboard Events

It’s time to take a look at keyboard events. Another popular feature of JavaScript is the capability to detect which keys were pressed and how they were pressed. Let’s first update our document to this. [crayon-5a0f4d2ec926b782853085/] Sweet! Now, let’s clear up the script and add this bit of code. [crayon-5a0f4d2ec9280045640922/] The first kind of event is the keydown event. This …

Read More »

Mouse Events – Advanced JavaScript Tutorial

Mouse Events

Keep track of how the mouse interacts with the web page. It is the primary device for navigation after all. Whenever mouse events occur, you’re passed in a lot of information as to where the mouse is located or what is also happening with the mouse. Let’s take a look at how this works. Coordinates We’re going to keep our …

Read More »

UI Events – Advanced JavaScript Tutorial

UI Events

UI events are events that aren’t specific to the document, but the window object. These events fire when something happens to the browser or window. Loading Events Loading events fire when the window has loaded all scripts, images, files and styles. There are also unloading events for when the user leaves the page. Update your document to this. [crayon-5a0f4d2ec9fd4327474536/] Let’s …

Read More »

Event Object – Advanced JavaScript Tutorial

Event Object

The event object is passed into your function whenever an event occurs. This object contains information about the event and even allows you to change how the event phases flow. We’ll be working with our previous example. Update your script to this. [crayon-5a0f4d2eca6a4723082809/] Our functions have been updated so that we can reference the event object. The event parameter will …

Read More »
ULTIMATE WORDPRESS DEVELOPMENT COURSE
Want to learn how to create your own custom WordPress plugins and themes? Check out my course!
Get 93% off my course. You'll also learn how to integrate WooCommerce and BuddyPress into your projects. This is a limited time offer
Yes, I would like to get 93% off your course!
No Thanks!
close-link