HTML5 implements functions similar to scratch cards, html5 implements scratch cards
HTML5 implements functions similar to scratch cards
This feature allows us to omit 300 words when we use a public number to send images!
Note:
1. Set user Scaling: user-scalable = no | yes
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, minimum-scale=1, user-scalable=no" />
2. Drag prohibited:
Document. ontouchmove = function (e) {e. preventDefault () ;}; // The document disables the touchmove event.
3. Disable the pop-up menu:
document.documentElement.style.webkitTouchCallout = "none";
Specific implementation code:
<! DOCTYPE html>
Preview:
Image material:
You can use html5 or js functions or css to save images in a specific box as images.
Cannot be implemented.
Window. location. href = "image/octet-stream" is only used to open the acquired image data in a new window, And the browser automatically prompts you to download the image.
But where does the image data come from? Canvas in HTML5 supports pixel-level operations to obtain image data. However, a webpage is rendered with a lot of DOM and styles instead of an image, in JS, it cannot be converted into an image, unless the browser provides related APIs, but currently there is no similar API provided by the browser, so it cannot be implemented for the time being.
You can see that all the current ones are either browser-based or plug-ins must be installed.
Can html5 achieve flash-like effects?
Yes. Here is a website: openrise.com/lab/PlasmaTree/ (if it cannot be opened for a higher browser version). You can see that the effect is very good and similar to that of flash. This should be the power of html5, I am also a beginner.
Accept