No, this is not an approved way to remove nuisance wildlife. They would need to trap the groundhogs. Putting out liquid is just going to accidentally poison opossums, cats, and dogs.
No matter which technique is used to remove the groundhogs, they need a permit from the Illinois Department of Natural Resources. They can contact Jeff Horn, IDNR district wildlife biologist in Stephenson County for the permit (it's free) and for advice about humane ways to remove wildlife that are causing property damage. Jeff's number is (815) 273-2771.
If that does not work, and if non-target wildlife continue to be taken, then a call to a Conservation Police Officer may be in order. Their number is 309/788-0418.