Treeview linking to wrong directory

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • madankarmukta
    Contributor
    • Apr 2008
    • 308

    Treeview linking to wrong directory

    Hi All,

    In an attached the shot - Exple.jpg

    [imgnothumb]http://bytes.com/attachments/attachment/6589d1346525682/exple.jpg[/imgnothumb]

    Code:
    Node1 is referred to default1.aspx
    Node1.1 is referred to Folder1/default11.aspx
    Node1.1.1 is referred to Folder1/default111.aspx
    On mouse-Hover of the Node 1.1.1, the status bar shows http://localhost/Folder1/Folder1/default111.aspx Please note that the Node 1.1 is clicked prior to the Node 1.1.1.

    Could anyone help me to understand technical reason behind why this is happening?
    Attached Files
    Last edited by zmbd; Sep 10 '12, 06:30 PM. Reason: (Z) Added code tags (?) added url tags made image viewable.
  • madankarmukta
    Contributor
    • Apr 2008
    • 308

    #2
    Anyone, Guesses/thesis please.

    Comment

    • acoder
      Recognized Expert MVP
      • Nov 2006
      • 16032

      #3
      Without code, it'd be difficult to say.

      The problem isn't clear either. What do you expect to see?

      Comment

      • madankarmukta
        Contributor
        • Apr 2008
        • 308

        #4
        Hi,

        Thank you for the reply.

        Actually, Node 1.1.1 points to Folder1/default111.aspx page.
        Wondering, the click to Node 1.1.1. is trying to find the page at Folder1/Folder1/default111.aspx which results into an error, page not found.

        How to get rid of this error?

        Thanks.

        Comment

        • acoder
          Recognized Expert MVP
          • Nov 2006
          • 16032

          #5
          You need to link to the page "default111.asp x" without the folder name. Not sure what this has to do with JavaScript.

          Comment

          • madankarmukta
            Contributor
            • Apr 2008
            • 308

            #6
            A part of nutshell, this is the tree view built via java script.

            Comment

            • madankarmukta
              Contributor
              • Apr 2008
              • 308

              #7
              @acoder,

              Thank you for the reply.
              Even accosting the link to the page name w/o the folder path, doesn't solve the problem.

              Anyone, Guesses/thesis please.

              Thank you.

              Comment

              • Rabbit
                Recognized Expert MVP
                • Jan 2007
                • 12517

                #8
                As was said before, it's hard to tell what's wrong without seeing the code.

                Comment

                • madankarmukta
                  Contributor
                  • Apr 2008
                  • 308

                  #9
                  Hi All,

                  Please guide to solve an incorrect linking problem.

                  Please find the attached the script.

                  Below is the Script tag in the page where the above jScript gets called.

                  Code:
                  <script type="text/javascript">
                  		
                  		d = new dTree('d');
                  
                  		d.add(0,-1,'Example');
                  		d.add(1,0,'Node 1','Default1.aspx');
                  		d.add(3,1,'Node 1.1','Folder1/Default11.aspx');
                  		d.add(5,3,'Node 1.1.1','Folder1/Default111.aspx');
                  		document.write(d);
                  
                  		
                  </script>
                  Please provide insights on why it's linking to the wrong directory.
                  Attached Files

                  Comment

                  • Rabbit
                    Recognized Expert MVP
                    • Jan 2007
                    • 12517

                    #10
                    What directory is it supposed to link to? What is it linking to instead?

                    Comment

                    • madankarmukta
                      Contributor
                      • Apr 2008
                      • 308

                      #11
                      Hi,

                      Thank you for the reply.

                      Once the leaf node of the tree is reached,all directories above in the hierarchy gets repeatedly routed to some non-usual path.

                      For e.g., as explained in the first post

                      Node1 refers to default1.aspx
                      Node1.1 refers to Folder1/default11.aspx
                      Node1.1.1 refers to Folder1/default111.aspx

                      On mouse-Hover of the Node 1.1.1, the status bar shows http://localhost/Folder1/Folder1/default111.aspx Please note that the Node 1.1 is clicked prior to the Node 1.1.1.

                      Ideally, as node 1.1.1 refers to folder1/default111.aspx the status bar should point to the path folder1/default111.aspx

                      Comment

                      • Rabbit
                        Recognized Expert MVP
                        • Jan 2007
                        • 12517

                        #12
                        So you're saying the first time you click on each one, it works correctly?

                        Comment

                        • madankarmukta
                          Contributor
                          • Apr 2008
                          • 308

                          #13
                          No, Actually Not.

                          That time too the user couldn't route to the correct path, if the user tries to navigate to the node by expanding the '+' without clicking the node.

                          Provide technical insights behind, please.

                          Comment

                          • Rabbit
                            Recognized Expert MVP
                            • Jan 2007
                            • 12517

                            #14
                            What's most likely happening is that your base folder is already http://localhost/Folder1/

                            Comment

                            • madankarmukta
                              Contributor
                              • Apr 2008
                              • 308

                              #15
                              Seems hard to infer.

                              Can that be routed dynamically... As per the user's requirement,if I understood your reply correctly.

                              If not pls correct me.
                              Last edited by madankarmukta; Feb 1 '13, 12:29 PM. Reason: Added a comment.

                              Comment

                              Working...