Fixed the Socket Error bug and subsequent bugs by switching to a parameterized POST in js and views.