You can also get insanely clever with VirtualPathProvider. I'm
currently writing a blog engine with this (got to while away the hours
somehow) and it means I can do highly hackable URLS like:
/index
/index/2006
/index/2006/oct.rss
/posts/TitleOfPost
/posts/TitleOfPost.json
/posts/TitleOfPost/comments.rss(0,92)
/tag/SomeTag/
/tag/SomeTag/MicroSummary.atom
where the files referenced by those URLs don't exist, the
VirtualPathProvider can parse the URL and return an appropriate
VirtualFile.
In your case I think you could create VirtualPathProvider to do the
following:
is the URL in the pages directory?
no -Pass it back to the default handler
yes ->
does the URL contain .aspx?
yes -pass it back to the default handler
no -pass url+".aspx" back to the default handler
There's a fairly relevant link here
[
http://blogs.msdn.com/davidebb/archi...provider.aspx]
Let me know how you get on if you go down the VPP route, 'cos I'm
curious.
Cowboy (Gregory A. Beamer) wrote:
http://www.fawcette.com/vsm/2002_02/...ne/columns/qa/
--
Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA
http://gregorybeamer.spaces.live.com
*************************************************
Think outside of the box!
*************************************************
"rapiddata" <ra*******@discussions.microsoft.comwrote in message
news:B5**********************************@microsof t.com...
Is there a way to rewrite urls that have no extensions in the url, i.e. no
.aspx or no .html
like
http://www.mywebsite.com/username
to be rewritten as
http://www.mywebsite.com/pages/username.aspx
This is currently done in myspace.com where you can type
http://www.myspace.com/username
So far I have not found a solution to this problem.
When I go to IIS Management Console and try to do the
configuration extension mapping, it does not allow me to enter
.* or no extension for the mapping to the asp.net dll
Any help is greatly appreciated.
Thanks,
Leo
201-923-9595