[ 'wage_base' => 7000, 'new_employer_rate' => 2.0 ], ]; function _getStateTaxPayable() { //Arizona is a percent of federal tax rate. //However after 01-Jul-10 it changed to a straight percent of gross. $annual_income = $this->getAnnualTaxableIncome(); $rate = (float)$this->getUserValue1(); Debug::text( 'Raw Rate: ' . $rate, __FILE__, __LINE__, __METHOD__, 10 ); //Because of the change from a percent of federal rate to a gross rate, //add some checks so if an employee's amount isn't changed we default to the closest rate. if ( $rate >= 39.5 ) { $rate = 5.1; } else if ( $rate >= 33.1 ) { $rate = 4.2; } else if ( $rate >= 26.7 ) { $rate = 3.6; } else if ( $rate >= 24.5 ) { $rate = 2.7; } else if ( $rate >= 20.3 ) { $rate = 1.8; } else if ( $rate >= 10.7 ) { $rate = 1.3; } Debug::text( ' Adjusted Rate: ' . $rate, __FILE__, __LINE__, __METHOD__, 10 ); $retval = bcmul( $annual_income, bcdiv( $rate, 100 ) ); if ( $retval < 0 ) { $retval = 0; } Debug::text( 'State Annual Tax Payable: ' . $retval, __FILE__, __LINE__, __METHOD__, 10 ); return $retval; } } ?>