• 0
Sign in to follow this  
Followers 0

Header Section


Question

Posted · Report post

Hi! I recently got my site set up and it looks great on a desktop. The problem I"m having is on a mobile device. The header is not being scaled correctly (it's full size, while everything else is fit to the screen). I think the problem occurred when I added a clickable header through the header.php file. The header shows up fine on the site, but the header section is now missing from the pagelines editor. This section is also what seems to be causing the problem with the mobile view (everything else scales, but the header).  Does anyone know how to add the header section back to the site via the editor? Or is there another fix to this?

 

My site is www.deepestoceanblue.com

 

Thanks!

 

Nikki

Share this post


Link to post
Share on other sites

21 answers to this question

  • 0

Posted · Report post

Hi Nikki,

 

Unfortunately, we do not provide support to users who have made changes to the core code. These changes are the cause of your non-responsive header too.

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Hi Danny,

 

Is there a way for me to get back to the original template? I've removed the header code, changed templates, deactivated and reactivated the theme, nothing seems to work. I just want the header section back at the top so I can edit it within the pagelines editor. 

 

Thanks for your help!

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

If you have removed your changes then the header area should be back to normal. If this isn't the case, I recommend you download a fresh copy of DMS and extract the zip. Then upload the header.php file and overwrite the one you currently have.

This should resolve your issue.

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

That worked! Thank you!!! Now that I know what NOT to do, what is the correct way to add code to the header section?

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Hi nikki4558 - Now that you've got things back to normal, your next step is to activate a child theme (sometimes called a base theme) which will allow you to start playing with things like the header without editing the core files themselves. Check out http://docs.pagelines.com/customize/base-child-theme for more information.

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

You will want to use hooks. However, if all you want to to do is add HTML, you should probably use the MediaBox section.

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Thanks so much for your help!! I'll look into the child theme and media box suggestions.

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Ok, one more question. I started from scratch and set up the site using only the pagelines editor (and used media boxes to add the header). I thought that would fix the mobile view problem I was having. Unfortunately, it didn't. Is there a way to fix it so that the website appears the same on desktop and mobile versions?

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Hi nikki4558 - DMS is designed by default to be responsive so there's not really a way to "turn it off" and make your website appear exactly as it does on the desktop version. There are, however, some things you can do to manipulate the way things render on different devices and browsers so perhaps you want to investigate those a bit? Check out http://docs.pagelines.com/tutorials/browser-specific-css and http://docs.pagelines.com/tutorials/html-css-utilities for more information. 

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Ok, I think I phrased that incorrectly. I would like the site to look the same on both the desktop and mobile, but understand that may not be possible.

 

However, I was under the impression (and as you said) the theme itself should be responsive, so I'm not sure why it's not working. I added a screen shot of the site from an iphone. The header and ad at the top are full size, while everything else is scaled. Is there a way to fix it where everything is scaled the same?  Also, when you click on the menu, a black box pops up, but it is hidden behind the header, so most of the choices are not available. 

 

Thank you again for your help!! I've almost got it where I want it :)

 

 

photo.png

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Hi nikki4558 - Gotcha, my apologies for misunderstanding. OK, it's definitely not a normal mobile view you're experiencing so we've got to track down whatever is causing the site to look wonky! Chrome tools shows an error  Uncaught SyntaxError: Unexpected token < and it's possible that's the culprit. Could you start disabling plugins except for the DMS Pro Tools and if that helps with the mobile view, turn them back on one at a time and test until you've narrowed it down?

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

No problem. I wasn't explaining it as well as I should have. I disabled all of the plugins except for DMS Pro Tools, but the site still looks the same. 

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

nikki4558 - This is a weird one! I think perhaps it's the ad in the header that's causing this. Is that a custom code in there? Could you try removing any and all customizations you've got going on and see if that does the trick? It has to be something custom in your site somewhere as I'm not able to re-create the issue on any test sites.

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

I took the ad out completely and it's still the same. It was just google analytics and google ads. It shouldn't be custom at all. Weird! Do you think it could be the header itself?

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

I just removed the header also. It seems to be fine now, and the menu works too. Now I just need to figure out how to add the header without screwing it up. 

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

I fixed the header. I added max before width in the code and that seemed to make it scalable. The ads are still not working though. I tried adding a max width on those too, but it didn't work. 

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Hello nikki4558 - I'm glad you've solve the header but concerned why you had to add a max-width - it should scale by default. Did you end up going with the media box? As for the ads themselves, I'm not sure if/how they act responsively. You could try to hide them from mobile view?

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Hi @Jake- I did use a media box. It's now scalable in mobile view, but not clickable (I have it image mapped). When you click on it in mobile view it acts as one image and only takes you to the home page. I didn't know I could hide the ads from mobile view. Is there an easy way to do that?

 

Thanks again for all your help!

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

How are you adding the ads to your page, if you're using HTML in a MediaBox you can wrap the ads code with the following:

 

<div class="hidden-phone">
Add Code here

</div>

 

This will hide the add on mobile devices.

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Hi, 

 

I have a question about headers in Pagelines that might not be directly related to the conversation in this thread but I figured it was close enough. I accidently removed the header section from my Pagelines website. How do I bring it back so I can have the fixed navigation as well as the header navigation appear on all my pages. Please help! My website is www.brookdale.org.

 

Thanks,

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Hi there, if you delete the section in the header area then this is actually a section area you're deleting, not the actual header. If you go to add a new section look for the section area icon and drag that back up to the top of the page and it will populate the header again. I've recorded the process of deleting the header and re-adding so you can see what I mean. Checkout http://screencast.com/t/ilgwXn7K8Qa

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0