Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Call a function from another page

Status
Not open for further replies.

eyal

Programmer
May 15, 2000
38
IL
Hi,<br>How can I call a function from one .asp page to another?<br>Thanks<br>Eyal
 
As far as I know you can't.<br><br>The best method is to create an .inc file with all your bulk functions.<br><br>I tend to have one for VBScript and one for JScript.<br>That way you only need change it in one place.<br><br>An .inc file is just another ASP page with a different extension, just to distinguish them, but you don't need to put any HTML/Body tags etc in, as it's going to rely on it's parents/calling ASP page.<br><br>To include a file use the following code wherever you want to insert it:<br><br>&lt;!-- #include file=&quot;filename.inc&quot;--&gt; <p>Ben Marshalsea<br><a href=mailto: > </a><br><a href= > </a><br>
 
I'd suggest not using the .inc extension.&nbsp;&nbsp;Users will be able to see/steal your source code unless you use an .asp extension. <p>nick bulka<br><a href=mailto: > </a><br><a href= > </a><br>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top