Hm, it's not clear to me what exactly you're trying to do, and you don't provide too much specific, so there's only so much I can help with.
Two things I might suggest:
- Since your first question is not a perl question, but rather an apache (webserver) question, I'd suggest looking on google. I did a search for 'apache cgi howto', and came up with this. (the short answer is you need to set a ScriptAlias in httpd.conf; see the link for more info).
- Check out the perlmonks Web Programming tutorial.