From d006cb2862382d2ea0a7f3097a0042d6b3f96951 Mon Sep 17 00:00:00 2001 From: andrewmbacon Date: Mon, 9 Nov 2015 15:43:27 -0500 Subject: [PATCH 01/23] Fixing UUP bug --- sass/_uup.scss | 4 +++- style.css | 2 ++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/sass/_uup.scss b/sass/_uup.scss index cbf7ad4..4d2bca1 100644 --- a/sass/_uup.scss +++ b/sass/_uup.scss @@ -48,7 +48,9 @@ } .uup-phones { .uup-phone1 {} - .uup-phone2 {} + .uup-phone2 { + display:block; + } } .uup-email { } diff --git a/style.css b/style.css index 951b0b3..57d5e66 100644 --- a/style.css +++ b/style.css @@ -7547,6 +7547,8 @@ q:before, table q:after { font-weight: bold; } .uup-list .uup-item .uup-text .uup-name .uup-first:after { content: ' '; } + .uup-list .uup-item .uup-text .uup-phones .uup-phone2 { + display: block; } .uup-index-table .uup-table-name.table-has-image { position: relative; From d91ac7d0e6a1ea2fa4f12ad1abed618ca62f09eb Mon Sep 17 00:00:00 2001 From: andrewmbacon Date: Wed, 11 Nov 2015 13:13:43 -0500 Subject: [PATCH 02/23] Person Content Template, and person archives. --- archive.php | 20 +++++++++++---- content-person.php | 62 ++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 77 insertions(+), 5 deletions(-) create mode 100644 content-person.php diff --git a/archive.php b/archive.php index 6ef1cab..0c50129 100755 --- a/archive.php +++ b/archive.php @@ -61,6 +61,12 @@ get_header(); ?> elseif ( is_tax( 'post_format', 'post-format-chat' ) ) : _e( 'Chats', 'cs' ); + + elseif ( is_tax( 'group') || is_tax('persontag')): + global $wp_query; + $term = $wp_query->get_queried_object(); + $name = $term->name; + echo $name; else : _e( 'Archives', 'cs' ); @@ -81,11 +87,15 @@ get_header(); ?> diff --git a/content-person.php b/content-person.php new file mode 100644 index 0000000..dbf0e57 --- /dev/null +++ b/content-person.php @@ -0,0 +1,62 @@ + +
> + + '; + echo ''; + echo '
'; + } ?> +
+ '; + the_field('first_name'); + echo ' '; + if (get_field('middle_name')){ + the_field('middle_name'); + echo ' '; + } + the_field('last_name'); + echo ''; + ?> +
+ + + + +
+ '.get_field('title').'

'; + if (strlen(get_field('email')) . 0 ){ + echo '

'.get_field('email').'

'; + } + if (strlen(get_field('phone')) > 0 ){ + echo '

'.get_field('phone').'

'; + } + + ?> + + + + +
+ '', + ) ); + ?> +
+ + '; + echo '
'; + } ?> +
From d2238fcbbd8d2a298ee75ac375fe50fdd5b47324 Mon Sep 17 00:00:00 2001 From: andrewmbacon Date: Wed, 11 Nov 2015 13:19:27 -0500 Subject: [PATCH 03/23] cleaning --- single-person.php | 27 --------------------------- 1 file changed, 27 deletions(-) diff --git a/single-person.php b/single-person.php index 7717029..aac4638 100644 --- a/single-person.php +++ b/single-person.php @@ -38,33 +38,6 @@ get_header(); ?> Contact Information'.$field_label.''; - echo '

'; - if ($field == 'email'){ - echo ''; - the_field($field); - echo ''; - } else if ($field == 'file'){ - $file = get_field($field); - $url= $file['url']; - echo ' '; - echo $file['title']; - echo ''; - } else { - the_field($field); - } - echo '


'; - } - } - */ function displayField($field){ if (get_field($field)){ From 06c811093b5a80b1d522de4b0347c4260a817100 Mon Sep 17 00:00:00 2001 From: andrewmbacon Date: Wed, 11 Nov 2015 13:28:53 -0500 Subject: [PATCH 04/23] Adaptive person template Changes layout based on presence of 'about' --- inc/person-no-about.php | 58 +++++++++++++++++++++++++++++++ inc/person-with-about.php | 62 +++++++++++++++++++++++++++++++++ single-person.php | 73 +++++---------------------------------- 3 files changed, 128 insertions(+), 65 deletions(-) create mode 100644 inc/person-no-about.php create mode 100644 inc/person-with-about.php diff --git a/inc/person-no-about.php b/inc/person-no-about.php new file mode 100644 index 0000000..d1ead73 --- /dev/null +++ b/inc/person-no-about.php @@ -0,0 +1,58 @@ +
+ '; + the_post_thumbnail(); + echo '
'; + };?> + +
+

+

+

+
+ Contact Information + '; + echo ''; + } + } + displayField('email'); + displayField('phone'); + displayField('phone_(alternate)'); + displayField('fax'); + displayField('file'); + displayField('mailing_address'); + displayField('office_location'); + displayField('office_hours'); + displayField('courses'); + ?> +
'.$field_label.''; + if ($field == 'email'){ + echo ''; + the_field($field); + echo ''; + } else if ($field == 'file'){ + $file = get_field($field); + $url= $file['url']; + echo ' '; + echo $file['title']; + echo ''; + } else { + the_field($field); + } + echo '
+ diff --git a/inc/person-with-about.php b/inc/person-with-about.php new file mode 100644 index 0000000..ea5ccc7 --- /dev/null +++ b/inc/person-with-about.php @@ -0,0 +1,62 @@ +
+

+

+

+
+ +
+
+ '; + the_post_thumbnail(); + echo '
'; + };?> +
+ + Contact Information + '; + echo ''; + } + } + displayField('email'); + displayField('phone'); + displayField('phone_(alternate)'); + displayField('fax'); + displayField('file'); + displayField('mailing_address'); + displayField('office_location'); + displayField('office_hours'); + displayField('courses'); + ?> +
'.$field_label.''; + if ($field == 'email'){ + echo ''; + the_field($field); + echo ''; + } else if ($field == 'file'){ + $file = get_field($field); + $url= $file['url']; + echo ' '; + echo $file['title']; + echo ''; + } else { + the_field($field); + } + echo '
+
+ \ No newline at end of file diff --git a/single-person.php b/single-person.php index aac4638..aefe8cc 100644 --- a/single-person.php +++ b/single-person.php @@ -13,72 +13,15 @@ get_header(); ?>
-
-

-

-

-
- -
-
- '; - the_post_thumbnail(); - echo '
'; - };?> -
- - Contact Information - '; - echo ''; - } - } - displayField('email'); - displayField('phone'); - displayField('phone_(alternate)'); - displayField('fax'); - displayField('file'); - displayField('mailing_address'); - displayField('office_location'); - displayField('office_hours'); - displayField('courses'); - ?> -
'.$field_label.''; - if ($field == 'email'){ - echo ''; - the_field($field); - echo ''; - } else if ($field == 'file'){ - $file = get_field($field); - $url= $file['url']; - echo ' '; - echo $file['title']; - echo ''; - } else { - the_field($field); - } - echo '
-
-
+ 0){ + include('inc/person-with-about.php'); + } else { + include('inc/person-no-about.php'); + } + ?>
- - From 67a12f57add80ddd82aed0ebb239f61b35a73384 Mon Sep 17 00:00:00 2001 From: andrewmbacon Date: Wed, 11 Nov 2015 14:08:38 -0500 Subject: [PATCH 05/23] Request for people not to use ALL CAPS --- inc/customizer-titlebar.php | 1 + 1 file changed, 1 insertion(+) diff --git a/inc/customizer-titlebar.php b/inc/customizer-titlebar.php index 7a4ba06..1d876db 100644 --- a/inc/customizer-titlebar.php +++ b/inc/customizer-titlebar.php @@ -1,6 +1,7 @@ get_section( 'title_tagline' )->title = 'Title Bar'; $wp_customize->remove_control('blogdescription');// removes tagline form field. + $wp_customize->get_control( 'blogname' )->description = 'Please use Title Case, not ALL CAPS, as defined in UConn Web Brand Standards. '; $wp_customize->add_setting( 'parentSiteTitle', array( From bbea1973b78c4dfd18577cce2ab4a54cd074d555 Mon Sep 17 00:00:00 2001 From: andrewmbacon Date: Thu, 12 Nov 2015 15:50:03 -0500 Subject: [PATCH 06/23] Megamenu Mobile Fixes --- css/megamenu-cornerstone-base.css | 18 +++++++++++------- sass/_nav.scss | 12 +++++++++++- style.css | 11 ++++++++++- 3 files changed, 32 insertions(+), 9 deletions(-) diff --git a/css/megamenu-cornerstone-base.css b/css/megamenu-cornerstone-base.css index 42ac96f..edfef3a 100644 --- a/css/megamenu-cornerstone-base.css +++ b/css/megamenu-cornerstone-base.css @@ -1,3 +1,13 @@ +#megamenu-wrapper { + background: #dbdbdb; + background: -webkit-gradient(linear, left top, left bottom, from(#ebebeb), to(#dbdbdb)); + background: -moz-linear-gradient(top, #ebebeb, #dbdbdb); + background: -ms-linear-gradient(top, #ebebeb, #dbdbdb); + background: -o-linear-gradient(top, #ebebeb, #dbdbdb); + background: linear-gradient(to bottom, #ebebeb, #dbdbdb); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ebebeb', endColorstr='#dbdbdb'); +} + #mega-menu-wrap-primary, #mega-menu-wrap-primary #mega-menu-primary, #mega-menu-wrap-primary #mega-menu-primary ul, #mega-menu-wrap-primary #mega-menu-primary li, #mega-menu-wrap-primary #mega-menu-primary p, #mega-menu-wrap-primary #mega-menu-primary img, #mega-menu-wrap-primary #mega-menu-primary div, #mega-menu-wrap-primary #mega-menu-primary a { color: #474747; font-family: inherit; @@ -562,13 +572,7 @@ z-index: 1; cursor: pointer; text-align: right; - background: #dbdbdb; - background: -webkit-gradient(linear, left top, left bottom, from(#ebebeb), to(#dbdbdb)); - background: -moz-linear-gradient(top, #ebebeb, #dbdbdb); - background: -ms-linear-gradient(top, #ebebeb, #dbdbdb); - background: -o-linear-gradient(top, #ebebeb, #dbdbdb); - background: linear-gradient(to bottom, #ebebeb, #dbdbdb); - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ebebeb', endColorstr='#dbdbdb'); + -webkit-border-radius: 2px 2px 2px 2px; -moz-border-radius: 2px 2px 2px 2px; -ms-border-radius: 2px 2px 2px 2px; diff --git a/sass/_nav.scss b/sass/_nav.scss index fc7cc49..e44f49e 100644 --- a/sass/_nav.scss +++ b/sass/_nav.scss @@ -171,6 +171,16 @@ $nav-z: 9999; } #megamenu-mobile-title { font-size:1.3em; - padding:.8em; + padding:.8em 90px .8em .8em; margin:0; +} +.mega-menu-toggle { + position:absolute; + right:0; + top:-3.2em; +} + +#megamenu-mobile-title a, +#megamenu-mobile-title a:hover { + color: $site-title-color; } \ No newline at end of file diff --git a/style.css b/style.css index 57d5e66..54720c7 100644 --- a/style.css +++ b/style.css @@ -5831,9 +5831,18 @@ button.close { #megamenu-mobile-title { font-size: 1.3em; - padding: .8em; + padding: .8em 90px .8em .8em; margin: 0; } +.mega-menu-toggle { + position: absolute; + right: 0; + top: -3.2em; } + +#megamenu-mobile-title a, +#megamenu-mobile-title a:hover { + color: black; } + /* - - - - - - - - - - - - - - - - - - - == Header Image - - - - - - - - - - - - - - - - - - - */ From 87cafebef90af001305df9f544ec4beab88fe742 Mon Sep 17 00:00:00 2001 From: briandunnigan Date: Thu, 19 Nov 2015 12:16:45 -0500 Subject: [PATCH 07/23] Test Commit for Test Compiling (Ignore) --- content-blank.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content-blank.php b/content-blank.php index f3a5fcc..a14ed33 100644 --- a/content-blank.php +++ b/content-blank.php @@ -12,4 +12,4 @@
', '' ); ?>
- \ No newline at end of file + \ No newline at end of file From c18053f18c1953bd2c21c60be670425b452c30f5 Mon Sep 17 00:00:00 2001 From: Joshua Roy Date: Thu, 19 Nov 2015 15:37:09 -0500 Subject: [PATCH 08/23] Change sorting to last name, first name --- user-people.php | 377 ++++++++++++++++++++++++------------------------ 1 file changed, 189 insertions(+), 188 deletions(-) diff --git a/user-people.php b/user-people.php index ee9f3d3..d37532e 100644 --- a/user-people.php +++ b/user-people.php @@ -1,188 +1,189 @@ - -
- - - -
-
-
-
-
> -
- ', '' ); ?> -
-
- -
- ', '' ); ?> -
-
- -1, - 'post_type' => 'person', - 'orderby' => 'menu_order title', - 'order' => 'ASC', - ); - - - - // Settings - - $layout = get_field( "layout" ); - $people_to_display = get_field( "people_to_display" ); - $break_into_groups = get_field( "break_into_groups" ); - $specific_people = get_field( "specific_people" ); - $specific_groups = get_field( "specific_groups" ); - $specific_tags = get_field( "specific_tags" ); - $information_to_display = get_field( "information_to_display" ); - - function createTextCell($setting, $field){ - global $information_to_display; - if (in_array($setting, $information_to_display)) { - echo ''; - the_field($field); - echo ''; - } - }; - - - - if ($specific_people){ - global $specific_people; - global $args; - $post__in = array(); - foreach($specific_people as &$value){ - array_push($post__in, $value->ID); - } - $args[post__in]= $post__in; - } - - // do we need a tax query? - if ($specific_groups != false || $specific_tags != false){ - - $tax_query = array(); - - if ($specific_groups != false) { - $group_query = array( - 'taxonomy' => 'group', - 'field' => 'term_id', - 'terms' => $specific_groups - ); - array_push($tax_query, $group_query); - } - if ($specific_tags != false) { - $tag_query = array( - 'taxonomy' => 'persontag', - 'field' => 'term_id', - 'terms' => $specific_tags - ); - array_push($tax_query, $tag_query); - } - $args[tax_query] = $tax_query; - - } - if ($break_into_groups == 1 ){ - //echo '

Break into Groups

'; - - // get all the people - $the_query = new WP_Query( $args ); - - // focusing on just the people, not the rest of the query. - $people = $the_query->posts; - - // look at each person, and see each group used, use that to create a list of terms. - $groups_in_use = array(); - - foreach($people as $value){ - $id = $value->ID; - $terms = get_the_terms($id, 'group'); - if (is_array($terms)){ - foreach($terms as $key => $value){ - //duplicates will overwrite themselves... - $slug = $value->slug; - $groups_in_use[$slug]= $slug; - } - }; - } - - // sort the groups in use alphabetically - sort($groups_in_use); - - // for each item in the list of terms, do a new query, but this time we're going to limit it to ONLY items from that one group. - foreach($groups_in_use as $value){ - - // this sets up the query we'll need, and will overwrite any group queries from the original settings. - $tax_query = array(); - $group_query = array( - 'taxonomy' => 'group', - 'field' => 'slug', - 'terms' => $value - ); - array_push($tax_query, $group_query); - $args['tax_query'] = $tax_query; - - // with $arg updated, let's do a new query. - echo '

'.get_term_by('slug', $value, 'group')->name.'

'; - - if ($layout == 'grid') { - include('inc/people-grid.php'); - } - if ($layout == 'table') { - include('inc/people-table.php'); - } - - } - - } else { - - if ($layout == 'grid') { - include('inc/people-grid.php'); - } - if ($layout == 'table') { - include('inc/people-table.php'); - } - - } - ?> - - -
-
-
-
-
-
- -
- - -
- - + +
+ + + +
+
+
+
+
> +
+ ', '' ); ?> +
+
+ +
+ ', '' ); ?> +
+
+ -1, + 'post_type' => 'person', + 'meta_key' => 'last_name', + 'orderby' => 'menu_order meta_value title', + 'order' => 'ASC', + ); + + + + // Settings + + $layout = get_field( "layout" ); + $people_to_display = get_field( "people_to_display" ); + $break_into_groups = get_field( "break_into_groups" ); + $specific_people = get_field( "specific_people" ); + $specific_groups = get_field( "specific_groups" ); + $specific_tags = get_field( "specific_tags" ); + $information_to_display = get_field( "information_to_display" ); + + function createTextCell($setting, $field){ + global $information_to_display; + if (in_array($setting, $information_to_display)) { + echo ''; + the_field($field); + echo ''; + } + }; + + + + if ($specific_people){ + global $specific_people; + global $args; + $post__in = array(); + foreach($specific_people as &$value){ + array_push($post__in, $value->ID); + } + $args[post__in]= $post__in; + } + + // do we need a tax query? + if ($specific_groups != false || $specific_tags != false){ + + $tax_query = array(); + + if ($specific_groups != false) { + $group_query = array( + 'taxonomy' => 'group', + 'field' => 'term_id', + 'terms' => $specific_groups + ); + array_push($tax_query, $group_query); + } + if ($specific_tags != false) { + $tag_query = array( + 'taxonomy' => 'persontag', + 'field' => 'term_id', + 'terms' => $specific_tags + ); + array_push($tax_query, $tag_query); + } + $args[tax_query] = $tax_query; + + } + if ($break_into_groups == 1 ){ + //echo '

Break into Groups

'; + + // get all the people + $the_query = new WP_Query( $args ); + + // focusing on just the people, not the rest of the query. + $people = $the_query->posts; + + // look at each person, and see each group used, use that to create a list of terms. + $groups_in_use = array(); + + foreach($people as $value){ + $id = $value->ID; + $terms = get_the_terms($id, 'group'); + if (is_array($terms)){ + foreach($terms as $key => $value){ + //duplicates will overwrite themselves... + $slug = $value->slug; + $groups_in_use[$slug]= $slug; + } + }; + } + + // sort the groups in use alphabetically + sort($groups_in_use); + + // for each item in the list of terms, do a new query, but this time we're going to limit it to ONLY items from that one group. + foreach($groups_in_use as $value){ + + // this sets up the query we'll need, and will overwrite any group queries from the original settings. + $tax_query = array(); + $group_query = array( + 'taxonomy' => 'group', + 'field' => 'slug', + 'terms' => $value + ); + array_push($tax_query, $group_query); + $args['tax_query'] = $tax_query; + + // with $arg updated, let's do a new query. + echo '

'.get_term_by('slug', $value, 'group')->name.'

'; + + if ($layout == 'grid') { + include('inc/people-grid.php'); + } + if ($layout == 'table') { + include('inc/people-table.php'); + } + + } + + } else { + + if ($layout == 'grid') { + include('inc/people-grid.php'); + } + if ($layout == 'table') { + include('inc/people-table.php'); + } + + } + ?> + + +
+
+
+
+
+
+ +
+ + +
+ + From 630b1dd16475da09c655f5d8dc651f0dafe23406 Mon Sep 17 00:00:00 2001 From: Joshua Roy Date: Tue, 1 Dec 2015 13:55:22 -0500 Subject: [PATCH 09/23] Fix mobile megamenu site title url --- inc/nav-maxmegamenu.php | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/inc/nav-maxmegamenu.php b/inc/nav-maxmegamenu.php index fd95416..6e1383c 100644 --- a/inc/nav-maxmegamenu.php +++ b/inc/nav-maxmegamenu.php @@ -1,16 +1,16 @@ -'; + } + + } + } + return; +} + +function disable_comments_media_attachments( $open, $post_id ){ + $post = get_post_type( $post_id ); + if( $post == 'attachment' ) { + $open = false; + } + return $open; +} +add_filter('comments_open', 'disable_comments_media_attachments', 10 , 2); + +function metaslider_filmstrip_alt_tags( $list_item, $post, $url ) { + $alt = get_post_meta( $post->ID, '_wp_attachment_image_alt', true ); + $list_item = "
  • ID} post-{$post->ID}\" style=\"display: none;\">\"{$alt}
  • "; + return $list_item; +} +add_filter( 'metaslider_filmstrip_list_item', 'metaslider_filmstrip_alt_tags', 10, 3 ); + + + +function remove_submenu() { + if (network_home_url() != 'http://development.wordpress.uconn.edu/'){ + remove_submenu_page( 'themes.php', 'megamenu_settings'); + } +} +add_action( 'admin_menu', 'remove_submenu', 999 ); + +function remove_core_widgets() { + unregister_widget('WP_Widget_Calendar'); + unregister_widget('WP_Widget_Meta'); +} +add_action( 'widgets_init', 'remove_core_widgets' ); + +function cornerstone_show_people(){ + if ( !is_plugin_active('uc-people/uc-people.php') ) { + activate_plugin('uc-people/uc-people.php'); + } +}; +add_action( 'admin_init', 'cornerstone_show_people' ); + +// Force the Page Builder plugin to include the 'simple-social-icons' class +add_filter( 'siteorigin_panels_widget_classes', 'ssi_add_widget_class' ); +function ssi_add_widget_class( $classes ) { + if ( in_array( 'widget_simple-social-icons', $classes ) ) { + $classes[] = 'simple-social-icons'; + } + + return $classes; +} + ?> \ No newline at end of file From 95b4f5662662dbe15881b6ae2d6193ea9842d863 Mon Sep 17 00:00:00 2001 From: briandunnigan Date: Fri, 11 Dec 2015 11:54:36 -0500 Subject: [PATCH 18/23] UC People Fix -Page headers -Table layouts --- sass/_content.scss | 56 +++++++++++++++++++++++++++++++++++++++++++++- sass/_widgets.scss | 3 +-- style.css | 48 ++++++++++++++++++++++++++++++++++----- 3 files changed, 99 insertions(+), 8 deletions(-) diff --git a/sass/_content.scss b/sass/_content.scss index 75dc228..057195d 100644 --- a/sass/_content.scss +++ b/sass/_content.scss @@ -171,4 +171,58 @@ a.btn { list-style-type: none; padding-bottom:10px; } -} \ No newline at end of file +} + +/*-------------------------------------------------------------- +10.5 UC People Page Template +--------------------------------------------------------------*/ + +#page-userlist { + .person { + padding-right:20px; + padding-bottom:20px; + padding-top:5px; + + ul { + list-style-type: disc; + } + ol { + list-style-type: decimal; + } + a.person-permalink { + h4.person-name { + font-size:19px; + } + } + } + + h3.group-title { + border-bottom: 1px solid #eee; + padding-bottom: 10px; + width: 100%; + } + + table { + margin-bottom:0px; + + td.person-thumbnail { + img { + max-width: none; + } + } + thead { + border-top:none !important; + border-bottom:none !important; + } + } + .table > thead > tr > th { + border-bottom:none !important; + } + .table > tbody > tr > td { + border-top:none !important; + } + .table > tbody > tr { + border-top:1px solid #eee; + border-bottom:1px solid #eee; + } +} \ No newline at end of file diff --git a/sass/_widgets.scss b/sass/_widgets.scss index 08eb945..4bc99ff 100644 --- a/sass/_widgets.scss +++ b/sass/_widgets.scss @@ -244,14 +244,13 @@ } a.person-permalink { h4.person-name { - font-size:19px; + font-size:19px; } } } h3.group-title { border-bottom: 1px solid #eee; - color: #ac0000; padding-bottom: 10px; width: 100%; } diff --git a/style.css b/style.css index d5033ae..c17ca15 100644 --- a/style.css +++ b/style.css @@ -7593,7 +7593,6 @@ button.close { } .home #content .widget.uc-people-widget h3.group-title { border-bottom: 1px solid #eee; - color: #ac0000; padding-bottom: 10px; width: 100%; } @@ -7987,7 +7986,6 @@ button.close { } .home #content .panel-grid .widget.uc-people-widget h3.group-title { border-bottom: 1px solid #eee; - color: #ac0000; padding-bottom: 10px; width: 100%; } @@ -8386,7 +8384,6 @@ button.close { } #page-sidebar .widget.uc-people-widget h3.group-title { border-bottom: 1px solid #eee; - color: #ac0000; padding-bottom: 10px; width: 100%; } @@ -8781,7 +8778,6 @@ button.close { } .subpage .widget.uc-people-widget h3.group-title { border-bottom: 1px solid #eee; - color: #ac0000; padding-bottom: 10px; width: 100%; } @@ -9437,6 +9433,49 @@ a.btn { padding-bottom: 10px; } +/*-------------------------------------------------------------- +10.5 UC People Page Template +--------------------------------------------------------------*/ +#page-userlist .person { + padding-right: 20px; + padding-bottom: 20px; + padding-top: 5px; +} +#page-userlist .person ul { + list-style-type: disc; +} +#page-userlist .person ol { + list-style-type: decimal; +} +#page-userlist .person a.person-permalink h4.person-name { + font-size: 19px; +} +#page-userlist h3.group-title { + border-bottom: 1px solid #eee; + padding-bottom: 10px; + width: 100%; +} +#page-userlist table { + margin-bottom: 0px; +} +#page-userlist table td.person-thumbnail img { + max-width: none; +} +#page-userlist table thead { + border-top: none !important; + border-bottom: none !important; +} +#page-userlist .table > thead > tr > th { + border-bottom: none !important; +} +#page-userlist .table > tbody > tr > td { + border-top: none !important; +} +#page-userlist .table > tbody > tr { + border-top: 1px solid #eee; + border-bottom: 1px solid #eee; +} + /* - - - - - - - - - - - - - - - - - - - == Captions - - - - - - - - - - - - - - - - - - - */ @@ -10036,7 +10075,6 @@ body.sticky .ie8 #footers { } #mega-footer .widget.uc-people-widget h3.group-title { border-bottom: 1px solid #eee; - color: #ac0000; padding-bottom: 10px; width: 100%; } From bb0173455916ab266465a63aa06f8016bce60aae Mon Sep 17 00:00:00 2001 From: Joshua Roy Date: Fri, 11 Dec 2015 13:37:54 -0500 Subject: [PATCH 19/23] UC People Bug Fixes --- inc/people-grid.php | 4 ++-- user-people.php | 8 +++++++- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/inc/people-grid.php b/inc/people-grid.php index 72301e9..40278a1 100644 --- a/inc/people-grid.php +++ b/inc/people-grid.php @@ -61,10 +61,10 @@ if ( $the_query->have_posts() ) { ?> }; if (in_array('file', $information_to_display)) { $file = get_field('file'); - $urlLength = strlen($file); + $urlLength = strlen($file['url']); if ($urlLength > 0){ echo '

    '; - echo ''.$file[title].''; + echo ''.$file['title'].''; echo '

    '; } }; diff --git a/user-people.php b/user-people.php index f1dd312..14a50f2 100644 --- a/user-people.php +++ b/user-people.php @@ -135,7 +135,13 @@ get_header(); ?> } }; } - + if(!empty($specific_groups) && is_array($specific_groups)){ + $groups_in_use = array(); + foreach($specific_groups as $group){ + $group = get_term_by('id', $group, 'group'); + $groups_in_use[] = $group->slug; + } + } // sort the groups in use alphabetically //sort($groups_in_use); usort($groups_in_use, 'sort_group_by_order' ); From b757e6c51e35af4ede8498abbd6e98e92feafbf6 Mon Sep 17 00:00:00 2001 From: briandunnigan Date: Mon, 14 Dec 2015 15:00:22 -0500 Subject: [PATCH 20/23] Removing 'Hello World' from archive.php --- archive.php | 1 - 1 file changed, 1 deletion(-) diff --git a/archive.php b/archive.php index f9fec31..f11fb25 100644 --- a/archive.php +++ b/archive.php @@ -10,7 +10,6 @@ get_header(); ?>
    -

    Hello World

    From f9ba36dca458a26b2f7b3460ff59dac1d45889d3 Mon Sep 17 00:00:00 2001 From: briandunnigan Date: Wed, 16 Dec 2015 12:24:02 -0500 Subject: [PATCH 21/23] UC People Archive - Adding Class --- content-person.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content-person.php b/content-person.php index dbf0e57..bc7e051 100644 --- a/content-person.php +++ b/content-person.php @@ -15,7 +15,7 @@ $information_to_display = get_field( "information_to_display" ); } ?>
    '; + echo '

    '; the_field('first_name'); echo ' '; if (get_field('middle_name')){ From c607e658921d82969c59eff8dedaf53a3e3c06e1 Mon Sep 17 00:00:00 2001 From: Joshua Roy Date: Thu, 17 Dec 2015 15:24:54 -0500 Subject: [PATCH 22/23] UC People Update --- inc/people-grid.php | 16 ++++ inc/people-table.php | 14 ++++ single-person.php | 169 ++++++++++++++++++++++++++++++++++--------- 3 files changed, 166 insertions(+), 33 deletions(-) diff --git a/inc/people-grid.php b/inc/people-grid.php index 40278a1..5163dd0 100644 --- a/inc/people-grid.php +++ b/inc/people-grid.php @@ -54,6 +54,14 @@ if ( $the_query->have_posts() ) { ?> } echo '

    '; }; + if (in_array('department', $information_to_display)) { + echo '

    '; + $departmentPieces = explode(";", get_field('department')); + foreach( $departmentPieces as $d ){ + echo ( !empty($d) ? "{$d}
    ": "" ); + } + echo '

    '; + }; if (in_array('about', $information_to_display)) { echo '

    diff --git a/inc/people-table.php b/inc/people-table.php index 06d84df..c936b76 100644 --- a/inc/people-table.php +++ b/inc/people-table.php @@ -90,6 +90,14 @@ if ( $the_query->have_posts() ) { } echo ''; } + if (in_array('department', $information_to_display)) { + echo ''; + $departmentPieces = explode(";", get_field('department')); + foreach( $departmentPieces as $d ){ + echo ( !empty($d) ? "{$d}
    ": "" ); + } + echo ''; + } createTextCell('about', 'about'); if (in_array('file', $information_to_display)) { echo ''; @@ -112,8 +120,14 @@ if ( $the_query->have_posts() ) { echo ''; } createTextCell('office_location', 'office_location'); + createTextCell('campus', 'campus'); createTextCell('office_hours', 'office_hours'); createTextCell('courses', 'courses'); + if (in_array('url', $information_to_display)) { + echo ''; + echo ''.get_field('url').''; + echo ''; + }; diff --git a/single-person.php b/single-person.php index aefe8cc..1d06553 100644 --- a/single-person.php +++ b/single-person.php @@ -1,33 +1,136 @@ - - -
    - - -
    -
    -
    -
    -
    - 0){ - include('inc/person-with-about.php'); - } else { - include('inc/person-no-about.php'); - } - ?> -
    -
    -
    -
    - -
    - - -
    - + + +
    + + +
    +
    +
    +
    +
    +
    +

    +

    + + '.$t.'

    ': '' ); + } + $departmentPieces = explode(";", get_field('department')); + foreach( $departmentPieces as $d ){ + echo ( !empty($d) ? '

    '.$d.'

    ': '' ); + } + ?> +
    + +
    +
    + '; + the_post_thumbnail(); + echo '
    '; + };?> +
    + + Contact Information + '.$field_label.''; + echo '

    '; + if ($field == 'email'){ + echo ''; + the_field($field); + echo ''; + } else if ($field == 'file'){ + $file = get_field($field); + $url= $file['url']; + echo ' '; + echo $file['title']; + echo ''; + } else { + the_field($field); + } + echo '


    '; + } + } + */ + function displayField($field){ + if (get_field($field)){ + + $field_key = 'field_'.$field; + $field_obj = get_field_object($field_key); + $field_value = $field_obj['value']; + $field_label = $field_obj['label']; + echo ''; + if ($field == 'file'){ + echo ''; + } else { + echo ''; + } + echo ''; + } + } + displayField('email'); + displayField('phone'); + displayField('phone_(alternate)'); + displayField('fax'); + displayField('file'); + displayField('mailing_address'); + displayField('office_location'); + displayField('campus'); + displayField('office_hours'); + displayField('courses'); + displayField('url'); + ?> +
    '.get_field('filelabel').''.$field_label.''; + if ($field == 'email'){ + echo ''; + the_field($field); + echo ''; + } else if ($field == 'file'){ + $file = get_field($field); + $url= $file['url']; + echo ' '; + echo $file['title']; + echo ''; + } else if ($field == 'mailing_address'){ + echo str_replace(';','
    ',get_field('mailing_address')); + } else { + the_field($field); + } + echo '
    +
    +
    +
    + + + +
    +
    + +
    + + +
    + From 69e139d6acd704500363a6cc596515d2cd27c5b1 Mon Sep 17 00:00:00 2001 From: Joshua Roy Date: Thu, 17 Dec 2015 15:41:39 -0500 Subject: [PATCH 23/23] Fixing out of sync issue --- inc/person-info.php | 48 ++++++++++++++++ inc/person-no-about.php | 46 ++------------- inc/person-with-about.php | 46 ++------------- single-person.php | 117 +++----------------------------------- 4 files changed, 65 insertions(+), 192 deletions(-) create mode 100644 inc/person-info.php diff --git a/inc/person-info.php b/inc/person-info.php new file mode 100644 index 0000000..b41b402 --- /dev/null +++ b/inc/person-info.php @@ -0,0 +1,48 @@ + + Contact Information + '; + if ($field == 'file'){ + echo ''; + } else { + echo ''; + } + echo ''; + } + } + displayField('email'); + displayField('phone'); + displayField('phone_(alternate)'); + displayField('fax'); + displayField('file'); + displayField('mailing_address'); + displayField('office_location'); + displayField('campus'); + displayField('office_hours'); + displayField('courses'); + displayField('url'); + ?> +
    '.get_field('filelabel').''.$field_label.''; + if ($field == 'email'){ + echo ''; + the_field($field); + echo ''; + } else if ($field == 'file'){ + $file = get_field($field); + $url= $file['url']; + echo ' '; + echo $file['title']; + echo ''; + } else if ($field == 'mailing_address'){ + echo str_replace(';','
    ',get_field('mailing_address')); + } else { + the_field($field); + } + echo '
    \ No newline at end of file diff --git a/inc/person-no-about.php b/inc/person-no-about.php index 78d737a..7ec1704 100644 --- a/inc/person-no-about.php +++ b/inc/person-no-about.php @@ -21,46 +21,10 @@ foreach( $titlePieces as $t ){ echo ( !empty($t) ? '

    '.$t.'

    ': '' ); } + $departmentPieces = explode(";", get_field('department')); + foreach( $departmentPieces as $d ){ + echo ( !empty($d) ? '

    '.$d.'

    ': '' ); + } ?> - - Contact Information - '; - echo ''; - } - } - displayField('email'); - displayField('phone'); - displayField('phone_(alternate)'); - displayField('fax'); - displayField('file'); - displayField('mailing_address'); - displayField('office_location'); - displayField('office_hours'); - displayField('courses'); - ?> -
    '.$field_label.''; - if ($field == 'email'){ - echo ''; - the_field($field); - echo ''; - } else if ($field == 'file'){ - $file = get_field($field); - $url= $file['url']; - echo ' '; - echo $file['title']; - echo ''; - } else if ($field == 'mailing_address'){ - echo str_replace(';','
    ',get_field('mailing_address')); - } else { - the_field($field); - } - echo '
    +
    diff --git a/inc/person-with-about.php b/inc/person-with-about.php index 1c87360..824aea5 100644 --- a/inc/person-with-about.php +++ b/inc/person-with-about.php @@ -14,6 +14,10 @@ foreach( $titlePieces as $t ){ echo ( !empty($t) ? '

    '.$t.'

    ': '' ); } + $departmentPieces = explode(";", get_field('department')); + foreach( $departmentPieces as $d ){ + echo ( !empty($d) ? '

    '.$d.'

    ': '' ); + } ?>
    @@ -25,46 +29,6 @@ echo ''; };?>
    - - Contact Information - '; - echo ''; - } - } - displayField('email'); - displayField('phone'); - displayField('phone_(alternate)'); - displayField('fax'); - displayField('file'); - displayField('mailing_address'); - displayField('office_location'); - displayField('office_hours'); - displayField('courses'); - ?> -
    '.$field_label.''; - if ($field == 'email'){ - echo ''; - the_field($field); - echo ''; - } else if ($field == 'file'){ - $file = get_field($field); - $url= $file['url']; - echo ' '; - echo $file['title']; - echo ''; - } else if ($field == 'mailing_address'){ - echo str_replace(';','
    ',get_field('mailing_address')); - } else { - the_field($field); - } - echo '
    +
    \ No newline at end of file diff --git a/single-person.php b/single-person.php index 1d06553..d11fc36 100644 --- a/single-person.php +++ b/single-person.php @@ -13,118 +13,15 @@ get_header(); ?>
    -
    -

    -

    - - '.$t.'

    ': '' ); + 0){ + include('inc/person-with-about.php'); + } else { + include('inc/person-no-about.php'); } - $departmentPieces = explode(";", get_field('department')); - foreach( $departmentPieces as $d ){ - echo ( !empty($d) ? '

    '.$d.'

    ': '' ); - } - ?> -
    - -
    -
    - '; - the_post_thumbnail(); - echo '
    '; - };?> -
    - - Contact Information - '.$field_label.''; - echo '

    '; - if ($field == 'email'){ - echo ''; - the_field($field); - echo ''; - } else if ($field == 'file'){ - $file = get_field($field); - $url= $file['url']; - echo ' '; - echo $file['title']; - echo ''; - } else { - the_field($field); - } - echo '


    '; - } - } - */ - function displayField($field){ - if (get_field($field)){ - - $field_key = 'field_'.$field; - $field_obj = get_field_object($field_key); - $field_value = $field_obj['value']; - $field_label = $field_obj['label']; - echo ''; - if ($field == 'file'){ - echo ''; - } else { - echo ''; - } - echo ''; - } - } - displayField('email'); - displayField('phone'); - displayField('phone_(alternate)'); - displayField('fax'); - displayField('file'); - displayField('mailing_address'); - displayField('office_location'); - displayField('campus'); - displayField('office_hours'); - displayField('courses'); - displayField('url'); - ?> -
    '.get_field('filelabel').''.$field_label.''; - if ($field == 'email'){ - echo ''; - the_field($field); - echo ''; - } else if ($field == 'file'){ - $file = get_field($field); - $url= $file['url']; - echo ' '; - echo $file['title']; - echo ''; - } else if ($field == 'mailing_address'){ - echo str_replace(';','
    ',get_field('mailing_address')); - } else { - the_field($field); - } - echo '
    -
    -
    + ?>
    - -