Polygamy was against the law in Illinois. An Illinois state law was enacted February 12, 1833:
"Bigamy consists in the having of two wives or two husbands at one and the same time, knowing that the former husband or wife is still alive. If any person or persons within the State, being married, or who shall hereafter marry, do at any time marry any person or persons, the former husband or wife being alive, the person so offended shall, on conviction thereof, be punished by a fine, not exceeding one thousand dollars, and imprisoned in the penitentiary, not exceeding two years." (Revised Laws of Illinois, Vandalia: Greiner & Sherman, 1833, pg. 198-199).
Polygamy was also against the Doctrine and Covenants
The first edition of the Doctrine and Covenants (1835) included a section on LDS Marriages:
"Inasmuch as this Church of Christ has been reproached with the crime of fornication and polygamy, we declare that we believe that one man should have one wife, and one woman but one husband, except in the case of death, when either is at liberty to marry again." (History of the Church, vol. 2, pg. 247, it is interesting to note that this section in the D&C was in every single edition until 1876 when the Doctrine and Covenants first included D&C 132).
For more references on the practice of polygamy at the same time the LDS Church publicly denied it please visit: http://www.mindspring.com/~engineer_my_dna/mormon/denpract.htm