1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

page node and EXTRA.CSS

Discussion in 'XenForo Questions and Support' started by masterchief, Sep 13, 2011.

  1. masterchief

    masterchief Well-Known Member

    How to reference page node in EXTRA.CSS ????
     
  2. Brogan

    Brogan XenForo Moderator Staff Member

    What are you trying to do exactly?

    Do you want to include the EXTRA.css template in a page?

    Pages already load that template so you don't need to include it.
     
  3. masterchief

    masterchief Well-Known Member

    I want to eliminate breadcrumbs from a page node using EXTRA.CSS

    .SOME_PAGE_NODE .breadCrumbsTop, .breadCrumbsBottom{ display:none;}

    UPDATED:

    .SOME_PAGE_NODE .breadBoxTop, .breadBoxBottom {display: none;}
     
  4. Brogan

    Brogan XenForo Moderator Staff Member

    You can't do that with CSS.

    You need to edit the PAGE_CONTAINER template like so:

    Code:
    <xen:hook name="page_container_breadcrumb_top">
    <xen:if is="{$quickNavSelected} != 'node-x'">
    <div class="breadBoxTop">
    <xen:if is="{$topctrl}"><div class="topCtrl">{xen:raw $topctrl}</div></xen:if>
    <xen:include template="breadcrumb"><xen:set var="$microdata">1</xen:set></xen:include>
    </div>
    </xen:if>
    </xen:hook>
    Code:
    <xen:hook name="page_container_breadcrumb_bottom">
    <xen:if is="{$quickNavSelected} != 'node-x'">
    <div class="breadBoxBottom"><xen:include template="breadcrumb" /></div>
    </xen:if>
    </xen:hook>
    Change the x to the node id.
     
  5. Floris

    Floris Guest

    pagenode_container i think the template is.
    if removing breadcrumb code doens't help, try adding to the dir: style="display:none"

    If that works, find the parent contentTemplate and use that in EXTRA.css to make the exception for page nodes.
     
  6. masterchief

    masterchief Well-Known Member

    breadcrumbs for every page is removed with this in EXTRA.CSS

    Code:
    
    .breadBoxTop, .breadBoxBottom
    {
        display: none;
    }
    
    
     
  7. Floris

    Floris Guest

    Which, appears to be:

    EXTRA.css
    Code:
    .pagenode_container .breadBoxTop { display:none; }
    Which applies only to pagenode_container template, so normal pages like forums, etc it works, but it goes away when it's /pages/
     
  8. masterchief

    masterchief Well-Known Member

    that did it! thanx Floris... this is what I am now using
    ~peace

    Code:
    
    .pagenode_container .breadBoxTop, .breadBoxBottom 
    {
        display: none;
    }
    
    
     
  9. masterchief

    masterchief Well-Known Member

    there is no way to specify individual page nodes????
     
  10. Brogan

    Brogan XenForo Moderator Staff Member

  11. Floris

    Floris Guest

    Glad to hear it helped, this is how i quickly found out:
    Screen-shot-2011-09-13-at-3.25.29-PM.png
     
  12. Floris

    Floris Guest

    If the node-ID is known, which it is on a per node /pages/ page
    Then you can use id="node-idhere" in a div, to basically in css be:

    #node-idhere { background-color: red; }

    note that the ID of a node is of course changing PER forum setup, it's different for everybody - so haring your extra.css with other will give them unexpected results
     

Share This Page