Tuesday 26 March 2013

Making seperate Social Media buttons for each Tour in Wordpress Midway Responsive -

Working on Wordpress website with the theme 'Midway Responsive' I was asked the following question by the customer.

Change the Home page FB icon link to our main tours Social Media stream and if possible on each tour page we would like the social media links to be different?

Here's how I solved this problem; I'll show you how to do it for the facebook link, for the rest all you need to do is repeat the process but replacing 'facebook' for the media stream you want.

OPEN wp-content/themes/midway/framework/config.php

around line 360 find
//Tours			array(				'id' => 'tour_metabox',				'title' =>  __('Tour Options', 'midway'),				'page' => 'tour',				'context' => 'normal',				'priority' => 'high',								'options' => array(
ADD UNDERNEATH
array(	'name' => __('Facebook','midway'),							'desc' => __('Does this tour have a seperate Facebook Account','midway'),							'id' => 'facebook',							'type' => 'text'),	
SAVE

OPEN wp-content/themes/(your child theme name)/header.php

FIND
						

REPLACE WITH
					ID,'_tour_facebook',true)) { 					$facebooklink=get_post_meta($post->ID,'_tour_facebook',true);?>					

SAVE AND UPLOAD
It's also worth reading this about Taxonomy , which is the process that your using to add to the array http://codex.wordpress.org/Taxonomies

No comments: