| 1 |
<?xml version="1.0"?> |
| 2 |
<ruleset name="DCDC_WordPress"> |
| 3 |
<description>WordPress Coding Standards</description> |
| 4 |
|
| 5 |
<!-- Use WordPress as a base --> |
| 6 |
<rule ref="WordPress"> |
| 7 |
<!-- Allow: while ( have_posts() ) : the_post(); --> |
| 8 |
<exclude name="Squiz.ControlStructures.ControlSignature.NewlineAfterOpenBrace"/> |
| 9 |
|
| 10 |
<!-- Disable overly picky rules --> |
| 11 |
<exclude name="WordPress.WP.CapitalPDangit"/> |
| 12 |
<exclude name="WordPress.PHP.DiscouragedPHPFunctions.serialize_serialize"/> |
| 13 |
<exclude name="WordPress.PHP.DiscouragedPHPFunctions.serialize_unserialize"/> |
| 14 |
|
| 15 |
<!-- Allow function( 'something', array( |
| 16 |
'something', |
| 17 |
) ); --> |
| 18 |
<exclude name="PEAR.Functions.FunctionCallSignature.ContentAfterOpenBracket"/> |
| 19 |
<exclude name="PEAR.Functions.FunctionCallSignature.CloseBracketLine"/> |
| 20 |
<exclude name="PEAR.Functions.FunctionCallSignature.MultipleArguments"/> |
| 21 |
</rule> |
| 22 |
|
| 23 |
<!-- Add custom sanitizing function(s). --> |
| 24 |
<rule ref="WordPress.Security.ValidatedSanitizedInput"> |
| 25 |
<properties> |
| 26 |
<property name="customSanitizingFunctions" type="array"> |
| 27 |
<element value="sanitize_update_auth_users" /> |
| 28 |
</property> |
| 29 |
</properties> |
| 30 |
</rule> |
| 31 |
</ruleset> |
| 32 |
|