Jump to content
Sign in to follow this  
rtysmith

Text between boxes and soapboxes

Recommended Posts

rtysmith

On a single page, I have both boxes and soapboxes, is there a way for me to put a title in between the two? i.e. Title: Pro Members box 1 box 2 Title: Jr. Members Soapbox 1 Soapbox 2

Share this post


Link to post
Share on other sites
kastelic

This would be a pretty simple line of jQuery, if you could post a link to your site I could give you the code to paste.

Share this post


Link to post
Share on other sites
kastelic

How's it work for you if you put this in Custom Code -> Footerscripts?

jQuery('.page-id-80 #boxes').before('<h1>Non-Pro Members</h1>');

Share this post


Link to post
Share on other sites
kastelic

Woops forgot the script tags, sorry:

<script>
	jQuery('.page-id-80 #boxes').before('<h1>Non-Pro Members</h1>');
	</script>

Share this post


Link to post
Share on other sites
catrina

Add this CSS to your custom code area:

.page-id-80 #boxes {margin-left: 100px;}

Increase the number value until you're satisfied with where the title is.


Please read the docs before posting. Please do not private message me unless I ask you to.

Designer | Catrina Dulay

Founder | Catrina and Mouse

Share this post


Link to post
Share on other sites
rtysmith

It doesn't move it at all, plus it needs to resize it with the page. Is there a way to do this with a hook?

Share this post


Link to post
Share on other sites
catrina

Replace the CSS selector with

.page-id-80 #boxes h1

. Do you want the title to be aligned left or centered?


Please read the docs before posting. Please do not private message me unless I ask you to.

Designer | Catrina Dulay

Founder | Catrina and Mouse

Share this post


Link to post
Share on other sites
kastelic
http://www.pagelines.com/docs/base-child-theme I believe there is a hook called pagelines_before_boxes that you could use. If you go into the Template Setup and find the boxes section and click 'advanced options' you can see all the hook options. If you want to stick with the jQuery, give your h2 a class like this
<h2 class="inserted-title">My title</h2>
and in the CSS:
.inserted-title{
	width:920px;
	margin:0 auto;
	}
When you do add the class make sure you are using either
"
or
'

depending on what is not wrapping the whole jQuery selector.

Share this post


Link to post
Share on other sites
rtysmith

Hooks look like the way to go. Where would I put the info to make it happen via a hook and only on the page that has that box type?

Share this post


Link to post
Share on other sites
rtysmith

wow, that was easy to use the hook! Thanks!

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  

×