Web Layout
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
 
User Name:
Password:
Remember me
Go Back   ASP Free ForumsWeb DesignWeb Layout

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread ASP Free Forums Sponsor:
  #1  
Old April 17th, 2005, 08:17 AM
Wardy Wardy is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Jan 2005
Posts: 26 Wardy User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 5 h 40 m 58 sec
Reputation Power: 0
Send a message via MSN to Wardy
Unhappy Can PHP and ASP go on the same page ?

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);
?>
 

Reply With Quote
  #2  
Old April 17th, 2005, 11:50 AM
Memnoch's Avatar
Memnoch Memnoch is offline
Unholy Moderator
ASP Free God 14th Plane (11500 - 11999 posts)
 
Join Date: Oct 2003
Location: In hell, where did you think?
Posts: 11,760 Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level) 
Time spent in forums: 3 Weeks 5 Days 5 h 22 m 16 sec
Reputation Power: 443
Do not post the same question in multiple areas.
I have already answered this question in your other post.

Reply With Quote
  #3  
Old April 17th, 2005, 01:13 PM
Wardy Wardy is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Jan 2005
Posts: 26 Wardy User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 5 h 40 m 58 sec
Reputation Power: 0
Send a message via MSN to Wardy
Quote:
Originally Posted by Memnoch
Do not post the same question in multiple areas.
I have already answered this question in your other post.


k soz ... wasnt sure where it fit

Reply With Quote
  #4  
Old April 19th, 2005, 05:57 AM
Phoenix's Avatar
Phoenix Phoenix is offline
Web-Standards Evangelist
ASP Free Intermediate (1500 - 1999 posts)
 
Join Date: Nov 2003
Posts: 1,522 Phoenix User rank is Corporal (100 - 500 Reputation Level)Phoenix User rank is Corporal (100 - 500 Reputation Level)Phoenix User rank is Corporal (100 - 500 Reputation Level)Phoenix User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 4 Days 23 h 48 m 4 sec
Reputation Power: 8
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.

Reply With Quote
  #5  
Old April 19th, 2005, 08:40 AM
Memnoch's Avatar
Memnoch Memnoch is offline
Unholy Moderator
ASP Free God 14th Plane (11500 - 11999 posts)
 
Join Date: Oct 2003
Location: In hell, where did you think?
Posts: 11,760 Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level) 
Time spent in forums: 3 Weeks 5 Days 5 h 22 m 16 sec
Reputation Power: 443
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.

Reply With Quote
  #6  
Old April 19th, 2005, 08:46 AM
Memnoch's Avatar
Memnoch Memnoch is offline
Unholy Moderator
ASP Free God 14th Plane (11500 - 11999 posts)
 
Join Date: Oct 2003
Location: In hell, where did you think?
Posts: 11,760 Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level) 
Time spent in forums: 3 Weeks 5 Days 5 h 22 m 16 sec
Reputation Power: 443
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.

Reply With Quote
  #7  
Old April 19th, 2005, 09:15 AM
Phoenix's Avatar
Phoenix Phoenix is offline
Web-Standards Evangelist
ASP Free Intermediate (1500 - 1999 posts)
 
Join Date: Nov 2003
Posts: 1,522 Phoenix User rank is Corporal (100 - 500 Reputation Level)Phoenix User rank is Corporal (100 - 500 Reputation Level)Phoenix User rank is Corporal (100 - 500 Reputation Level)Phoenix User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 4 Days 23 h 48 m 4 sec
Reputation Power: 8
Nah, simple.

Just add ".muwahahah" to the ISAPI extensions list and set the PHP, ASP, and ASP.Net ISAPIs to handle that extension.

Reply With Quote
  #8  
Old April 19th, 2005, 10:42 AM
Memnoch's Avatar
Memnoch Memnoch is offline
Unholy Moderator
ASP Free God 14th Plane (11500 - 11999 posts)
 
Join Date: Oct 2003
Location: In hell, where did you think?
Posts: 11,760 Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level)Memnoch User rank is Lieutenant Colonel (40000 - 50000 Reputation Level) 
Time spent in forums: 3 Weeks 5 Days 5 h 22 m 16 sec
Reputation Power: 443
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.

Reply With Quote
  #9  
Old April 19th, 2005, 12:00 PM
Phoenix's Avatar
Phoenix Phoenix is offline
Web-Standards Evangelist
ASP Free Intermediate (1500 - 1999 posts)
 
Join Date: Nov 2003
Posts: 1,522 Phoenix User rank is Corporal (100 - 500 Reputation Level)Phoenix User rank is Corporal (100 - 500 Reputation Level)Phoenix User rank is Corporal (100 - 500 Reputation Level)Phoenix User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 4 Days 23 h 48 m 4 sec
Reputation Power: 8
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.

Reply With Quote
Reply

Viewing: ASP Free ForumsWeb DesignWeb Layout > Can PHP and ASP go on the same page ?


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway