adding tripadvisor and flickr to the social media view files
authorAnthony Talarico <talarico@gaslightmedia.com>
Sun, 20 Oct 2019 20:16:05 +0000 (16:16 -0400)
committerAnthony Talarico <talarico@gaslightmedia.com>
Sun, 20 Oct 2019 20:16:05 +0000 (16:16 -0400)
controllers/Admin.php
views/footer.php
views/social-media.php

index 8e0bb7a..951873d 100644 (file)
@@ -348,13 +348,7 @@ class Glmclientinfo_Admin_Controller
                 'type'  => 'textarea'
             ),
         );
-        
-        // foreach($fieldNames as $index => $setting){
-        //     if( ! in_array( $setting['name'], get_option( GLM_CLIENTINFO_SETTINGS ) ) &&  get_option( GLM_CLIENTINFO_SETTINGS ) !== FALSE ){
-        //         update_option(GLM_CLIENTINFO_SETTINGS , $fieldNames);
-        //     }
-        // }
-   
+
         $fieldNames2 = array(
             array(
                 'name'  => 'address2',
@@ -405,42 +399,7 @@ class Glmclientinfo_Admin_Controller
                 'name'  => 'gpslon2',
                 'label' => 'Secondary GPS Lon.',
                 'type'  => 'text'
-            ),
-            array(
-                'name'  => 'facebook',
-                'label' => 'Facebook',
-                'type'  => 'text'
-            ),
-            array(
-                'name'  => 'twitter',
-                'label' => 'Twitter',
-                'type'  => 'text'
-            ),
-            array(
-                'name'  => 'instagram',
-                'label' => 'Instagram',
-                'type'  => 'text'
-            ),
-            array(
-                'name'  => 'youtube',
-                'label' => 'Youtube',
-                'type'  => 'text'
-            ),
-            array(
-                'name'  => 'pinterest',
-                'label' => 'Pinterest',
-                'type'  => 'text'
-            ),
-            array(
-                'name'  => 'tripadvisor',
-                'label' => 'Trip Advisor',
-                'type'  => 'text'
-            ),
-            array(
-                'name'  => 'flickr',
-                'label' => 'Flickr',
-                'type'  => 'text'
-            ),
+            )
         );
 
         $this->glmclientinfoAddSettingTextField(
index a259f99..ea3f412 100644 (file)
@@ -1,5 +1,13 @@
 <div class="glm-footer-client-info">
-    <?php $exclude = array("facebook", "twitter", "instagram", "pinterest", "youtube"); ?>
+    <?php $exclude = array(
+        "facebook", 
+        "twitter", 
+        "instagram", 
+        "pinterest", 
+        "youtube", 
+        "flickr", 
+        "tripadvisor"
+    ); ?>
     <?php foreach( get_option('glmclientinfo_settings') as $setting => $value){ ?>
             <div class="glm-client-info-field glm-client-info-<?php echo $setting; ?>">
                 <?php if( $value !== '' && ! in_array($setting, $exclude) ) { ?>
index b9460f3..0748203 100644 (file)
@@ -2,11 +2,13 @@
     <?php 
         $options = get_option('glmclientinfo_settings'); 
         $social_media_settings = array(
-            "facebook"  => $options['facebook'],
-            "instagram" => $options['instagram'],
-            'twitter'   => $options['twitter'],
-            'pinterest' => $options['pinterest'],
-            "youtube"   => $options['youtube'],
+            "facebook"      => $options['facebook'],
+            "instagram"     => $options['instagram'],
+            'twitter'       => $options['twitter'],
+            'pinterest'     => $options['pinterest'],
+            "youtube"       => $options['youtube'],
+            "flickr"        => $options['flickr'],
+            "tripadvsior"   => $options['tripadvisor'],
 
         );
     ?>