Green synthesis of TiO2 and its photocatalytic activity