http://qs321.pair.com?node_id=867852


in reply to Re^3: How to eval an array element in regex's substitution
in thread How to eval an array element in regex's substitution

yes, i think in this case regex is too much, as it's only a fixed parameter substitution. regex can become easily overused. And when you use a regex you introduce pitfalls. I always go for simple substitution or other string operations first. substr and index functions come in very handy.
regards testing smtp...just in case this is not common knowledge, you can telnet to port 25 on your smtp server and issue commands to send emails, just as a module would. it's great for testing the viability of a particular idea/method...and then you can see if a module can do it or needs some tweaking. For example, you would see that you can send multiple separate emails during one session/connection to smtp server. Mind you, setting up a massively parallel process to send emails isn't going to change much on the smtp server end, which serves a FIFO queue anyway. And using one connection/send/disconnection per email is useful as a unit of measure that one email send completed. I would argue that unless your program needs hours to complete (the bulk email send) that you should just send them one by one. it's also good not to hog/thrash the mail server.
anyway, hope your project is progressing well.
the hardest line to type correctly is: stty erase ^H