Skip to content
This repository has been archived by the owner. It is now read-only.

Fixing sharelines #13

Merged
merged 1 commit into from Aug 18, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion content-single.php
Expand Up @@ -26,7 +26,7 @@

<div class="entry-content clearfix subpage">
<?php
if(get_post_meta( $post->ID, 'enable_sharelines', true)){
if(get_post_meta( $post->ID, 'enable_sharelines', true) != 'disabled'){
?>
<div class="sharelines">
<?php
Expand Down
17 changes: 8 additions & 9 deletions functions.php
Expand Up @@ -330,9 +330,9 @@ acf_add_local_field_group(array (
'fields' => array (
array (
'key' => 'field_598483a2ea9d9',
'label' => 'Enable Sharelines',
'label' => 'Sharelines',
'name' => 'enable_sharelines',
'type' => 'checkbox',
'type' => 'radio',
'instructions' => '',
'required' => 0,
'conditional_logic' => 0,
Expand All @@ -342,15 +342,14 @@ acf_add_local_field_group(array (
'id' => '',
),
'choices' => array (
'Enable Sharelines' => 'Enable Sharelines',
),
'allow_custom' => 0,
'save_custom' => 0,
'default_value' => array (
0 => 'Enable Sharelines',
'enabled' => 'Enabled',
'disabled' => 'Disabled',
),
'allow_null' => 0,
'other_choice' => 0,
'save_other_choice' => 0,
'default_value' => 'enabled',
'layout' => 'vertical',
'toggle' => 0,
'return_format' => 'value',
),
array (
Expand Down