product247
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: Else and ElseIf With Advanced Page FieldsI FIGURED IT OUT!!! (one explanation point for each day it took)
<div id="slides"> <?php query_posts(array('post_parent' => $post->ID, 'post_type' => 'page')); while (have_posts()) { the_post(); ?> <?php $navigation_main = get_field('navigation_main_image'); ?> <?php $page = get_field('page_image'); ?> <?php $content = get_field('content_image'); ?> <div class="slide"> <?php if($navigation_main) { ?> <a href='<?php the_permalink() ?>' rel="bookmark"><img src="<?php the_field('navigation_main_image') ?>" /></a> <?php } elseif($page) { ?> <img src="<?php the_field('page_image') ?>" /> <?php } else { // You can remove this line and the two below if you don't need them - just leave the first "}" (ignore quotes) ?> <div id="contentimg"><img src="<?php the_field('content_image') ?>" /></div> <div id="contenttext"> <h1 class="entry-title"><?php the_title(); ?></h1> <?php the_content(); ?> </div> <div style="clear:both"></div> <?php } ?> </div> <?php } ?> </div>
Forum: Fixing WordPress
In reply to: Else and ElseIf With Advanced Page FieldsAnyone??
Forum: Fixing WordPress
In reply to: Getting the parent page id automatically$post->ID worked perfectly! Thank You
Forum: Fixing WordPress
In reply to: Display Custom Field Data In LoopActually I realized that the above code works.. Thanks Guys!!!
Forum: Fixing WordPress
In reply to: Display Custom Field Data In LoopHere is what I did so far:
<?php query_posts(array('post_parent' => 19, 'post_type' => 'page')); while (have_posts()) { the_post(); ?> <a href='<?php the_permalink() ?>' rel="bookmark"> <li class="menuItem"><img src="<?php echo get_post_meta($post->ID, 'navigation_thumbnail', true) ?>" alt="<?php the_title(); ?>" /> </a></li> <?php } ?>
It is pulling the sub categories and displaying the alt text but when I view the source the image location is empty. Could you tell me what I am doing wrong? Thank You
Awesome it worked. Just for the record here is what I did.
went to plugins > wp-survey-and-quiz-tool > includes > site > quiz.php
It was actually around line 268
This is the modified line of code:
$answers = $wpdb->get_results( $wpdb->prepare('SELECT id,text,correct FROM '.WPSQT_ANSWER_TABLE.' WHERE questionid = %d ORDER BY text ASC', array($origQuestion['id']) ), ARRAY_A);
Here is the site where I have used your plugin: https://www.passthischirotest.com
Thanks Again!