Email: Password:       Forgot Password 
    .netCodeSG
A Saarsha Group Online Community for dot net codes group like C#, Asp.NET, VB.NET, Sharepoint, JavaScript, JQuery, Ajax, SQL, WCF, WPF.
 
TECHNOLOGIES:
 

Put Content in Center in an ASP.NET Web Page

Article:
Viewed:  792 
Posted On:  21/02/2015 22:45:37 
How we can put our content in center in an ASP.NET Web page ? 

In this article I am going to show how we can put our content in center in an ASP.NET  web page:

Below is my aspx:

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <style type="text/css">
        #wrapper
        {
            width: 760px;
            margin: auto;
        }
        #content
        {
            background-color: skyblue;
            color: Maroon;
            border: solid 2px green;
            padding: 10px;
            font-weight: normal;
        }
    </style>
</head>
<body>
    <form id="form1" runat="server">
    <div id="wrapper">
        <div id="content">
            This is my test Content.This is my test Content.This is my test Content.This is
            my test Content.This is my test Content. This is my test Content.This is my test
            Content.This is my test Content.This is my test Content.This is my test Content.
            This is my test Content.This is my test Content.This is my test Content.This is
            my test Content.This is my test Content. This is my test Content.This is my test
            Content.This is my test Content.This is my test Content.This is my test Content.
        </div>
    </div>
    </form>
</body>
</html>
 

Now run your application:

1.png

Image 1.

  Comment:
         HOME   |   Submit Article   |   Contact Us   |   About Us   |   Terms & Condition   |   Advertise With us