Entries with “javascript” tag

Fixing the scrollTop bug

by Simon Pieters in Articles

Which element scrolls the viewport when using scrollTop? This article explains what “the scrollTop bug” is and what we need to do to get it fixed. Your help is needed!

An Introduction to IndexedDB

by Tiffany Brown in Articles

IndexedDB offers a powerful way to store and retrieve data in the browser. As with server-side databases, IndexedDB allows us to generate keys, search data, or sort it by a particular field. In this article, we’ll dig into the IndexedDB API by building a to-do list manager. But first, let’s look at some of the concepts around databases and IndexedDB.

Media Capture in Mobile Browsers

by Francesco Iovine in Articles

Media Capture is one of the most interesting features in web applications, especially for mobile devices. Surprisingly capturing media on the spot is quite a new thing for browsers in general, until recently always being delegated to browser plugins such as Flash or Silverlight. In this article we will explore how to use the Media Capture APIs, their compatibility across mobile browsers and the current state of the W3C specifications that define them.

Opera Coast: Developer Resources

by Samuel Irons in Articles

Opera Coast takes advantage of mobile browsing by supporting and encouraging development for touch-based web design. There are many resources available online for developers to optimize their sites to this end.

Network Service Discovery API Support in Opera

by Daniel Davis, Rich Tibbett in Articles

The Network Service Discovery API enables web pages to communicate with devices advertising themselves on the network via different discovery protocols in a peer-to-peer configuration. Now you can use JavaScript to find a UPnP server locally, browse its content and send that content to a UPnP client. This article, with links to experimental builds, shows you how.

Opera Mini and JavaScript

by Tiffany Brown in Articles

Opera Mini is one of the world’s foremost mobile browsers, which runs on pretty much any device, even low-powered ones. It is a proxy-based browser, which has many advantages, including reducing the size of pages downloaded onto the user’s phone by up to 90%. On the downside, JavaScript can behave in unexpected ways when requested by Opera Mini. In this article we’ll discuss exactly what this means for your development work, in detail.

HTML5 Drag and Drop

by Mike Taylor in Articles

HTML5 includes the Drag and Drop API, which gives us the ability to natively drag, drop, and transfer data to HTML elements. Up until now, JavaScript libraries have commonly been used to achieve something similar. What libraries such as jQuery UI or Dojo can’t do, however, is interact with other windows, frames, and applications (to and from the file system) or access a rich drag data store.

An Introduction to HTML5 Web Messaging

by Tiffany Brown in Articles

HTML5 web messaging provides a way for documents to share data without exposing the DOM to malicious cross-origin scripting. This article provides an introductory guide to using this new functionality, and some simple examples to get you started.

An Introduction to WebGL — Part 2: Porting 3D Graphics

by Luz Caballero in Articles

This article explores importing existing 3D models into WebGL — a much easier way to go than creating them from scratch in WebGL! The steps include exporting models from 3D packages (including Blender, SketchUp and Shade) into .obj format, converting them from there into JSON, then rendering them from there using the Three.js WebGL library.

Introducing ECMAScript 5.1

by Mike Taylor in Articles

The newest version of ECMAScript to get widespread browser support, ES5, brings with it many useful changes from ES3 and new additions to the language. In this introductory article we’ll review these, showing what is available.

An Introduction to WebGL — Part 1

by Luz Caballero in Articles

This is the first in our series of articles about WebGL. The objective of this series is to provide the information and resources you’ll need to get started learning WebGL. In this piece, we will discuss how WebGL works, what you need to create WebGL applications, and what a simple example looks like.

A More Accessible HTML5 <video> Player

by Ionuț Colceriu in Articles

Cristian returns this week with another detailed look at custom HTML5 <video> players! Following on from his last article, he shows us how to make a much more accessible, while still visually appealing, video player including WAI-ARIA support, captions, transcripts, and more.

JavaScript Best Practices

by Christian Heilmann in Articles

Writing a best practice article is quite a tricky business. To a number of you, what you are about to read will appear to be very obvious and just the sensible thing to do. However, looking around the web and getting code handed over to me from other developers for years has taught me that common sense is actually quite a rarity in live code on the web.

Programming — the Real Basics!

by Christian Heilmann in Articles

As an experienced developer you’ll sooner or later have to face people that are just not technical and will consider whatever you do as black magic. This article explains in simple terms what programming is about and hopefully will help both parties involved to steer these non-conversations into more productive waters.

All Together Now: Video, 3D, File Access

by Charles McCathieNevile in Blog

It’s here, the newest singing, dancing labs build (so far…). This time we basically have the latest desktop build plus video, 3D canvas, and File I/O. And this time we have Windows, Linux and Mac builds — so all you Mac fans, you can now have an Opera of your own in Ogg Theora.

JSON Configuration for JavaScript

by Gareth Rushgrove in Articles

If you’re working in a web development team with developers alongside designers, and you want to give the designers an easy way to change the variable parts of the application without the risk of breaking things, an external configuration file is a great idea, and JSON (JavaScript Object Notation) is a perfect format in which to store this data. In this article, Gareth Rushgrove shows you how.

A Call for Video on the Web — Opera <video> Release on Labs

by DevRel Team in Articles

To really make a splash on the Web, video needs an open solution that can easily be integrated into web pages without the need for proprietary plugins. The HTML5 <video> element and Ogg Theora can provide this, and Opera is proud to announce an experimental build that supports it. So read this article, and download and play with it today.

Using Capability Detection

by Hallvord R. M. Steen in Articles

Browser name sniffing, using scripts figure out which browser is used and then provide different content to them, is a widespread practice with a long history. Unfortunately these scripts are usually static, while browsers keep evolving. Simply put: sniffing browser names can seriously damage the future health of your script.

Efficient JavaScript

by Mark Wilton-Jones in Articles

Traditionally, a Web page would not contain much scripting, or at least, not much that would affect the performance of that Web page. However, as Web pages become more like applications, the performance of scripts is having a bigger effect. With more and more applications being developed using Web technologies, improving the performance of scripts is becoming increasingly important.