Jump to content


Photo
- - - - -

Templates for different pages

template region section full width hero unit global local

Best Answer James B , 04 March 2014 - 02:19 AM

Hi,

 

That full width section has to be within the 'template' area. At the moment its above it.

 

This is where yours is currently, just above the template/local scope area - http://screencast.com/t/gycVf8g7Yu

 

Needs to be under template area, like - http://screencast.com/t/UEHsrklCe

Go to the full post


  • Please log in to reply
9 replies to this topic

#1 wesleymusgrove

wesleymusgrove

    Member

  • Members

  • 15 posts
  • Framework Version:DMS 2.1.4
  • Country: Country Flag

Posted 03 March 2014 - 07:35 PM

I'm having some issues getting 2 different templates to save their own unique and different sections, respectively.  I have one template for the "Home Page" and another template for an "About Us" page.  Both templates have the same fixed navbar, nothing in the "Header Global Scope Region", various sections and widgets in the "Template Local Scope Region", and share a footer menu in the "Footer Global Scope Region".

 

I have added a full-width section between the "Header Global Scope Region" and the "Template Local Scope Region" to the home page template in order to hold a Hero Unit.  I needed to put this hero unit inside a full-width section so it could have a full-width background color.  If I put this hero unit inside the "Template Local Scope Region", a full-width background color is not possible on the hero unit's row alone, as it will also give a full-width background color to the entire body of the "Template Local Scope Region" thereby affecting the other widgets and columns on the home page.  

 

I do not want this hero unit or the full-width section it is contained within to appear on the "About Us" template.  So back on the "Home Page" template, I only filled out the hero unit's local scope section options and left the global options blank.  This however does not prevent the hero unit full-width section from displaying on the "About Us" template.  It just displays the default hero unit's global settings.

 

How can I make the full-width section containing a hero unit only display on the "Home Page" template and not on the "About Us" template?  

 

Are all custom full-width sections forced to be globally applied to all templates?

 

It seems to me that one template's (non-global) regions and sections shouldn't be concerned with another template's (non-global) regions and sections.  Isn't that the point of having different templates so I can give sub pages a different layout from the home page?

 

Any help would be much appreciated.

 

Thanks,

Wesley



#2 James B

James B

    Advocate

  • Members

  • 5126 posts
  • LocationSurrey - UK
  • Country: Country Flag

Posted 04 March 2014 - 12:38 AM

Hi Wesley

 

To resolve the area background color issue add a new full widith section area http://screencast.com/t/1zpn22NY and then place the hero unit inside there, set the color on that full width section area and it will leave the rest of the page content area as standard.

 

It sounds like both pages are using the same template, did you create one template from the other? If so after creating it and saving did you make sure it was actually loaded on that page and saved? If you have Pro Tools installed you should see in the wp admin bar at the top which template the page is currently using, do they both state they're using different templates? The local regions shouldn't appear on other templates at all, unless its a special page like category,archive, search etc.



#3 wesleymusgrove

wesleymusgrove

    Member

  • Members

  • 15 posts
  • Framework Version:DMS 2.1.4
  • Country: Country Flag

Posted 04 March 2014 - 01:29 AM

Hi James,

 

That's precisely what I did previously to get a full-width background on the hero unit.

 

My problem is with this full-width section that's holding the hero unit.  I only added it to the home page template, but it also shows up when I load the "About" template on that page.  Also any changes I make and publish to the About template carry over to the home page template when I switch back to the home page.

 

This screen http://screencast.com/t/hsRcBivTqbQ shows my "Customhomepage" template with the hero unit as it's supposed to be.  It also shows some stuff above the hero unit that I added to the "About" template.  That text box, share box, and navbar shouldn't be a part of the "Customhomepage" template.

 

This screen http://screencast.com/t/uDPIURm9wd shows my "About" template with the hero unit that I added only to the home page template.  It's showing the default global settings, but it shouldn't even be a part of this page.  The text box, share box, and navbar are the only things that should show up.

 

Furthermore, why are both of these templates using the same full-width section?

 

Thanks,

Wesley



#4 James B

James B

    Advocate

  • Members

  • 5126 posts
  • LocationSurrey - UK
  • Country: Country Flag

Posted 04 March 2014 - 02:19 AM   Best Answer

Hi,

 

That full width section has to be within the 'template' area. At the moment its above it.

 

This is where yours is currently, just above the template/local scope area - http://screencast.com/t/gycVf8g7Yu

 

Needs to be under template area, like - http://screencast.com/t/UEHsrklCe



#5 wesleymusgrove

wesleymusgrove

    Member

  • Members

  • 15 posts
  • Framework Version:DMS 2.1.4
  • Country: Country Flag

Posted 04 March 2014 - 03:29 AM

Ah many thanks.  That did the trick.  For some reason I thought a full-width region had to be siblings with the header/template/footer scope regions, which is why I had it outside the template region.  I put it inside the template region, as you said, and now the different templates are only concerned with what's in their own respective template regions.

 

Thanks again!



#6 Danny

Danny

    Is Awesome!

  • Moderators
  • 16342 posts
  • LocationManchester, UK
  • Country: Country Flag

Posted 04 March 2014 - 10:34 AM

Thanks for informing us the issue has been resolved.



#7 circ2013

circ2013

    Member

  • Members

  • 29 posts
  • LocationColorado
  • Framework Version:DMS
  • Country: Country Flag

Posted 21 August 2014 - 08:25 PM

I think I am having a similar issue as this one, but still not getting the the content to be idependent of the template as I would like.  Here is my issue:

 

I have a template called "Products"  This template is shared between 5 different pages/products.

 

Obviously, the WP Content/Loop is unique on every page, but I would like a full width hero image to also be unique on each page (ideally controlled through the page or a widget and not through the DMS editor, but alright it that is going to be the easiest solution for now). 

 

I am trying to insert a RevSlider (but open to other suggestions on tool, widget, plugin...) on the page that will display a lifestyle image below the "Header" and above a two column layout (Col 1 = custom menu/sub nav and Col 2 = WP Content/Loop) that will be unique to the page/product.

 

For example, on the Rancher page I want a photo of a ranch and on the Beach page, it has to be a beach.

 

Today, everything I do puts the same image on all pages using this template.  I am trying to find a solution that doesn't require a unique template for every page of the site.

 

It looks like I am inserting the RevSlider in as a Local Option, but perhaps I am still doing something wrong.  I am attaching a screenshot.

 

http://www.screencast.com/t/4j3BOeNj

 

Thanks,

Scott



#8 Danny

Danny

    Is Awesome!

  • Moderators
  • 16342 posts
  • LocationManchester, UK
  • Country: Country Flag

Posted 22 August 2014 - 11:25 AM

@circ2013 - If you want to have a unique image on specific pages, then what you're going to need to do is load the template you want to use on the page, then unlink that template. Then proceed to make sure your changes, that way the changes will only be specific to that page and not effect other pages using that template.

 

https://cloudup.com/cd6ifEGUguZ



#9 circ2013

circ2013

    Member

  • Members

  • 29 posts
  • LocationColorado
  • Framework Version:DMS
  • Country: Country Flag

Posted 25 August 2014 - 11:01 PM

I knew it was going to be something easy like that.  Thank you once again.

 

Scott



#10 Danny

Danny

    Is Awesome!

  • Moderators
  • 16342 posts
  • LocationManchester, UK
  • Country: Country Flag

Posted 26 August 2014 - 10:41 AM

No problem.







Also tagged with one or more of these keywords: template, region, section, full width, hero unit, global, local