Forum Replies Created
-
AuthorPosts
-
Ben @ Inbound CreativeMember
Nevermind. It was because I hadn't called the footer on the template. No idea why that was impacting it, but it's working now.
Ben @ Inbound CreativeMemberHi Sridhar,
Thanks for taking the time to help.
I've done this and it hasn't worked.
Is there a chance that because this is being executed out of the loop that it isn't working.
This is the full code of the homepage template
<?php /* Template Name: Home */ get_header(); ?> <div id="header"> <a href="/" id="logo"> <img src="/images/logo.png" alt="Advice Media"> </a> <div class="text" role="main"> <h1>We create content</h1> <h1>that <span id="rotate">this</span>. Period.</h1> <a href="#contact" id="contactlink">Let's talk</a> </div> <div class="content" id="scrolldown"> <a href="#start"><img src="/images/arrow.png" alt="Scroll down"></a> </div> </div>
Ben @ Inbound CreativeMemberI put it in double quotes from the off. Just realised you'd put it in single quotes the first time round. I'd copy and pasted the bit between the <>s.
And haha. That's exactly the same expression I had when it worked.
Everytime you think you've got your head around PHP, it throws you another curveball.
Ben @ Inbound CreativeMemberSecond one worked. I had a horrible gut feeling it was going to be something like echoing the string.
Thanks Chris!
Ben @ Inbound CreativeMemberHi defree99,
If you're trying to make the text easier to read, it might not be best to go for a white background while you're text is white.
I had a quick mess around and found that a black background looks slightly better with white text.
You have a div with the style "colorbox". I'm not sure how that style is applied, but if it was by you, the easiest way of changing it would be to swap the word 'colorbox' with the following:
background: rgba(0, 0, 0, 0.6); padding: 19px;
The background sets the color – for example, if you wanted to change the text color to black and have the background as white, simply change all the 0s to 255.
The last bit – currently 0.6 controls the opacity. 1 is opaque while 0 is transparent. 0.7 would make it more opaque while 0.5 would make it more transparent. You see what I mean?
As for the padding, that's personal preference. I personally don't like text that runs up to the edge of a box. 19px is the max you can set it at without the boxes dropping under one another. Feel free to set it to less.
The best thing that you could do – if it is possible – is to assign the div with a class or ID and put that code into your style.css file rather than using style though.
Hope that helps.
Ben @ Inbound CreativeMemberThanks Andrea. I thought it was going to be something embarrassingly simple like that.
I think I need more caffeine.. or sleep.
Ben @ Inbound CreativeMemberCan you paste the code that you changed before the site broke please?
Ben @ Inbound CreativeMemberHave you checked the function.php file to see if the images sizes are still being defined as 620 x 230?
Anyway, a quick and easy fix for this is to go into your style.css folder.
Go to line 1081:
It should look like:
img.alignleft, .wp-caption.alignleft { display: inline; margin: 0 20px 20px 0; }
Simply add:
min-width: 100%;
It should then look like:
img.alignleft, .wp-caption.alignleft { display: inline; margin: 0 20px 20px 0; min-width: 100%; }
That will fix it.
If it doesn't fix immediately, clear the cache of your browser and refresh the page.
Let me know if it doesn't work.
Ben @ Inbound CreativeMemberI've solved it.
I ended up adding a new Taxonomy and using that to control its appearance through the GFWA widget.
June 7, 2013 at 1:42 pm in reply to: Call widget area before content in genesis_post_content? #44626Ben @ Inbound CreativeMemberThank Ryan,
I had a feeling it was going to be a case of setting a priority level.
Just for reference – in case anyone else is interested – once I put that code into, I needed to create css for each of the div ids.
I used the information from the .spotbox classes, and simply added clear: both; to each of the new ids.
That sorted it all out now.
For example, in the advert box – which is a text widget, the css is now:
`#text-5 {
width: 45%;
clear: both;
float: left;
margin: 0 0 15px 0;
margin: 0 0 1rem 0;
padding: 0;
border: none;
}`
June 6, 2013 at 9:27 am in reply to: Call widget area before content in genesis_post_content? #44325Ben @ Inbound CreativeMemberAll that does is constrain the content within the boundaries of the width on the left rather than the right side of the genesis_post_content area like I need it to be.
I've copied the CSS and functions pages over from the local host and pasted them as is into the same files on the server hosted version.
This post is the only thing I've uploaded as it's the only thing I've having an issue with at the moment.
http://www.furfiemedia.co.uk/news/involuntary-it-managers-costing-small-businesses-in-productivity/
Let me know if you need any other information or code.
June 5, 2013 at 7:16 pm in reply to: Call widget area before content in genesis_post_content? #44253Ben @ Inbound CreativeMemberHi Ryan,
I might upload it to my hosting tomorrow to make it easier to debug.
In the meantime, it's not a clearance issue. I'll paste the relevant code below until I've uploaded the site tomorrow.
From the functions file (for the call):
`// Inserts advert spotbox into single posts
add_action( 'genesis_post_content', 'metro_advert_box' );
function metro_advert_box() {
if (is_single() && is_active_sidebar( 'in-post' ) ) {
echo '';
dynamic_sidebar( 'in-post' );
echo '';
}
}`And the CSS:
`.entry-content p {
clear: none;
position: relative;
font-size: 14px;
font-size: 0.875rem;
width: 53%;
padding-left: 47%;
right: 0;
}``.spotbox {
width: 45%;
float: left;
margin: 0 0 15px 0;
margin: 0 0 1rem 0;
padding: 0;
border: none;
}.spotbox img {
float: left;
margin: 0 0 15px 0;
margin: 0 0 1rem 0;
padding: 0;
border: none;
}`
June 5, 2013 at 7:11 pm in reply to: Call widget area before content in genesis_post_content? #44251Ben @ Inbound CreativeMemberJust in case it's not 100 per cent obvious what I'm trying to achieve without being able to access the site, I've mocked up a screen in photoshop to demonstrate.
As you can see, the widgets on the left have moved up to be inline with the top of the content under the featured image.
As I said, any help will be much appreciated.
Ben @ Inbound CreativeMemberThanks Anitac.
I ended up managing to solve the issue in the following way (for anyone else that's interested).
I changed the slider content settings to pull from the excerpt.
I then used inline span styling to get the right look, before creating classes and adding them to the css file.
It was then simply a case of adding <span class="#"> and the relevant class to each line.
As for the opacity, I ended up using rgba to get the look (I know it won't work on IE).
Changing the background attribute in .slider-excerpt to "background: rgba(255,255,255,0.8);" (the 0.8 controlling the opacity) did the job.
-
AuthorPosts