Posts

Showing posts with the label CSS

Apply Style to Every Control on Website in ASP.NET

Introduction I guess you are expert in styling controls using CSS. But the thing I am going to talk in this post is bit different. Let's look at following asks: (i) How to apply style to all Label controls on website? (ii) How to apply TextBox background color or font color (ForeColor) to all controls on websites? (iii) How to apply style to all Hyperlink controls on website? To answer these all question let's read this. Follow the steps:- Step 1 Create a style sheet page by name 'SiteStyle.css' and save this under project root. Step 2 Type following style information in SiteStyle.css page:         span:hover         {             font-size : 12px ;             font-style : oblique ;         }                 input         {             background-color : #999999 ;             color : Blue ;         }                 a:hover         {             color : Green ;         } Please note: I am usi

Rounded Corner DIV in ASP.NET

Image
Introduction Look at the image given below: In the above image, you can see the rounded corner control. Most of you will guess its image or even you call it as background image, but actually it is not image, its rounded corner DIV. To create such rounded corner DIV you just need to add some special styles with existing DIV tag.  Look at the DIV given below: < div style =" margin :0 auto; background-color :#EAFFFF; -moz-border-radius : 100px; -webkit-border-radius : 100px; border-radius : 100px; padding :15px 15px 15px; width :200px;">             Place your data here </ div > Try the above code it will create the rounded DIV for you. And even it is very concise way because it will take less memory to download.

Creating Master Page (Using CSS) in ASP.NET Part 1

Image
Introduction Master Page enables us to share the same content among multiple content pages in a website. We can use a Master Page to create a common page layout. For example, if we want all the pages in our website to share a three-column layout, we can create the layout once in a Master Page and apply the layout to multiple content pages. We also can use Master Pages to display common content in multiple pages. For example, if we want to display a standard header and footer in each page in our website, then we can create the standard header and footer in a Master Page. By taking advantage of Master Pages, we can make our website easier to maintain, extend, and modify. If we need to add a new page to our website that looks just like the other pages in our website, then we simply need to apply the same Master Page to the new content page. If we decide to completely modify the design of our website, we do not need to change every content page. We can modify just a single Master Page

Popular posts from this blog

Migrating database from ASP.NET Identity to ASP.NET Core Identity

Customize User's Profile in ASP.NET Identity System

Lambda two tables and three tables inner join code samples