Melting of solvents nanoconfined by polymers and networks