473,386 Members | 1,798 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

URL without extensions

Given the following URL, www.xyz.com/game, can it be
redirected to www.xyz.com/game.aspx instead? Can it be
done using asp.net if so, how?

thanks
Nov 18 '05 #1
5 1407
Do you not want the user to see game.aspx displayed in the URL bar? Just use default documents within each folder. In your example, in IIS set the default document of that game folder to game.aspx. You'll have to move game.aspx from your root folder to this game folder to do that though.

"Prince" <an*******@discussions.microsoft.com> wrote in message news:1f*****************************@phx.gbl...
Given the following URL, www.xyz.com/game, can it be
redirected to www.xyz.com/game.aspx instead? Can it be
done using asp.net if so, how?

thanks

Nov 18 '05 #2
When the user enters www.xyz.com/game, I want the URL to
automatically change to www.xyz.com/game.aspx. I just
don't want the person to have to worry about typing the
extension.
-----Original Message-----
Do you not want the user to see game.aspx displayed in the URL bar? Just use default documents within each
folder. In your example, in IIS set the default document
of that game folder to game.aspx. You'll have to move
game.aspx from your root folder to this game folder to do
that though.
"Prince" <an*******@discussions.microsoft.com> wrote in

message news:1f*****************************@phx.gbl...
Given the following URL, www.xyz.com/game, can it be
redirected to www.xyz.com/game.aspx instead? Can it be done using asp.net if so, how?

thanks

.

Nov 18 '05 #3
Prince wrote:
When the user enters www.xyz.com/game, I want the URL to
automatically change to www.xyz.com/game.aspx. I just
don't want the person to have to worry about typing the
extension.


AFAIK IIS and its ISAPI extensions (and thus ASP.NET) only work based on
extensions, not on paths.

Cheers,

--
Joerg Jooss
jo*********@gmx.net

Nov 18 '05 #4
One more advanced way to do this is to use URL rewriting. In this
approach you would map all incoming requests to ASP.NET, so even if
the user enters a URL with a path that does not exist, your code gets
to examine the path and can rewrite the internal path and point to an
ASPX page to process the request.

It's hard to explain how to do this in one newsgroup post, but there
is a good article here:

URL Rewriting in ASP.NET
http://msdn.microsoft.com/library/de...lrewriting.asp

In particular you might want to look at "Creating Hackable URLs".

HTH,

--
Scott
http://www.OdeToCode.com


On Mon, 21 Jun 2004 11:25:10 -0700, "Prince"
<an*******@discussions.microsoft.com> wrote:
Given the following URL, www.xyz.com/game, can it be
redirected to www.xyz.com/game.aspx instead? Can it be
done using asp.net if so, how?

thanks


Nov 18 '05 #5
One more advanced way to do this is to use URL rewriting. In this
approach you would map all incoming requests to ASP.NET, so even if
the user enters a URL with a path that does not exist, your code gets
to examine the path and can rewrite the internal path and point to an
ASPX page to process the request.

It's hard to explain how to do this in one newsgroup post, but there
is a good article here:

URL Rewriting in ASP.NET
http://msdn.microsoft.com/library/de...lrewriting.asp

In particular you might want to look at "Creating Hackable URLs".

HTH,

--
Scott
http://www.OdeToCode.com


On Mon, 21 Jun 2004 11:25:10 -0700, "Prince"
<an*******@discussions.microsoft.com> wrote:
Given the following URL, www.xyz.com/game, can it be
redirected to www.xyz.com/game.aspx instead? Can it be
done using asp.net if so, how?

thanks


Nov 18 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Amaury | last post by:
Hello, When debugging C extensions, I find the most difficult is to detect that an object is Py_DECREF'ed when it should not. And when you find yourself with an invalid object, it's a nightmare...
4
by: Tian | last post by:
In Windows, I have been simply using os.system() to run command line program in python. but there will be a black console window. How can I run the program without invoking that window? i guess...
4
by: Smegly | last post by:
Hi, I want to write a routine that periodically ( every t seconds) gets a value from a file and puts in into a queue. How can i implement this without getting into a busy-waiting loop . . ...
6
by: zhixin_han | last post by:
Following warnings are found in my application: ..../adm_std_mo_descr.h:240: warning: non-static const member `const struct std_tee_t std_mo::tee' in class without a constructor...
38
by: ted | last post by:
I have an old link that was widely distributed. I would now like to put a link on that old page that will go to a new page without displaying anything.
43
by: shaanxxx | last post by:
if u give cordinates to programme at run time and want a line to be drawn.. how to do this in c without usin any graphics function? like x1,y1 and x2,y2 and lines should be drawn from the 1st...
1
by: =?Utf-8?B?T2xlZw==?= | last post by:
Hi, I'm wondering if anybody using ajax extensions where UpdatePanel tag is used in addition to existing ajax implementation where UpdatePanel wasn't used yet. So, there is already a web project...
1
by: Yan | last post by:
Hi, I'm apparently far from being the 1st one to meet this error... My asp.net ajax page requires ScriptManager.axd but gets a 404. following a lot of "This is how I solved it" posts, I : -...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

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.