Display list items in rows

HTML lists allow web developers to group a set of related items in lists. Normally,items in a list are displayed vertically : one below the other. We can display list items in row by setting the styles of list items. Result

HTML pattern Attribute for email

The “pattern” attribute specifies a regular expression that the <input> element’s value is checked against on form submission Syntax <input pattern=”regexp“> regexp Specifies a regular expression that the <input> element’s value is checked against Pattern of valid emails are1.An e-mail address always starts with a word.. or ” cannot be in the starting of email id. Double… Continue reading HTML pattern Attribute for email

Scroll to another div on button click in Javascript

We can scroll to another div using window.scrollBy() .The window.scrollBy() method scrolls the document by the specified number of pixels.  Syntax :Function can be used in following ways 1.window.scrollBy(x-coord, y-coord)  x-coord : Required. Number of pixels to scroll (horizontally). Positive values scroll to the right, negative values to the left. window.scrollBy(options)  y-coord : Required. Number ofpixels to scroll (vertically). Positive values scroll down,… Continue reading Scroll to another div on button click in Javascript

Scroll to page top on page refresh using javascript

On page reload,most of the browsers tend to restore the last scroll position. The JavaScript ‘history’ API has the ‘scrollRestoration ‘property, which when set to manual , prevents the last scroll location on the page to be restored. We can use this property in the following way: history.scrollRestoration = ‘manual’; Before the page unloads, we… Continue reading Scroll to page top on page refresh using javascript

Flash News/Breaking News Marquee Animation

An animation allows an element gradually change from one style to another.To make animation using css, we must first specify some keyframes for the animation.Keyframes hold what styles the element will have at certain times.When we specify CSS styles inside the @keyframes rule, the animation will gradually change from the current style to the new… Continue reading Flash News/Breaking News Marquee Animation

Change color of bullet color of a list in HTML

By default,Color of bullet in unordered list is black and we can’t change the color of bullet using list style properties. By setting some css properties ,it is possible to change color of list item. Following example demonstrate how to set color for bullet of a list item. First we change ” list-style” property to… Continue reading Change color of bullet color of a list in HTML

Favicon in wordpress

Favicon It is used by webbrowsers in address bar(URL).It helps to identify our site visually. In mobile, it is used as application icon.Favicon means Favourite Icon. It is 16 * 16 pixel image. By default wordpress have a favicon. But we can change it to our icon.Navigate to wordpress dashboard(As admin)=>Appearance=>CustomizeOn the left side bar,… Continue reading Favicon in wordpress

Create a Plugin in wordpress

Create a Plugin in wordpress  1.Create a folder and a php file in it.  In the php file,add a comment so that wordpress identify php file as plugin.  /* Plugin Name: DB Plugin add Menu */  Appropriate code can be written in the php file to achieve the functionality of plugin. Activation and deactivation hooks provide ways to… Continue reading Create a Plugin in wordpress