Hi Bill

Off the top of my head I can't think of a reason why that wouldn't work,
but to my mind, relying on the server's error catching to perform
designed functionality just "feels" wrong - it feels like bad design,
and it's shifting some of your logic from the application itself to the
server software that it's running under. Just my opinion, of course, but
if it was me, I'd either -
 
- make the default CFM template strip the name of the directory out of
the url and check it against the query.

- use a url such as http://www.mycompany.com/contacts/BillHenderson ,
and put an extension-less file called "contacts" in the root. Make IIS
pass files with no extension through CF and put your logic to get the
name, check the query and re-locate, into that contacts file. I've used
this myself many times on many different webservers, with no problems.

Hope that helps!

Alistair

Alistair Davidson
Application Developer
www.smartgroups.com
Freeserve.com PLC

-----Original Message-----
From: Bill Henderson [mailto:[EMAIL PROTECTED]] 
Sent: 01 August 2002 09:05
To: CF-Talk
Subject: Can anybody see a problem with this?

Hey All - 
 
The marketing department of my company wanted to have a list of
directories with names of marketing contacts.
(http://www.mycompany.com/BillHenderson/, etc) I first set up a tool
using cfdirectory and cffile to create the directories and put the files
in them. I found that making changes to the files in the directories or
adding new directories or deleting the directories caused quite a lot of
problems, not to mention the clutter it caused in the root directory of
the site, so I came up with this idea, that does not actually use any
custom directories at all, and I want to know if anybody can see
possible security problems, server resource issues, etc.
 
1. The user enters the URL in browser with custom directory at the end 
 
2. IIS catches the 404 error and uses a custom cfm template 
 
3. The cfm template pulls the directory out of the url and checks it
against a list of names from a cached query 
 
4. If it find a match, it cf_locations to a template with custom content
for the marketing contact 
 
5. If no match is found, it cf_locations to the standard 404b.htm from
IIS.
 
Any insight would be appreciated.
 
Bill Henderson
[EMAIL PROTECTED]
 



______________________________________________________________________
Your ad could be here. Monies from ads go to support these lists and provide more 
resources for the community. http://www.fusionauthority.com/ads.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to