QPR carved out just their third win of the Premier League season at Southampton to renew hope of avoiding relegation.