.aspx not working

Status
Not open for further replies.

vincec

New Member
Messages
5
Reaction score
0
Points
0
I've read through a lot of posts in this forum and still can't solve my problem.
  • I am on the Starka server.
  • I am using Visual Studio 2005.
  • I can get an index.htm file working.
  • I cannot get a very simple (no controls) aspx file working.
  • When I try to go to my site, I get a blank page.
  • I have no web.config file at all.
  • I also modified the .htaccess file to point to MyTestPage.aspx file with the command:
DirectoryIndex MyTestPage.aspx

Can anyone help or provide suggestions?

Thanks
 

masshuu

Head of the Geese
Community Support
Enemy of the State
Messages
2,293
Reaction score
50
Points
48
Put this into somthing like test.aspx
Code:
<%@ Page Language="C#" %>
<%@ Import Namespace="System.Reflection" %>
<%
  Response.ContentType = "Text/Plain";
  Response.Write("HELLO WORLD!\n\n");
  Response.Write("ASP.NET version is " + System.Environment.Version.ToString());
  Response.Write("\n\n");
  Type monoRuntimeType;
  MethodInfo getDisplayNameMethod;
  if ((monoRuntimeType = typeof(object).Assembly.GetType("Mono.Runtime")) != null && (getDisplayNameMethod = monoRuntimeType.GetMethod("GetDisplayName", BindingFlags.NonPublic | BindingFlags.Static | BindingFlags.DeclaredOnly | BindingFlags.ExactBinding, null, Type.EmptyTypes, null)) != null)
    Response.Write("Mono Verson: " + (string)getDisplayNameMethod.Invoke(null, null));
  else
    Response.Write("Mono.Runtime.GetDisplayName not implemented(probably on windows?)");


%>
if it works then you need to go over your code, and remember that the systems running mono on apache, not microsofts .net system on IIS.
If it doesn't, we bug an admin to look at it
(this is what it should produce: http://com.x10hosting.com/test.aspx )

also add web.config file:
Code:
<?xml version="1.0" ?>
    <configuration>
         <appSettings />

         <connectionStrings />

         <system.web>
              <customErrors mode="Off" />
         </system.web>
   </configuration>
 
Last edited:

vincec

New Member
Messages
5
Reaction score
0
Points
0
Thanks for the reply. I copied exactly what you provided into a Test.aspx file. I also used DirectoryIndex Test.aspx in the .htaccess file. I created a web.config file with the code you provided. Unfortunately, I continue to receive a blank page.

What next?
 

masshuu

Head of the Geese
Community Support
Enemy of the State
Messages
2,293
Reaction score
50
Points
48
remove the DirectoryIndex Test.aspx and access the file directly(as i can't be sure that something else is being used as an index page)
 

vincec

New Member
Messages
5
Reaction score
0
Points
0
I removed the line: DirectoryIndex Test.aspx from .htaccess, the file is completely blank now.

Now when I go to my site I get an "Index of /" (and then each of the files in public_html.

If I click on the Test.aspx file, then I get the following error:

XML Parsing Error: no element found
Location: http://www.vincec.x10hosting.com/Test.aspx
Line Number 1, Column 1:

I will do a search on this type of error in the forums.

Thanks.

Update: It seems like someone else had the same XML Parsing Error in this thread, http://x10hosting.com/forums/a/117864-asp-net.html. Apparently, the mono project (used to run ASP.NET on Linux servers) is currently unavailable after migrations.
 
Last edited:
Status
Not open for further replies.
Top