• toleolu

    (@toleolu)


    Using a Weaver Child Theme, I created a page template by copying and renaming the page.php file and adding the template php code.

    I want this template to call a different header, so I copied and renamed the header.php file. I want this header.php file to call a different header image.

    I am assuming this is the code that calls the default header image based on the Word Press theme settings:

    /* ======== HEADER IMAGE ======== */
    get_template_part(‘hdr’,’image’);

    I know very little about php as you can no doubt tell, but this appears to be calling on a function of some type and it’s somewhere within that function that actually knows the location of the image to insert. So how would I modify this call the image I uploaded to the media library?

    Second question on the page template, how do I modify this code to call the header I want:

    get_header(); (I deleted the dot php stuff)

    If the header I want is header1.php, do I put it as:

    get_header(header1.php)

    We have 6 divisions within our organization, we want 6 different header images for each division home page child pages, so basically, 6 template and 6 header.php files.

    If someone has a better way of skinning this cat, I’m all ears.

    Thanks

    [No bumping, thank you.]

  • The topic ‘Template Question’ is closed to new replies.