Jump to content
Sign in to follow this  

Pageglines Javascript Code display problem with WP 3.5.1

Recommended Posts


Dear Pagelines Community,


I have not really seen this issue posted before, so I'm posting now.


As we all know, WP 3.5.1 has been released.


I have encountered a problem when I try to paste a javascript ad code into a post.


The problem is, that the code does not display right using the Pagelines theme.


I'll give two examples, both using the same javascript ad code.


First on Pagelines w/ WP 3.5.1:



Next, same code on another non-Pagelines theme w/ WP 3.5.1



Are there any ideas on what the cause can be?


I have disabled all plugins, and the display problem is still occuring.


Thank you,


Share this post

Link to post
Share on other sites

Hi Daniel,


Keeping in mind that we're a framework, not a theme, we must consider the container for the ad itself.  There are much more specific sections and containers for code in PageLines Framework than you'll find in typical themes. As a result, one must add the javascript in a proper container.  That said, you can pretty much add your javascript in most places on the site.


If you're adding it inside the post, there's a few things to remember.

  • You should add the code in Text mode (the right/top tab over the post edit panel when adding the post). This ensures that WordPress will not modify the code changing things like brackets to ascii code. Added in the Visual mode, the javascript can break, causing the ad to appear oddly.
  • The width of the ad should not exceed the width of the layout for the Content Area.  A good rule of thumb is to calculate the width of the ad plus 50 pixels (10px padding plus 15px margins on either side).  Go to Dashboard > PageLines > Site Options > Layout Editor.  Depending on how you have your site structured, the Content Area's Main Column is the one you want to check.  If this is narrower than the width of the ad it could corrupt the code or cause the ad to break through that area, bleeding under the sidebars.   Often, people seeking to use ads within the content will apply a 325x300px or 300x250px  or a 468x60px ad size to ensure it fits.

Depending on where you want it placed, you might want to try the Content Box, which may be included top or bottom in the Main Column (Content Area) via Drag & Drop.  Unfortunately, this cannot be placed in the middle of your post content, if that's your intent.


I hope this advice helps you achieve your goals. If you need any additional assistance, please let us know.

Former PageLines Moderator, Food Expert and Raconteur

Share this post

Link to post
Share on other sites

Hi Rob,

Thank you as always for your advice.

When I added the script to the post, I used the Text mode.

WP 3.5.1 now has this as Text mode, but it used to be HTML mode, could it be possible that this is the problem?

With regard to the width of the ad and the content area,

the  ad does not display properly even on a full-width page of 1100px (ad is 728px).


Share this post

Link to post
Share on other sites

The only other thing I can think of is that there may be some CSS associated with the ad that's either outdated (not CSS3) or, conflicting with other code or perhaps, simply incorrect by contemporary standards used by PageLines Framework versus themes.


Can we try going to Dashboard > PageLines > Drag & Drop and adding the Content Box (it must be installed and activated through the Store - though it's free) to the Content Area for the template you're using (if a page) or, for Blog Page.  I'd recommend using a page for testing, versus a post, so the template's best.


Click on Content Area. Select the template you will use (from 1 to 5), then drag Content Box to the top of the Active Sections.


Open a new page, select that tempate and save as a draft.


Scroll down to PageLines Meta Settings and paste your ad code in the Content Box area.  Select the full-width layout, for good measure and Publish.


If you see the problem when the code is in the Content Box, then the problem isn't the Text Mode.  By the way, yes HTML Mode is now called Text, I don't think that's an issue.  They relabeled that tab to avoid confusion - some folks thought it was only for adding HTML code, not for viewing things as a text editor.

Former PageLines Moderator, Food Expert and Raconteur

Share this post

Link to post
Share on other sites

Hi Rob,


Thank you for your help.


After a few days of trying, I am still not able to make this Javascript work in the base theme of my Pagelines framework.


I have tried a few different things in addition to the Content Box area.


This code does not work in the sidebars, nor does it work when I use the "Simply Custom" section from the Pagelines store.


This Javascript code works just fine on other themes, but I do not want to say that Pagelines is incompatible so I tested with similar Javascript code, and they appear to be displaying normally.




I'm still not sure how to go about fixing this, but I'll keep looking. Thank you again for your help and suggestions, they're always appreciated!


Share this post

Link to post
Share on other sites

Just keep us updated :)

Mackenzie - PageLines Help Desk

The Centsible Family - Writer, Photographer and Coffee Addict


Kindly search this forum and read the documentation before posting. It will help you resolve many issues.

For CSS help be sure to check out W3Schools first and be sure to download FireBug for FireFox for troubleshooting.

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  

  • Similar Content

    • tuciudadenred
      By tuciudadenred+
      Hi everyone, what happens is that the web page metrosalarmas.com has a google tags which I have not attacked where I can look to remove those tags and be able to locate the correct ones.
    • Michael Kummer
      By Michael Kummer+
      Hi guys!
      I am using a plugin called Speed Booster Pack to speed up the load time of michaelkummer.com. One of the plugin settings, Minimize HTML and JavaScript causes an error that I only get with Pagelines. With other themes, such as WordPress' Twenty Seventeen, I do not get that error.
      I have reproduced the problem on my staging site and if you look at the JavaScript console, you will see the following error:
      SyntaxError: Unexpected end of script
      Any clue what PageLines may be doing differently to be contributing to this issue? I contacted the plugin developer and they, of course, pointed me to the theme developer
    • flourishdesignstudio
      By flourishdesignstudio+
      We are working on a site and the customers are complaining that the site loads too slowly. They contacted their host who mentioned that the Java Script is all loading at the beginning. Is it possible to delay the load of the less important Java Script until after the initial load to speed up the site? The goal is to load the page faster by minimizing the initial javascript calls.
      Are there any preferred plugins that you would recommend or does this end up causing excessive problems with plugins, etc.?
      Thanks for the help!
    • oseehys
      By oseehys+
      Hello There,
      So i want to use platform 5 and DMS sections on a single page, i am using a child theme with pinspro as my main theme and i activated platform 5, the only problem am having so far is the fixed option, my navbars are not aligning to their default size, and it will be great if platform 5 header and footer section will function, has anyone used this option, how can i make the best use of platform 5 and DMS on a site
    • thirdstonemedia
      By thirdstonemedia+
      I've been fighting with a resolution issue ? Want to use Flick Slider, the site looks great on my monitor but client says she can't see bottom of homes. I believe she's on an old PC using outdated browser/s ... but, she's important to me and I'd like to make this work, on her system. Without asking her adjust her own set-up. 
      I put the Flick Slider inside a container, here ::
      Set the Height of Flick Slider to 50 Base ... I don't know how this works exactly ... there is a Base then a Min ... but, haven't adjusted the Min ::
      Tried using Splash Up, which presents the same issue (she can only see top of home) and she wants several images to rotate on Home page, so not sure this would work anyway ::
      I have tried going into Layout and making the width narrower, and that does make the site narrower, but the homes still don't display in full, on her system. Help ?

      Here are her screen grabs, both desktop and iPad  (dumped the chalkboard background).

      FInally, she said these look great ::
      What am I doing wrong ?? Is there a better way to accomplish making the site look great on any resolution at any size ?
      (Longtime Pagelines-lover.)