Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Pre-set formatting on asp.net pages.

Posted on 2014-01-28
1
Medium Priority
?
411 Views
Last Modified: 2014-01-28
I am newish to Asp.net. I have inherited a web application project. When I create a new page it already has some formatting on the top even though I don't use any master page when creating the page. This I can see when I build the page. I am using ASP.Net 4.0, C# language.

You can see the formatting here at:

http://imgur.com/0z5wnjM

For the life of me I cant figure out as in the underlying code for the file there is no reference to any css or any elements. The code for page.aspx is as follows:

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Test.aspx.cs" Inherits="Test" %>
<!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>
</head>
<body>
</body>
</html>

Open in new window


The code behind is as follows:

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class Test : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }
}

Open in new window


Here is the rendered code:

The rendered code is as follows:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">; <html xmlns="w3.org/1999/xhtml">; <head><title> </title><link href="App_Themes/Default/flexslider.css" type="text/css" rel="stylesheet" /><link href="App_Themes/Default/PublicStyle.css" type="text/css" rel="stylesheet" /></head> <body> </body> </html> – 

Open in new window



Thanks in advance for any help I can get.
0
Comment
Question by:JonhDonogan
1 Comment
 
LVL 41

Accepted Solution

by:
Kyle Abrahams earned 1500 total points
ID: 39815080
From:
stackoverflow.com/questions/4905999/prevent-asp-net-themes-from-auto-adding-css-files

Try adding this to your <%@ Page> Directive

EnableTheming="false" Theme="" StylesheetTheme=""

It could be the website is using a theme which is automatically adding those CSS files for you.

More on themes:
http://msdn.microsoft.com/en-us/library/ykzx33wh.aspx
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Problem Hi all,    While many today have fast Internet connection, there are many still who do not, or are connecting through devices with a slower connect, so light web pages and fast load times are still popular.    If your ASP.NET page …
Calculating holidays and working days is a function that is often needed yet it is not one found within the Framework. This article presents one approach to building a working-day calculator for use in .NET.
this video summaries big data hadoop online training demo (http://onlineitguru.com/big-data-hadoop-online-training-placement.html) , and covers basics in big data hadoop .
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an anti-spam), the admin…
Suggested Courses

824 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question