To set media queries for different CSS style rules, you can try to run the following code −ExampleLive Demo body { background-color: lightpink; } @media screen and (max-width: 420px) { body { background-color: lightblue; } } If screen size is less than 420px, then it will show lightblue color, or else it will show light pink color
Definition and UsageThe atan2() function calculates arc tan of two variablesatan2(y, x) returns the arc tangent of the two numbers x and y. although it is similar to atan(y)/atan(x), the signs of both x and y are used to determine the quadrant of the result. Accordingly for values of x and y atan2() isatan(y/x) if x>0atan(y/x)+pi if x>0atan(y/x)-pi if xOutputThis will produce following result −atan2(5, -5) = 2.3561944901923Example Live DemoFollowing program computes atan2(5, 0) and returns 1.570796326795 (M_PI_2) −OutputThis will produce following result −atan2(5, 0) = 1.5707963267949Example Live DemoFollowing example computes atan2(0, 0) and returns 0OutputThis will produce following result −atan2(0, 0) ... Read More
Box-sizing property is used to change the height and width of the element. Since CSS2, the box property has worked like as shown below −width + padding + border = actual visible/rendered width of an element's box height + padding + border = actual visible/rendered height of an element's boxExampleTo understand the box-sizing property, let us see an example:Live Demo .div1 { width: 300px; height: 100px; border: 1px solid blue; box-sizing: border-box; } .div2 { width: 300px; height: 100px; padding: 50px; border: 1px solid red; box-sizing: border-box; } TutorialsPoint.com TutorialsPoint.com
Definition and UsageThe atanh() function returns the inverse hyperbolic tangent ratio of given given parameter. In other words, the return value of atanh() is hyperbolic tangent of given parameter. A inverse hyperbolic tangent function is defined as .atanh(x) = 0.5Xlog((1+x)/(1-x))This function returns a float value .Syntaxatanh ( float $arg ) : floatParametersSr.NoParameter & Description1argA floating point value whose inverse hyperbolic tangent is to be calculatedReturn ValuesPHP atanh() function returns inverse hyperbolic tangent ratio of given parameter.PHP VersionThis function is available in PHP versions 4.x, PHP 5.x as well as PHP 7.x.Example Live DemoFollowing example calculates atanh(pi/4) and returns which is also ... Read More
The value attribute of the element specifies the current value of the gauge. This is a required attribute.Following is the syntax −Above, num represents the current value as a floating-point number.Let us now see an example to implement the value attribute of the element −Example Live Demo Result Girls pass % Boys pass % OutputIn the above example, we have set the pass percentage of girls as well as boys using the element. The current value is set using the value attribute −Boys pass %
The CSS3 resize property is having three common values as shown below −horizontalverticalbothExampleUsing both the values in resize property in the CSS3 user interface:Live Demo div { border: 2px solid; padding: 20px; width: 300px; resize: both; overflow: auto; } My Website
Definition and UsageThe atan() function returns the arc tan or tan inverse of arg in radians. atan() is the inverse function of tan(). Therefore if tan(x)=y, atan(y)=x.For example, tan(pi/3)= 1.73205080757 (Squre Root of 3) and atan(1.73205080757)=1.04719755 rad which is equal to pi/3.This function returns a float value .Syntaxatan ( float $arg ) : floatParametersSr.NoParameter & Description1argA floating point number whose arc tan is to be calculated.Return ValuesPHP atan() function returns arc tan of given number. It is angle represented in radians. Returned value is between -pi/2 and pi/2PHP VersionThis function is available in PHP versions 4.x, PHP 5.x as well ... Read More
Definition and UsageThe asinh() function calculates inverse of hyperbolic sine of given parameter. In other words, the return value of asinh() is hyperbolic sine of given parameter. A inverse hyperbolic sine function is defined asasinh(x) = log(x+sqrt(pow(x, 2)+1))This function returns a float value.Syntaxasinh( float $arg ) : floatParametersSr.NoParameter & Description1argA floating point value whose inverse hyperbolic sine is to be calculatedReturn ValuesPHP asinh() function returns inverse hyperbolic sine ratio of given parameter.PHP VersionThis function is available in PHP versions 4.x, PHP 5.x as well as PHP 7.x.Example Live DemoFollowing example calculates asinh(pi/2) which we can verify using the definition −OutputThis will ... Read More
Definition and UsageThe asin() function returns the arc sine or sine inverse of arg in radians. asin() is the inverse function of sin(). Therefore if sin(x)=y, asin(y)=x.For example, sin(pi/2)=1 and asin(1)=1.57079633 rad which is equal to pi/2.This function returns a float value.Syntaxasin ( float $arg ) : floatParametersSr.NoParameter & Description1argA floating point number whose arc sine is to be calculated. Number should be withing -1 to 1Return ValuesPHP asin() function returns arc sine of given number. It is angle represented in radians.PHP VersionThis function is available in PHP versions 4.x, PHP 5.x as well as PHP 7.x.Example Live DemoFollowing example calculates ... Read More
The href attribute of the element is used to set the url of the external resource.Following is the syntax −Above, the url is the url of the linked document. Let us now see an example to implement the href attribute of the element −Example Demo Heading This is demo text. We have an external document above “new.css”, which is linked using href. This document is a CSS style file −h1{ color − blue; } p{ background-color − red; }OutputThis will produce the following output. We styled the heading and text in the above “new.css” −
Data Structure
Networking
RDBMS
Operating System
Java
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP