The original way of choosing the senators, as prescribed by the constitution of 1787, was that the Senators were chosen by the State Legislatures. This was described in Article One, Section 3 of the Constitution.
This was then changed by the Seventeenth Amendmend passed in 1913.