Conditions | 1 |
Paths | 1 |
Total Lines | 16 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 2 |
Changes | 0 |
1 | <?php |
||
21 | public static function get_param_var( $param_var ) { |
||
22 | // Find and replace |
||
23 | // @link https://github.com/woothemes/woocommerce/blob/v2.0.19/classes/emails/class-wc-email-new-order.php |
||
24 | $find = array(); |
||
25 | $replace = array(); |
||
26 | |||
27 | $find[] = '{site_url}'; |
||
28 | $replace[] = site_url(); |
||
29 | |||
30 | $find[] = '{home_url}'; |
||
31 | $replace[] = home_url(); |
||
32 | |||
33 | // Parameter Variable |
||
34 | $param_var = str_replace( $find, $replace, $param_var ); |
||
35 | |||
36 | return $param_var; |
||
37 | } |
||
39 |