Forum Replies Created

Viewing 12 replies - 1 through 12 (of 12 total)
  • Thread Starter ibu

    (@ibu)

    Any help would be appreciate. Thank you.

    Hi there!

    If you don’t have firebug installed, you should definitely do so. It can shed light on all of these css issues for you by giving you the location of the css file associated with a particular piece of html. It’ll even tell you the line of the css document that you need to look in.

    There are a couple of issues at hand here. First, the css you’re trying to write at top is incorrect. But we’ll address that in a second. Firs you need to locate where the CSS file with the correct body declaration is located. Here is where you can find it:

    http://www.hdolsen.com/wp-content/themes/bueno/styles/default.css

    on Line 11, find:

    body {
     background: url("default/bodytile.jpg")
    }

    The url() is where the background image is located. To remove it and change it to a white background, simply make it:

    background: #fff;

    Hope this helps!

    Thread Starter ibu

    (@ibu)

    Thank you so much for your help MichaelH. I hope our discourse here can help other people in the future.

    Thread Starter ibu

    (@ibu)

    MichaelH yours works swimmingly.

    Here is the fix I came up with based on this post:

    <?php global $post; $thispage = $post->ID; // grabs the current post id from global and then assigns it to thispage ?>
            <?php $pagekids = get_pages("child_of=".$thispage."&sort_column=menu_order"); // gets a list of page that are sub pages of the current page and assigns then to pagekids ?>
            <?php if ($pagekids) { // if there are any values stored in pagekids and therefore the current page has subpages ?>
            	<ul>
            		<?php wp_list_pages("depth=1&title_li=&sort_column=menu_order&child_of=".$thispage); // display the sub pages of the current page only ?>
                </ul>
            <?php } else { // if there are no sub pages for the current page ?>
            	<ul>
            		<?php echo wp_list_pages('title_li=&child_of='.$post->post_parent.'&echo=0'); ?>
                </ul>
    
            <?php } ?>
    Thread Starter ibu

    (@ibu)

    Haha Michael I stumbled upon a solution as soon as you posted yours! I’m going to test yours as well to see if we both are viable solutions in case someone else can benefit.

    Thread Starter ibu

    (@ibu)

    MichaelH,

    First off, thank you for your help. Unfortunately the output on the partner profile pages is the same as the example code from that you linked to. It’s possible I’ve made a mistake, so here’s the code I’m using:

    <?php
    $partner_id = 26; // "partner" page id = 26
    if($post->post_parent && $post->parent != $partner_id)
      $children = wp_list_pages("&title_li=&child_of=".$post->post_parent."&echo=0");
      else
      $children = wp_list_pages("title_li=&child_of=".$post->ID."&echo=0");
      if ($children) { ?>
      <ul>
      <?php echo $children; ?>
      </ul>
    <?php } ?>

    And here are example pages: Cindy’s top level profile page Cindy’s admissions page.

    Thread Starter ibu

    (@ibu)

    I think I need to test for something other than post_parent.

    I could do something like:

    <?php
      if($post->is_page('42,23,44,11'))
      $children = wp_list_pages('title_li=&child_of='.$post->ID.'&echo=0');
      if ($children) { ?>
      <ul>
      <?php echo $children; ?>
      </ul>
     <?php } ?

    But I’d like to keep things dynamic so if they have to add a page later they won’t have to have us do it for them. Am I on the wrong track?

    Thread Starter ibu

    (@ibu)

    Wow that made absolutely no sense.

    Both of the pages are CHILDREN is what I meant, so they display the information of their parent.

    Thread Starter ibu

    (@ibu)

    I thought so too but that doesn’t work because it displays the sub pages of the parent. Because of the page hierarchy, the pages are both parents, so you get a top level menu when looking at a person’s profile. When you click on the sub, sub menu items, the correct information is displayed but if you are on the top level profile page for someone, it’s sub pages are displayed.

    Thread Starter ibu

    (@ibu)

    Quick bump in case anyone has time to reply today.

    Thread Starter ibu

    (@ibu)

    I should also mention that I’ve read the wp_list_pages codex page and tried to work with the examples to no avail. If the answer is there I missed it due to a low understanding of php and not for a lack of effort, haha.

    Thread Starter ibu

    (@ibu)

    I lied, The Example Page Hierarchy is this:

    • Our People
    • Partners
    • Michael McConnell
    • Areas of Practice
    • Education
    • Awards
    • Etc
Viewing 12 replies - 1 through 12 (of 12 total)