Ergebnis 1 bis 5 von 5

Thema: Hilfe bei Baummenue

  1. #1
    story300
    Gast

    Standard Hilfe bei Baummenue

    Hallo zusammen.
    Ich habe ein Script für ein Baummenue auf folgender Seite gefunden.


    http://www.dhtml-now.de/dhtml_script...FC&script=Baum

    Habe es auch schon für meine Bedürfnisse angepasst.. leider komme ich an einer Stelle nicht weiter.

    Die Links im menue ohne Ordner kann ich im anderen Frame anzeigen lassen, das ist ja recht einfach.
    Nur die Links welche aus einem Ordner oderunterordner heraus aufgerufen werden, die öffnen sich im selben Frame wie das Menue und ich komme hier nicht weiter.

    Kann von Euch jemand Helfen.
    Danke
    Gruß André
    Achtung: Dies ist ein alter Thread im HTML und Webmaster Forum
    Diese Diskussion ist älter als 90 Tage. Die darin enthaltenen Informationen sind möglicherweise nicht mehr aktuell. Erstelle bitte zu deiner Frage ein neues Thema im Forum !!!!!

  2. #2
    Kaiser(in)
    Registriert seit
    09.12.2005
    Alter
    29
    Beiträge
    2.496
    Danke
    1
    Bekam 0 mal "Danke" in 0 Postings

    Standard

    ich glaube frameübergreifend geht sowas nicht
    --> tabellen oder css
    Sei immer du selbst. Außer du kannst Batman sein. Sei immer Batman!

  3. #3
    Meister(in)
    Registriert seit
    20.10.2005
    Beiträge
    460
    Danke
    0
    Bekam 0 mal "Danke" in 0 Postings

    Standard

    es geht bei ihm ja auch bei den anderen links...
    musst halt target="mainframe" noch hinzufügen weiss aber nich wo weil ichs nich angekuckt hab
    mfG Sleeme


  4. #4
    story300
    Gast

    Standard

    moin zusammen...
    ich lege mal den quelltext hier rein.. vielleicht könnt ihr mir dann helfen.
    ------------------------------------------------------------------------------

    Code:
    <html>
    <head>
    
    <style type="text/css">
    <!--
    
        A
        &#123;
            font-family&#58; Tahoma, Arial, Helvetica, Sans-Serif;
            font-size&#58; 80%;
            text-decoration&#58; none;
        &#125;
    
        DIV.Tree
        &#123;
            position&#58; absolute;
            left&#58; 0px;
            top&#58; 10px;
        &#125;
    
        DIV.TreeNode
        &#123;
            padding-left&#58; 20px;
        &#125;
    
        TD.TreeNode
        &#123;
            padding-left&#58; 5px;
            padding-right&#58; 5px;
            padding-top&#58; 2px;
            padding-bottom&#58; 2px;
        &#125;
    
        A.Tree&#58;link, A.Tree&#58;visited
        &#123;
            color&#58; #000080;
            text-decoration&#58; none;
        &#125;
    
        A.TreeOpenedNode&#58;link, A.TreeOpenedNode&#58;visited
        &#123;
            color&#58; #000080;
            text-decoration&#58; none;
        &#125;
    
        A.TreeClosedNode&#58;link, A.TreeClosedNode&#58;visited
        &#123;
            color&#58; #000080;
            text-decoration&#58; none;
        &#125;
    
    //-->
    </style>
    
    <script language="JavaScript" type="text/javascript" src="hover.js">
    </script>
    
    <script language="JavaScript" type="text/javascript" src="bibliothek.js">
    </script>
    
    <script language="JavaScript" type="text/javascript">
    <!--
    
        /** default icon for a leaf &#40;node with no child&#41; */
        var defaultLeafIcon = 'leaf.gif';
        /** default icon for a opened node with at least one child */
        var defaultOpenedNodeIcon = 'opened_node.gif';
        /** default icon for a closed node with at least one child */
        var defaultClosedNodeIcon = 'closed_node.gif';
    
        /**
         * Creates a new tree.
         */
        function Tree&#40;&#41;
        &#123;
            this.m_Children = new Array&#40;&#41;;
            this.m_HoveredLinks = new Array&#40;&#41;;
    
            this.appendChild = Tree_appendChild;
            this.create = Tree_create;
            this.addHoveredLink = Tree_addHoveredLink;
            this.createHoveredLinks = Tree_createHoveredLinks;
        &#125;
    
        /**
         * Adds a hovered link.
         * @param hoveredLink the hovered link
         */
        function Tree_addHoveredLink&#40; hoveredLink &#41;
        &#123;
            this.m_HoveredLinks&#91;this.m_HoveredLinks.length&#93; = hoveredLink;
        &#125;
    
        /**
         * Creates the hovered links.
         */
        function Tree_createHoveredLinks&#40;&#41;
        &#123;
            var i;
            for &#40; i=0; i < this.m_HoveredLinks.length; i++ &#41;
            &#123;
                this.m_HoveredLinks&#91;i&#93;.create&#40;&#41;;
            &#125;
        &#125;
    
        /**
         * Appends a tree node to the tree.
         * @param node the tree node
         */
        function Tree_appendChild&#40; node &#41;
        &#123;
            this.m_Children&#91;this.m_Children.length&#93; = node;
            node.setTree&#40; this &#41;;
        &#125;
    
        /**
         * Creates and shows the tree.
         */
        function Tree_create&#40;&#41;
        &#123;
            var i;
    
            var panel = document.createElement&#40; 'DIV' &#41;;
            panel.className = 'Tree';
    
            for &#40; i=0; i < this.m_Children.length; i++ &#41;
            &#123;
                panel.appendChild&#40; this.m_Children&#91;i&#93;.create&#40;&#41; &#41;;
            &#125;
    
            document.body.appendChild&#40; panel &#41;;
    
            this.createHoveredLinks&#40;&#41;;
        &#125;
    
        /**
         * Creates a new tree node for the tree.
         */
        function TreeNode&#40;&#41;
        &#123;
            this.m_Panel = null;
            this.m_Icon = null;
            this.m_Link = null;
    
            this.m_Url = '#';
            this.m_Target = '';
            this.m_Text = '';
            this.m_LeafIcon = defaultLeafIcon;
            this.m_OpenedIcon = defaultOpenedNodeIcon;
            this.m_ClosedIcon = defaultClosedNodeIcon;
            this.m_Children = new Array&#40;&#41;;
            this.m_IsLeaf = true;
            this.m_IsOpened = false;
            this.m_Tree = null;
    
            this.setUrl = TreeNode_setUrl;
            this.setTarget = TreeNode_setTarget;
            this.setText = TreeNode_setText;
            this.setIcon = TreeNode_setIcon;
            this.setLeafIcon = TreeNode_setLeafIcon;
            this.setOpenedIcon = TreeNode_setOpenedIcon;
            this.setClosedIcon = TreeNode_setClosedIcon;
            this.setOpened = TreeNode_setOpened;
            this.isOpened = TreeNode_isOpened;
            this.getPanel = TreeNode_getPanel;
            this.setTree = TreeNode_setTree;
            this.getTree = TreeNode_getTree;
            this.getLink = TreeNode_getLink;
            this.appendChild = TreeNode_appendChild;
            this.create = TreeNode_create;
            this.createIcon = TreeNode_createIcon;
            this.createLink = TreeNode_createLink;
            this.openOrClose = TreeNode_openOrClose;
        &#125;
    
        /**
         * Sets the url for the tree node. Used in <a href
         * @param url the url
         */
        function TreeNode_setUrl&#40; url &#41;
        &#123;
            this.m_Url = url;
        &#125;
    
        /**
         * Sets the target frame for the tree node.
         * @param target the target frame
         */
        function TreeNode_setTarget&#40; target &#41;
        &#123;
            this.m_Target = target;
        &#125;
    
        /**
         * Sets the tree node text.
         * @param text the text
         */
        function TreeNode_setText&#40; text &#41;
        &#123;
            this.m_Text = text;
        &#125;
    
        /**
         * Sets the leaf, opened and closed icon.
         * @param icon the icon
         */
        function TreeNode_setIcon&#40; icon &#41;
        &#123;
            this.m_LeafIcon = icon;
            this.m_OpenedIcon = icon;
            this.m_ClosedIcon = icon;
        &#125;
    
        /**
         * Sets the leaf icon.
         * @param icon the leaf icon
         */
        function TreeNode_setLeafIcon&#40; icon &#41;
        &#123;
            this.m_LeafIcon = icon;
        &#125;
    
        /**
         * Sets the opened icon.
         * @param icon the icon
         */
        function TreeNode_setOpenedIcon&#40; icon &#41;
        &#123;
            this.m_OpenedIcon = icon;
        &#125;
    
        /**
         * Sets the closed icon.
         * @param icon the icon
         */
        function TreeNode_setClosedIcon&#40; icon &#41;
        &#123;
            this.m_ClosedIcon = icon;
        &#125;
    
        /**
         * Sets if a tree node is opened.
         * @param opened true, if the tree node is opened
         */
        function TreeNode_setOpened&#40; opened &#41;
        &#123;
            this.m_IsOpened = opened;
        &#125;
    
        /**
         * Returns if the tree node is opened.
         * @return true, if the tree node is opened.
         */
        function TreeNode_isOpened&#40;&#41;
        &#123;
            return this.m_IsOpened;
        &#125;
    
        /**
         * Returns the html panel of the tree node.
         * @return the panel
         */
        function TreeNode_getPanel&#40;&#41;
        &#123;
            return this.m_Panel;
        &#125;
    
        /**
         * Sets the parent tree.
         * @param tree the parent tree
         */
        function TreeNode_setTree&#40; tree &#41;
        &#123;
            this.m_Tree = tree;
        &#125;
    
        /**
         * Returns the parent tree.
         * @return the parent tree
         */
        function TreeNode_getTree&#40;&#41;
        &#123;
            return this.m_Tree;
        &#125;
    
        /**
         * Returns the link.
         * @return the link
         */
        function TreeNode_getLink&#40;&#41;
        &#123;
            return this.m_Link;
        &#125;
    
        /**
         * Appends a tree node to the current node, current node is no more a leaf.
         * @param node the tree node
         */
        function TreeNode_appendChild&#40; node &#41;
        &#123;
            this.m_Children&#91;this.m_Children.length&#93; = node;
            node.setTree&#40; this.getTree&#40;&#41; &#41;;
            this.m_IsLeaf = false;
        &#125;
    
        /**
         * Creates the tree node.
         * @return the tree node html element
         */
        function TreeNode_create&#40;&#41;
        &#123;
            this.m_Panel = document.createElement&#40; 'DIV' &#41;;
            this.m_Panel.className = 'TreeNode';
            var table = document.createElement&#40; 'TABLE' &#41;;
            table.className = 'TreeNode';
            table.cellPadding = '0';
            table.cellSpacing = '0';
    
            var row = table.insertRow&#40; table.rows.length &#41;;
            row.className = 'TreeNode';
    
            var cell = row.insertCell&#40; row.cells.length &#41;;
            cell.className = 'TreeNode';
            this.m_Icon = this.createIcon&#40;&#41;;
            cell.appendChild&#40; this.m_Icon &#41;;
    
            cell = row.insertCell&#40; row.cells.length &#41;;
            cell.className = 'TreeNode';
            this.m_Link = this.createLink&#40;&#41;;
            cell.appendChild&#40; this.m_Link &#41;;
    
            this.m_Panel.appendChild&#40; table &#41;;
    
            if &#40; this.isOpened&#40;&#41; &#41;
            &#123;
                for &#40; i=0; i < this.m_Children.length; i++ &#41;
                &#123;
                    this.m_Panel.appendChild&#40; this.m_Children&#91;i&#93;.create&#40;&#41; &#41;;
                &#125;
            &#125;
    
            return this.m_Panel;
        &#125;
    
        /**
         * Creates an icon for the tree node.
         * @return the icon html element
         */
        function TreeNode_createIcon&#40;&#41;
        &#123;
            var icon = document.createElement&#40; 'IMG' &#41;;
            if &#40; this.m_IsLeaf &#41;
            &#123;
                icon.src = this.m_LeafIcon;
            &#125;
            else if &#40; !this.m_IsLeaf && this.m_IsOpened &#41;
            &#123;
                icon.src = this.m_OpenedIcon;
            &#125;
            else if &#40; !this.m_IsLeaf && !this.m_IsOpened &#41;
            &#123;
                icon.src = this.m_ClosedIcon;
            &#125;
    
            return icon;
        &#125;
    
        /**
         * Creates a link for the tree node.
         * @return the link html element
         */
        function TreeNode_createLink&#40;&#41;
        &#123;
            var link = document.createElement&#40; 'A' &#41;;
            link.href = this.m_Url;
            link.target = this.m_Target;
            link.treeNode = this;
    
            if &#40; this.m_IsLeaf &#41;
            &#123;
                link.className = 'TreeLeaf';
            &#125;
            else if &#40; !this.m_IsLeaf && this.m_IsOpened &#41;
            &#123;
                link.className = 'TreeOpenedNode';
            &#125;
            else if &#40; !this.m_IsLeaf && !this.m_IsOpened &#41;
            &#123;
                link.className = 'TreeClosedNode';
            &#125;
    
            if &#40; !this.m_IsLeaf &#41;
            &#123;
                link.onclick = function&#40;&#41; &#123; this.treeNode.openOrClose&#40;&#41;; &#125;;
            &#125;
            link.onfocus = function&#40;&#41; &#123; this.blur&#40;&#41;; &#125;;
    
            link.appendChild&#40; document.createTextNode&#40; this.m_Text &#41; &#41;;
    
            return link;
        &#125;
    
        /**
         * Open a menu.
         */
        function TreeNode_openOrClose&#40;&#41;
        &#123;
            if &#40; this.m_IsOpened &#41;
            &#123;
                var i;
                for &#40; i=0; i < this.m_Children.length; i++ &#41;
                &#123;
                    this.m_Panel.removeChild&#40; this.m_Children&#91;i&#93;.getPanel&#40;&#41; &#41;;
                    document.body.removeChild&#40; this.m_Children&#91;i&#93;.getLink&#40;&#41;.hoverContainer &#41;;
                &#125;
                this.setOpened&#40; false &#41;;
                this.m_Icon.src = this.m_ClosedIcon;
            &#125;
            else
            &#123;
                var i;
                for &#40; i=0; i < this.m_Children.length; i++ &#41;
                &#123;
                    this.m_Panel.appendChild&#40; this.m_Children&#91;i&#93;.create&#40;&#41; &#41;;
                &#125;
                this.setOpened&#40; true &#41;;
                this.m_Icon.src = this.m_OpenedIcon;
            &#125;
    
            this.getTree&#40;&#41;.createHoveredLinks&#40;&#41;;
        &#125;
    //-->
    </script>
    
    <script language="JavaScript" type="text/javascript">
    <!--
    window.tree = new Tree&#40;&#41;;
    
    var node = new TreeNode&#40;&#41;;
    node.setUrl&#40; 'eins.html' &#41;;
    node.setTarget&#40; '_blank' &#41;;
    node.setText&#40; 'Erster Link' &#41;;
    tree.appendChild&#40; node &#41;;
    
    node = new TreeNode&#40;&#41;;
    node.setText&#40; 'Erster Ordner' &#41;;
    tree.appendChild&#40; node &#41;;
    
    var child = new TreeNode&#40;&#41;;
    child.setUrl&#40; 'zwei.html' &#41;;
    child.setText&#40; 'Zweiter Link' &#41;;
    node.appendChild&#40; child &#41;;
    
    var subnode = new TreeNode&#40;&#41;;
    subnode.setText&#40; 'Erster Unterordner' &#41;;
    
    child = new TreeNode&#40;&#41;;
    child.setUrl&#40; 'unter.html' &#41;;
    child.setText&#40; 'Neuer Link' &#41;;
    subnode.appendChild&#40; child &#41;;
    
    node.appendChild&#40; subnode &#41;;
    
    child = new TreeNode&#40;&#41;;
    child.setUrl&#40; 'drei.html' &#41;;
    child.setText&#40; 'Dritter Link' &#41;;
    node.appendChild&#40; child &#41;;
    
    node = new TreeNode&#40;&#41;;
    node.setText&#40; 'Zweiter Ordner' &#41;;
    tree.appendChild&#40; node &#41;;
    
    child = new TreeNode&#40;&#41;;
    child.setUrl&#40; 'vier.html' &#41;;
    child.setText&#40; 'Vierter Link' &#41;;
    node.appendChild&#40; child &#41;;
    
    window.treeHoveredLink = new HoveredLink&#40; 'TABLE', 'TreeNode' &#41;;
    window.treeHoveredLink.setColor&#40; '#404040' &#41;;
    window.treeHoveredLink.setBackgroundColor&#40; '#E0E0E0' &#41;;
    tree.addHoveredLink&#40; window.treeHoveredLink &#41;;
    
    window.onload = function&#40;&#41;
    &#123;
        window.tree.create&#40;&#41;;
    &#125;
    //-->
    </script>
    
    </head>
    <body>
    
    </body>
    </html>
    --------------------------------------------------------------------------------
    danke im voraus

    gruß andré

  5. #5
    tested
    Gast

    Standard Baummenü

    bei den child-node folgendes einfügen:

    child.setTarget( '<fenstername>' );

    evtl. mit:

    parent.frames[x].name

    den Fensternamen ermitteln

Ähnliche Themen

  1. BIITE HILFE - MORGEN KLAUSUR - BITTE HILFE
    Von unbekannt im Forum Off Topic und Quasselbox
    Antworten: 0
    Letzter Beitrag: 06.03.2008, 21:10
  2. hilfe bei daemon tools! ich brauch hilfe bei den images
    Von im Forum Computer - Internet Forum
    Antworten: 7
    Letzter Beitrag: 10.10.2007, 11:16
  3. Hilfe webspace speicher voll brauche dringend hilfe
    Von Claudi im Forum HTML & CSS Forum
    Antworten: 1
    Letzter Beitrag: 21.03.2006, 10:29
  4. Hilfe ich brauche hilfe wer kennt sich bei beepworld aus ???
    Von TheGodGame im Forum HTML & CSS Forum
    Antworten: 2
    Letzter Beitrag: 03.02.2005, 10:09
  5. HILFE brauche dringend Hilfe bei meiner Formular Abfrage
    Von Traction1977 im Forum PHP Forum - Apache - CGI - Perl - JavaScript und Co.
    Antworten: 1
    Letzter Beitrag: 28.04.2004, 11:43

Stichworte

Berechtigungen

  • Neue Themen erstellen: Nein
  • Themen beantworten: Nein
  • Anhänge hochladen: Nein
  • Beiträge bearbeiten: Nein
  •