Role of pH in the green synthesis of silver nanoparticles