chaos67731
Forum Replies Created
-
I think I ended up not having <?php wp_footer(); ?> in my footer.php
Forum: Hacks
In reply to: A type of "featured" page and then have it displayed on front-page.phpYes the echo what just to test the output so I could find out what I was calling, I have
<?php // Name of Custom Navagation in the back end $menu_name = 'featured-page'; if ( ( $locations = get_nav_menu_locations() ) && isset( $locations[ $menu_name ] )) { $menu = wp_get_nav_menu_object( $locations[ $menu_name ] ); $menu_items = wp_get_nav_menu_items($menu->term_id); } foreach ( $menu_items as $menu_item ) { $numbers[] = get_post_meta( $menu_item->ID, '_menu_item_object_id', true ); } var_dump($numbers) ; ?>
The var_bump will output this
array(3) { [0]=> string(2) “11” [1]=> string(1) “9” [2]=> string(1) “8” }So my next step is to turn that in to “11,9,8” as you will see in my second post I am wanting to use that to get what pages I will display in the front-page.php
Thank you so much for your help, I am not the best at php so I am still trying to understand what to do next, but non the less you have hellped me out for sure!
Forum: Hacks
In reply to: A type of "featured" page and then have it displayed on front-page.phpI am trying to make this code work for getting the ID’s needed but am having no luck. Hopping someone can help out.
I am making a navagation in the back-end and trying to pull the ID’s from there.
$menu_name = 'featured-page'; if ( ( $locations = get_nav_menu_locations() ) && isset( $locations[ $menu_name ] )) { $menu = wp_get_nav_menu_object( $locations[ $menu_name ] ); $menu_items = wp_get_nav_menu_items($menu->term_id); } foreach ( $menu_items as $menu_item ) { $numbers[] = $menu_item->ID; } $numbers[] = get_post_meta( $menu_item->ID, '_menu_item_object_id', true ); echo $numbers;
https://wordpress.stackexchange.com/questions/94787/get-page-ids-from-nav-items/
Forum: Hacks
In reply to: A type of "featured" page and then have it displayed on front-page.phpSo I have found this code:
<?php $args=array( 'order' =>'asc', 'post_type' =>'page', 'post__in' => array(8,9,11), ); $page_query = new WP_Query($args); while ($page_query->have_posts()) : $page_query->the_post(); ?> <div class="featured-pages"> <h2><?php the_title();?></h2> <?php the_excerpt(); ?> </div> <?php endwhile; ?>
This does just what I want it to do, the question now is, how do I make it so people can pick the pages from the back-end so there is no need to touch the code?
Forum: Plugins
In reply to: Email subscribe plus coupon plugin?I have found Voucher Press that seems to do a good job at this.
I am having the same problem on this site, but its odd. . It just stopped working today.
https://joshstevensfoundation.org/gallery/
Could you take a look at it and see if I am missing something?
Never mind, it just hit me I added a little contact from that used jquery to the side bar. That was the problem.
Thanks for the great plugin
Forum: Your WordPress
In reply to: Making a Diet Site!?? It would seem its on the first page of yahoo for “hcg diet forum”!
lol
Well not a lot of people use Yahoo its a new site and not done so getting traffic from any where is making me happy.
Forum: Your WordPress
In reply to: My New Landscaping BlogVery nice site!
Forum: Your WordPress
In reply to: Suggestions to improve the design & loading speedVery nice site!
Forum: Your WordPress
In reply to: My New Landscaping BlogVery nice! I would suggest that you add some kind of active design to the nav so people know where they are. ??
Forum: Fixing WordPress
In reply to: Print out a navigation title?I have seen a few ways to do it bot none were as good as that blog!!
So thanks again! ?? Just what I was looking for.
Forum: Fixing WordPress
In reply to: Print out a navigation title?Thank You!!
Forum: Networking WordPress
In reply to: Pull from one database for 2 domains?Im not sure I get what your saying, I know I can use .htaccess to sent all mobile users to the m.domain.com but I am wanting the m.domain.com to be the same thing as the full site just cut down a lot. (mobile friendly)
when I add *cf_action=show_mobile* to the end of the url nothing seems to change.
Do you have a blog post or is there somewhere in the wiki that can give me more information on this?
Forum: Networking WordPress
In reply to: Pull from one database for 2 domains?I am wanting the mobile version of the site to be on m.domain.com