I believe I answered this question on another forum but since you have provided information here that was not in the other post I'll do so again.
As I indicated on the other board, terming while on STD is not, per se, illegal. Disability benefits provide NO job protection whatsoever. What provides job protection is FMLA, which may or may not be running concurrently with the disability benefits.
On the other board you gave no indication of how long you had been out. Five weeks is not long enough for FMLA to have expired, IF FMLA APPLIES and IF THERE HAS BEEN NO PREVIOUS FMLA WITHIN THE LAST 12 MONTHS. However, that does not necessarily make the termination illegal. We need to determine first, if FMLA even applies, and second, whether or not you had used FMLA previously.
If you can answer the following questions, we can take the next step:
1.) How long have you worked for this employer?
2.) How many employees does the employer have within 75 miles of your location? (If exact number is unknown, state over or under 50.)
3.) In the 12 months immediately preceding your leave, had you worked a minimum of 1,250 hours?
4.) In the 12 months immediately preceding your leave, how much, if any, other time had you missed for medical reasons?
5.) What state are you in? (Some states have extended benefits.)