I need to mirror a website. However, each of the links on the site's webpage is actually a 'submit' to a cgi script that shows up the resulting page. AFAIK wget should fail on this since it needs static links.
What should I use or can do?
If I understand your question, wget should work just fine. Even if the target pages are CGI, wget doesn't care, as long as you're talking about regular links, where the parameters are passed via HTTP GET.
The biggest issue is that your mirror is going to be static, whereas the original site is presumable dynamic. If you want to mirror the site's dynamic behavior, you need to have the CGI source.