Sol-gel synthesis of organic/inorganic nanobuilding blocks for the preparation of hybrid materials for photonic applications