Forum Replies Created
-
AuthorPosts
-
nunotmpMembernunotmpMember
You can view it by going to the backend and hovering apperance>editor
nunotmpMemberUse this
add_action('set_current_user', 'hide_admin_bar'); function hide_admin_bar() { if (!current_user_can('edit_posts')) { show_admin_bar(false); } }
This will check if the use has the ability to edit post(basically editor or admin ).
nunotmpMemberIt looks like your theme has a class of
.slider
with only a width of 610px. If you change it to 100% I think you will get the effect you are going for..slider { float: left; width: 610px; }
The style is on line 648 of your style.css file.
nunotmpMemberPriority.
This is useful with adding multiple functions to the same hook. Example:
add_action( 'genesis_entry_content', 'genesis_do_post_image', 8 ); add_action( 'genesis_entry_content', 'genesis_do_post_content' ); add_action( 'genesis_entry_content', 'genesis_do_post_content_nav', 12 ); add_action( 'genesis_entry_content', 'genesis_do_post_permalink', 14 );
The lower then number the sooner the code will execute. If you wanted to add the post title just under the post image you can do something like
add_action( 'genesis_entry_content', 'genesis_do_post_title', 9 );
or above it with
add_action( 'genesis_entry_content', 'genesis_do_post_title', 7 );
September 16, 2013 at 4:46 pm in reply to: Help With Single Page Template and Advanced Custom Fields #62898nunotmpMemberWe can do this using only hook....A lot of hooks. 🙂
// First lets remove all of the post elements so we can inject our own remove_action( 'genesis_entry_header', 'genesis_entry_header_markup_open', 5 ); remove_action( 'genesis_entry_header', 'genesis_entry_header_markup_close', 15 ); remove_action( 'genesis_entry_header', 'genesis_do_post_title' ); remove_action( 'genesis_entry_header', 'genesis_post_info', 12 ); remove_action( 'genesis_entry_content', 'genesis_do_post_content' ); remove_action( 'genesis_entry_footer', 'genesis_entry_footer_markup_open', 5 ); remove_action( 'genesis_entry_footer', 'genesis_entry_footer_markup_close', 15 ); remove_action( 'genesis_entry_footer', 'genesis_post_meta' ); // We will define a function to add two columns into the post this will add everything in the <article> tags add_action( 'genesis_entry_content', 'wpz_column_artist' ); // We can start adding all the necessary loop parts into our new custom hooks // Left column content here add_action( 'wpz_left_column', 'genesis_do_post_title' ); add_action( 'wpz_left_column', 'genesis_do_post_content' ); // Right column content here add_action( 'wpz_right_column', 'genesis_do_post_image' ); // ADD code to display ACP /* Action Functions ----------------------------------------------- */ function wpz_column_artist() { echo '<div class="one-half first">'; // Lets create a left column hook do_action('wpz_left_column'); echo '</div>'; //END .one-half first echo '<div class="one-half">'; // Lets create a right column hook do_action('wpz_right_column'); echo '</div>'; //END .one-half first }
You may need to add a few more function to output the data you want. Just use the custom hooks to display left or right side.
September 16, 2013 at 12:01 pm in reply to: How to insert custom markup outside of header's .wrap? #62851nunotmpMemberYou know what, do this.
remove_action( 'genesis_header', 'genesis_header_markup_close', 15 ); add_action( 'genesis_header', 'wpz_header_markup_close', 15 ); function wpz_header_markup_close() { genesis_structural_wrap( 'header', 'close' ); do_action( 'wpz_after_header_wrap' ); genesis_markup( array( 'html5' => '</header>', 'xhtml' => '</div>', ) ); }
What this does is removed the genesis closeing markup and inserts our custom markup. I added a custom hook after the
.wrap
and before the</header>
so you can then use the example above to add the custom markup like soadd_action( 'wpz_after_header_wrap', custom_wrap_open', 12 ); add_action( 'wpz_after_header_wrap', 'custom_wrap_close', 14 ); add_action( 'wpz_after_header_wrap', 'everything_within_custom_wrap', 13 );
The WPZ is my personal prefix you can change it.
September 16, 2013 at 11:51 am in reply to: How to insert custom markup outside of header's .wrap? #62846nunotmpMemberSorry about that. I just re-read you question. This will require quite a bit of work. Genesis since 2.0 automatically adds the .wrap in the header. What exactly are you wanting to do? Maybe there is an easier way?
September 16, 2013 at 7:27 am in reply to: How to insert custom markup outside of header's .wrap? #62810nunotmpMemberGenesis uses the following hooks to create the header markup
add_action( 'genesis_header', 'genesis_header_markup_open', 5 ); add_action( 'genesis_header', 'genesis_header_markup_close', 15 );
with
add_action( 'genesis_header', 'genesis_header_markup_close', 15 );
closing the</header>
(html5) or the</div>
(xhtml). You can follow the same pattern and create you actions like soadd_action( 'genesis_header', custom_wrap_open', 12 ); add_action( 'genesis_header', 'custom_wrap_close', 14 );
This will hold the openig a closing markup and you can simply add your actions using the priority of 13 like so
add_action( 'genesis_header', 'everything_within_custom_wrap', 13 );
Or an even easier if you do not really need to add so many thing just create a single action
add_action( 'genesis_header', 'wpz_custom_wrap', 13 ); function wpz_custom_wrap() { echo '<div class="custom-wrap">'; // add anythiing you want within the wrap echo '</div">'; }
nunotmpMemberAre you basically trying to display all post under your categories? So if you create a category "TV" you can a title with all post that are marked as tv to display?
nunotmpMemberIf the content is still showing you may be using html5? The hook has changed so you need to use
remove_action( 'genesis_entry_content', 'genesis_do_post_content' );
September 15, 2013 at 8:39 pm in reply to: Create background image that adjusts to different screen resolutions? #62752nunotmpMemberYou can use a background size of cover. something like this
#inner { background: #5282C3 url(images/inner.png) no-repeat center center; clear: both; margin: 0 auto; overflow: hidden; padding: 30px 0; -webkit-background-size: cover; -moz-background-size: cover; -o-background-size: cover; background-size: cover; }
This will adjust to all screen sizes and uses the necessary browser prefixes.
September 15, 2013 at 6:28 pm in reply to: Modify .content & .sidebar width without breaking the responsive functionnality #62740nunotmpMemberOne of the things you will need to do is instead of use
width:
you may need to usemax-width:
instead.
nunotmpMemberI just took a quick look into your stylesheet and it looks like you do not have any responsive design. Responsive sites has
@media
queries and you site has none. Im guessing you had someone customize your site? Looks like they deleted the responsive styles.
nunotmpMemberMickmel is correct. You style sheet uses this style
#nav li.right { display: none; }
when the screen size is lower than 960px. If you remove the
display: none;
you will need to add some additional styles to position the search properly or it will float off to the right. Good luck.
September 15, 2013 at 5:35 pm in reply to: How to add a Soliloquy slider to a Genesis page template file #62727nunotmpMemberGreat post! I personally always create a widget area to hold my slider.
nunotmpMemberIt looks like your site is not using the viewport meta tag. Place this in your functions.php file
/** Add Viewport meta tag for mobile browsers */ add_action( 'genesis_meta', 'child_viewport_meta_tag' ); function child_viewport_meta_tag() { echo '<meta name="viewport" content="width=device-width, initial-scale=1.0"/>'; }
nunotmpMemberI just looked at the styles using firebug and it is using the Capriola font on my end. Try using ctrl+shift+r for a full refresh.
September 15, 2013 at 5:23 pm in reply to: change background color for breadcrumbs and body text "quote" #62723nunotmpMemberYour breadcrumbs uses the
.breadcrumb
class and the quote on the sidebar uses.niceQuote
nunotmpMemberNot sure why they have not responded to your queries but give the contact form another go http://www.studiopress.com/contact or you can try twitter @studiopress
Good luck.
-
AuthorPosts