Pulling values from a sepcific row in table

$leader_result = $wpdb->get_results(“SELECT user_first_name, user_last_name FROM “.$wpdb->prefix.”mro_attendees WHERE event_id = “.$project_id.” AND user_role=”team_leader” LIMIT 0,1″) foreach($leader_result as $row=>$value) { echo $value->column_name; }

WordPress custom posttype meta values doesnot save

You forgot to declare global $post //Create Meta box function astest_add_metabox() { add_meta_box(“astestimonial_metaboxes”, “AS-Testimonial Client Information”, “astestimonial_meta_box”, “astestimonial”, “side”, “low”); } add_action(‘add_meta_boxes’,’astest_add_metabox’); //html code function astestimonial_meta_box() { global $post; wp_nonce_field(‘astest_meta_box’,’astest_meta_box_nonce’); $clientname = get_post_meta($post->ID,’clientname_value’,true); echo'<label for=”client_name_val”>’; _e(‘Name: ‘, ‘astestimonial_textdomain’); echo'</label>’; echo'<input type=”text” id=”clientname_value” name=”clientname_value” value=”‘.esc_attr($clientname).'” />’; } //save post function as_testi_save_data($post_id){ if(isset($_POST[‘post_type’]) && ($_POST[‘post_type’] == “astestimonial”)) … Read more

Database Name Change

Ok… So after some more research I found: http://andrewapeterson.com/2012/08/fix-wordpress-media-library-and-attachments-broken-after-movingcloning-site/ which explains that you can’t just do a find and replace in a text editor and be good to go. Fortunately, I still had the original database, so I dropped all the tables in the tsi_ database and restored the original wp_ database. All my images … Read more