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 can i handle url

how can i handle url

Scheduled Pinned Locked Moved ASP.NET
questiondatabasegame-devhelp
4 Posts 2 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.
  • H Offline
    H Offline
    hi_everybody
    wrote on last edited by
    #1

    hiii, i am first time working on master pages. there is problem related url. my folder structure is game(main folder in game) -search(sub folder) in search folder -cricket(in cricket folder)-cricket.aspx -hocky(folder in this)-hocky.aspx now when user login into the website (he has permission to search only) it shows links as, home|cricket|hocky when he click on cricket it should shows the cricket.aspx page when click on hocky it should shows hocky.aspx. but problem is that,when i click on cricket link it shows criket.aspx(and url is localhost/game/search/cricket/cricket.aspx) but after then i click on hocky link when im in cricket.aspx page it will shows the url like this, localhost/game/search/cricket/search/hocky/hocky.aspx which is wrong url the url should be localhost/game/search/hocky/hocky.aspx please, tell me how can i handle this problem? the links path i have used are taken form database and directly assigned by using href to the text(i.e. to the link name)

    N 1 Reply Last reply
    0
    • H hi_everybody

      hiii, i am first time working on master pages. there is problem related url. my folder structure is game(main folder in game) -search(sub folder) in search folder -cricket(in cricket folder)-cricket.aspx -hocky(folder in this)-hocky.aspx now when user login into the website (he has permission to search only) it shows links as, home|cricket|hocky when he click on cricket it should shows the cricket.aspx page when click on hocky it should shows hocky.aspx. but problem is that,when i click on cricket link it shows criket.aspx(and url is localhost/game/search/cricket/cricket.aspx) but after then i click on hocky link when im in cricket.aspx page it will shows the url like this, localhost/game/search/cricket/search/hocky/hocky.aspx which is wrong url the url should be localhost/game/search/hocky/hocky.aspx please, tell me how can i handle this problem? the links path i have used are taken form database and directly assigned by using href to the text(i.e. to the link name)

      N Offline
      N Offline
      Not Active
      wrote on last edited by
      #2

      It would be helpful to show the actual code you are using to assign the urls. What does the database results look like? Assuming you are using HyperLink controls, link.NavigationUrl = "Search/Cricket.aspx";


      I know the language. I've read a book. - _Madmatt

      H 1 Reply Last reply
      0
      • N Not Active

        It would be helpful to show the actual code you are using to assign the urls. What does the database results look like? Assuming you are using HyperLink controls, link.NavigationUrl = "Search/Cricket.aspx";


        I know the language. I've read a book. - _Madmatt

        H Offline
        H Offline
        hi_everybody
        wrote on last edited by
        #3

        hi, actualy im giving an example of game, <code>Private Sub fillArrFrmLC(ByVal strTmpForMnuArr(,) As String, ByVal intcode As Integer, ByVal intModuleCode As Integer) Dim tmpArr() As String = New String() {}, intCnt As Integer, intIndex As Integer Dim intLen As Integer = strTmpForMnuArr.GetUpperBound(1) If intLen >= 0 Then If intModuleCode = 2 Then For intIndex = 0 To intLen strTmpForSubMnuArr = objClsGlob.fillSubList(strTmpForMnuArr(0, intIndex), "subMnuForSearch", intcode) Dim intLen1 As Integer = strTmpForSubMnuArr.GetUpperBound(1) If intLen1 >= 0 Then tmpArr = Split(strTmpForSubMnuArr(1, 0), ",") 'fillArrFrmLC(, , ) ReDim Preserve arrLinkNames(arrLinkNames.Length) ReDim Preserve arrCodes(arrCodes.Length) ReDim Preserve arrLinks(arrLinks.Length) arrLinkNames(arrLinkNames.Length - 1) = strTmpForMnuArr(1, intIndex) arrLinks(arrLinks.Length - 1) = tmpArr(1) arrCodes(arrCodes.Length - 1) = strTmpForMnuArr(0, intIndex) End If Next Else For intIndex = 0 To intLen strTmpForSubMnuArr = objClsGlob.fillSubList(strTmpForMnuArr(0, intIndex), "subMnu", intcode) Dim intLen1 As Integer = strTmpForSubMnuArr.GetUpperBound(1) If intLen1 >= 0 Then For intCnt = 0 To intLen1 tmpArr = Split(strTmpForSubMnuArr(1, intCnt), ",") ReDim Preserve arrLinkNames(arrLinkNames.Length) ReDim Preserve arrCodes(arrCodes.Length) ReDim Preserve arrLinks(arrLinks.Length) arrLinkNames(arrLinkNames.Length - 1) = tmpArr(0) arrLinks(arrLinks.Length - 1) = tmpArr(1) arrCodes(arrCodes.Length - 1) = strTmpForSubMnuArr(0, intCnt) Next End If Next End If End If End Sub Private Function getModules() As String(,) 'Dim intCode As Integer = Session("currUsr") Dim strTmpArr(,) As String = New String(,) {} strTmpArr = objClsGlob.fillSubList(intCode

        N 1 Reply Last reply
        0
        • H hi_everybody

          hi, actualy im giving an example of game, <code>Private Sub fillArrFrmLC(ByVal strTmpForMnuArr(,) As String, ByVal intcode As Integer, ByVal intModuleCode As Integer) Dim tmpArr() As String = New String() {}, intCnt As Integer, intIndex As Integer Dim intLen As Integer = strTmpForMnuArr.GetUpperBound(1) If intLen >= 0 Then If intModuleCode = 2 Then For intIndex = 0 To intLen strTmpForSubMnuArr = objClsGlob.fillSubList(strTmpForMnuArr(0, intIndex), "subMnuForSearch", intcode) Dim intLen1 As Integer = strTmpForSubMnuArr.GetUpperBound(1) If intLen1 >= 0 Then tmpArr = Split(strTmpForSubMnuArr(1, 0), ",") 'fillArrFrmLC(, , ) ReDim Preserve arrLinkNames(arrLinkNames.Length) ReDim Preserve arrCodes(arrCodes.Length) ReDim Preserve arrLinks(arrLinks.Length) arrLinkNames(arrLinkNames.Length - 1) = strTmpForMnuArr(1, intIndex) arrLinks(arrLinks.Length - 1) = tmpArr(1) arrCodes(arrCodes.Length - 1) = strTmpForMnuArr(0, intIndex) End If Next Else For intIndex = 0 To intLen strTmpForSubMnuArr = objClsGlob.fillSubList(strTmpForMnuArr(0, intIndex), "subMnu", intcode) Dim intLen1 As Integer = strTmpForSubMnuArr.GetUpperBound(1) If intLen1 >= 0 Then For intCnt = 0 To intLen1 tmpArr = Split(strTmpForSubMnuArr(1, intCnt), ",") ReDim Preserve arrLinkNames(arrLinkNames.Length) ReDim Preserve arrCodes(arrCodes.Length) ReDim Preserve arrLinks(arrLinks.Length) arrLinkNames(arrLinkNames.Length - 1) = tmpArr(0) arrLinks(arrLinks.Length - 1) = tmpArr(1) arrCodes(arrCodes.Length - 1) = strTmpForSubMnuArr(0, intCnt) Next End If Next End If End If End Sub Private Function getModules() As String(,) 'Dim intCode As Integer = Session("currUsr") Dim strTmpArr(,) As String = New String(,) {} strTmpArr = objClsGlob.fillSubList(intCode

          N Offline
          N Offline
          Not Active
          wrote on last edited by
          #4

          Useless crap!!! Learn how to format the code before posting again.:mad:


          I know the language. I've read a book. - _Madmatt

          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