Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. How to Change url Navigation address

How to Change url Navigation address

Scheduled Pinned Locked Moved ASP.NET
8 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • P Offline
    P Offline
    ParagGupta
    wrote on last edited by
    #1

    Hi, I would like to know how to perform following action. In our website there is a page as "www.websitename.com/temp/default.aspx" Now in case user put "www.websitename.com/temp" or "www.websitename.com/temp/" in address bar then we would like to navigate it to our page "www.websitename.com/temp/default.aspx". I have tried url rewriting under application_beginrequest event in global.ascx but when it is not working. How can it be done? Please help... Regards, PG

    C 1 Reply Last reply
    0
    • P ParagGupta

      Hi, I would like to know how to perform following action. In our website there is a page as "www.websitename.com/temp/default.aspx" Now in case user put "www.websitename.com/temp" or "www.websitename.com/temp/" in address bar then we would like to navigate it to our page "www.websitename.com/temp/default.aspx". I have tried url rewriting under application_beginrequest event in global.ascx but when it is not working. How can it be done? Please help... Regards, PG

      C Offline
      C Offline
      Christian Graus
      wrote on last edited by
      #2

      You configure IIS to open default.aspx as the default page. Just add it to the list.

      Christian Graus Driven to the arms of OSX by Vista. "I am new to programming world. I have been learning c# for about past four weeks. I am quite acquainted with the fundamentals of c#. Now I have to work on a project which converts given flat files to XML using the XML serialization method" - SK64 ( but the forums have stuff like this posted every day )

      P 1 Reply Last reply
      0
      • C Christian Graus

        You configure IIS to open default.aspx as the default page. Just add it to the list.

        Christian Graus Driven to the arms of OSX by Vista. "I am new to programming world. I have been learning c# for about past four weeks. I am quite acquainted with the fundamentals of c#. Now I have to work on a project which converts given flat files to XML using the XML serialization method" - SK64 ( but the forums have stuff like this posted every day )

        P Offline
        P Offline
        ParagGupta
        wrote on last edited by
        #3

        Thanks Christian for your answer but I dont think that it will help. As we already have a default page as in www.websitename.com/default.aspx is default page.... and I am talking about creating default pages at directory level As in www.websitename.com/dir1 should navigate to www.websitename.com/dir1/default1.aspx and www.websitename.com/dir2 should navigate to www.websitename.com/dir2/default1.aspx .... Regards, Parag

        C A 2 Replies Last reply
        0
        • P ParagGupta

          Thanks Christian for your answer but I dont think that it will help. As we already have a default page as in www.websitename.com/default.aspx is default page.... and I am talking about creating default pages at directory level As in www.websitename.com/dir1 should navigate to www.websitename.com/dir1/default1.aspx and www.websitename.com/dir2 should navigate to www.websitename.com/dir2/default1.aspx .... Regards, Parag

          C Offline
          C Offline
          Christian Graus
          wrote on last edited by
          #4

          OK, well, perhaps when someone makes a suggestion, you should read it. If you configure IIS correctly, it will open the default page at any level. You can put default.aspx in any folder, and it will then open if just that folder is browsed to.

          Christian Graus Driven to the arms of OSX by Vista. "I am new to programming world. I have been learning c# for about past four weeks. I am quite acquainted with the fundamentals of c#. Now I have to work on a project which converts given flat files to XML using the XML serialization method" - SK64 ( but the forums have stuff like this posted every day )

          P 1 Reply Last reply
          0
          • P ParagGupta

            Thanks Christian for your answer but I dont think that it will help. As we already have a default page as in www.websitename.com/default.aspx is default page.... and I am talking about creating default pages at directory level As in www.websitename.com/dir1 should navigate to www.websitename.com/dir1/default1.aspx and www.websitename.com/dir2 should navigate to www.websitename.com/dir2/default1.aspx .... Regards, Parag

            A Offline
            A Offline
            anilpal
            wrote on last edited by
            #5

            Hi, If u want to do this at directory level then please implement IHttpModule and the implement yr logic for rewritting the URL on BeginRequest event. Feel free to ask

            Regards Anil Pal

            1 Reply Last reply
            0
            • C Christian Graus

              OK, well, perhaps when someone makes a suggestion, you should read it. If you configure IIS correctly, it will open the default page at any level. You can put default.aspx in any folder, and it will then open if just that folder is browsed to.

              Christian Graus Driven to the arms of OSX by Vista. "I am new to programming world. I have been learning c# for about past four weeks. I am quite acquainted with the fundamentals of c#. Now I have to work on a project which converts given flat files to XML using the XML serialization method" - SK64 ( but the forums have stuff like this posted every day )

              P Offline
              P Offline
              ParagGupta
              wrote on last edited by
              #6

              Sorry but I am not aware of this feature. I am aware of creating only one default page that too through solution explorer in Visual Studio. I dont have any idea about how to create multiple default pages at different directory levels. (i.e. if I have 3 different folders then we should have 4 default pages one each for folder and one as home page for website) Can you please guide me over this. I am using IIS 5. Regards, Parag

              C Y 2 Replies Last reply
              0
              • P ParagGupta

                Sorry but I am not aware of this feature. I am aware of creating only one default page that too through solution explorer in Visual Studio. I dont have any idea about how to create multiple default pages at different directory levels. (i.e. if I have 3 different folders then we should have 4 default pages one each for folder and one as home page for website) Can you please guide me over this. I am using IIS 5. Regards, Parag

                C Offline
                C Offline
                Christian Graus
                wrote on last edited by
                #7

                You set up the default page in IIS. It will have a list of files it will open if they are there, make sure default.aspx is amongst them.

                Christian Graus Driven to the arms of OSX by Vista. "I am new to programming world. I have been learning c# for about past four weeks. I am quite acquainted with the fundamentals of c#. Now I have to work on a project which converts given flat files to XML using the XML serialization method" - SK64 ( but the forums have stuff like this posted every day )

                1 Reply Last reply
                0
                • P ParagGupta

                  Sorry but I am not aware of this feature. I am aware of creating only one default page that too through solution explorer in Visual Studio. I dont have any idea about how to create multiple default pages at different directory levels. (i.e. if I have 3 different folders then we should have 4 default pages one each for folder and one as home page for website) Can you please guide me over this. I am using IIS 5. Regards, Parag

                  Y Offline
                  Y Offline
                  yafi
                  wrote on last edited by
                  #8

                  here you go IIS Default Page

                  1 Reply Last reply
                  0
                  Reply
                  • Reply as topic
                  Log in to reply
                  • Oldest to Newest
                  • Newest to Oldest
                  • Most Votes


                  • Login

                  • Don't have an account? Register

                  • Login or register to search.
                  • First post
                    Last post
                  0
                  • Categories
                  • Recent
                  • Tags
                  • Popular
                  • World
                  • Users
                  • Groups