Jump to content


Photo
- - - - -

Fixed div not working properly.

fixed divs pagelines

  • Please log in to reply
3 replies to this topic

#1 danoah

danoah

    Super Member

  • Members
  • 132 posts

Posted 03 March 2013 - 06:42 PM

Hello, I've built a div that I'd like to have fixed to the left side of the screen. You can see an example here:

 

Please Login or Register to see this Hidden Content

 

The problem is, no matter where I install it, it either shows up all skiwampus, or if the layout shows up correctly, the links and animations don't work.

 

I've tried the following:

 

  • Installing it in the header file just below the body tag.
  • Installing it in the functions file with a hook in several different places.
  • Installing it as an iframe in the header file just below the body tag

Where do I install both the HTML and CSS to make this work in my pagelines site?

 

You can see my site at www.danoah.com.

 

Thanks, Dan Pearce



#2 Rob

Rob

    One Smart Egg

  • Members
  • 13575 posts
  • LocationEast Coast, USA
  • Framework Version:The Latest, of course
  • Country: Country Flag

Posted 03 March 2013 - 06:57 PM

Dan,

 

First, let me point out that we don't recommend or support modifications to the core files. 

 

It seems that you're going outside the page or content, but you're within the body. Thus, my suggestion for this would be to do this with CSS. How are you finding hooks? With Action map?  The proper hooks are either pagelines_code_before_head or pagelines_before_html. 

 

My best recommendation would be to use CSS with the body tag to set the blue background and include the links in a hook. The HTML code would be added in the hook. The CSS can apply the images and hover action. You'd apply that in Dashboard > PageLines > Site Options > Custom Code.  I recommend this location because it would likely load in precedence over anything in a child theme, but that's just my opinion. Others more skilled with this may disagree ;)

 

If you have PageLines Customize, I'd recommend applying the hook in the functions.php there.



#3 danoah

danoah

    Super Member

  • Members
  • 132 posts

Posted 03 March 2013 - 08:27 PM

Thanks for the quick reply Rob.

 

Using the pagelines_before_html puts it in the right place, but it still shows as dead links, and the small text css effects don't ever fly in or show up.

 

The blue background is just for testing purposes. The div has no background and needs to sit against my current image background on danoah.com.



#4 Rob

Rob

    One Smart Egg

  • Members
  • 13575 posts
  • LocationEast Coast, USA
  • Framework Version:The Latest, of course
  • Country: Country Flag

Posted 03 March 2013 - 08:43 PM

Dan,

 

I'm not sure what you placed in the hook.  Can you paste it here in the code option (the little <> above in the editing tools)?