Category: CSS

Selection Selector using CSS

<!DOCTYPE html> <html> <head> <style> ::-moz-selection { /* Code for Firefox */ color: blue; background: yellow; } ::selection { color: blue; background: yellow; text-shadow: 2px 2px 2px grey; } </style> </head> <body> <h1>Select some text on this page:</h1> <p>Hello World How Are You.</p> <div>This is some text in a div element.</div> <p><strong>Note:</strong> ::selection is not […]

what is CSS Gradient? how to use Gradient in CSS3

Why CSS Gradient These are the following reasons to use CSS gradient. You don’t have to use images to display transition effects. The download time and bandwidth usage can also be reduced. It provides better look to the element when zoomed, because the gradient is generated by the browser. There are two types of gradient […]

CSS Background Image Animation

Background animations are an awesome touch when used correctly.Luckily these days CSS animations are widely supported enough to rely on them to take over JavaScript-based animation tasks.The following simple CSS snippet animates the background image through background position of a given element. Here,The Nature background image within the sample element will elegantly scroll from left […]

Cut Image using HTML

This is also known as Clip Property of CSS. Take a look at the image of the Nature at following. That Image has Cropped. Let’s see how to crop image using html. The Original image is 600×450. but we need to display small image. here i cut the image at right side. <!DOCTYPE html> <html> <head> <style> […]