@@ -36,7 +36,7 @@ discard block |
||
36 | 36 | */ |
37 | 37 | public function _replyToSetFooterInfo() { |
38 | 38 | |
39 | - if ( ! $this->oProp->isPageAdded() ) { |
|
39 | + if ( ! $this->oProp->isPageAdded() ) { |
|
40 | 40 | return; |
41 | 41 | } |
42 | 42 | parent::_replyToSetFooterInfo(); |
@@ -211,7 +211,7 @@ discard block |
||
211 | 211 | public function _replyToAddSettingsLinkInPluginListingPage( $aLinks ) { |
212 | 212 | |
213 | 213 | // If the sub-pages are not added, do nothing. |
214 | - if ( count( $this->oProp->aPages ) < 1 ) { |
|
214 | + if ( count( $this->oProp->aPages ) < 1 ) { |
|
215 | 215 | return $aLinks; |
216 | 216 | } |
217 | 217 | |
@@ -260,7 +260,7 @@ discard block |
||
260 | 260 | */ |
261 | 261 | public function _replyToAddLinkToPluginDescription( $aLinks, $sFile ) { |
262 | 262 | |
263 | - if ( $sFile !== plugin_basename( $this->oProp->aScriptInfo[ 'sPath' ] ) ) { |
|
263 | + if ( $sFile !== plugin_basename( $this->oProp->aScriptInfo[ 'sPath' ] ) ) { |
|
264 | 264 | return $aLinks; |
265 | 265 | } |
266 | 266 | |
@@ -271,7 +271,8 @@ discard block |
||
271 | 271 | if ( ! $_sLLinkHTML ) { |
272 | 272 | continue; |
273 | 273 | } |
274 | - if ( is_array( $_sLLinkHTML ) ) { // should not be an array |
|
274 | + if ( is_array( $_sLLinkHTML ) ) { |
|
275 | +// should not be an array |
|
275 | 276 | $_aAddingLinks = array_merge( $_sLLinkHTML, $_aAddingLinks ); |
276 | 277 | continue; |
277 | 278 | } |
@@ -90,7 +90,7 @@ |
||
90 | 90 | $this->oProp->aPluginTitleLinks = array_merge( |
91 | 91 | $this->oProp->aPluginTitleLinks, |
92 | 92 | $asLinks |
93 | - ); |
|
93 | + ); |
|
94 | 94 | } |
95 | 95 | |
96 | 96 | $this->_addFilterHook_PluginTitleActionLink(); |
@@ -36,7 +36,7 @@ discard block |
||
36 | 36 | */ |
37 | 37 | public function _replyToSetFooterInfo() { |
38 | 38 | |
39 | - if ( ! $this->oProp->isPageAdded() ) { |
|
39 | + if ( !$this->oProp->isPageAdded() ) { |
|
40 | 40 | return; |
41 | 41 | } |
42 | 42 | parent::_replyToSetFooterInfo(); |
@@ -56,8 +56,8 @@ discard block |
||
56 | 56 | */ |
57 | 57 | public function _addLinkToPluginDescription( $asLinks ) { |
58 | 58 | |
59 | - if ( ! is_array( $asLinks ) ) { |
|
60 | - $this->oProp->aPluginDescriptionLinks[] = $asLinks; |
|
59 | + if ( !is_array( $asLinks ) ) { |
|
60 | + $this->oProp->aPluginDescriptionLinks[ ] = $asLinks; |
|
61 | 61 | } else { |
62 | 62 | $this->oProp->aPluginDescriptionLinks = array_merge( |
63 | 63 | $this->oProp->aPluginDescriptionLinks, |
@@ -84,8 +84,8 @@ discard block |
||
84 | 84 | */ |
85 | 85 | public function _addLinkToPluginTitle( $asLinks ) { |
86 | 86 | |
87 | - if ( ! is_array( $asLinks ) ) { |
|
88 | - $this->oProp->aPluginTitleLinks[] = $asLinks; |
|
87 | + if ( !is_array( $asLinks ) ) { |
|
88 | + $this->oProp->aPluginTitleLinks[ ] = $asLinks; |
|
89 | 89 | } else { |
90 | 90 | $this->oProp->aPluginTitleLinks = array_merge( |
91 | 91 | $this->oProp->aPluginTitleLinks, |
@@ -120,7 +120,7 @@ discard block |
||
120 | 120 | } |
121 | 121 | $_sPluginBaseName = plugin_basename( $this->oProp->aScriptInfo[ 'sPath' ] ); |
122 | 122 | add_filter( |
123 | - $this->_sFilterSuffix_PluginActionLinks . $_sPluginBaseName, |
|
123 | + $this->_sFilterSuffix_PluginActionLinks.$_sPluginBaseName, |
|
124 | 124 | array( $this, '_replyToAddPluginActionLinks' ) |
125 | 125 | ); |
126 | 126 | } |
@@ -133,14 +133,14 @@ discard block |
||
133 | 133 | * @return string |
134 | 134 | * @internal |
135 | 135 | */ |
136 | - public function _replyToAddInfoInFooterLeft( $sLinkHTML='' ) { |
|
136 | + public function _replyToAddInfoInFooterLeft( $sLinkHTML = '' ) { |
|
137 | 137 | |
138 | - if ( ! $this->_isPageAdded() ) { |
|
138 | + if ( !$this->_isPageAdded() ) { |
|
139 | 139 | return $sLinkHTML; // $sLinkHTML is given by the hook. |
140 | 140 | } |
141 | - $sLinkHTML = empty( $this->oProp->aScriptInfo['sName'] ) |
|
141 | + $sLinkHTML = empty( $this->oProp->aScriptInfo[ 'sName' ] ) |
|
142 | 142 | ? $sLinkHTML |
143 | - : $this->oProp->aFooterInfo['sLeft']; |
|
143 | + : $this->oProp->aFooterInfo[ 'sLeft' ]; |
|
144 | 144 | |
145 | 145 | $_sPageSlug = $this->oProp->getCurrentPageSlug(); |
146 | 146 | $_sTabSlug = $this->oProp->getCurrentTabSlug(); |
@@ -151,11 +151,11 @@ discard block |
||
151 | 151 | array( |
152 | 152 | $this->getAOrB( |
153 | 153 | $_sTabSlug, |
154 | - 'footer_left_' . $_sPageSlug . '_' . $_sTabSlug, |
|
154 | + 'footer_left_'.$_sPageSlug.'_'.$_sTabSlug, |
|
155 | 155 | null // will be ignored |
156 | 156 | ), |
157 | - 'footer_left_' . $_sPageSlug, |
|
158 | - 'footer_left_' . $this->oProp->sClassName |
|
157 | + 'footer_left_'.$_sPageSlug, |
|
158 | + 'footer_left_'.$this->oProp->sClassName |
|
159 | 159 | ), |
160 | 160 | $sLinkHTML |
161 | 161 | ); |
@@ -169,9 +169,9 @@ discard block |
||
169 | 169 | * @return string |
170 | 170 | * @internal |
171 | 171 | */ |
172 | - public function _replyToAddInfoInFooterRight( $sLinkHTML='' ) { |
|
172 | + public function _replyToAddInfoInFooterRight( $sLinkHTML = '' ) { |
|
173 | 173 | |
174 | - if ( ! $this->_isPageAdded() ) { |
|
174 | + if ( !$this->_isPageAdded() ) { |
|
175 | 175 | return $sLinkHTML; // $sLinkTHML is given by the hook. |
176 | 176 | } |
177 | 177 | |
@@ -184,13 +184,13 @@ discard block |
||
184 | 184 | array( |
185 | 185 | $this->getAOrB( |
186 | 186 | $_sTabSlug, |
187 | - 'footer_right_' . $_sPageSlug . '_' . $_sTabSlug, |
|
187 | + 'footer_right_'.$_sPageSlug.'_'.$_sTabSlug, |
|
188 | 188 | null // will be ignored |
189 | 189 | ), |
190 | - 'footer_right_' . $_sPageSlug, |
|
191 | - 'footer_right_' . $this->oProp->sClassName |
|
190 | + 'footer_right_'.$_sPageSlug, |
|
191 | + 'footer_right_'.$this->oProp->sClassName |
|
192 | 192 | ), |
193 | - $this->oProp->aFooterInfo['sRight'] |
|
193 | + $this->oProp->aFooterInfo[ 'sRight' ] |
|
194 | 194 | ); |
195 | 195 | |
196 | 196 | } |
@@ -203,7 +203,7 @@ discard block |
||
203 | 203 | */ |
204 | 204 | private function _isPageAdded() { |
205 | 205 | |
206 | - if ( ! isset( $_GET[ 'page' ] ) ) { |
|
206 | + if ( !isset( $_GET[ 'page' ] ) ) { |
|
207 | 207 | return false; |
208 | 208 | } |
209 | 209 | return ( bool ) $this->oProp->isPageAdded( $_GET[ 'page' ] ); |
@@ -228,7 +228,7 @@ discard block |
||
228 | 228 | : $this->oProp->sLabelPluginSettingsLink; |
229 | 229 | |
230 | 230 | // If the user disables the settings link, the label property is empty. If so, do not add it. |
231 | - if ( ! $this->oProp->sLabelPluginSettingsLink ) { |
|
231 | + if ( !$this->oProp->sLabelPluginSettingsLink ) { |
|
232 | 232 | return $aLinks; |
233 | 233 | } |
234 | 234 | |
@@ -246,13 +246,13 @@ discard block |
||
246 | 246 | array_unshift( |
247 | 247 | $aLinks, |
248 | 248 | // '<a href="' . esc_url( $_sLinkURL ) . '">' |
249 | - '<a ' . $this->getAttributes( |
|
249 | + '<a '.$this->getAttributes( |
|
250 | 250 | array( |
251 | 251 | 'href' => esc_url( $_sLinkURL ), |
252 | 252 | // 3.5.7+ Added for acceptance testing |
253 | 253 | 'class' => 'apf-plugin-title-action-link apf-post-type', |
254 | 254 | ) |
255 | - ) . '>' |
|
255 | + ).'>' |
|
256 | 256 | . $this->oProp->sLabelPluginSettingsLink |
257 | 257 | . '</a>' |
258 | 258 | ); |
@@ -275,16 +275,16 @@ discard block |
||
275 | 275 | |
276 | 276 | // Backward compatibility sanitisation. |
277 | 277 | $_aAddingLinks = array(); |
278 | - foreach( array_filter( $this->oProp->aPluginDescriptionLinks ) as $_sLLinkHTML ) { |
|
278 | + foreach ( array_filter( $this->oProp->aPluginDescriptionLinks ) as $_sLLinkHTML ) { |
|
279 | 279 | |
280 | - if ( ! $_sLLinkHTML ) { |
|
280 | + if ( !$_sLLinkHTML ) { |
|
281 | 281 | continue; |
282 | 282 | } |
283 | 283 | if ( is_array( $_sLLinkHTML ) ) { // should not be an array |
284 | 284 | $_aAddingLinks = array_merge( $_sLLinkHTML, $_aAddingLinks ); |
285 | 285 | continue; |
286 | 286 | } |
287 | - $_aAddingLinks[] = ( string ) $_sLLinkHTML; |
|
287 | + $_aAddingLinks[ ] = ( string ) $_sLLinkHTML; |
|
288 | 288 | |
289 | 289 | } |
290 | 290 | return array_merge( $aLinks, $_aAddingLinks ); |
@@ -301,13 +301,13 @@ discard block |
||
301 | 301 | public function _replyToAddPluginActionLinks( $aLinks ) { |
302 | 302 | |
303 | 303 | $_aAddingLinks = array(); |
304 | - foreach( array_filter( $this->oProp->aPluginTitleLinks ) as $_sLinkHTML ) { |
|
304 | + foreach ( array_filter( $this->oProp->aPluginTitleLinks ) as $_sLinkHTML ) { |
|
305 | 305 | |
306 | 306 | if ( is_array( $_sLinkHTML ) ) { |
307 | 307 | $_aAddingLinks = array_merge( $_sLinkHTML, $aAddingLinks ); |
308 | 308 | continue; |
309 | 309 | } |
310 | - $_aAddingLinks[] = ( string ) $_sLinkHTML; |
|
310 | + $_aAddingLinks[ ] = ( string ) $_sLinkHTML; |
|
311 | 311 | |
312 | 312 | } |
313 | 313 | return array_merge( $aLinks, $_aAddingLinks ); |
@@ -107,8 +107,8 @@ |
||
107 | 107 | } |
108 | 108 | CSSRULES; |
109 | 109 | |
110 | - return $_sCSS . PHP_EOL |
|
111 | - . self::_getPageLoadStatsRules() . PHP_EOL |
|
110 | + return $_sCSS.PHP_EOL |
|
111 | + . self::_getPageLoadStatsRules().PHP_EOL |
|
112 | 112 | . self::_getVersionSpecificRules(); |
113 | 113 | |
114 | 114 | } |
@@ -29,7 +29,7 @@ discard block |
||
29 | 29 | array( $this, '_replyToRegisterFormItems' ), |
30 | 30 | 100 // priority - low value is set as meta boxes use the `current_screen` action hook for `setUp()`. |
31 | 31 | ); |
32 | - } else { |
|
32 | + } else { |
|
33 | 33 | add_action( |
34 | 34 | $this->aArguments[ 'action_hook_form_registration' ], |
35 | 35 | array( $this, '_replyToRegisterFormItems' ) |
@@ -147,12 +147,12 @@ discard block |
||
147 | 147 | * Changed the name from `getFieldsModel()`. |
148 | 148 | * @return array |
149 | 149 | */ |
150 | - public function getDataStructureFromAddedFieldsets() { |
|
150 | + public function getDataStructureFromAddedFieldsets() { |
|
151 | 151 | |
152 | 152 | $_aFormDataStructure = array(); |
153 | 153 | foreach ( $this->getAsArray( $this->aFieldsets ) as $_sSectionID => $_aFieldsets ) { |
154 | 154 | |
155 | - if ( $_sSectionID != '_default' ) { |
|
155 | + if ( $_sSectionID != '_default' ) { |
|
156 | 156 | $_aFormDataStructure[ $_sSectionID ] = $_aFieldsets; |
157 | 157 | continue; |
158 | 158 | } |
@@ -185,7 +185,7 @@ discard block |
||
185 | 185 | * @param array $aSubject The subject array to modify. Usually the saved option data. |
186 | 186 | * @return array The modified options array. |
187 | 187 | */ |
188 | - public function dropRepeatableElements( array $aSubject ) { |
|
188 | + public function dropRepeatableElements( array $aSubject ) { |
|
189 | 189 | $_oFilterRepeatableElements = new AdminPageFramework_Form_Model___Modifier_FilterRepeatableElements( |
190 | 190 | $aSubject, |
191 | 191 | $this->getElementAsArray( |
@@ -402,7 +402,6 @@ discard block |
||
402 | 402 | * |
403 | 403 | * @since 3.7.0 |
404 | 404 | * @param array $aSavedData |
405 | - * @param boolean $bOnlyFieldsets Whether to format only the fieldsets. The taxonomy field factory uses this parameter. |
|
406 | 405 | */ |
407 | 406 | protected function _formatElementDefinitions( array $aSavedData ) { |
408 | 407 | |
@@ -438,7 +437,6 @@ discard block |
||
438 | 437 | * Changed the name from `_getFieldErrors()`. |
439 | 438 | * @access public The field type class accesses this method to render nested fields. |
440 | 439 | * @internal |
441 | - * @param boolean $bDelete whether or not the transient should be deleted after retrieving it. |
|
442 | 440 | * @return array |
443 | 441 | */ |
444 | 442 | public function getFieldErrors() { |
@@ -47,16 +47,16 @@ discard block |
||
47 | 47 | * @return array |
48 | 48 | * @since 3.7.0 |
49 | 49 | */ |
50 | - public function getSubmittedData( array $aDataToParse, $bExtractFromFieldStructure=true, $bStripSlashes=true ) { |
|
50 | + public function getSubmittedData( array $aDataToParse, $bExtractFromFieldStructure = true, $bStripSlashes = true ) { |
|
51 | 51 | |
52 | 52 | // Extracts the form data from the subject data for parsing |
53 | - $_aSubmittedFormData = $bExtractFromFieldStructure |
|
53 | + $_aSubmittedFormData = $bExtractFromFieldStructure |
|
54 | 54 | ? $this->castArrayContents( |
55 | 55 | $this->getDataStructureFromAddedFieldsets(), // form data (options) structure |
56 | 56 | $aDataToParse // the subject data array, usually $_POST. |
57 | 57 | ) |
58 | 58 | : $aDataToParse; |
59 | - $_aSubmittedFormData = $this->getHTTPRequestSanitized( $_aSubmittedFormData, $bStripSlashes ); |
|
59 | + $_aSubmittedFormData = $this->getHTTPRequestSanitized( $_aSubmittedFormData, $bStripSlashes ); |
|
60 | 60 | return $this->getSortedInputs( $_aSubmittedFormData ); // [3.6.0] - sorts dynamic elements. |
61 | 61 | |
62 | 62 | } |
@@ -79,12 +79,12 @@ discard block |
||
79 | 79 | array_merge( |
80 | 80 | $this->getElementAsArray( |
81 | 81 | $_POST, |
82 | - '__repeatable_elements_' . $this->aArguments[ 'structure_type' ], |
|
82 | + '__repeatable_elements_'.$this->aArguments[ 'structure_type' ], |
|
83 | 83 | array() |
84 | 84 | ), |
85 | 85 | $this->getElementAsArray( |
86 | 86 | $_POST, |
87 | - '__sortable_elements_' . $this->aArguments[ 'structure_type' ], |
|
87 | + '__sortable_elements_'.$this->aArguments[ 'structure_type' ], |
|
88 | 88 | array() |
89 | 89 | ) |
90 | 90 | ) |
@@ -143,9 +143,9 @@ discard block |
||
143 | 143 | * Changed the name from `getFieldsModel()`. |
144 | 144 | * @return array |
145 | 145 | */ |
146 | - public function getDataStructureFromAddedFieldsets() { |
|
146 | + public function getDataStructureFromAddedFieldsets() { |
|
147 | 147 | |
148 | - $_aFormDataStructure = array(); |
|
148 | + $_aFormDataStructure = array(); |
|
149 | 149 | foreach ( $this->getAsArray( $this->aFieldsets ) as $_sSectionID => $_aFieldsets ) { |
150 | 150 | |
151 | 151 | if ( $_sSectionID != '_default' ) { |
@@ -154,7 +154,7 @@ discard block |
||
154 | 154 | } |
155 | 155 | |
156 | 156 | // For default field items. |
157 | - foreach( $_aFieldsets as $_sFieldID => $_aFieldset ) { |
|
157 | + foreach ( $_aFieldsets as $_sFieldID => $_aFieldset ) { |
|
158 | 158 | $_aFormDataStructure[ $_aFieldset[ 'field_id' ] ] = $_aFieldset; |
159 | 159 | } |
160 | 160 | |
@@ -186,7 +186,7 @@ discard block |
||
186 | 186 | $aSubject, |
187 | 187 | $this->getElementAsArray( |
188 | 188 | $_POST, |
189 | - '__repeatable_elements_' . $this->aArguments[ 'structure_type' ] |
|
189 | + '__repeatable_elements_'.$this->aArguments[ 'structure_type' ] |
|
190 | 190 | ) |
191 | 191 | ); |
192 | 192 | return $_oFilterRepeatableElements->get(); |
@@ -199,13 +199,13 @@ discard block |
||
199 | 199 | public function _replyToRegisterFormItems() { |
200 | 200 | |
201 | 201 | // Check if the form should be created or not. |
202 | - if ( ! $this->isInThePage() ) { |
|
202 | + if ( !$this->isInThePage() ) { |
|
203 | 203 | return; |
204 | 204 | } |
205 | 205 | |
206 | 206 | // Load field type definitions. |
207 | - $this->_setFieldTypeDefinitions( 'admin_page_framework' ); // site-wide |
|
208 | - $this->_setFieldTypeDefinitions( $this->aArguments[ 'caller_id' ] ); // per class |
|
207 | + $this->_setFieldTypeDefinitions( 'admin_page_framework' ); // site-wide |
|
208 | + $this->_setFieldTypeDefinitions( $this->aArguments[ 'caller_id' ] ); // per class |
|
209 | 209 | |
210 | 210 | // Set the options array |
211 | 211 | $this->aSavedData = $this->_getSavedData( |
@@ -233,7 +233,7 @@ discard block |
||
233 | 233 | $this->aArguments, |
234 | 234 | $this->aFieldsets, |
235 | 235 | self::$_aResources, |
236 | - $this->aFieldTypeDefinitions, // must be called after performing `_setFieldTypeDefinitions()`. |
|
236 | + $this->aFieldTypeDefinitions, // must be called after performing `_setFieldTypeDefinitions()`. |
|
237 | 237 | $this->aCallbacks |
238 | 238 | ); |
239 | 239 | self::$_aResources = $_oFieldResources->get(); // updates the property |
@@ -250,10 +250,10 @@ discard block |
||
250 | 250 | $this->callBack( |
251 | 251 | $this->aCallbacks[ 'handle_form_data' ], |
252 | 252 | array( |
253 | - $this->aSavedData, // 1st parameter |
|
254 | - $this->aArguments, // 2nd parameter |
|
255 | - $this->aSectionsets, // 3rd parameter |
|
256 | - $this->aFieldsets, // 4th parameter |
|
253 | + $this->aSavedData, // 1st parameter |
|
254 | + $this->aArguments, // 2nd parameter |
|
255 | + $this->aSectionsets, // 3rd parameter |
|
256 | + $this->aFieldsets, // 4th parameter |
|
257 | 257 | ) |
258 | 258 | ); |
259 | 259 | |
@@ -267,15 +267,15 @@ discard block |
||
267 | 267 | $this->aSectionsets = $this->callBack( |
268 | 268 | $this->aCallbacks[ 'secitonsets_before_registration' ], |
269 | 269 | array( |
270 | - $this->aSectionsets, // 1st parameter |
|
270 | + $this->aSectionsets, // 1st parameter |
|
271 | 271 | ) |
272 | 272 | ); |
273 | 273 | // Let the main routine modify the fieldsets definition array. |
274 | 274 | $this->aFieldsets = $this->callBack( |
275 | 275 | $this->aCallbacks[ 'fieldsets_before_registration' ], |
276 | 276 | array( |
277 | - $this->aFieldsets, // 1st parameter |
|
278 | - $this->aSectionsets, // 2nd parameter |
|
277 | + $this->aFieldsets, // 1st parameter |
|
278 | + $this->aSectionsets, // 2nd parameter |
|
279 | 279 | ) |
280 | 280 | ); |
281 | 281 |
@@ -43,7 +43,7 @@ discard block |
||
43 | 43 | /** |
44 | 44 | * Stores the section definition. |
45 | 45 | */ |
46 | - public $aSection = array(); |
|
46 | + public $aSection = array(); |
|
47 | 47 | |
48 | 48 | /** |
49 | 49 | * Indicates the sub section index. |
@@ -91,8 +91,8 @@ discard block |
||
91 | 91 | |
92 | 92 | $_aSection[ '_is_collapsible' ] = $_aSection[ 'collapsible' ] && 'section' === $_aSection[ 'collapsible' ][ 'container' ]; |
93 | 93 | |
94 | - $_aSection[ '_tag_id' ] = 'section-' . $_aSection[ 'section_id' ] . '__' . $this->iIndex; |
|
95 | - $_aSection[ '_tag_id_model' ] = 'section-' . $_aSection[ 'section_id' ] . '__' . '___i___'; |
|
94 | + $_aSection[ '_tag_id' ] = 'section-'.$_aSection[ 'section_id' ].'__'.$this->iIndex; |
|
95 | + $_aSection[ '_tag_id_model' ] = 'section-'.$_aSection[ 'section_id' ].'__'.'___i___'; |
|
96 | 96 | |
97 | 97 | return $_aSection; |
98 | 98 |
@@ -236,7 +236,7 @@ |
||
236 | 236 | */ |
237 | 237 | private function _shouldShowCaptionTitle( $aSectionset, $iSectionIndex ) { |
238 | 238 | |
239 | - if ( ! $aSectionset[ 'title' ] ){ |
|
239 | + if ( ! $aSectionset[ 'title' ] ) { |
|
240 | 240 | return false; |
241 | 241 | } |
242 | 242 | if ( $aSectionset[ 'collapsible' ] ) { |
@@ -80,7 +80,7 @@ discard block |
||
80 | 80 | */ |
81 | 81 | private function _getCaption( array $aSectionset, $iSectionIndex, $aFieldsets, $aFieldErrors, $aFieldTypeDefinitions, $aCallbacks, $oMsg ) { |
82 | 82 | |
83 | - if ( ! $aSectionset[ 'description' ] && ! $aSectionset[ 'title' ] ) { |
|
83 | + if ( !$aSectionset[ 'description' ] && !$aSectionset[ 'title' ] ) { |
|
84 | 84 | return "<caption class='admin-page-framework-section-caption' style='display:none;'></caption>"; |
85 | 85 | } |
86 | 86 | |
@@ -103,7 +103,7 @@ discard block |
||
103 | 103 | 'collapsible' => $_abCollapsible, |
104 | 104 | 'container_type' => 'section', // section or sections |
105 | 105 | |
106 | - 'sectionset' => $aSectionset, // 3.7.0+ for tooltip |
|
106 | + 'sectionset' => $aSectionset, // 3.7.0+ for tooltip |
|
107 | 107 | ), |
108 | 108 | $aFieldsets, |
109 | 109 | $this->aSavedData, |
@@ -113,15 +113,15 @@ discard block |
||
113 | 113 | $aCallbacks // field output element callables. |
114 | 114 | ); |
115 | 115 | |
116 | - $_bShowTitle = empty( $_abCollapsible ) && ! $aSectionset[ 'section_tab_slug' ]; |
|
116 | + $_bShowTitle = empty( $_abCollapsible ) && !$aSectionset[ 'section_tab_slug' ]; |
|
117 | 117 | return |
118 | - "<caption " . $this->getAttributes( |
|
118 | + "<caption ".$this->getAttributes( |
|
119 | 119 | array( |
120 | 120 | 'class' => 'admin-page-framework-section-caption', |
121 | 121 | // data-section_tab is referred by the repeater script to hide/show the title and the description |
122 | 122 | 'data-section_tab' => $aSectionset[ 'section_tab_slug' ], |
123 | 123 | ) |
124 | - ) . ">" |
|
124 | + ).">" |
|
125 | 125 | . $_oCollapsibleSectionTitle->get() |
126 | 126 | . $this->getAOrB( |
127 | 127 | $_bShowTitle, |
@@ -175,7 +175,7 @@ discard block |
||
175 | 175 | 'tag' => 'h3', |
176 | 176 | 'section_index' => $iSectionIndex, |
177 | 177 | |
178 | - 'sectionset' => $aSectionset, // 3.7.0+ for tooltip |
|
178 | + 'sectionset' => $aSectionset, // 3.7.0+ for tooltip |
|
179 | 179 | ), |
180 | 180 | $aFieldsets, |
181 | 181 | $this->aSavedData, |
@@ -184,7 +184,7 @@ discard block |
||
184 | 184 | $this->oMsg, |
185 | 185 | $this->aCallbacks // field output element callables. |
186 | 186 | ); |
187 | - return "<div " . $this->getAttributes( |
|
187 | + return "<div ".$this->getAttributes( |
|
188 | 188 | array( |
189 | 189 | 'class' => 'admin-page-framework-section-title', |
190 | 190 | 'style' => $this->getAOrB( |
@@ -193,7 +193,7 @@ discard block |
||
193 | 193 | 'display: none;' |
194 | 194 | ), |
195 | 195 | ) |
196 | - ). ">" |
|
196 | + ).">" |
|
197 | 197 | . $_oSectionTitle->get() |
198 | 198 | . "</div>"; |
199 | 199 | } |
@@ -209,7 +209,7 @@ discard block |
||
209 | 209 | if ( $aSectionset[ 'collapsible' ] ) { |
210 | 210 | return ''; |
211 | 211 | } |
212 | - if ( ! is_callable( $hfSectionCallback ) ) { |
|
212 | + if ( !is_callable( $hfSectionCallback ) ) { |
|
213 | 213 | return ''; |
214 | 214 | } |
215 | 215 | |
@@ -241,7 +241,7 @@ discard block |
||
241 | 241 | */ |
242 | 242 | private function _shouldShowCaptionTitle( $aSectionset, $iSectionIndex ) { |
243 | 243 | |
244 | - if ( ! $aSectionset[ 'title' ] ){ |
|
244 | + if ( !$aSectionset[ 'title' ] ) { |
|
245 | 245 | return false; |
246 | 246 | } |
247 | 247 | if ( $aSectionset[ 'collapsible' ] ) { |
@@ -65,7 +65,7 @@ |
||
65 | 65 | private function _getFieldError( $aErrors, $aSectionPath, $aFieldPath, $sHeadingMessage ) { |
66 | 66 | |
67 | 67 | // If this field has a section and the error element is set |
68 | - $_aErrorPath = array_merge( $aSectionPath, $aFieldPath ); |
|
68 | + $_aErrorPath = array_merge( $aSectionPath, $aFieldPath ); |
|
69 | 69 | if ( $this->_hasFieldError( $aErrors, $_aErrorPath ) ) { |
70 | 70 | return "<span class='field-error'>* " |
71 | 71 | . $sHeadingMessage |
@@ -75,6 +75,7 @@ |
||
75 | 75 | * |
76 | 76 | * @since 3.1.0 |
77 | 77 | * @since 3.7.0 Moved from `AdminPageFramework_Form_View___Fieldset`. |
78 | + * @param string $sHeadingMessage |
|
78 | 79 | * @return string The error string message. An empty value if not found. |
79 | 80 | */ |
80 | 81 | private function _getFieldError( $aErrors, $aSectionPath, $aFieldPath, $sHeadingMessage ) { |
@@ -17,7 +17,7 @@ discard block |
||
17 | 17 | */ |
18 | 18 | class AdminPageFramework_Form_View___Attribute_SectionTableBody extends AdminPageFramework_Form_View___Attribute_Base { |
19 | 19 | |
20 | - public $sContext = 'section_table_content'; |
|
20 | + public $sContext = 'section_table_content'; |
|
21 | 21 | |
22 | 22 | /** |
23 | 23 | * Returns an attribute array. |
@@ -35,10 +35,10 @@ discard block |
||
35 | 35 | return array( |
36 | 36 | 'class' => $this->getAOrB( |
37 | 37 | $this->aArguments[ '_is_collapsible' ], |
38 | - 'admin-page-framework-collapsible-section-content' . ' ' |
|
39 | - . 'admin-page-framework-collapsible-content' . ' ' |
|
40 | - . 'accordion-section-content' . ' ' |
|
41 | - . 'admin-page-framework-collapsible-content-type-' . $_sCollapsibleType, |
|
38 | + 'admin-page-framework-collapsible-section-content'.' ' |
|
39 | + . 'admin-page-framework-collapsible-content'.' ' |
|
40 | + . 'accordion-section-content'.' ' |
|
41 | + . 'admin-page-framework-collapsible-content-type-'.$_sCollapsibleType, |
|
42 | 42 | null |
43 | 43 | ), |
44 | 44 | ); |
@@ -23,11 +23,11 @@ |
||
23 | 23 | */ |
24 | 24 | protected function _get() { |
25 | 25 | |
26 | - $_sSpinnerPath = $this->getWPAdminDirPath() . '/images/wpspin_light-2x.gif'; |
|
27 | - if ( ! file_exists( $_sSpinnerPath ) ) { |
|
26 | + $_sSpinnerPath = $this->getWPAdminDirPath().'/images/wpspin_light-2x.gif'; |
|
27 | + if ( !file_exists( $_sSpinnerPath ) ) { |
|
28 | 28 | return ''; |
29 | 29 | } |
30 | - $_sSpinnerURL = esc_url( admin_url( '/images/wpspin_light-2x.gif' ) ); |
|
30 | + $_sSpinnerURL = esc_url( admin_url( '/images/wpspin_light-2x.gif' ) ); |
|
31 | 31 | return <<<CSSRULES |
32 | 32 | .admin-page-framework-form-loading { |
33 | 33 | position: absolute; |
@@ -50,8 +50,8 @@ |
||
50 | 50 | } |
51 | 51 | |
52 | 52 | $_aOutput = array(); |
53 | - foreach( $this->aDescriptions as $_sDescription ) { |
|
54 | - $_aOutput[] = "<p class='" . esc_attr( $this->sClassAttribute ) . "'>" |
|
53 | + foreach ( $this->aDescriptions as $_sDescription ) { |
|
54 | + $_aOutput[ ] = "<p class='".esc_attr( $this->sClassAttribute )."'>" |
|
55 | 55 | . "<span class='description'>" |
56 | 56 | . $_sDescription |
57 | 57 | . "</span>" |
@@ -16,7 +16,7 @@ |
||
16 | 16 | * @internal |
17 | 17 | * @extends AdminPageFramework_FrameworkUtility |
18 | 18 | */ |
19 | -class AdminPageFramework_Form_View___Description extends AdminPageFramework_FrameworkUtility { |
|
19 | +class AdminPageFramework_Form_View___Description extends AdminPageFramework_FrameworkUtility { |
|
20 | 20 | |
21 | 21 | public $aDescriptions = array(); |
22 | 22 |