Internally Referenced Ammonia Sensor Based on an Electrochemically Prepared Porous SiO2 Photonic Crystal