Training, Open Source computer languages
PerlPHPPythonMySQLApache / TomcatTclRubyJavaC and C++LinuxCSS 
Search for:
Home Accessibility Courses Diary The Mouth Forum Resources Site Map About Us Contact
Calling a perl script from another perl script

Posted by pragatid (pragatid), 9 July 2007
Hi,
I am new to Perl programming. Let me explain my requirement over here. I have a Perl script located in /usr/sbin/ say script A and I want to invoke this script via web  after accepting some user inputs.
What I am thinking is , I will write a perl script(script B) which will invoke my script A and I will post my HTML form to script B. I will be using tomcat as a web server.
Please guide me if this is going to work or let me know if there are any suggestions...
I am just doubtful that would script B be able to invoke scrip A which is located in /usr/sbin/ ?

Thanks
-Pragati

Posted by admin (Graham Ellis), 10 July 2007
You can invoke one perl script from within another in exactly the same way that you can invoke any other application (or any operating system command, come to that!).  This may leave the two scripts rather loosley coupled, though, so you may prefer to look at require and include statements.



This page is a thread posted to the opentalk forum at www.opentalk.org.uk and archived here for reference. To jump to the archive index please follow this link.

You can Add a comment or ranking to this page

© WELL HOUSE CONSULTANTS LTD., 2012: Well House Manor • 48 Spa Road • Melksham, Wiltshire • United Kingdom • SN12 7NY
PH: 01144 1225 708225 • FAX: 01144 1225 899360 • EMAIL: info@wellho.net • WEB: http://www.wellho.net • SKYPE: wellho