Found 601 Articles for Front End Scripts

JavaScript File Drop with HTML5

Nancy Den
Updated on 29-Jan-2020 08:12:03

199 Views

Drag and Drop (DnD) is powerful User Interface concept that makes it easy to copy, reorder and deletion of items with the help of mouse clicks. This allows the user to click and hold the mouse button down over an element, drag it to another location, and release the mouse button to drop the element there.For drag and drop:                    #boxA, #boxB {float:left;padding:10px;margin:10px; -moz-user-select:none;}          #boxA { background-color: #6633FF; width:75px; height:75px; }          #boxB { background-color: #FF6699; width:150px; height:150px; }       ... Read More

Does HTML5 only replace the video aspects of Flash/Silverlight?

Lakshmi Srinivas
Updated on 29-Jan-2020 08:12:31

57 Views

Flash provides amazing GUI and many visual features for animations. It allows the user build everything inside a particular platform without a full integration into the browser wrapped inside the browser with the main scopes that are multimedia and other kinds of animation.The HTML5 element gives you an easy and powerful way to draw graphics using JavaScript. It can be used to draw graphs, make photo compositions or do simple (and not so simple) animations.Here is a simple element that has only two specific attributes width and height plus all the core HTML5 attributes like id, name, and ... Read More

How to keep the image at the back of the HTML5 canvas when moving elements with fabric.js?

karthikeya Boyini
Updated on 29-Jan-2020 08:11:26

266 Views

To keep the image at the back of the canvas, when move elements, you need to pass:preserveObjectStackingAnd the following would work and the image is not visible in the background:window.canvas = new fabric.Canvas('c', { preserveObjectStacking:true });Now, on moving the shape will appear over the image.

An empty box is displayed instead of the rupee symbol in HTML

Samual Sam
Updated on 29-Jan-2020 08:11:00

149 Views

The rupee symbol is the following and not every browser supports it:₹To make it visible on your web page: You can use the following as well:₹

How to adopt a flex div's width to content in HTML?

Lakshmi Srinivas
Updated on 29-Jan-2020 08:10:22

233 Views

Use display: inline-flex to adopt a flex div’s width to content:#box {    display: inline-flex;    flex-direction: row;    flex-wrap: wrap;    max-width: 200px;    padding: 10px;    margin: 20px;    background-color: blue; }

Update HTML5 canvas rectangle on hover

Daniol Thomas
Updated on 29-Jan-2020 08:09:58

462 Views

To update HTML5 canvas rectangle on hover, try to run the following code:var canvas = document.getElementById("myCanvas"); var context = canvas.getContext("2d"); context.rect(20,20,150,100); context.stroke(); $(canvas).hover(function(e){    context.fillStyle = blue;    context.fill(); });

Layers of canvas fabric.js

karthikeya Boyini
Updated on 16-Jun-2020 13:51:07

846 Views

FabricJS has the following API methods that change the z-index of objects:canvas.sendBackwards(myObject) canvas.sendToBack(myObject) canvas.bringForward(myObject) canvas.bringToFront(myObject)You can also use:fabric.Canvas.prototype.orderObjects = function(compare) {    this._objects.sort(compare);    this.renderAll(); }

Unicode Byte Order Mark (BOM) character in HTML5 document.

Samual Sam
Updated on 30-Jul-2019 22:30:22

554 Views

A byte order mark (BOM) consists of the character code U+FEFF at the beginning of a data stream, where it can be used as a signature defining the byte order and encoding form, primarily of unmarked plaintext files.Many Windows programs (including Windows Notepad) add the bytes 0xEF, 0xBB, 0xBF at the start of any document saved as UTF-8. This is the UTF-8 encoding of the Unicode byte order mark (BOM), and is commonly referred to as a UTF-8 BOM even though it is not relevant to byte order.For HTML5 document, you can use a Unicode Byte Order Mark (BOM) character ... Read More

How to create multi-column layout in HTML5 using tables?

Nishtha Thakur
Updated on 29-Jan-2020 08:09:25

762 Views

Design your webpage to put your web content on multiple pages. You can keep your content in the middle column, you can use left column to use menu, and right column can be used to put an advertisement or some other stuff.Example           Three Column HTML Layout                                                    Main Menu                HTML                PHP                PERL...                                        Technical and Managerial Tutorials                                        Right Menu                HTML                PHP                PERL...                                

Special Characters in HTML

Smita Kapse
Updated on 29-Jan-2020 07:30:58

5K+ Views

Some characters are reserved in HTML and they have special meaning when used in HTML document. For example, you cannot use the greater than and less than signs or angle brackets within your HTML text because the browser will treat them differently and will try to draw a meaning related to HTML tag.HTML processors must support following five special characters listed in the table that follows.SymbolDescriptionEntity NameNumber Code "quotation mark""'apostrophe''&ersand&&greater-than>>

Advertisements