Completed
Branch dev (69a0d4)
by
unknown
33:44
created
development/factory/meta_box/AdminPageFramework_MetaBox_Controller.php 3 patches
Indentation   +26 added lines, -26 removed lines patch added patch discarded remove patch
@@ -18,32 +18,32 @@
 block discarded – undo
18 18
 abstract class AdminPageFramework_MetaBox_Controller extends AdminPageFramework_MetaBox_View {
19 19
        
20 20
     /**
21
-    * The method for all necessary set-ups.
22
-    * 
23
-    * <h4>Example</h4>
24
-    * <code> public function setUp() {     
25
-    *     $this->addSettingFields(
26
-    *         array(
27
-    *             'field_id'    => 'sample_metabox_text_field',
28
-    *             'title'       => 'Text Input',
29
-    *             'description' => 'The description for the field.',
30
-    *             'type'        => 'text',
31
-    *         ),
32
-    *         array(
33
-    *             'field_id'    => 'sample_metabox_textarea_field',
34
-    *             'title'       => 'Textarea',
35
-    *             'description' => 'The description for the field.',
36
-    *             'type'        => 'textarea',
37
-    *             'default'     => 'This is a default text value.',
38
-    *         )
39
-    *     );     
40
-    * }</code>
41
-    * 
42
-    * @abstract
43
-    * @since        2.0.0
44
-    * @remark       The user should override this method.
45
-    * @return       void
46
-    */  
21
+     * The method for all necessary set-ups.
22
+     * 
23
+     * <h4>Example</h4>
24
+     * <code> public function setUp() {     
25
+     *     $this->addSettingFields(
26
+     *         array(
27
+     *             'field_id'    => 'sample_metabox_text_field',
28
+     *             'title'       => 'Text Input',
29
+     *             'description' => 'The description for the field.',
30
+     *             'type'        => 'text',
31
+     *         ),
32
+     *         array(
33
+     *             'field_id'    => 'sample_metabox_textarea_field',
34
+     *             'title'       => 'Textarea',
35
+     *             'description' => 'The description for the field.',
36
+     *             'type'        => 'textarea',
37
+     *             'default'     => 'This is a default text value.',
38
+     *         )
39
+     *     );     
40
+     * }</code>
41
+     * 
42
+     * @abstract
43
+     * @since        2.0.0
44
+     * @remark       The user should override this method.
45
+     * @return       void
46
+     */  
47 47
     public function setUp() {}    
48 48
 
49 49
     /**
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
      * 
67 67
      * @since 3.5.0
68 68
      */
69
-    public function enqueueStyles( $aSRCs, $aPostTypes=array(), $aCustomArgs=array() ) {
69
+    public function enqueueStyles( $aSRCs, $aPostTypes = array(), $aCustomArgs = array() ) {
70 70
         return $this->oResource->_enqueueStyles( $aSRCs, $aPostTypes, $aCustomArgs );
71 71
     }
72 72
     /**
@@ -89,7 +89,7 @@  discard block
 block discarded – undo
89 89
      * @param       array       (optional) The argument array for more advanced parameters.
90 90
      * @return      string The script handle ID. If the passed url is not a valid url string, an empty string will be returned.
91 91
      */    
92
-    public function enqueueStyle( $sSRC, $aPostTypes=array(), $aCustomArgs=array() ) {
92
+    public function enqueueStyle( $sSRC, $aPostTypes = array(), $aCustomArgs = array() ) {
93 93
         return $this->oResource->_enqueueStyle( $sSRC, $aPostTypes, $aCustomArgs );     
94 94
     }
95 95
     /**
@@ -97,7 +97,7 @@  discard block
 block discarded – undo
97 97
      * 
98 98
      * @since 3.5.0
99 99
      */
100
-    public function enqueueScripts( $aSRCs, $aPostTypes=array(), $aCustomArgs=array() ) {
100
+    public function enqueueScripts( $aSRCs, $aPostTypes = array(), $aCustomArgs = array() ) {
101 101
         return $this->oResource->_enqueueScripts( $aSRCs, $aPostTypes, $aCustomArgs );
102 102
     }    
103 103
     /**
@@ -132,7 +132,7 @@  discard block
 block discarded – undo
132 132
      * @param       array       (optional) The argument array for more advanced parameters.
133 133
      * @return      string The script handle ID. If the passed url is not a valid url string, an empty string will be returned.
134 134
      */
135
-    public function enqueueScript( $sSRC, $aPostTypes=array(), $aCustomArgs=array() ) {    
135
+    public function enqueueScript( $sSRC, $aPostTypes = array(), $aCustomArgs = array() ) {    
136 136
         return $this->oResource->_enqueueScript( $sSRC, $aPostTypes, $aCustomArgs );
137 137
     }    
138 138
         
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -132,7 +132,7 @@
 block discarded – undo
132 132
      * @param       array       (optional) The argument array for more advanced parameters.
133 133
      * @return      string The script handle ID. If the passed url is not a valid url string, an empty string will be returned.
134 134
      */
135
-    public function enqueueScript( $sSRC, $aPostTypes=array(), $aCustomArgs=array() ) {    
135
+    public function enqueueScript( $sSRC, $aPostTypes=array(), $aCustomArgs=array() ) {
136 136
         return $this->oResource->_enqueueScript( $sSRC, $aPostTypes, $aCustomArgs );
137 137
     }    
138 138
         
Please login to merge, or discard this patch.
development/factory/meta_box/AdminPageFramework_MetaBox_Model.php 3 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -136,11 +136,11 @@
 block discarded – undo
136 136
      * 
137 137
      * Triggered when a post has not been created so no post id is assigned.
138 138
      * 
139
-	 * @internal
139
+     * @internal
140 140
      * @since       3.3.0
141 141
      * @callback    filter      wp_insert_attachment_data
142 142
      * @callback    filter      wp_insert_post_data
143
-	 * @param       array       $aPostData      An array of slashed post data.
143
+     * @param       array       $aPostData      An array of slashed post data.
144 144
      * @param       array       $aUnmodified    An array of sanitized, but otherwise unmodified post data.
145 145
      */
146 146
     public function _replyToFilterSavingData( $aPostData, $aUnmodified ) {
Please login to merge, or discard this patch.
Spacing   +16 added lines, -16 removed lines patch added patch discarded remove patch
@@ -75,14 +75,14 @@  discard block
 block discarded – undo
75 75
      * @callback    action      add_meta_boxes
76 76
      */ 
77 77
     public function _replyToAddMetaBox() {
78
-        foreach( $this->oProp->aPostTypes as $sPostType ) {
78
+        foreach ( $this->oProp->aPostTypes as $sPostType ) {
79 79
             add_meta_box( 
80
-                $this->oProp->sMetaBoxID,                       // id
81
-                $this->oProp->sTitle,                           // title
80
+                $this->oProp->sMetaBoxID, // id
81
+                $this->oProp->sTitle, // title
82 82
                 array( $this, '_replyToPrintMetaBoxContents' ), // callback
83
-                $sPostType,                                     // post type
84
-                $this->oProp->sContext,                         // context
85
-                $this->oProp->sPriority,                        // priority
83
+                $sPostType, // post type
84
+                $this->oProp->sContext, // context
85
+                $this->oProp->sPriority, // priority
86 86
                 null                                            // argument - deprecated $this->oForm->aFields
87 87
             );
88 88
         }      
@@ -114,7 +114,7 @@  discard block
 block discarded – undo
114 114
          * @internal
115 115
          * @return      integer     The found post ID. `0` if not found.
116 116
          */
117
-        private function _getPostID()  {
117
+        private function _getPostID() {
118 118
             
119 119
             // for an editing post page.
120 120
             if ( isset( $GLOBALS[ 'post' ]->ID ) ) {
@@ -146,14 +146,14 @@  discard block
 block discarded – undo
146 146
     public function _replyToFilterSavingData( $aPostData, $aUnmodified ) {
147 147
 
148 148
         // Perform initial checks.
149
-        if ( ! $this->_shouldProceedValidation( $aUnmodified ) ) { 
149
+        if ( !$this->_shouldProceedValidation( $aUnmodified ) ) { 
150 150
             return $aPostData; 
151 151
         }
152 152
                 
153 153
         // Retrieve the submitted data. 
154
-        $_aInputs       = $this->oForm->getSubmittedData(
155
-            $_POST,     // subject data to be parsed
156
-            true,       // extract data with the fieldset structure
154
+        $_aInputs = $this->oForm->getSubmittedData(
155
+            $_POST, // subject data to be parsed
156
+            true, // extract data with the fieldset structure
157 157
             false       // strip slashes
158 158
         );
159 159
         $_aInputsRaw    = $_aInputs; // store one for the last input array.
@@ -188,8 +188,8 @@  discard block
 block discarded – undo
188 188
         }
189 189
                     
190 190
         $this->oForm->updateMetaDataByType( 
191
-            $_iPostID,   // object id
192
-            $_aInputs,   // user submit form data
191
+            $_iPostID, // object id
192
+            $_aInputs, // user submit form data
193 193
             $this->oForm->dropRepeatableElements( $_aSavedMeta ), // Drop repeatable section elements from the saved meta array.
194 194
             $this->oForm->sStructureType   // fields type
195 195
         );        
@@ -246,14 +246,14 @@  discard block
 block discarded – undo
246 246
             }
247 247
      
248 248
             // If our nonce isn't there, or we can't verify it, bail
249
-            if ( ! isset( $_POST[ $this->oProp->sMetaBoxID ] ) ) {
249
+            if ( !isset( $_POST[ $this->oProp->sMetaBoxID ] ) ) {
250 250
                 return false;
251 251
             }
252
-            if ( ! wp_verify_nonce( $_POST[ $this->oProp->sMetaBoxID ], $this->oProp->sMetaBoxID ) ) {
252
+            if ( !wp_verify_nonce( $_POST[ $this->oProp->sMetaBoxID ], $this->oProp->sMetaBoxID ) ) {
253 253
                 return false;
254 254
             }
255 255
             
256
-            if ( ! in_array( $aUnmodified[ 'post_type' ], $this->oProp->aPostTypes ) ) {
256
+            if ( !in_array( $aUnmodified[ 'post_type' ], $this->oProp->aPostTypes ) ) {
257 257
                 return false;
258 258
             }              
259 259
             
Please login to merge, or discard this patch.
Braces   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -114,7 +114,7 @@  discard block
 block discarded – undo
114 114
          * @internal
115 115
          * @return      integer     The found post ID. `0` if not found.
116 116
          */
117
-        private function _getPostID()  {
117
+        private function _getPostID() {
118 118
             
119 119
             // for an editing post page.
120 120
             if ( isset( $GLOBALS[ 'post' ]->ID ) ) {
@@ -146,7 +146,7 @@  discard block
 block discarded – undo
146 146
     public function _replyToFilterSavingData( $aPostData, $aUnmodified ) {
147 147
 
148 148
         // Perform initial checks.
149
-        if ( ! $this->_shouldProceedValidation( $aUnmodified ) ) { 
149
+        if ( ! $this->_shouldProceedValidation( $aUnmodified ) ) {
150 150
             return $aPostData; 
151 151
         }
152 152
                 
@@ -236,12 +236,12 @@  discard block
 block discarded – undo
236 236
          */
237 237
         private function _shouldProceedValidation( array $aUnmodified ) {
238 238
             
239
-            if ( 'auto-draft' === $aUnmodified[ 'post_status' ] ) { 
239
+            if ( 'auto-draft' === $aUnmodified[ 'post_status' ] ) {
240 240
                 return false; 
241 241
             }            
242 242
             
243 243
             // Bail if we're doing an auto save
244
-            if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) { 
244
+            if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) {
245 245
                 return false;
246 246
             }
247 247
      
Please login to merge, or discard this patch.
development/factory/meta_box/AdminPageFramework_MetaBox_Router.php 2 patches
Braces   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
      */ 
37 37
     public function __construct( $sMetaBoxID, $sTitle, $asPostTypeOrScreenID=array( 'post' ), $sContext='normal', $sPriority='default', $sCapability='edit_posts', $sTextDomain='admin-page-framework' ) {
38 38
         
39
-        if ( empty( $asPostTypeOrScreenID ) ) { 
39
+        if ( empty( $asPostTypeOrScreenID ) ) {
40 40
             return; 
41 41
         }
42 42
                 
@@ -80,7 +80,7 @@  discard block
 block discarded – undo
80 80
             return false;
81 81
         }
82 82
         
83
-        if ( ! in_array( $this->oUtil->getCurrentPostType(), $this->oProp->aPostTypes ) ) {     
83
+        if ( ! in_array( $this->oUtil->getCurrentPostType(), $this->oProp->aPostTypes ) ) {
84 84
             return false;    
85 85
         }    
86 86
 
@@ -112,7 +112,7 @@  discard block
 block discarded – undo
112 112
      */
113 113
     public function _replyToDetermineToLoad( $oScreen ) {
114 114
  
115
-        if ( ! $this->_isInThePage() ) { 
115
+        if ( ! $this->_isInThePage() ) {
116 116
             return; 
117 117
         }
118 118
         
Please login to merge, or discard this patch.
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
      * @param       string          $sTextDomain            (optional) The text domain applied to the displayed text messages. Default: `admin-page-framework`.
35 35
      * @return      void
36 36
      */ 
37
-    public function __construct( $sMetaBoxID, $sTitle, $asPostTypeOrScreenID=array( 'post' ), $sContext='normal', $sPriority='default', $sCapability='edit_posts', $sTextDomain='admin-page-framework' ) {
37
+    public function __construct( $sMetaBoxID, $sTitle, $asPostTypeOrScreenID = array( 'post' ), $sContext = 'normal', $sPriority = 'default', $sCapability = 'edit_posts', $sTextDomain = 'admin-page-framework' ) {
38 38
         
39 39
         if ( empty( $asPostTypeOrScreenID ) ) { 
40 40
             return; 
@@ -54,8 +54,8 @@  discard block
 block discarded – undo
54 54
         
55 55
         $this->oProp->sMetaBoxID    = $sMetaBoxID ? $this->oUtil->sanitizeSlug( $sMetaBoxID ) : strtolower( $_sClassName );
56 56
         $this->oProp->sTitle        = $sTitle;
57
-        $this->oProp->sContext      = $sContext;    // 'normal', 'advanced', or 'side' 
58
-        $this->oProp->sPriority     = $sPriority;   // 'high', 'core', 'default' or 'low'    
57
+        $this->oProp->sContext      = $sContext; // 'normal', 'advanced', or 'side' 
58
+        $this->oProp->sPriority     = $sPriority; // 'high', 'core', 'default' or 'low'    
59 59
 
60 60
         if ( $this->oProp->bIsAdmin ) {
61 61
             $this->oUtil->registerAction(
@@ -76,11 +76,11 @@  discard block
 block discarded – undo
76 76
      */
77 77
     public function _isInThePage() {
78 78
 
79
-        if ( ! in_array( $this->oProp->sPageNow, array( 'post.php', 'post-new.php' ) ) ) {
79
+        if ( !in_array( $this->oProp->sPageNow, array( 'post.php', 'post-new.php' ) ) ) {
80 80
             return false;
81 81
         }
82 82
         
83
-        if ( ! in_array( $this->oUtil->getCurrentPostType(), $this->oProp->aPostTypes ) ) {     
83
+        if ( !in_array( $this->oUtil->getCurrentPostType(), $this->oProp->aPostTypes ) ) {     
84 84
             return false;    
85 85
         }    
86 86
 
@@ -96,7 +96,7 @@  discard block
 block discarded – undo
96 96
     protected  function _isInstantiatable() {
97 97
         
98 98
         // Disable in admin-ajax.php
99
-        if ( isset( $GLOBALS['pagenow'] ) && 'admin-ajax.php' === $GLOBALS['pagenow'] ) {
99
+        if ( isset( $GLOBALS[ 'pagenow' ] ) && 'admin-ajax.php' === $GLOBALS[ 'pagenow' ] ) {
100 100
             return false;
101 101
         }
102 102
         return true;
@@ -116,9 +116,9 @@  discard block
 block discarded – undo
116 116
          * When the current_screen action is already triggered, the parameter will not be passed. 
117 117
          * So retrieve the screen object anyway.
118 118
          */
119
-        $_oScreen  = get_current_screen();
119
+        $_oScreen = get_current_screen();
120 120
         
121
-        if ( ! $this->_isInThePage() ) { 
121
+        if ( !$this->_isInThePage() ) { 
122 122
             return; 
123 123
         }
124 124
         
Please login to merge, or discard this patch.
development/factory/meta_box/AdminPageFramework_MetaBox_View.php 2 patches
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
 
32 32
         // Use nonce for verification
33 33
         $_aOutput   = array();
34
-        $_aOutput[] = wp_nonce_field(
34
+        $_aOutput[ ] = wp_nonce_field(
35 35
             $this->oProp->sMetaBoxID, 
36 36
             $this->oProp->sMetaBoxID, 
37 37
             true, 
@@ -39,10 +39,10 @@  discard block
 block discarded – undo
39 39
         );
40 40
                                  
41 41
         // Get the fields output.
42
-        $_aOutput[] = $this->oForm->get();
42
+        $_aOutput[ ] = $this->oForm->get();
43 43
 
44 44
         // Do actions
45
-        $this->oUtil->addAndDoActions( $this, 'do_' . $this->oProp->sClassName, $this );
45
+        $this->oUtil->addAndDoActions( $this, 'do_'.$this->oProp->sClassName, $this );
46 46
         
47 47
         // Render the filtered output.
48 48
         echo $this->oUtil->addAndApplyFilters(
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@
 block discarded – undo
27 27
      * @return      void
28 28
      * @internal    
29 29
      */ 
30
-    public function _replyToPrintMetaBoxContents( $oPost, $vArgs ) {    
30
+    public function _replyToPrintMetaBoxContents( $oPost, $vArgs ) {
31 31
 
32 32
         // Use nonce for verification
33 33
         $_aOutput   = array();
Please login to merge, or discard this patch.
factory/meta_box/_controller/AdminPageFramework_Resource_MetaBox.php 1 patch
Spacing   +16 added lines, -16 removed lines patch added patch discarded remove patch
@@ -30,11 +30,11 @@  discard block
 block discarded – undo
30 30
      * @since 2.1.5
31 31
      * @internal
32 32
      */
33
-    public function _enqueueStyles( $aSRCs, $aPostTypes=array(), $aCustomArgs=array() ) {
33
+    public function _enqueueStyles( $aSRCs, $aPostTypes = array(), $aCustomArgs = array() ) {
34 34
         
35 35
         $_aHandleIDs = array();
36
-        foreach( ( array ) $aSRCs as $_sSRC ) {
37
-            $_aHandleIDs[] = $this->_enqueueStyle( $_sSRC, $aPostTypes, $aCustomArgs );
36
+        foreach ( ( array ) $aSRCs as $_sSRC ) {
37
+            $_aHandleIDs[ ] = $this->_enqueueStyle( $_sSRC, $aPostTypes, $aCustomArgs );
38 38
         }
39 39
         return $_aHandleIDs;
40 40
         
@@ -58,7 +58,7 @@  discard block
 block discarded – undo
58 58
      * @return string The script handle ID. If the passed url is not a valid url string, an empty string will be returned.
59 59
      * @internal
60 60
      */    
61
-    public function _enqueueStyle( $sSRC, $aPostTypes=array(), $aCustomArgs=array() ) {
61
+    public function _enqueueStyle( $sSRC, $aPostTypes = array(), $aCustomArgs = array() ) {
62 62
         
63 63
         $sSRC = trim( $sSRC );
64 64
         if ( empty( $sSRC ) ) { return ''; }
@@ -74,13 +74,13 @@  discard block
 block discarded – undo
74 74
                 'sSRC'          => $sSRC,
75 75
                 'aPostTypes'    => empty( $aPostTypes ) ? $this->oProp->aPostTypes : $aPostTypes,
76 76
                 'sType'         => 'style',
77
-                'handle_id'     => 'style_' . $this->oProp->sClassName . '_' .  ( ++$this->oProp->iEnqueuedStyleIndex ),
77
+                'handle_id'     => 'style_'.$this->oProp->sClassName.'_'.( ++$this->oProp->iEnqueuedStyleIndex ),
78 78
             ),
79 79
             self::$_aStructure_EnqueuingResources
80 80
         );
81 81
         
82 82
         // Store the attributes in another container by url.
83
-        $this->oProp->aResourceAttributes[ $this->oProp->aEnqueuingStyles[ $_sSRCHash ]['handle_id'] ] = $this->oProp->aEnqueuingStyles[ $_sSRCHash ]['attributes'];
83
+        $this->oProp->aResourceAttributes[ $this->oProp->aEnqueuingStyles[ $_sSRCHash ][ 'handle_id' ] ] = $this->oProp->aEnqueuingStyles[ $_sSRCHash ][ 'attributes' ];
84 84
         
85 85
         return $this->oProp->aEnqueuingStyles[ $_sSRCHash ][ 'handle_id' ];
86 86
         
@@ -92,11 +92,11 @@  discard block
 block discarded – undo
92 92
      * @since 2.1.5
93 93
      * @internal
94 94
      */
95
-    public function _enqueueScripts( $aSRCs, $aPostTypes=array(), $aCustomArgs=array() ) {
95
+    public function _enqueueScripts( $aSRCs, $aPostTypes = array(), $aCustomArgs = array() ) {
96 96
         
97 97
         $_aHandleIDs = array();
98
-        foreach( ( array ) $aSRCs as $_sSRC ) {
99
-            $_aHandleIDs[] = $this->_enqueueScript( $_sSRC, $aPostTypes, $aCustomArgs );
98
+        foreach ( ( array ) $aSRCs as $_sSRC ) {
99
+            $_aHandleIDs[ ] = $this->_enqueueScript( $_sSRC, $aPostTypes, $aCustomArgs );
100 100
         }
101 101
         return $_aHandleIDs;
102 102
         
@@ -121,7 +121,7 @@  discard block
 block discarded – undo
121 121
      * @return string The script handle ID. If the passed url is not a valid url string, an empty string will be returned.
122 122
      * @internal
123 123
      */
124
-    public function _enqueueScript( $sSRC, $aPostTypes=array(), $aCustomArgs=array() ) {
124
+    public function _enqueueScript( $sSRC, $aPostTypes = array(), $aCustomArgs = array() ) {
125 125
         
126 126
         $sSRC       = trim( $sSRC );
127 127
         if ( empty( $sSRC ) ) { return ''; }
@@ -137,13 +137,13 @@  discard block
 block discarded – undo
137 137
                 'sSRC'          => $sSRC,
138 138
                 'aPostTypes'    => empty( $aPostTypes ) ? $this->oProp->aPostTypes : $aPostTypes,
139 139
                 'sType'         => 'script',
140
-                'handle_id'     => 'script_' . $this->oProp->sClassName . '_' .  ( ++$this->oProp->iEnqueuedScriptIndex ),
140
+                'handle_id'     => 'script_'.$this->oProp->sClassName.'_'.( ++$this->oProp->iEnqueuedScriptIndex ),
141 141
             ),
142 142
             self::$_aStructure_EnqueuingResources
143 143
         );
144 144
         
145 145
         // Store the attributes in another container by url.
146
-        $this->oProp->aResourceAttributes[ $this->oProp->aEnqueuingScripts[ $_sSRCHash ]['handle_id'] ] = $this->oProp->aEnqueuingScripts[ $_sSRCHash ]['attributes'];
146
+        $this->oProp->aResourceAttributes[ $this->oProp->aEnqueuingScripts[ $_sSRCHash ][ 'handle_id' ] ] = $this->oProp->aEnqueuingScripts[ $_sSRCHash ][ 'attributes' ];
147 147
         
148 148
         return $this->oProp->aEnqueuingScripts[ $_sSRCHash ][ 'handle_id' ];
149 149
         
@@ -155,7 +155,7 @@  discard block
 block discarded – undo
155 155
      * @since 3.0.0
156 156
      * @internal
157 157
      */
158
-    public function _forceToEnqueueStyle( $sSRC, $aCustomArgs=array() ) {
158
+    public function _forceToEnqueueStyle( $sSRC, $aCustomArgs = array() ) {
159 159
         return $this->_enqueueStyle( $sSRC, array(), $aCustomArgs );
160 160
     }
161 161
     /**
@@ -164,7 +164,7 @@  discard block
 block discarded – undo
164 164
      * @since 3.0.0
165 165
      * @internal
166 166
      */    
167
-    public function _forceToEnqueueScript( $sSRC, $aCustomArgs=array() ) {
167
+    public function _forceToEnqueueScript( $sSRC, $aCustomArgs = array() ) {
168 168
         return $this->_enqueueScript( $sSRC, array(), $aCustomArgs );
169 169
     }
170 170
     
@@ -177,8 +177,8 @@  discard block
 block discarded – undo
177 177
      */
178 178
     protected function _enqueueSRCByCondition( $aEnqueueItem ) {
179 179
        
180
-        $_sCurrentPostType = isset( $_GET['post_type'] ) ? $_GET['post_type'] : ( isset( $GLOBALS['typenow'] ) ? $GLOBALS['typenow'] : null );
181
-        if ( in_array( $_sCurrentPostType, $aEnqueueItem['aPostTypes'] ) ) {
180
+        $_sCurrentPostType = isset( $_GET[ 'post_type' ] ) ? $_GET[ 'post_type' ] : ( isset( $GLOBALS[ 'typenow' ] ) ? $GLOBALS[ 'typenow' ] : null );
181
+        if ( in_array( $_sCurrentPostType, $aEnqueueItem[ 'aPostTypes' ] ) ) {
182 182
             return $this->_enqueueSRC( $aEnqueueItem );
183 183
         }
184 184
             
Please login to merge, or discard this patch.
factory/meta_box/_model/AdminPageFramework_MetaBox_Model___PostMeta.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
      */
45 45
     public function get() {
46 46
 
47
-        if ( ! $this->iPostID ) {
47
+        if ( !$this->iPostID ) {
48 48
             return array();
49 49
         }
50 50
         return $this->_getSavedDataFromFieldsets(
@@ -66,11 +66,11 @@  discard block
 block discarded – undo
66 66
             );     
67 67
 
68 68
             $_aMetaData = array();
69
-            foreach( $aFieldsets as $_sSectionID => $_aFieldsets ) {
69
+            foreach ( $aFieldsets as $_sSectionID => $_aFieldsets ) {
70 70
                 
71
-                if ( '_default' == $_sSectionID  ) {
72
-                    foreach( $_aFieldsets as $_aFieldset ) {
73
-                        if ( ! in_array( $_aFieldset[ 'field_id' ], $_aMetaKeys ) ) {
71
+                if ( '_default' == $_sSectionID ) {
72
+                    foreach ( $_aFieldsets as $_aFieldset ) {
73
+                        if ( !in_array( $_aFieldset[ 'field_id' ], $_aMetaKeys ) ) {
74 74
                             continue;
75 75
                         }
76 76
                         $_aMetaData[ $_aFieldset[ 'field_id' ] ] = get_post_meta( 
@@ -80,7 +80,7 @@  discard block
 block discarded – undo
80 80
                         );    
81 81
                     }
82 82
                 }
83
-                if ( ! in_array( $_sSectionID, $_aMetaKeys ) ) {
83
+                if ( !in_array( $_sSectionID, $_aMetaKeys ) ) {
84 84
                     continue;
85 85
                 }                
86 86
                 $_aMetaData[ $_sSectionID ] = get_post_meta( 
Please login to merge, or discard this patch.
development/factory/meta_box/_model/AdminPageFramework_Property_MetaBox.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
      * @since       2.1.0       Moved from the meta box class.
36 36
      * @var string
37 37
      */     
38
-    public $sMetaBoxID ='';
38
+    public $sMetaBoxID = '';
39 39
     
40 40
     /**
41 41
      * Stores the meta box title.
@@ -156,7 +156,7 @@  discard block
 block discarded – undo
156 156
      */
157 157
     public $_sFormRegistrationHook = 'admin_enqueue_scripts';      
158 158
     
159
-    public function __construct( $oCaller, $sClassName, $sCapability='edit_posts', $sTextDomain='admin-page-framework', $sStructureType='post_meta_box' ) {
159
+    public function __construct( $oCaller, $sClassName, $sCapability = 'edit_posts', $sTextDomain = 'admin-page-framework', $sStructureType = 'post_meta_box' ) {
160 160
         
161 161
         // meta boxes don't need the caller script path.
162 162
         parent::__construct( 
Please login to merge, or discard this patch.
factory/meta_box/form/_view/AdminPageFramework_Form_View___CSS_meta_box.php 1 patch
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@
 block discarded – undo
21 21
      * @since       DEVVER
22 22
      * @return      string
23 23
      */
24
-    protected function _get() {        
24
+    protected function _get() {
25 25
         return $this->_getRules();
26 26
     }
27 27
         /**
Please login to merge, or discard this patch.
development/factory/network_admin_page/AdminPageFramework_NetworkAdmin.php 2 patches
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -30,12 +30,12 @@  discard block
 block discarded – undo
30 30
     protected $_aBuiltInRootMenuSlugs = array(
31 31
         // All keys must be lower case to support case insensitive look-ups.
32 32
         'dashboard'     => 'index.php',
33
-        'sites'         => 'sites.php',         // not work
34
-        'themes'        => 'themes.php',        // not work
33
+        'sites'         => 'sites.php', // not work
34
+        'themes'        => 'themes.php', // not work
35 35
         'plugins'       => 'plugins.php',
36 36
         'users'         => 'users.php',
37 37
         'settings'      => 'settings.php',
38
-        'updates'       => 'update-core.php',   // does not work
38
+        'updates'       => 'update-core.php', // does not work
39 39
     );     
40 40
         
41 41
     /**
@@ -55,9 +55,9 @@  discard block
 block discarded – undo
55 55
      * @param       string      $sTextDomain        (optional) the <a href="http://codex.wordpress.org/I18n_for_WordPress_Developers#Text_Domains" target="_blank">text domain</a> used for the framework's system messages. Default: `admin-page-framework`.
56 56
      * @return      void        returns nothing.
57 57
      */
58
-    public function __construct( $sOptionKey=null, $sCallerPath=null, $sCapability='manage_network', $sTextDomain='admin-page-framework' ){
58
+    public function __construct( $sOptionKey = null, $sCallerPath = null, $sCapability = 'manage_network', $sTextDomain = 'admin-page-framework' ) {
59 59
             
60
-        if ( ! $this->_isInstantiatable() ) {
60
+        if ( !$this->_isInstantiatable() ) {
61 61
             return;
62 62
         }
63 63
         
@@ -65,7 +65,7 @@  discard block
 block discarded – undo
65 65
             
66 66
         $sCallerPath = $sCallerPath 
67 67
             ? $sCallerPath 
68
-            : AdminPageFramework_Utility::getCallerScriptPath( __FILE__ );     // this is important to attempt to find the caller script path here when separating the library into multiple files.
68
+            : AdminPageFramework_Utility::getCallerScriptPath( __FILE__ ); // this is important to attempt to find the caller script path here when separating the library into multiple files.
69 69
         
70 70
         $this->oProp = new AdminPageFramework_Property_NetworkAdmin( $this, $sCallerPath, get_class( $this ), $sOptionKey, $sCapability, $sTextDomain );
71 71
         
@@ -81,7 +81,7 @@  discard block
 block discarded – undo
81 81
      */
82 82
     protected function _isInstantiatable() {
83 83
         
84
-        if ( isset( $GLOBALS['pagenow'] ) && 'admin-ajax.php' === $GLOBALS['pagenow'] ) {
84
+        if ( isset( $GLOBALS[ 'pagenow' ] ) && 'admin-ajax.php' === $GLOBALS[ 'pagenow' ] ) {
85 85
             return false;
86 86
         }     
87 87
         
@@ -125,7 +125,7 @@  discard block
 block discarded – undo
125 125
      * @param       mixed       $vDefault     the default value that will be returned if nothing is stored.
126 126
      * @return      mixed       If the field ID is not specified.
127 127
      */
128
-    static public function getOption( $sOptionKey, $asKey=null , $vDefault=null ) {
128
+    static public function getOption( $sOptionKey, $asKey = null, $vDefault = null ) {
129 129
         return AdminPageFramework_WPUtility::getSiteOption( $sOptionKey, $asKey, $vDefault );
130 130
     }
131 131
     
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -55,7 +55,7 @@
 block discarded – undo
55 55
      * @param       string      $sTextDomain        (optional) the <a href="http://codex.wordpress.org/I18n_for_WordPress_Developers#Text_Domains" target="_blank">text domain</a> used for the framework's system messages. Default: `admin-page-framework`.
56 56
      * @return      void        returns nothing.
57 57
      */
58
-    public function __construct( $sOptionKey=null, $sCallerPath=null, $sCapability='manage_network', $sTextDomain='admin-page-framework' ){
58
+    public function __construct( $sOptionKey=null, $sCallerPath=null, $sCapability='manage_network', $sTextDomain='admin-page-framework' ) {
59 59
             
60 60
         if ( ! $this->_isInstantiatable() ) {
61 61
             return;
Please login to merge, or discard this patch.