?
Solved

Does ASP.net 2.0 renders inc files

Posted on 2012-08-21
3
Medium Priority
?
756 Views
Last Modified: 2012-08-23
Hi,

We have given our website to design to some agency. They have given full html, images, javascript, jquery, css etc

They have given file with extensions .aspx

Now we need to do the dynamic stuff ourself for example form submission, inserting values into database, displaying news dynamically etc

What I am seeing in there aspx file provided that it has many 'inc' includes for example

<!--#include virtual="/inc/en/meta.inc"-->
<!--#include virtual="/inc/en/header-topnav.inc"-->

I think this all is asp code inside aspx file extension.

We need to convert complete website in ASP.net 2.0 using C#. That includes creating Master pages etc

Please confirm if my understanding is correct that inside aspx file they have used classic asp code.

ASP.net2.0 do not render inc files

As visual studio 2005 also not rendering .inc files, no css and js is found in Visual Studio 2005, which is written in .inc files

Please correct my understanding

Thanks
0
Comment
Question by:tia_kamakshi
  • 2
3 Comments
 
LVL 11

Accepted Solution

by:
madgino earned 2000 total points
ID: 38319326
Indeed include virtual was used in classic asp and now is obsolete as .NET uses master pages for this.
Regarding the .inc rendering, I've tried and by default .inc files are rendered by .NET and even the C# code is executed inside it.
But this can be changed by IIS setup, you can modify from there how you want 'include virtual' to be handled and also how to render .inc file (deny, use .NET or smth else).

In conclusion, theoretically your code should work like it is but you need to confirm that your server setup allows it, but the recommendation is to convert to asp.net using master pages.
0
 

Author Comment

by:tia_kamakshi
ID: 38320604
Thanks for your reply.

Yes, I know that we can do IIS settings to run inc files.

But how about at the time of development. We donot have IIS on our local machine, so, its hard to debug.

Indeed I will convert all inc files to user control or master page. But is there anyway to run inc files in Visual Studio 2005

Thanks again
0
 
LVL 11

Expert Comment

by:madgino
ID: 38320660
Rename them from .inc to .aspx (or .html or .asp - test to see which one is better).
As far as I've checked the include is still working and VS will render the pages for you.
However there is no tool to render you the included file in your main page, you have to open each included file to see how it looks.
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

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

Introduction This article shows how to use the open source plupload control to upload multiple images. The images are resized on the client side before uploading and the upload is done in chunks. Background I had to provide a way for user…
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Integration Management Part 2
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

864 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