| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
I designed a site a while back but wasnt to keen on it
so i recently decided to try out a nice content management system which i think is great ! i basically have exactly what i want now apart from one thing, the content management system is entirely php and my old site was asp based, and i really think that 1 script in particular from the old site would just complete my new site. the only trouble is that i cant seem to get my asp code to actually run. the code makes a table and shows it on the page filling it with the contents of a folder on my computer (lists the files) All i seem to get is the table and inside where my filename would be i get " "> " which leads me to believe that the table itself being plain html is used and then the server is lead to believe it is still working on php code so doesnt correctly use the scripting needed within the table fields. can you input an asp script in to a page of php or would i need to convert my existing asp code to the new php language that i know little about ? this is what im doing so far and saved as any file type doesnt seem to work (i thought that it might be treated differently if saved under a different file type) .... Code:
<?php
require_once("class2.php");
require_once(e_HANDLER."news_class.php");
require_once(HEADERF);
?>
<html>
<<<<<< and my script goes here >>>>>
</html>
<?php
require_once(FOOTERF);
?>
|
|
#2
|
||||
|
||||
|
Do not post the same question in multiple areas.
I have already answered this question in your other post. |
|
#3
|
|||
|
|||
|
Quote:
k soz ... wasnt sure where it fit |
|
#4
|
||||
|
||||
|
If I missed it... yes, you can combine PHP, ASP, and ASP.Net on the same page by making use of the stacking order of ISAPI filters and extensions in IIS.
Apache has similar functionality. |
|
#5
|
||||
|
||||
|
Provide documentation on where you found this.
The general understanding is the page extension determines the interpreter/compiler used and therefore if the page is a .asp extension then the php and or .net code would be ignored. Last edited by Memnoch : April 19th, 2005 at 08:44 AM. |
|
#6
|
||||
|
||||
|
I still seriously doubt that you can do this on a page and have it properly display everything regardless of the file extension.
Code:
<?php echo 'Hello World'; ?> <%="Hello World"%> <asp:Label ID="Hello1" Text="Hello World"></asp:Label> Last edited by Memnoch : April 19th, 2005 at 08:49 AM. |
|
#7
|
||||
|
||||
|
Nah, simple.
Just add ".muwahahah" to the ISAPI extensions list and set the PHP, ASP, and ASP.Net ISAPIs to handle that extension. |
|
#8
|
||||
|
||||
|
Provide a link where you found this.
I tried to do it for about an hour, but it didn't work. Here's why it seems to not work. 1) You can only assign a single ISAPI dll file to a newly created application extension. 2) You can only have one unique application extension in the list. So it seems impossible to do the following, which you suggested. A) Create a new extension and assign 3 separate ISAPI dlls to it. OR B) Create three identical extensions and assign each ISAPI dll (.php, .asp, .aspx) to each extension respectively. Last edited by Memnoch : April 19th, 2005 at 10:48 AM. |
|
#9
|
||||
|
||||
|
Okay... my bad
But you could always run servers behind each other. Back during the CodeRed Crises, many IIS servers were located behind Apache frontends. As a side-effect, you could run pages returned from IIS through ther PHP modules in Apache. |
![]() |
| Viewing: ASP Free Forums > Web Design > Web Layout > Can PHP and ASP go on the same page ? |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|