Samual Sam has Published 2492 Articles

HTML5 Microdata Attributes

Samual Sam

Samual Sam

Updated on 29-Jan-2020 07:25:23

120 Views

Microdata introduces five global attributes that would be available for any element to use and give context for machines about your data.AttributeDescriptionItemscopeThis is used to create an item. The itemscope attribute is a boolean attribute that tells that there is Microdata on this page, and this is where it starts.Itemtype This ... Read More

Draw Lines with easelJS using Ticker in HTML

Samual Sam

Samual Sam

Updated on 29-Jan-2020 06:39:08

258 Views

EaseLJS is a JavaScript library to make the HTML5 Canvas element easy. Use it for creating games, graphics, etc.To draw lines using Ticker method in HTML with easeLJS:var myLine = new createjs.Shape(); myLine.graphics.setStrokeStyle(4); myLine.graphics.beginStroke(color); myLine.graphics.moveTo(startX, startY); startY++; myLine.graphics.lineTo(startX, startY); myLine.graphics.endStroke();Read More

Blank PNG image is shown with toBase64Image() function

Samual Sam

Samual Sam

Updated on 29-Jan-2020 06:35:13

145 Views

If a blank image is shown with the toBase64Image() function, you need to use the following to work on it correctly:animation: {    duration: 2000,    onComplete: function (animation) {       this.toBase64Image();    } }With that, you can also use another fix. Call save64Img(myChart.toBase64Image()) over an additional callback ... Read More

What is the most efficient way of assigning all my HTML5 video sources as trusted without having to loop over all of them

Samual Sam

Samual Sam

Updated on 29-Jan-2020 06:28:30

38 Views

Add some config to assign trust to your videos in HTML5:app.config(function($sceDelegateProvider) {    $sceDelegateProvider.resourceUrlWhitelist([    // allowing same origin resource loads    'self',    // allowing loading from our assets domain    'http://media.w3.org/**']); });

How to detect the browser's format for HTML input type date

Samual Sam

Samual Sam

Updated on 29-Jan-2020 06:26:09

229 Views

An input.the valueAsDate method returns a Date object reflecting the input's current value. The displayed value follows the same format. To make it work:new Date().toISOString().substr( 0, 10 ); new Date().toLocaleDateString(); input.valueAsDate; input.valueAsDate.toLocaleDateString(); new Date( input.valueAsDate ); new Date( input.valueAsDate ).toISOString().substr( 0, 10 );

toDataURL throw Uncaught Security exception in HTML

Samual Sam

Samual Sam

Updated on 29-Jan-2020 06:24:50

85 Views

To solve the Uncaught Security Exception, you need to add the crossorigin attribute: function getBase64() {    var myImg = document.getElementById("myid");    var c = document.createElement("canvas");    c.width = myImg.width;    c.height = myImg.width;    var context = c.getContext("2d");    context.drawImage(img, 0, 0);    var dataURL ... Read More

How can we put comments in a column of existing MySQL table?

Samual Sam

Samual Sam

Updated on 29-Jan-2020 05:56:20

2K+ Views

It can be done by using ‘COMMENT’ keyword while modifying the column with ALTER TABLE command. For example if we want to add comment in column ‘id’ of table ‘testing’ then following query will do itmysql> ALTER TABLE testing MODIFY id INT COMMENT 'id of employees'; Query OK, 0 rows ... Read More

Exam Guidance for CAT (Common Admission Test)

Samual Sam

Samual Sam

Updated on 28-Jan-2020 12:39:21

210 Views

In a world obsessed with the word ‘Management’, MBA has become one of the most sought after degrees. Management and entrepreneurship often go hand-in-hand. Most of the startup CEOs and corporate honchos are MBA degree holders. CAT which stands for Common Admission Test is a much bandied about entrance exam ... Read More

Facebook introduces video as your profile pic!

Samual Sam

Samual Sam

Updated on 28-Jan-2020 12:29:39

200 Views

Now you can upload a 7-second video as your profile pic. Isn’t that great? You can upload a fun-filled video or just a formal introduction in just that small little profile space describing you.Along with the profile video, you can now, highlight your bio-data with a 100-character bio field.And we ... Read More

Find if your Email Provider is Leaking Your IP Address

Samual Sam

Samual Sam

Updated on 28-Jan-2020 12:27:12

574 Views

Many people are unaware, that by sending an email to others, they disclose more information about them, which they do not prefer to disclose. Yes, most of you might be surprised to know this.Whenever you send an email message to others, few unwanted information also goes along with your message, ... Read More

Advertisements