473,889 Members | 1,803 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

ASP code in page with .SHTML extension

3 New Member
I'm managing a site that I didn't create. It runs IIS-5. All of the pages have a .SHTML extension, which I understand. A number of pages have ASP code embedded in them. The ISP has configured IIS to allow the ASP code to execute even though the page extension is not .ASP. The people who set all of this up are long gone by several years.

I have a mirror of the site on my system but I haven't been able to figure out how to configure IIS to allow that behaviour. It just displays the scripts as text in line.

If you know how to accomplish this, I'd really appreciate your explanation.

Thanks.

Bob
Jan 2 '07 #1
5 6668
jaketrimble
14 New Member
in IIS go to "properties " of the directory that holds the .shtml pages that have the ASP code, then on the Directory tab click on "Configuration" , then choose the "Applicatio n Mappings" tab.

Ok, if you have got this far you are almost done.

find the .asp extension click edit

copy the path to the .dll file that handles the execution.

then close the window

now click "Add"

Paste the path that you just copied and add the extension .shtml

for verbs, you will add this

GET,HEAD,POST

thats it....

BUT

make sure that you copy the path to the existing .shtml .dll that handles the page configuration.

this should work, if not let me know

cheers!
Jan 6 '07 #2
rmcape
3 New Member
Thanks Jake!

I modified the entry for .shtml to read: C:\WINDOWS\Syst em32\inetsrv\as p.dll

The VB Scripts embedded in the .shtml worked as expected.

You mentioned:

"BUT
make sure that you copy the path to the existing .shtml .dll that handles the page configuration."

I'm not sure what you mean by this.

Before I modified the entry for .shtml, it read: C:\WINDOWS\Syst em32\inetsrv\ss inc.dll

Should they both be there? Separated by a ";" ?

Thanks,

Bob
Jan 8 '07 #3
jaketrimble
14 New Member
Thanks Jake!

I modified the entry for .shtml to read: C:\WINDOWS\Syst em32\inetsrv\as p.dll

The VB Scripts embedded in the .shtml worked as expected.

You mentioned:

"BUT
make sure that you copy the path to the existing .shtml .dll that handles the page configuration."

I'm not sure what you mean by this.

Before I modified the entry for .shtml, it read: C:\WINDOWS\Syst em32\inetsrv\ss inc.dll

Should they both be there? Separated by a ";" ?

Thanks,

Bob
No, they both do not need to be in there. I just wanted to make sure you kept the path to that dll saved, just in case you needed to change it back, or it did not work for some reason.

glad to help

-Jake
Jan 9 '07 #4
jaketrimble
14 New Member
also, this technique can be applied to other static pages. I first discovered this when I was trying to secure static documents and images within a .NET application. so for "static" documents like .doc, .pdf, .jpg, .gif...etc....y ou can just add these extensions and use the dll that should handle them, like you did for your shtml page.

by doing that, if users were not logged into that directory, if they would try to access one of those static documents that resided in that specific directory, they would be redirected to the log in page...works something like this...

request (static document)
dll reference (i used the asp dll)
web.config (since it handles it like my other asp pages)
if not logged in, send to log in page, else view the "static document"

cheers!
Jan 9 '07 #5
rmcape
3 New Member
Thanks Jake!

I appreciate your clarification and the info about other static pages.

Regards,

Bob
Jan 10 '07 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

3
6549
by: Sean Berry | last post by:
Hi there. I am relativly new to Python CGI and need a question answered. I have made custom 404 error pages and have them in various web directories. I have not been able to figure out a way to have apache use a file not within it's own home directory, so I was going to have a .py file in cgi-bin forward the user on to the correct error page.
7
5082
by: Sherry Littletree | last post by:
Hi All I am working on a site that has a large amount of common html on all its web pages. I am looking for a way to place this in a single file so, if changes are made, I can change this single file and do not have to change each and every page. I have the Java scripting in a common .Js file but have not been able to find a way to do this with my html content.
5
4783
by: Glenn Mulno | last post by:
Hi, I am trying to create a report page for several teams. Each team runs the same reports but the reports use different values. For a while this was getting insane everytime I updated the queries I had to change them in many places. Then I started using server side includes to keep me from changing some items in multiple places. There is still some double (quadruple) updating going on though when I make
3
1811
by: Mutkey | last post by:
Hi; I have 2 sides of my website, which uses 2 different stylesheets.They have in common a feedback (HTML02) page. Currently I have duplicated the feedback pages in both sides of the webpage so they show the correct stylesheet for that area. But this involves double updating everytime the feedback is changed. How could I have HTML01 file pointing to the feedback (HTML02) page,
10
3171
by: EnjoyNews | last post by:
I have a php site I have an include line called "include 'Cookie.php';" In this Cookie.php file I have these codes. <?php $conn = mysql_connect("$db", "$user", "$pass"); mysql_select_db("$db"); //-------------------------------------------------------------------------- -------------
2
1090
by: Kenneth Baltrinic | last post by:
I am working on a static web site that uses server side includes. Thus the files have the .shtml extention. The IDE does not recoginzis this extention as being html and uses the generic text editor. I want it to use the html editor. How do I get this to happen? I have already modified the registry for .shtml files so that the system knows they are html/text. I just duplicated the entry for the .html extension. This did not help the...
15
1981
by: Jack | last post by:
Hi, I have a asp form where one element is a list box which lists four years starting from 2004. This list is drawn from a database table which has YearID and Year as two fields as shown below: YearID YEAR 1 2004 2 2005 3 2006 4 2007 PART OF ASP CODE IS:
4
7246
by: Ju Hui | last post by:
I wanna use urllib2 to get a page with a socks 5 proxy,who can give me a sample code ? example, the proxy server is :123.123.123.123 and the port is :1080 and the username/password is : user/pass I want to open http://www.google.com how to write this kind of script?
1
4728
by: One Lazy Russian | last post by:
Thanks in advance to anyone that can help. I created an extension for firefox that acts as a bookmarklet for Gmail, Yahoo, and all standalone clients (via the mailto function). Upon clickin on the toolbar-button it will send a user the the title and url in the subject line and body respectively. Recently, I've been bombarded with emails on adding a feature which will allow the user to send the page as it is displayed (none of the
0
10794
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10896
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10443
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9612
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7999
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5830
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
6029
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4650
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
4251
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.