Click to See Complete Forum and Search --> : what is .inc (inc extension) file


ahmed1
03-15-2006, 03:31 AM
What is inc file used in asp scripts
Is that the essential part of our code???or not

If we want to write our code without .inc file.
Then is that possible???
i am asking because i dont know what is the perpose and importance of inc file in asp script.
is there any help available for inc file
how to create them and what is the perpose of inc file in our code???
Plz reply urgent
Ahmed Ali

TheBearMay
03-15-2006, 07:18 AM
Generally used for files used in an include statement....

pcthug
03-15-2006, 07:24 AM
Text file containing declarations, headers, functions, or other data referenced by a program's source code. However you should never include any sensitive data inside a .inc file, as they are not parsed by the server, therefore allowing the client to see asp code.

Ubik
03-15-2006, 10:11 AM
However you should never include any sensitive data inside a .inc file, as they are not parsed by the server, therefore allowing the client to see asp code.

Which is why I never use '.inc' as a file extention. I use '.asp', and I put '_' in front of the filename so that when I look at the files in the folder on the server, I can instantly see all of my include files at the top of the list.

If the client types the URL of my include file, they will most likely get an asp error message, and will not see the VBScript code, as the server will have processed it as an asp page.

But that is just me, apparently.

Terrorke
03-15-2006, 11:21 AM
Including files is handy when you have the same code used in several places.

But you don't have to use it when you don't want to of course :-)

lmf232s
03-15-2006, 03:45 PM
ubik,
has it perfectly. Dont use a .inc file extension. I have many include files but they dont end in .inc. I have a directory called Include where i keep all files that have reusable code. I have seen this many of times as a naming convention.

common_inc.asp

Dont use the .inc extension stick w/ a .asp extension

Ubik
03-16-2006, 05:19 PM
Like this:

_commonfunctions.asp
_devdumper.asp
_footer.asp
_header.asp
about.asp
contact.asp
default.asp
etc.etc.etc.asp