We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 25847
    • 62 Posts
    Hello,

    I am working on modifying the modxlight admin template. I modified the template so that I could put my own logo above the main navigation bar and everything works perfectly except for one thing. I cannot get the collapse/hide icon for the tree to display in the right place whenever I hide the tree. What happens, is that now that I expanded the table above the navigation bar, I pushed everything else down. However, when I click to hide the tree, the button to show the tree again pops up way to high on the page. Does anyone know how I can fix this? I have been trying to edit the style.php file in the modxlight template directory, but so far haven’t had any luck. Any help on this would be awesome!!!
      • 25847
      • 62 Posts
      Any one have any ideas on this one? Where is the location of this button defined?
        • 28042 ☆ A M B ☆
        • 24,524 Posts
        I suspect it’s in the manager/frames/tree.php file

        Yeah, line 443.
          Studying MODX in the desert - http://sottwell.com
          Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
          Join the Slack Community - http://modx.org
          • 25847
          • 62 Posts
          I actually found the style for the tree in the file:

          /manager/media/style/MODxLight/images/style.php

          with the following code:

          // Tree Menu Toolbar
          $_style["add_doc_tree"] = "<img src=\"".$style_path."images/icons/folder_page_add.png\" style=\"width:16px;height:16px\" />";
          $_style["add_weblink_tree"] = "<img src=\"".$style_path."images/icons/link_add.png\" style=\"width:16px;height:16px\" />";
          $_style["collapse_tree"] = "<img src=\"".$style_path."images/icons/arrow_up.png\" style=\"width:16px;height:16px\" />";
          $_style["empty_recycle_bin"] = "<img src=\"".$style_path."images/icons/trash_full.png\" style=\"width:16px;height:16px\" />";
          $_style["empty_recycle_bin_empty"] = "<img src=\"".$style_path."images/icons/trash.png\" style=\"width:16px;height:16px\" />";
          $_style["expand_tree"] = "<img src=\"".$style_path."images/icons/arrow_down.png\" style=\"width:16px;height:16px\" />";
          $_style["hide_tree"] = "<img src=\"".$style_path."images/icons/application_side_contract.png\" style=\"width:16px;height:16px\" />";
          $_style["refresh_tree"] = "<img src=\"".$style_path."images/icons/refresh.png\" style=\"width:16px;height:16px\" />";
          $_style["show_tree"] = $style_path."images/icons/application_side_expand.png" ;
          $_style["sort_tree"] = "<img src=\"".$style_path."images/icons/sort.png\" style=\"width:16px;height:16px\" />";


          So I tried changing the code for $_style["show_tree"] from what it was to:
          $_style["show_tree"] = "<img src=\"".$style_path."images/icons/application_side_expand.png" style=\"position:absolute;margin-top:200px;width:16px;height:16px\" />";

          to see if that would do anything. All it did was make the button not work at all to hide the tree! Once I put it back to normal again, the tree started working.

          Am I missing something here?