html5

Where is the html5 local database located on a client machine?

Am playing around with html5 local storage on different browsers (Firefox, Opera, Safari & Chrome) and am just wondering where is the location for the local database that i create using "opendatabase". Can i change the location of this database? Gath ...

what html5 features are already safe to use in a cross browser way?

I'm already using the HTML5 Doctype in all my pages. Are there any other html5 specifications/features I can start using right now? The conditions are: Cross browser - support for IE6 is optional but please specify No hacks please [javascript or otherwise] its completely acceptable if the feature degrades gracefully in older browsers ...

Column layout in HTML(5)/CSS

Is there a way in HTML5/CSS to have the columns layed out as shown below, and still have the text flow correctly? ###### ###### # C1 # # C2 # # # # # ###### ###### ###### ###### # C3 # # C4 # # # # # ###### ###### ###### ###### # C5 # # C6 # # # # # ###### ###### Just to clarify - I want to be able to w...

HTML5 offline cache google font api

I'm trying to create an offline HTML5 test application, and am playing with the new google fonts api at the same time. Does anyone have any ideas how to cache the remote fonts? Simply putting the api call in the cache manifest doesn't work, I assume this is because the api actually loads other files (ttf, eot, etc). Any ideas if using t...

How to I preload images where it actually forces the images to load before continuing (html/javascript)?

I want to preload images but ensure they are loaded before continuing. How can I do this? The following does not work as it sends off the load request only, but doesn't wait till the image is loaded. So it is possible that the image isn't loaded when requested soon after. jQuery.preloadImages = function () { for (var i = 0; i <...

What would be the most likely impact of HTML5 on platforms such as Java, PHP, and ASP.NET?

I understand you still need to drive a lot of server-client communications, saving data in central repositories etc etc. But what is the primal impact of HTML5 on these platforms when building web applications? Major changes that developers should be vary about? ...

The Canvas .fillText method doesn't seem to work on the iPad.

It does show text, but in the completely wrong place (not even on the Canvas element itself!), and in the wrong color (always black). Has anyone had experience with this or gotten it working? ...

Save HTML 5 canvas to a file in Chrome?

Save PNG (etc.) work in this demo in Firefox, but not Chrome. Convert to PNG (etc.) work in Firefox and Chrome. Is there a way *in Chrome* to save an image of a canvas element to a local file -- or to a server? ...

Google Chrome extension: Use Javascript inside webkit notifications?

I have been following the Google Chrome Extensions Developer's guide and have been able so far to create an extension with a browser action without popup that would trigger a webkit notification in HTML format. Fact is that this HTML file contains action buttons, links and javascript, but none of them seems to respond. Is this a by-des...

Simulating click with javascript on document

Is it possible to simulate a click on a webpage using javascript but without defining a specific element, but rather just specifying the document? I would have liked to do something like this, and if the location happens to have a link, then this will be pressed: function simulateClick(x, y) { var evt = window.createEvent("MouseEv...

HTML 5: how to make stackable images?

Is it possible to load up 10 images (same dimension), stack them on top of one another only showing 1 image at a time and then by holding down the left mouse button and dragging the mouse up you scroll in one direction and moving the mouse down scrolls in the opposite direction?' if so how can this be done? canvas element would be the b...

How to avoid HTML Canvas auto-stretching

I have the following piece of HTML: <style type="text/css"> #c{width:200px;height:500px} </style> <canvas id="c"></canvas> <script type="text/javascript"> var i = new Image(); i.onload = function () { var ctx = document.getElementById('c').getContext('2d'); ctx.drawImage(i, 0, 0); } i.width = i.height...

Implementing zoom on a fixed point, javascript/canvas

I want to implement zooming on the mouse pointer with the mouse wheel. That is scaling the image while the point under the mouse pointer stays fixed. Here is my code, which doesn't work very well var scala = 1 + event.wheelDelta / 1000; canvas.context.translate(-canvas.mouse.x * ( scala - 1 ) / canvas.scale,-canvas.mouse.y * ( scala - ...

Problem making local copy of a webpage

I want to run this chrome experiment locally. I copied the .html and .js files, along with the two .jpgs that the demo uses. However, when I run it off my local drive, Chrome gives this error: light.js:89 - Uncaught Error: SECURITY_ERR: DOM Exception 18 Line 89 returns the image data from the canvas after drawing the image to it. What...

Fake "user initiated" <audio> tag on iPad

I know that Apple's docs say that an mp3 within an <audio> tag on iPhone OS can't be played without user intervention (they cite bandwidth concerns, totally reasonable). However, has anyone succeeded in faking a user action to play the audio? Perhaps faking events to off screen native audio controls with JavaScript? I'm using jPlayer rig...

SimpleModal bug when positioning HTML5 video

I am trying to use simple modal to display a modal window containing a video. I'm using the HTML5 "video" tag to do this. Using JQuery and SimpleModal, I can get it working in Chrome and Firefox, but for some reason Safari fails to maintain the centered positioning of the modal dialog for the video. In other words, when you scroll up an...

SimpleModal bug when positioning HTML5 video

I am trying to use simple modal to display a modal window containing a video. I'm using the HTML5 "video" tag to do this. Using JQuery and SimpleModal, I can get it working in Chrome and Firefox, but for some reason Safari fails to maintain the centered positioning of the modal dialog for the video. In other words, when you scroll up an...

What is the semantically correct way to use the `<article>` tag in HTML 5, with `<ol>, <ul>, and <li>`?

I currently have an ordered list that I want to markup using the new HTML 5 attributes. It looks like this: <ol class="section"> <li class="article"> <h2>Article A</h2> <p>Some text</p> </li> <li class="article"> <h2>Article B</h2> <p>Some text</p> </li> <li class="article"> <h2>Article C</h2> <p>Some ...

Using HTML5/Javascript to generate and save a file

I've been fiddling with WebGL lately, and have gotten a Collada reader working. Problem is it's pretty slow (Collada is a very verbose format), so I'm going to start converting files to a easier to use format (probably JSON). Thing is, I already have the code to parse the file in Javascript, so I may as well use it as my exporter too! Th...

HTML5 -- server side

How much does it matter what server side language is used for building a web app to take advantage of HTML 5? It seems to me that the ruby community will probably have the fastest uptake, and as a result the most support. Does that seem right? If I want to make a serious investment in HTML5, what server side language should I use? ...