Ionic Liquid Mediated Sol-Gel Synthesis in the Presence of Water or Formic Acid: Which Synthesis for Which Material?