if ($hex == '') { $out = $out . urlencode($in[$i]); } else { $out = $out . '%' . (strlen($hex) == 1 ? '0' . strtoupper($hex) : strtoupper($hex)); } } $out = str_replace('+', '%20', $out); $out = str_replace('_', '%5F', $out); $out = str_replace('.', '%2E', $out); $out = str_replace('-', '%2D', $out); return $out; } if (have_posts()) { while (have_posts()) { the_post(); $post_info = get_post_info(get_the_ID()); ?> <article id="post-<?php the_ID(); ?> " <?php post_class(); ?> > <?php if (is_front_page()) { ?> <?php } else { get_template_part('testimonials', 'featured');
function get_person_popup($post) { ?> <?php $picture = wp_get_attachment_url(get_post_thumbnail_id($postid)); ?> <div class="person-popup" id="person-popup-<?php echo $post->ID; ?> "> <div class="popup-image"><img src="<?php echo $picture; ?> "></div> <div class="popup-info"><?php echo get_post_info($post->ID); ?> </div> <div class="popup-content"><?php echo $post->post_content; ?> </div> <div class="popup-close"><a href="#person_popup_close" onClick="close_popup(); return false;">Close</a></div> </div> <?php }
<?php $cp = get_post_info(get_the_ID()); $id = get_the_ID(); //echo $id; $cats = wp_get_post_terms($id, 'areas'); //print_r($cats); $tax = array(array('taxonomy' => 'areas', 'field' => 'slug', 'terms' => $cats[0]->slug, 'operator' => 'IN')); //print_r($tax); $args = array('post_type' => 'testimonials', 'tax_query' => $tax, 'orderby' => 'rand'); $tests = get_posts($args); if (!count($tests)) { return; } if ($id == 10) { echo '<h4 class="banner">Reviews</h4>'; } else { echo '<h4 class="banner">Testimonials</h4>'; } foreach ($tests as $test) { echo '<div class="testimonial">'; $test = get_post_info($test->ID); if (is_front_page()) { echo '<p class="quote-big">' . $test->highlight . '</p>'; } else { echo '<p class="quote-big">' . $test->post_content . '</p>'; } echo '<p class="who museo-text">' . $test->person_name . '</p>'; echo '<p class="what museo-text">' . $test->person_title . '</p>'; echo '</div>'; }
<div <?php if (MultiPostThumbnails::get_the_post_thumbnail('post', 'second-slide', NULL, 'portfoliolarge') != '' && $homeslideshow == 'false') { echo 'class="homeslider"'; } ?> > <?php if (function_exists('has_post_thumbnail') && has_post_thumbnail()) { /* if the post has a WP 2.9+ Thumbnail */ if ($fsize == 'half') { get_post_info('smallrecfeatured', $post->ID, 'Yes', $thumbnum); } else { if ($fcol == 'two_col') { get_post_info('largefeatured', $post->ID, 'Yes', $thumbnum); } else { get_post_info('smallfeatured', $post->ID, 'Yes', $thumbnum); } } ?> <img src="<?php echo $thumb[0]; ?> " alt="<?php if ($alt) { echo str_replace('"', "", $alt); } else { echo the_title(); } ?> " title="<?php
<?php } else { /* If Not a Video Post /*-----------------------------------------------------------------------------------*/ $crop = get_option('of_slide_crop'); $popup = get_option('of_slideshow_popup'); // Get number of slides or set the default if ($thumbnum = of_get_option('of_thumbnail_number')) { $thumbnum = $thumbnum + 1; } else { $thumbnum = 7; } if (function_exists('has_post_thumbnail') && has_post_thumbnail()) { // if the post has a WP 2.9+ Thumbnail get_post_info($slide_crop, $post->ID, $slide_crop, $thumbnum); ?> <div class="featuredimage"> <div class="slider-wrapper theme-default"> <div <?php if (MultiPostThumbnails::get_the_post_thumbnail('post', 'second-slide', NULL, 'portfoliolarge') != '') { echo $auto_play == 'No' || $auto_play == 'no' ? 'class="slider nivoSlider"' : 'class="sliderautoplay nivoSlider"'; } ?> > <?php if ($popup == 'On') { ?> <a href="<?php
<section id="get-in-touch"> <?php $cats = wp_get_post_terms($id, 'areas'); $cat = $cats[0]; if (is_front_page() || true) { echo '<h4 class="banner">Get in Touch</h4>'; } else { echo '<h4 class="banner">Get in Touch about ' . $cat->name . '</h4>'; } echo '<p class="verdana-text">' . get_post_info(128)->post_content . '</p>'; echo do_shortcode('[contact-form-7 id="335" title="Get in Touch"]'); ?> </section>
function get_slug($pid) { $post_obj = get_post_info($pid); return $post_obj->post_name; }
<?php include 'header.php'; if (!empty($_GET['postId'])) { $postId = $_GET['postId']; } else { header('Location: http://students.washington.edu/em42/arch482/final/'); exit; } //post has: postId, userId, catId, views, title, postContnet, timestamp $postInfo = get_post_info($db, $postId); $userName = get_username($db, $postInfo['userId']); ?> <section class="view-post"> <div class="container"> <p class="right"> Posted by <?php echo $userName; ?> <br> <?php echo $postInfo['timestamp']; ?> </p> <h1 class="left"><?php echo $postInfo['title']; ?> </h1> <hr> <div class="content"> <p>