Articles on Trending Technologies

Technical articles with clear explanations and examples

How to Find out Linux Version currently Installed on your Machine?

Samual Sam
Samual Sam
Updated on 28-Jan-2020 356 Views

Are you new to Linux/Ubuntu? Do you know, which version of Ubuntu/Linux is currently installed on your machine? If you are in a dilemma, then this article explains you about how to find out Linux version currently installed on your machine.Method 1Use the following command to find Ubuntu version as shown below −$cat /etc/*-releaseThe sample output should be like this –DISTRIB_ID=Ubuntu DISTRIB_RELEASE=16.04 DISTRIB_CODENAME=xenial DISTRIB_DESCRIPTION="Ubuntu 16.04.1 LTS" NAME="Ubuntu" VERSION="16.04.1 LTS (Xenial Xerus)" ID=ubuntu ID_LIKE=debian PRETTY_NAME="Ubuntu 16.04.1 LTS" VERSION_ID="16.04" HOME_URL="http://www.ubuntu.com/" SUPPORT_URL="http://help.ubuntu.com/" BUG_REPORT_URL="http://bugs.launchpad.net/ubuntu/" UBUNTU_CODENAME=xenialTo get the kernel information about Linux machine, use the following command as shown below −$ hostnamectlSample output should be ...

Read More

Why we cannot use MySQL DATE data type along with time value?

seetha
seetha
Updated on 28-Jan-2020 149 Views

The default format for MySQL DATE data type is “YYYY-MM-DD” and in this format, there is no possibility to store the time value. Hence, we can say that we cannot use DATE data type along with time value.As we can see in the following example MySQL returns only date value even on using time along with the date.mysql> select DATE("2017-09-25 09:34:21"); +-----------------------------------+ | DATE("2017-09-25 09:34:21")       | +-----------------------------------+ | 2017-09-25                        | +-----------------------------------+ 1 row in set (0.04 sec)However, in DATETIME and TIMESTAMP date data types we can use the time to date.

Read More

How to search a record by date in MySQL table?

Prabhas
Prabhas
Updated on 28-Jan-2020 1K+ Views

Suppose we have a table ‘Order123’ having ProductName, Quantity and OrderDate columns as follows −mysql> Select * from Order123; +-------------+----------+------------+ | ProductName | Quantity | OrderDate  | +-------------+----------+------------+ | A           | 100      | 2017-05-25 | | B           | 105      | 2017-05-25 | | C           | 55       | 2017-05-25 | | D           | 250      | 2017-05-26 | | E           | 500      | 2017-05-26 | | ...

Read More

HTML5 / JS storage event handler

Jennifer Nicholas
Jennifer Nicholas
Updated on 28-Jan-2020 358 Views

Storage event handlers only fire if the storage event triggered by another window. You can try to run the following code:// event handler window.addEventListener('storage', storageEventHandlerFunc, false); function storageEventHandlerFunc(evt) {    alert("Storage event called key: " + event.key );    switch(event.key){       case 'one':       case 'two': batteryDCMeter(); break;       case 'extPowerOn': rechargeBattery(); break;    } } sessionStorage.setItem("someKey", "someValue");

Read More

Does 'position: absolute' conflict with flexbox?

karthikeya Boyini
karthikeya Boyini
Updated on 28-Jan-2020 324 Views

Absolutely positioning will not conflict with flex containers. You need to set the parent width and values as well:.parent {    display: flex;    justify-content: center;    position: absolute;    width:100% }The following is the HTML:    text

Read More

Polymer 1.0 dom-repeat should display index starting at 1 with HTML

Samual Sam
Samual Sam
Updated on 28-Jan-2020 197 Views

Polymer.js is a JavaScript library created by Google that allows reusing the HTML elements for building applications with components.To achieve this index, you need to set the index as:{{displayIndex(index)}}The displayIndex would be:function (index) {    return index + 1; }Let us see it in an example:Subject {{displayIndex(index)}}

Read More

Flexbox layout losing proportions when reduced in size

Nitya Raut
Nitya Raut
Updated on 28-Jan-2020 138 Views

To avoid the Flexbox layout issue, you need to add the following:* {    flex-shrink: 0;    min-width: 0;    min-height: 0; }Here, flex-shrink: 1 - Flex items are allows to shrinkmin-width: 0 - flex items to shrink past their content

Read More

Improve performance of a HTML5 Canvas with particles bouncing around

Nishtha Thakur
Nishtha Thakur
Updated on 28-Jan-2020 217 Views

To enhance the performance of Canvas with particles bouncing around, try the following:Separate the calculations from the drawing.Request a redraw after you have updated your calculations.Optimize collision detection by not testing evert particle against each other.Reduce callback usage.Reduce function calls.Inline.

Read More

Difference between div~div and div:not(:first-of-type)?

karthikeya Boyini
karthikeya Boyini
Updated on 28-Jan-2020 169 Views

Both are same in terms of matching elements. Let us see an example:                             If you have CSS rules with both selectors matching the same elements, then your div: not(:first-of-type) will get precedence due to the: first-of-type pseudo-class.

Read More

What HTML5 tag should be used for filtering search results.

Smita Kapse
Smita Kapse
Updated on 28-Jan-2020 250 Views

To filter search results, use the element. The header should be in the section of the search results:    Search results                                                                      

Read More
Showing 50451–50460 of 61,248 articles
Advertisements