Completed
Branch dev (182fee)
by
unknown
39s
created
development/factory/page_meta_box/AdminPageFramework_PageMetaBox_Model.php 3 patches
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -81,7 +81,7 @@
 block discarded – undo
81 81
      */
82 82
     public function _replyToRegisterMetaBoxes( $sPageHook='' ) {
83 83
         foreach( $this->oProp->aPageSlugs as $_sKey => $_asPage ) {
84
-            if ( is_string( $_asPage ) )  {
84
+            if ( is_string( $_asPage ) ) {
85 85
                 $this->_registerMetaBox( $_asPage );
86 86
                 continue;
87 87
             }
Please login to merge, or discard this patch.
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -256,7 +256,7 @@
 block discarded – undo
256 256
 
257 257
     }
258 258
 
259
-       /**
259
+        /**
260 260
          * Extracts meta box form fields options array from the given options array of an admin page.
261 261
          *
262 262
          * @since       3.5.6
Please login to merge, or discard this patch.
Spacing   +21 added lines, -21 removed lines patch added patch discarded remove patch
@@ -45,11 +45,11 @@  discard block
 block discarded – undo
45 45
     public function _replyToSetUpValidationHooks( $oScreen ) {
46 46
 
47 47
         // Validation hooks
48
-        foreach( $this->oProp->aPageSlugs as $_sIndexOrPageSlug => $_asTabArrayOrPageSlug ) {
48
+        foreach ( $this->oProp->aPageSlugs as $_sIndexOrPageSlug => $_asTabArrayOrPageSlug ) {
49 49
 
50 50
             if ( is_scalar( $_asTabArrayOrPageSlug ) ) {
51 51
                 $_sPageSlug = $_asTabArrayOrPageSlug;
52
-                add_filter( "validation_saved_options_without_dynamic_elements_{$_sPageSlug}", array( $this, '_replyToFilterPageOptionsWODynamicElements' ), 10, 2 );  // 3.4.1+
52
+                add_filter( "validation_saved_options_without_dynamic_elements_{$_sPageSlug}", array( $this, '_replyToFilterPageOptionsWODynamicElements' ), 10, 2 ); // 3.4.1+
53 53
                 add_filter( "validation_{$_sPageSlug}", array( $this, '_replyToValidateOptions' ), 10, 4 );
54 54
                 add_filter( "options_update_status_{$_sPageSlug}", array( $this, '_replyToModifyOptionsUpdateStatus' ) );
55 55
                 continue;
@@ -58,7 +58,7 @@  discard block
 block discarded – undo
58 58
             // At this point, the array key is the page slug. It means the user specified the tab(s).
59 59
             $_sPageSlug = $_sIndexOrPageSlug;
60 60
             $_aTabs     = $_asTabArrayOrPageSlug;
61
-            foreach( $_aTabs as $_sTabSlug ) {
61
+            foreach ( $_aTabs as $_sTabSlug ) {
62 62
                 add_filter( "validation_{$_sPageSlug}_{$_sTabSlug}", array( $this, '_replyToValidateOptions' ), 10, 4 );
63 63
                 add_filter( "validation_saved_options_without_dynamic_elements_{$_sPageSlug}_{$_sTabSlug}", array( $this, '_replyToFilterPageOptionsWODynamicElements' ), 10, 2 ); // 3.4.1+
64 64
                 add_filter( "options_update_status_{$_sPageSlug}_{$_sTabSlug}", array( $this, '_replyToModifyOptionsUpdateStatus' ) );
@@ -78,9 +78,9 @@  discard block
 block discarded – undo
78 78
      * @return      void
79 79
      * @callback    action      add_meta_boxes
80 80
      */
81
-    public function _replyToRegisterMetaBoxes( $sPageHook='' ) {
82
-        foreach( $this->oProp->aPageSlugs as $_sKey => $_asPage ) {
83
-            if ( is_string( $_asPage ) )  {
81
+    public function _replyToRegisterMetaBoxes( $sPageHook = '' ) {
82
+        foreach ( $this->oProp->aPageSlugs as $_sKey => $_asPage ) {
83
+            if ( is_string( $_asPage ) ) {
84 84
                 $this->_registerMetaBox( $_asPage );
85 85
                 continue;
86 86
             }
@@ -96,8 +96,8 @@  discard block
 block discarded – undo
96 96
          * @return      void
97 97
          */
98 98
         private function _registerMetaBoxes( $sPageSlug, $asPage ) {
99
-            foreach( $this->oUtil->getAsArray( $asPage ) as $_sTabSlug ) {
100
-                if ( ! $this->oProp->isCurrentTab( $_sTabSlug ) ) {
99
+            foreach ( $this->oUtil->getAsArray( $asPage ) as $_sTabSlug ) {
100
+                if ( !$this->oProp->isCurrentTab( $_sTabSlug ) ) {
101 101
                     continue;
102 102
                 }
103 103
                 $this->_registerMetaBox( $sPageSlug );
@@ -114,12 +114,12 @@  discard block
 block discarded – undo
114 114
          */
115 115
         private function _registerMetaBox( $sPageSlug ) {
116 116
             add_meta_box(
117
-                $this->oProp->sMetaBoxID,                       // id
118
-                $this->oProp->sTitle,                           // title
117
+                $this->oProp->sMetaBoxID, // id
118
+                $this->oProp->sTitle, // title
119 119
                 array( $this, '_replyToPrintMetaBoxContents' ), // callback
120 120
                 $this->oProp->_getScreenIDOfPage( $sPageSlug ), // screen ID
121
-                $this->oProp->sContext,                         // context
122
-                $this->oProp->sPriority,                        // priority
121
+                $this->oProp->sContext, // context
122
+                $this->oProp->sPriority, // priority
123 123
                 null                                            // argument (deprecated)
124 124
             );
125 125
         }
@@ -167,17 +167,17 @@  discard block
 block discarded – undo
167 167
 
168 168
         $_aNewMetaBoxInputs      = $this->oForm->getSubmittedData( $_POST );
169 169
         $_aOldMetaBoxInputs      = $this->oUtil->castArrayContents(
170
-            $this->oForm->getDataStructureFromAddedFieldsets(),   // model
170
+            $this->oForm->getDataStructureFromAddedFieldsets(), // model
171 171
             $aOldPageOptions        // data source
172 172
         );
173 173
 
174 174
         // Apply filters - third party scripts will have access to the input.
175 175
         $_aNewMetaBoxInputsRaw   = $_aNewMetaBoxInputs; // copy one for validation errors.
176 176
         $_aNewMetaBoxInputs      = call_user_func_array(
177
-            array( $this, 'validate' ),     // triggers __call()
177
+            array( $this, 'validate' ), // triggers __call()
178 178
             array( $_aNewMetaBoxInputs, $_aOldMetaBoxInputs, $this, $aSubmitInfo )
179 179
         ); // 3.5.3+
180
-        $_aNewMetaBoxInputs      = $this->oUtil->addAndApplyFilters(
180
+        $_aNewMetaBoxInputs = $this->oUtil->addAndApplyFilters(
181 181
             $this,
182 182
             "validation_{$this->oProp->sClassName}",
183 183
             $_aNewMetaBoxInputs,
@@ -215,7 +215,7 @@  discard block
 block discarded – undo
215 215
      */
216 216
     public function _replyToModifyOptionsUpdateStatus( $aStatus ) {
217 217
 
218
-        if ( ! $this->hasFieldError() ) {
218
+        if ( !$this->hasFieldError() ) {
219 219
             return $aStatus;
220 220
         }
221 221
         return array(
@@ -245,12 +245,12 @@  discard block
 block discarded – undo
245 245
 
246 246
         $_aPageOptions = $this->oUtil->addAndApplyFilter(
247 247
             $this, // the caller factory object
248
-            'options_' . $this->oProp->sClassName,
248
+            'options_'.$this->oProp->sClassName,
249 249
             $_aPageOptions
250 250
         );
251 251
 
252 252
         return $this->oUtil->castArrayContents(
253
-            $this->oForm->getDataStructureFromAddedFieldsets(),   // model
253
+            $this->oForm->getDataStructureFromAddedFieldsets(), // model
254 254
             $_aPageOptions        // data source
255 255
         );
256 256
 
@@ -267,9 +267,9 @@  discard block
 block discarded – undo
267 267
         private function _getPageMetaBoxOptionsFromPageOptions( array $aPageOptions, array $aFieldsets ) {
268 268
 
269 269
             $_aOptions = array();
270
-            foreach( $aFieldsets as $_sSectionID => $_aFieldsets ) {
271
-                if ( '_default' === $_sSectionID  ) {
272
-                    foreach( $_aFieldsets as $_aField ) {
270
+            foreach ( $aFieldsets as $_sSectionID => $_aFieldsets ) {
271
+                if ( '_default' === $_sSectionID ) {
272
+                    foreach ( $_aFieldsets as $_aField ) {
273 273
                         if ( array_key_exists( $_aField[ 'field_id' ], $aPageOptions ) ) {
274 274
                             $_aOptions[ $_aField[ 'field_id' ] ] = $aPageOptions[ $_aField[ 'field_id' ] ];
275 275
                         }
Please login to merge, or discard this patch.
development/factory/post_type/AdminPageFramework_PostType_View.php 2 patches
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -135,7 +135,7 @@
 block discarded – undo
135 135
      */
136 136
     public function _replyToModifyActionLinks( $aActionLinks, $oPost ) {
137 137
         
138
-        if ( $oPost->post_type !== $this->oProp->sPostType ){
138
+        if ( $oPost->post_type !== $this->oProp->sPostType ) {
139 139
             return $aActionLinks;
140 140
         }
141 141
 
Please login to merge, or discard this patch.
Spacing   +16 added lines, -16 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
 
32 32
         if ( $this->oProp->bIsAdmin ) {
33 33
 
34
-            add_action( 'load_' . $this->oProp->sPostType, array( $this, '_replyToSetUpHooksForView' ) );
34
+            add_action( 'load_'.$this->oProp->sPostType, array( $this, '_replyToSetUpHooksForView' ) );
35 35
 
36 36
             // 3.5.10+
37 37
             add_action( 'admin_menu', array( $this, '_replyToRemoveAddNewSidebarMenu' ) );
@@ -105,19 +105,19 @@  discard block
 block discarded – undo
105 105
             private function _removeAddNewSidebarSubMenu( $sMenuKey, $sPostTypeSlug ) {
106 106
 
107 107
                 // Remove the default post type menu item.
108
-                if ( ! isset( $GLOBALS[ 'submenu' ][ $sMenuKey ] ) ) {
108
+                if ( !isset( $GLOBALS[ 'submenu' ][ $sMenuKey ] ) ) {
109 109
                     // logged-in users of an insufficient access level don't have the menu to be registered.
110 110
                     return;
111 111
                 }
112 112
 
113 113
                 foreach ( $GLOBALS[ 'submenu' ][ $sMenuKey ] as $_iIndex => $_aSubMenu ) {
114 114
 
115
-                    if ( ! isset( $_aSubMenu[ 2 ] ) ) {
115
+                    if ( !isset( $_aSubMenu[ 2 ] ) ) {
116 116
                         continue;
117 117
                     }
118 118
 
119 119
                     // Remove the default Add New entry.
120
-                    if ( 'post-new.php?post_type=' . $sPostTypeSlug === $_aSubMenu[ 2 ] ) {
120
+                    if ( 'post-new.php?post_type='.$sPostTypeSlug === $_aSubMenu[ 2 ] ) {
121 121
                         unset( $GLOBALS[ 'submenu' ][ $sMenuKey ][ $_iIndex ] );
122 122
                         break;
123 123
                     }
@@ -134,7 +134,7 @@  discard block
 block discarded – undo
134 134
      */
135 135
     public function _replyToModifyActionLinks( $aActionLinks, $oPost ) {
136 136
 
137
-        if ( $oPost->post_type !== $this->oProp->sPostType ){
137
+        if ( $oPost->post_type !== $this->oProp->sPostType ) {
138 138
             return $aActionLinks;
139 139
         }
140 140
 
@@ -156,12 +156,12 @@  discard block
 block discarded – undo
156 156
      */
157 157
     public function _replyToAddAuthorTableFilter() {
158 158
 
159
-        if ( ! $this->oProp->bEnableAuthorTableFileter ) {
159
+        if ( !$this->oProp->bEnableAuthorTableFileter ) {
160 160
             return;
161 161
         }
162 162
 
163 163
         if (
164
-            ! ( isset( $_GET[ 'post_type' ] ) && post_type_exists( $_GET[ 'post_type' ] )
164
+            !( isset( $_GET[ 'post_type' ] ) && post_type_exists( $_GET[ 'post_type' ] )
165 165
             && in_array( strtolower( $_GET[ 'post_type' ] ), array( $this->oProp->sPostType ) ) )
166 166
         ) {
167 167
             return;
@@ -201,7 +201,7 @@  discard block
 block discarded – undo
201 201
 
202 202
         foreach ( get_object_taxonomies( $GLOBALS[ 'typenow' ] ) as $_sTaxonomySulg ) {
203 203
 
204
-            if ( ! in_array( $_sTaxonomySulg, $this->oProp->aTaxonomyTableFilters ) ) {
204
+            if ( !in_array( $_sTaxonomySulg, $this->oProp->aTaxonomyTableFilters ) ) {
205 205
                 continue;
206 206
             }
207 207
 
@@ -215,7 +215,7 @@  discard block
 block discarded – undo
215 215
             // Echo the drop down list based on the passed array argument.
216 216
             wp_dropdown_categories(
217 217
                 array(
218
-                    'show_option_all'   => $this->oMsg->get( 'show_all' ) . ' ' . $_oTaxonomy->label,
218
+                    'show_option_all'   => $this->oMsg->get( 'show_all' ).' '.$_oTaxonomy->label,
219 219
                     'taxonomy'          => $_sTaxonomySulg,
220 220
                     'name'              => $_oTaxonomy->name,
221 221
                     'orderby'           => 'name',
@@ -235,24 +235,24 @@  discard block
 block discarded – undo
235 235
      *
236 236
      * @internal
237 237
      */
238
-    public function _replyToGetTableFilterQueryForTaxonomies( $oQuery=null ) {
238
+    public function _replyToGetTableFilterQueryForTaxonomies( $oQuery = null ) {
239 239
 
240 240
         if ( 'edit.php' != $this->oProp->sPageNow ) {
241 241
             return $oQuery;
242 242
         }
243 243
 
244
-        if ( ! isset( $GLOBALS[ 'typenow' ] ) ) {
244
+        if ( !isset( $GLOBALS[ 'typenow' ] ) ) {
245 245
             return $oQuery;
246 246
         }
247 247
 
248 248
         foreach ( get_object_taxonomies( $GLOBALS[ 'typenow' ] ) as $sTaxonomySlug ) {
249 249
 
250
-            if ( ! in_array( $sTaxonomySlug, $this->oProp->aTaxonomyTableFilters ) ) {
250
+            if ( !in_array( $sTaxonomySlug, $this->oProp->aTaxonomyTableFilters ) ) {
251 251
                 continue;
252 252
             }
253 253
 
254 254
             $sVar = &$oQuery->query_vars[ $sTaxonomySlug ];
255
-            if ( ! isset( $sVar ) ) {
255
+            if ( !isset( $sVar ) ) {
256 256
                 continue;
257 257
             }
258 258
 
@@ -291,7 +291,7 @@  discard block
 block discarded – undo
291 291
         $_sStyle = trim( $_sStyle );
292 292
 
293 293
         // Print out the filtered styles.
294
-        if ( ! empty( $_sStyle ) ) {
294
+        if ( !empty( $_sStyle ) ) {
295 295
             echo "<style type='text/css' id='admin-page-framework-style-post-type'>"
296 296
                     . $this->oProp->sStyle
297 297
                 . "</style>";
@@ -347,10 +347,10 @@  discard block
 block discarded – undo
347 347
      */
348 348
     public function _replyToFilterPostTypeContent( $sContent ) {
349 349
 
350
-        if ( ! is_singular() ) {
350
+        if ( !is_singular() ) {
351 351
             return $sContent;
352 352
         }
353
-        if ( ! is_main_query() ) {
353
+        if ( !is_main_query() ) {
354 354
             return $sContent;
355 355
         }
356 356
         global $post;
Please login to merge, or discard this patch.
development/utility/plugin_bootstrap/AdminPageFramework_PluginBootstrap.php 2 patches
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -76,7 +76,7 @@
 block discarded – undo
76 76
         register_deactivation_hook( $this->sFilePath, array( $this, 'replyToPluginDeactivation' ) );
77 77
                  
78 78
         // 8. Schedule to load plugin specific components.
79
-        if ( ! $this->sSetUpHook || did_action( $this->sSetUpHook ) )  {
79
+        if ( ! $this->sSetUpHook || did_action( $this->sSetUpHook ) ) {
80 80
             $this->_replyToLoadPluginComponents();
81 81
         } else {
82 82
             add_action( $this->sSetUpHook, array( $this, '_replyToLoadPluginComponents' ), $this->iPriority );
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -122,7 +122,7 @@  discard block
 block discarded – undo
122 122
      * @param       string      $sSetUpHook             The action hook name for the setUp callback. Default 'plugins_loaded'.
123 123
      * @param       string      $iPriority              The priority. Set a lower number to get loader earlier. Default: `10`.
124 124
      */
125
-    public function __construct( $sPluginFilePath, $sPluginHookPrefix='', $sSetUpHook='plugins_loaded', $iPriority=10 ) {
125
+    public function __construct( $sPluginFilePath, $sPluginHookPrefix = '', $sSetUpHook = 'plugins_loaded', $iPriority = 10 ) {
126 126
 
127 127
         // Check if it has been loaded.
128 128
         if ( $this->_hasLoaded() ) {
@@ -158,7 +158,7 @@  discard block
 block discarded – undo
158 158
         register_deactivation_hook( $this->sFilePath, array( $this, 'replyToPluginDeactivation' ) );
159 159
 
160 160
         // 8. Schedule to load plugin specific components.
161
-        if ( ! $this->sSetUpHook || did_action( $this->sSetUpHook ) )  {
161
+        if ( !$this->sSetUpHook || did_action( $this->sSetUpHook ) ) {
162 162
             $this->_replyToLoadPluginComponents();
163 163
         } else {
164 164
             add_action( $this->sSetUpHook, array( $this, '_replyToLoadPluginComponents' ), $this->iPriority );
@@ -200,14 +200,14 @@  discard block
 block discarded – undo
200 200
         protected function _registerClasses() {
201 201
 
202 202
             // This class should be used in the framework bootstrap so disabling the auto-load option for performance.
203
-            if ( ! class_exists( 'AdminPageFramework_RegisterClasses', false ) ) {
203
+            if ( !class_exists( 'AdminPageFramework_RegisterClasses', false ) ) {
204 204
                 return;
205 205
             }
206 206
 
207 207
             // Register classes
208 208
             new AdminPageFramework_RegisterClasses(
209
-                $this->getScanningDirs(),   // scanning directory paths
210
-                array(),                    // autoloader options
209
+                $this->getScanningDirs(), // scanning directory paths
210
+                array(), // autoloader options
211 211
                 $this->getClasses()         // pre-generated class list
212 212
             );
213 213
 
Please login to merge, or discard this patch.
help/AdminPageFrameworkLoader_AdminPage_Help_Example.php 2 patches
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -52,7 +52,7 @@
 block discarded – undo
52 52
         /**
53 53
          * @return      string
54 54
          */
55
-        private function getReadMeContents()  {
55
+        private function getReadMeContents() {
56 56
             return $this->_getReadmeContents(
57 57
                 AdminPageFrameworkLoader_Registry::$sDirPath . '/asset/text/examples.txt',
58 58
                 '',
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@  discard block
 block discarded – undo
23 23
 
24 24
         $_aItems     = $this->getContentsByHeader( $this->getReadmeContents(), 3 );
25 25
         $_iLastIndex = count( $_aItems ) - 1;
26
-        foreach( $_aItems as $_iIndex => $_aContent ) {
26
+        foreach ( $_aItems as $_iIndex => $_aContent ) {
27 27
 
28 28
             $_oParser   = new AdminPageFramework_WPReadmeParser;
29 29
             $_oParser->setText( $_aContent[ 1 ] );
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
             $oAdminPage->addSettingSections(
32 32
                 $this->sPageSlug, // the target page slug
33 33
                 array(
34
-                    'section_id'        => 'examples_' . $_iIndex,
34
+                    'section_id'        => 'examples_'.$_iIndex,
35 35
                     'title'             => $_aContent[ 0 ],
36 36
                     'collapsible'       => array(
37 37
                         'toggle_all_button' => $_iLastIndex === $_iIndex
@@ -52,9 +52,9 @@  discard block
 block discarded – undo
52 52
         /**
53 53
          * @return      string
54 54
          */
55
-        private function getReadMeContents()  {
55
+        private function getReadMeContents() {
56 56
             return $this->_getReadmeContents(
57
-                AdminPageFrameworkLoader_Registry::$sDirPath . '/asset/text/examples.txt',
57
+                AdminPageFrameworkLoader_Registry::$sDirPath.'/asset/text/examples.txt',
58 58
                 '',
59 59
                 array( 'Examples' )
60 60
             );
Please login to merge, or discard this patch.
admin-page-framework/help/AdminPageFrameworkLoader_AdminPage_Help_Tip.php 2 patches
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -53,7 +53,7 @@
 block discarded – undo
53 53
         /**
54 54
          * @return      string
55 55
          */
56
-        private function getReadMeContents()  {
56
+        private function getReadMeContents() {
57 57
             return $this->_getReadmeContents(
58 58
                 AdminPageFrameworkLoader_Registry::$sDirPath . '/readme.txt', // source path
59 59
                 '', // TOC title
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -25,14 +25,14 @@  discard block
 block discarded – undo
25 25
 
26 26
         $_aItems     = $this->getContentsByHeader( $this->getReadmeContents(), 4 );
27 27
         $_iLastIndex = count( $_aItems ) - 1;
28
-        foreach( $_aItems as $_iIndex => $_aContent ) {
28
+        foreach ( $_aItems as $_iIndex => $_aContent ) {
29 29
 
30 30
             $_oParser   = new AdminPageFramework_WPReadmeParser( $_aContent[ 1 ] );
31 31
             $_sContent  = $_oParser->get();
32 32
             $oAdminPage->addSettingSections(
33 33
                 $this->sPageSlug, // the target page slug
34 34
                 array(
35
-                    'section_id'        => 'tips_' . $_iIndex,
35
+                    'section_id'        => 'tips_'.$_iIndex,
36 36
                     'title'             => $_aContent[ 0 ],
37 37
                     'collapsible'       => array(
38 38
                         'toggle_all_button' => $_iLastIndex === $_iIndex
@@ -53,9 +53,9 @@  discard block
 block discarded – undo
53 53
         /**
54 54
          * @return      string
55 55
          */
56
-        private function getReadMeContents()  {
56
+        private function getReadMeContents() {
57 57
             return $this->_getReadmeContents(
58
-                AdminPageFrameworkLoader_Registry::$sDirPath . '/readme.txt', // source path
58
+                AdminPageFrameworkLoader_Registry::$sDirPath.'/readme.txt', // source path
59 59
                 '', // TOC title
60 60
                 array( 'Other Notes' )  // sections
61 61
             );
Please login to merge, or discard this patch.
include/class/utility/AdminPageFrameworkLoader_Utility.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@
 block discarded – undo
34 34
             ),
35 35
             2 => __( 'Header already sent.', 'admin-page-framework-loader' ),
36 36
         );
37
-        if ( ! class_exists( 'AdminPageFramework_AdminNotice' ) ) {
37
+        if ( !class_exists( 'AdminPageFramework_AdminNotice' ) ) {
38 38
             return;
39 39
         }
40 40
         new AdminPageFramework_AdminNotice(
Please login to merge, or discard this patch.
factory/user_meta/_model/AdminPageFramework_UserMeta_Model___UserMeta.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,6 +21,6 @@
 block discarded – undo
21 21
     /**
22 22
      * The callback function name or the callable object to retrieve meta data.
23 23
      */
24
-    protected $osCallable   = 'get_user_meta'; 
24
+    protected $osCallable = 'get_user_meta'; 
25 25
         
26 26
 }
Please login to merge, or discard this patch.
_common/_abstract/_model/AdminPageFramework_Factory_Model___Meta_Base.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -23,17 +23,17 @@  discard block
 block discarded – undo
23 23
     /**
24 24
      * The callback function name or the callable object to retrieve meta data.
25 25
      */
26
-    protected $osCallable   = 'get_post_meta';
26
+    protected $osCallable = 'get_post_meta';
27 27
 
28 28
     /**
29 29
      * The object ID such as post ID, user ID, and term ID.
30 30
      */
31
-    public $iObjectID       = 0;
31
+    public $iObjectID = 0;
32 32
     
33 33
     /**
34 34
      * A form fieldsets array.
35 35
      */
36
-    public $aFieldsets      = array();
36
+    public $aFieldsets = array();
37 37
     
38 38
     /**
39 39
      * Sets up properties.
@@ -57,7 +57,7 @@  discard block
 block discarded – undo
57 57
      */
58 58
     public function get() {
59 59
 
60
-        if ( ! $this->iObjectID ) {
60
+        if ( !$this->iObjectID ) {
61 61
             return array();
62 62
         }
63 63
         return $this->_getSavedDataFromFieldsets(
@@ -76,11 +76,11 @@  discard block
 block discarded – undo
76 76
             
77 77
             $_aMetaKeys = $this->_getMetaKeys( $iObjectID );
78 78
             $_aMetaData = array();
79
-            foreach( $aFieldsets as $_sSectionID => $_aFieldsets ) {
79
+            foreach ( $aFieldsets as $_sSectionID => $_aFieldsets ) {
80 80
                 
81
-                if ( '_default' == $_sSectionID  ) {
82
-                    foreach( $_aFieldsets as $_aFieldset ) {
83
-                        if ( ! in_array( $_aFieldset[ 'field_id' ], $_aMetaKeys ) ) {
81
+                if ( '_default' == $_sSectionID ) {
82
+                    foreach ( $_aFieldsets as $_aFieldset ) {
83
+                        if ( !in_array( $_aFieldset[ 'field_id' ], $_aMetaKeys ) ) {
84 84
                             continue;
85 85
                         }
86 86
                         $_aMetaData[ $_aFieldset[ 'field_id' ] ] = call_user_func_array(
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
                         );
94 94
                     }
95 95
                 }
96
-                if ( ! in_array( $_sSectionID, $_aMetaKeys ) ) {
96
+                if ( !in_array( $_sSectionID, $_aMetaKeys ) ) {
97 97
                     continue;
98 98
                 }                
99 99
                 $_aMetaData[ $_sSectionID ] = call_user_func_array(
Please login to merge, or discard this patch.
form/_view/fieldset/AdminPageFramework_Form_View___Fieldset_Base.php 3 patches
Braces   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -157,7 +157,7 @@  discard block
 block discarded – undo
157 157
                 self::$_bIsLoadedJSScripts_Widget = true;
158 158
             }
159 159
             
160
-            if ( self::$_bIsLoadedJSScripts ) { 
160
+            if ( self::$_bIsLoadedJSScripts ) {
161 161
                 return; 
162 162
             }
163 163
             self::$_bIsLoadedJSScripts = true;
@@ -255,7 +255,7 @@  discard block
 block discarded – undo
255 255
      * 
256 256
      * @since 3.0.0
257 257
      */    
258
-    protected function _getSortableFieldEnablerScript( $sFieldsContainerID ) {        
258
+    protected function _getSortableFieldEnablerScript( $sFieldsContainerID ) {
259 259
     
260 260
         $_sScript = <<<JAVASCRIPTS
261 261
     jQuery( document ).ready( function() {
Please login to merge, or discard this patch.
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -272,8 +272,8 @@  discard block
 block discarded – undo
272 272
                     'href'      => empty( $aArguments[ 'disabled' ] )
273 273
                         ? null
274 274
                         : '#TB_inline?width=' . $aArguments[ 'disabled' ][ 'box_width' ]
275
-                          . '&height=' . $aArguments[ 'disabled' ][ 'box_height' ]
276
-                          . '&inlineId=' . 'repeatable_field_disabled_' . $sFieldsContainerID,
275
+                            . '&height=' . $aArguments[ 'disabled' ][ 'box_height' ]
276
+                            . '&inlineId=' . 'repeatable_field_disabled_' . $sFieldsContainerID,
277 277
                 );
278 278
                 return $this->getAttributes( $_sPlusButtonAttributes );
279 279
             }
@@ -285,7 +285,7 @@  discard block
 block discarded – undo
285 285
             private function ___getRemoveButtonAttributes( $sFieldsContainerID, $sSmallButtonSelector, $iFieldCount ) {
286 286
                 $_aMinusButtonAttributes = array(
287 287
                     'class'     => 'repeatable-field-remove-button button-secondary repeatable-field-button button'
288
-                         . $sSmallButtonSelector,
288
+                            . $sSmallButtonSelector,
289 289
                     'title'     => $this->oMsg->get( 'remove' ),
290 290
                     'style'     => $iFieldCount <= 1
291 291
                         ? 'visibility: hidden'
Please login to merge, or discard this patch.
Spacing   +25 added lines, -25 removed lines patch added patch discarded remove patch
@@ -67,7 +67,7 @@  discard block
 block discarded – undo
67 67
      * @param       object      $oMsg                   An object storing the system messages.
68 68
      * @param       array       $aCallbacks             An array storing the form-field specific callbacks.     
69 69
      */
70
-    public function __construct( $aFieldset, $aOptions, $aErrors, &$aFieldTypeDefinitions, &$oMsg, array $aCallbacks=array() ) {
70
+    public function __construct( $aFieldset, $aOptions, $aErrors, &$aFieldTypeDefinitions, &$oMsg, array $aCallbacks = array() ) {
71 71
 
72 72
         // Set up the properties that will be accessed later in the methods.
73 73
         $this->aFieldset                = $this->_getFormatted( $aFieldset, $aFieldTypeDefinitions );
@@ -76,13 +76,13 @@  discard block
 block discarded – undo
76 76
         $this->aErrors                  = $this->getAsArray( $aErrors );
77 77
         $this->oMsg                     = $oMsg;
78 78
         $this->aCallbacks               = $aCallbacks + array(
79
-            'hfID'              => null,    // the input id attribute
80
-            'hfTagID'           => null,    // the fieldset/field row container id attribute
81
-            'hfName'            => null,    // the input name attribute
82
-            'hfNameFlat'        => null,    // the flat input name attribute                
79
+            'hfID'              => null, // the input id attribute
80
+            'hfTagID'           => null, // the fieldset/field row container id attribute
81
+            'hfName'            => null, // the input name attribute
82
+            'hfNameFlat'        => null, // the flat input name attribute                
83 83
             'hfInputName'       => null,
84 84
             'hfInputNameFlat'   => null,
85
-            'hfClass'           => null,    // the class attribute
85
+            'hfClass'           => null, // the class attribute
86 86
         );        
87 87
         
88 88
         // 2. Load necessary JavaScript scripts.
@@ -149,9 +149,9 @@  discard block
 block discarded – undo
149 149
          * @since   3.2.0   Added the `$sFieldsType` parameter.
150 150
          * @internal
151 151
          */
152
-        private function _loadScripts( $sStructureType='' ) {
152
+        private function _loadScripts( $sStructureType = '' ) {
153 153
 
154
-            if ( 'widget' === $sStructureType && ! self::$_bIsLoadedJSScripts_Widget ) {
154
+            if ( 'widget' === $sStructureType && !self::$_bIsLoadedJSScripts_Widget ) {
155 155
                 new AdminPageFramework_Form_View___Script_Widget;
156 156
                 self::$_bIsLoadedJSScripts_Widget = true;
157 157
             }
@@ -176,8 +176,8 @@  discard block
 block discarded – undo
176 176
      */
177 177
     protected function _getRepeaterFieldEnablerScript( $sFieldsContainerID, $iFieldCount, $aSettings ) {
178 178
         
179
-        $_sSmallButtons         = '"' . $this->___getRepeatableButtonHTML( $sFieldsContainerID, ( array ) $aSettings, $iFieldCount, true ) . '"';
180
-        $_sNestedFieldsButtons  = '"' . $this->___getRepeatableButtonHTML( $sFieldsContainerID, ( array ) $aSettings, $iFieldCount, false ) . '"';
179
+        $_sSmallButtons         = '"'.$this->___getRepeatableButtonHTML( $sFieldsContainerID, ( array ) $aSettings, $iFieldCount, true ).'"';
180
+        $_sNestedFieldsButtons  = '"'.$this->___getRepeatableButtonHTML( $sFieldsContainerID, ( array ) $aSettings, $iFieldCount, false ).'"';
181 181
         $_aJSArray              = json_encode( $aSettings );
182 182
         $_sScript               = <<<JAVASCRIPTS
183 183
 jQuery( document ).ready( function() {
@@ -223,36 +223,36 @@  discard block
 block discarded – undo
223 223
          * @since       3.8.0
224 224
          * @return      string
225 225
          */
226
-        private function ___getRepeatableButtonHTML( $sFieldsContainerID, array $aArguments, $iFieldCount, $bSmall=true ) {
226
+        private function ___getRepeatableButtonHTML( $sFieldsContainerID, array $aArguments, $iFieldCount, $bSmall = true ) {
227 227
 
228 228
             // @todo Move this formatting routine to the field-set formatter class.
229 229
             $_oFormatter             = new AdminPageFramework_Form_Model___Format_RepeatableField( $aArguments, $this->oMsg );
230 230
             $_aArguments             = $_oFormatter->get();
231 231
             $_sSmallButtonSelector   = $bSmall ? ' button-small' : '';
232 232
             if ( version_compare( $GLOBALS[ 'wp_version' ], '5.3', '>=' ) ) {
233
-                return "<div " . $this->___getContainerAttributes( $_aArguments ) . " >"
234
-                        . "<a " . $this->___getRemoveButtonAttributes( $sFieldsContainerID, $_sSmallButtonSelector, $iFieldCount ) . ">"
233
+                return "<div ".$this->___getContainerAttributes( $_aArguments )." >"
234
+                        . "<a ".$this->___getRemoveButtonAttributes( $sFieldsContainerID, $_sSmallButtonSelector, $iFieldCount ).">"
235 235
                             . "<span class='dashicons dashicons-minus'></span>"
236 236
                         . "</a>"
237
-                        . "<a " . $this->___getAddButtonAttribtes( $_aArguments, $sFieldsContainerID, $_sSmallButtonSelector ) . ">"
237
+                        . "<a ".$this->___getAddButtonAttribtes( $_aArguments, $sFieldsContainerID, $_sSmallButtonSelector ).">"
238 238
                             . "<span class='dashicons dashicons-plus-alt2'></span>"
239 239
                         ."</a>"
240 240
                     . "</div>"
241 241
                     . $this->getModalForDisabledRepeatableElement(
242
-                        'repeatable_field_disabled_' . $sFieldsContainerID,
242
+                        'repeatable_field_disabled_'.$sFieldsContainerID,
243 243
                         $_aArguments[ 'disabled' ]
244 244
                     );
245 245
             }
246
-            return "<div " . $this->___getContainerAttributes( $_aArguments ) . " >"
247
-                    . "<a " . $this->___getRemoveButtonAttributes( $sFieldsContainerID, $_sSmallButtonSelector, $iFieldCount ) . ">"
246
+            return "<div ".$this->___getContainerAttributes( $_aArguments )." >"
247
+                    . "<a ".$this->___getRemoveButtonAttributes( $sFieldsContainerID, $_sSmallButtonSelector, $iFieldCount ).">"
248 248
                         . "-"
249 249
                     . "</a>"
250
-                    . "<a " . $this->___getAddButtonAttribtes( $_aArguments, $sFieldsContainerID, $_sSmallButtonSelector ) . ">"
250
+                    . "<a ".$this->___getAddButtonAttribtes( $_aArguments, $sFieldsContainerID, $_sSmallButtonSelector ).">"
251 251
                         . "+"
252 252
                     ."</a>"
253 253
                 . "</div>"
254 254
                 . $this->getModalForDisabledRepeatableElement(
255
-                    'repeatable_field_disabled_' . $sFieldsContainerID,
255
+                    'repeatable_field_disabled_'.$sFieldsContainerID,
256 256
                     $_aArguments[ 'disabled' ]
257 257
                 );
258 258
 
@@ -271,9 +271,9 @@  discard block
 block discarded – undo
271 271
                     'data-id'   => $sFieldsContainerID,
272 272
                     'href'      => empty( $aArguments[ 'disabled' ] )
273 273
                         ? null
274
-                        : '#TB_inline?width=' . $aArguments[ 'disabled' ][ 'box_width' ]
275
-                          . '&height=' . $aArguments[ 'disabled' ][ 'box_height' ]
276
-                          . '&inlineId=' . 'repeatable_field_disabled_' . $sFieldsContainerID,
274
+                        : '#TB_inline?width='.$aArguments[ 'disabled' ][ 'box_width' ]
275
+                          . '&height='.$aArguments[ 'disabled' ][ 'box_height' ]
276
+                          . '&inlineId='.'repeatable_field_disabled_'.$sFieldsContainerID,
277 277
                 );
278 278
                 return $this->getAttributes( $_sPlusButtonAttributes );
279 279
             }
@@ -300,10 +300,10 @@  discard block
 block discarded – undo
300 300
              * @return      string
301 301
              */
302 302
             private function ___getContainerAttributes( $aArguments ) {
303
-                $_aContainerAttributes   = array(
303
+                $_aContainerAttributes = array(
304 304
                     'class' => $this->getClassAttribute(
305 305
                         'admin-page-framework-repeatable-field-buttons',
306
-                        ! empty( $aArguments[ 'disabled' ] )
306
+                        !empty( $aArguments[ 'disabled' ] )
307 307
                             ? 'disabled'
308 308
                             : ''
309 309
                     ),
@@ -316,7 +316,7 @@  discard block
 block discarded – undo
316 316
                     unset( $aArguments[ 'disabled' ] );
317 317
                 }
318 318
                 return $this->getAttributes( $_aContainerAttributes )
319
-                    . ' ' . $this->getDataAttributes( $aArguments );
319
+                    . ' '.$this->getDataAttributes( $aArguments );
320 320
             }
321 321
 
322 322
     /**
Please login to merge, or discard this patch.