Forum Replies Created
-
AuthorPosts
-
csbeckMember
Ah-ha. OK, I see what you're talking about. Sorry for being so thick-headed.
So it looks like these are the styles that are making you're page have those issues:
#header .wrap {min-height: 90px;
}
#title {
background: url("images/logo.png") no-repeat scroll 0 0 transparent;
border-top: 0 none;
display: inline-block;
font-family: 'Raleway',arial,serif;
font-size: 27px;
line-height: 1;
margin: 0;
min-height: 33px;
padding: 18px 20px 17px;
position: relative;
text-shadow: 0 1px #96430D;}
#inner {clear: both;
margin-top: 90px;}
/** in your responsive section (max-width: 800px) **/#title {
background-position: center top;
padding: 18px 0 17px;
width: 100%;}
Make these changes:
#header .wrap {
min-height: 58px;
}
/** in your responsive section (max-width: 800px)**/
#title {
background-position: center top;
padding: 18px 0 0;
width: 100%;
}#inner {
clear: both;
margin-top: 180px;}
See if that does it. There might be some issues with the navigation. Like I noticed that when I went to 800px wide, the navigation went to 2 lines but the last item didn't have a dark background so it looked less than perfect.
Let me know how it goes.
ChriscsbeckMemberHi Mike,
I just refreshed the page and it looks good to me. But perhaps I'm not understanding your issue.
Here's a link to a screen shot of your menus. Please let me know if this looks good or not.
https://dl.dropboxusercontent.com/u/54563062/menustyle01.jpg
If this is how it's supposed to look and it doesn't show up that way on your computer, you might have to clear your cache or just refresh the page.
Chris
csbeckMemberHi Mike,
Take a look at the style "#header .menu a". You'll see that the padding is:
padding: 20px 15px 17px;You need to change it to:
padding: 19px 15px 17px;
Also this style needs to be changed to this for the sub-menu popouts:
.menu-primary li ul ul, .menu-secondary li ul ul, #header .menu li ul ul {
margin: -37px 0 0 159px;
}
See if that works and let me know.
PS - sorry for not seeing your message back in March.
May 18, 2013 at 12:41 pm in reply to: Add page and post specific content between title and content #41521csbeckMemberI've created a Gist of the code that I'm using with the addition of Brad's code as well. I've put this in the bottom of my functions.php file. Hopefully it will help someone else. I will still note if I find a suitable and helpful plugin that performs this function while giving a wysiwyg editor.
https://gist.github.com/csbeck/5605378
Chris
May 18, 2013 at 10:23 am in reply to: Add page and post specific content between title and content #41511csbeckMemberOk, I've used that code from the WP Codex and added your function and got it to work.!
I only made changes to a couple places.
Your code, I added the call to the meta item:
add_action( 'genesis_after_post_title', 'custom_field_before_content' ); function custom_field_before_content() { if(is_page() || is_single() ) { genesis_custom_field('subtitle_text'); } }
The new code from the Codex, I changed the name of the field:
// The actual fields for data entry // Use get_post_meta to retrieve an existing value from the database and use the value for the form $value = get_post_meta( $post->ID, 'subtitle_text', true ); echo '<label for="myplugin_new_field">'; _e("Please enter the custom text that follows the page title.", 'myplugin_textdomain' ); echo '</label> '; echo '<input type="text" id="myplugin_new_field" name="myplugin_new_field" value="'.esc_attr($value).'" size="80" />';
and the final line of code for what to do with it:
// Do something with $mydata update_post_meta($post_ID, 'subtitle_text', $mydata);
When I have time, I'll add a Gist or Github.
My wishlist would be to have it use a wysiwyg editor. I'm sure a plugin or more code would do that. I'll keep my eyes open for that.
Chris
May 18, 2013 at 8:55 am in reply to: Add page and post specific content between title and content #41507csbeckMemberLooks like WP has custom meta boxes:
http://codex.wordpress.org/Function_Reference/add_meta_box
Looks a bit hairy and complicated. I'm sure I could copy the entire code sample and put it in my functions.php. I'll try it and see what happens. I'm just a little confused at how to grab the content from that custom meta box. i.e. how to reference it. I'll give it a go and let you know what I come up with (meaning, if it crashes me or not). 😉
May 18, 2013 at 8:46 am in reply to: Add page and post specific content between title and content #41506csbeckMemberBrad you are the man! I knew there just had to be a way. Thanks so much for your continued effort on this! And with the extra braces 😉 - haha.
This works like a charm. I believe the client will be able to understand this. True though - I agree it would be better to use a custom meta box. That would be great. I have attempted custom post types on another trial project so I see the ability and the power of doing that but didn't want to go with complete custom post types since it's still basically a page or post. I can only imagine there might be some few lines of code somewhere that could add a custom meta box without going the route of custom post types. Yes, please let me know if you find anything. I will also do some searching.
Thanks again! You've been very helpful.
csbeckMemberHi Brad,
Thanks so much for both your FAQ suggestion and looking into a solution. I will do better at posting code now.
As for your code, your code does work, I was incorrect and I apologize. But it didn't work on the PAGE where I was looking because a single PAGE is not identified as "single". So your code didn't affect my test PAGE. Now I went to a post and there is your text. So thanks for getting that to me. I hope you don't take offense at my responses due to my ignorance and less experience of PHP - which I'm attempting to improve upon - I'm more of a designer.
If anyone cares, I've modified the code to be this so that it will appear on both PAGES and POSTS:
function after_title_text() { if(is_page() || is_single() ) echo '<div class="single-title">Add content after your titles but before your content here</div>'; }; add_action('genesis_after_post_title', 'after_title_text');
So thanks again and your searching for an alternative is very much appreciated.
Though I don't understand why I would need to create a separate thread; I still feel the solution to this (be it PHP, shortcodes, or custom fields) would be associated to my original question, I will create a separate thread.
Thanks! Chris
csbeckMemberYour code needed another set of curly brackets to encase the statement within the if statement. Then the text showed up just like I wanted!
But now I want to add some dynamic text there so different pages could show different text and I'd like to modify that from the page.
OK, so here's the code that I put in my functions.php:
function after_title_text() {
if(is_page() ) {
echo '<div class="thispage_excerpt"><?php the_meta(); ?></div>';
}};
add_action('genesis_after_post_title', 'after_title_text');I've also added a custom field on my test page: http://acquireb2bdev.com/products
Key: Page ExcerptValue: This is my excerpt.
When I test the page out, the div exists on the page but the content doesn't. I'm afraid that I'm doing custom fields incorrectly. Can regular pages not have custom fields? Can you give any further advice?
Thanks, Chris
csbeckMemberThis is great Brad. I'll give it a try.
With this hook in there, how would I dynamically pull the excerpt or custom field content into this section?
Would I?:
- Create a custom field on the page (I could call the custom field "thispage_excerpt")
- Add content (value)
- Then in your code put something like:
- echo '<div class="single-title"><?php the_meta(); ?></div>';
csbeckMemberI found a pretty good plugin to do this. Connections - Connections Pro website.
csbeckMemberYou absolutely rock! I guess I was scared to try that. Thanks so much. Works like a charm!
csbeckMemberHi Mike,
Your site is just a single page right now so I can't go into your code. I also don't have "eleven40" theme.
But, if all you're trying to do though is change some spacing in the responsive section for the header, then go down into your style.css code and find where it starts with a label called: /* Responsive Design
Look for where it says #header and make changes in those sections with respect to the padding, margin and height. You may also have to make a new style called #header or something.
You may have to make these changes in all of your different media queries sections.
Something I've found very helpful, if you're not using it, is use FireFox with Firebug or Chrome with Web Developer tools. You can make changes to the css on the fly and see what you need to change.
I hope this is somewhat helpful. If necessary, you could share your style.css file and I could lend a little more help.
Chris
March 14, 2013 at 12:01 pm in reply to: Trying to change the text on the "Return to top" link #26235csbeckMemberOr you could try the Genesis Simple Edits plugin.
Just a thought.
March 14, 2013 at 9:20 am in reply to: Minimum Theme: Removing the 'Sorry, no posts matched your criteria' #26187csbeckMemberGood points. I'm glad Louise that you got it working! Never give up. Never surrender. Happy Genesis-ing.
csbeckMemberGreat! You're welcome.
March 14, 2013 at 7:55 am in reply to: Minimum Theme: Removing the 'Sorry, no posts matched your criteria' #26167csbeckMemberWhy don't you create a custom home.php page? And put on it what you want? That way you wouldn't use hacks. Just wondering.
Chris
csbeckMemberYou can also edit post meta with the Genesis Simple Edits plugin. I love it. Simple and powerful.
csbeckMemberYeah, that's a lot.
OK, so we can get rid of the lower "Player Forums" now using CSS - just create a new style called:
#inner .wrap #content-sidebar-wrap #content. h2.entry-title and set display: none;
One of your last lines - the last else says to name the general archive default to Blog Archives. If you change that to Player Forums, won't that wrap it up?
csbeckMemberHmmm. It seems to look fine to me.
http://dl.dropbox.com/u/54563062/daildance01.jpg
Perhaps you need to clear your cache and refresh your page.
-
AuthorPosts