Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
<?php
add_action( 'wp_enqueue_scripts', 'theme_enqueue_styles', 2 );
function theme_enqueue_styles() {
wp_enqueue_style( 'inn-css', get_stylesheet_directory_uri() . '/css/innovation.css', array('cs-style') );
//wp_enqueue_script( 'inn-js', get_stylesheet_directory_uri() . '/js/innovation.js', array( 'cs' ));
}
function show_people(){
if ( !is_plugin_active('uc-people/uc-people.php') ) {
activate_plugin('uc-people/uc-people.php');
}
};
//add_action( 'after_switch_theme', 'show_people' );
function hide_people(){
if ( is_plugin_active('uc-people/uc-people.php') ) {
deactivate_plugins('uc-people/uc-people.php');
}
};
//add_action( 'switch_theme', 'hide_people' );
function hide_uup(){
global $wp_themes;
if ( is_plugin_active('uup/uup.php') ) {
remove_shortcode('uc_uup');
}
};
//add_action( 'init', 'hide_uup' );
function tfc_remove_page_templates( $templates ) {
unset( $templates['page-user-profile.php'] );
unset( $templates['user-index-table.php'] );
unset( $templates['user-index.php'] );
return $templates;
}
add_filter( 'theme_page_templates', 'tfc_remove_page_templates' );
// Rename existing "Groups" and "Tags" taxonomies.
// sauce: http://wordpress.stackexchange.com/questions/4182/can-the-default-post-tags-taxonomy-be-renamed
function rename_people_taxonomies() {
global $wp_taxonomies;
// The list of labels we can modify comes from
// http://codex.wordpress.org/Function_Reference/register_taxonomy
// http://core.trac.wordpress.org/browser/branches/3.0/wp-includes/taxonomy.php#L350
$wp_taxonomies['group']->labels = (object)array(
'name' => 'Areas of Expertise',
'menu_name' => 'Areas of Expertise',
'singular_name' => 'Area',
'search_items' => 'Search Areas',
'popular_items' => 'Popular Areas',
'all_items' => 'All Areas',
'parent_item' => 'Parent Area',
'parent_item_colon' => ':',
'edit_item' => 'Edit Area',
'update_item' => 'Update Area',
'add_new_item' => 'Add new Area',
'new_item_name' => 'New Area',
'separate_items_with_commas' => null,
'add_or_remove_items' => 'Add or remove Areas',
'choose_from_most_used' => 'Choose from the most used Areas',
);
$wp_taxonomies['group']->label = 'Areas of Expertise';
$wp_taxonomies['persontag']->labels = (object)array(
'name' => 'Specialties',
'menu_name' => 'Specialties',
'singular_name' => 'Specialty',
'search_items' => 'Search Specialties',
'popular_items' => 'Popular Specialties',
'all_items' => 'All Specialties',
'parent_item' => null, // Tags aren't hierarchical
'parent_item_colon' => null,
'edit_item' => 'Edit Specialty',
'update_item' => 'Update Specialty',
'add_new_item' => 'Add new Specialty',
'new_item_name' => 'New Specialty Name',
'separate_items_with_commas' => 'Separata Specialties with commas',
'add_or_remove_items' => 'Add or remove Specialties',
'choose_from_most_used' => 'Choose from the most used Specialties',
);
$wp_taxonomies['persontag']->label = 'Specialties';
}
add_action( 'init', 'rename_people_taxonomies');
add_filter('acf/settings/show_admin', '__return_true');
if( function_exists('acf_add_local_field_group') ):
acf_add_local_field_group(array (
'key' => 'group_55f6df84519b8',
'title' => 'Innovation People Fields',
'fields' => array (
array (
'key' => 'field_55f6e07c40980',
'label' => 'Faculty Website',
'name' => 'faculty_website',
'type' => 'url',
'instructions' => 'Enter the full address, including "http://"',
'required' => 0,
'conditional_logic' => 0,
'wrapper' => array (
'width' => '',
'class' => '',
'id' => '',
),
'default_value' => '',
'placeholder' => '',
),
array (
'key' => 'field_55f6e21940982',
'label' => 'Name Suffix',
'name' => 'name_suffix',
'type' => 'text',
'instructions' => 'Appears after last name. i.e. "Ph.D."',
'required' => 0,
'conditional_logic' => 0,
'wrapper' => array (
'width' => '',
'class' => '',
'id' => '',
),
'default_value' => '',
'placeholder' => '',
'prepend' => '',
'append' => '',
'maxlength' => '',
'readonly' => 0,
'disabled' => 0,
),
array (
'key' => 'field_55f6fd09d43b7',
'label' => 'Summary',
'name' => 'summary',
'type' => 'wysiwyg',
'instructions' => 'Appears on Grid/Expertise page only. Full Text goes into "About". ',
'required' => 0,
'conditional_logic' => 0,
'wrapper' => array (
'width' => '',
'class' => '',
'id' => '',
),
'default_value' => '',
'tabs' => 'all',
'toolbar' => 'full',
'media_upload' => 1,
),
),
'location' => array (
array (
array (
'param' => 'post_type',
'operator' => '==',
'value' => 'person',
),
),
),
'menu_order' => 0,
'position' => 'normal',
'style' => 'default',
'label_placement' => 'top',
'instruction_placement' => 'label',
'hide_on_screen' => '',
'active' => 1,
'description' => '',
));
endif;
?>