CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Intermediate:
Reruning script from within a subroutine

 



wjbell
stranger

Jan 12, 2003, 9:04 PM

Post #1 of 2 (613 views)
Reruning script from within a subroutine Can't Post

I have a messageboard script that I need to jump from a sub to the begining of the script to display the index again. The index (main page) is displayed by calling the script with no args. (foo.com/bbs.cgi) What I'm doing is setting cookies in a subroutine and then want to automatically forward to the messageboard index again. How can I call the script from withing the script? The part of the script that prints the main page isn't contained in a subroutine so I can't do a &index; to jump to a sub. Right now I just print out a page with a meta refresh pointing to the index page. Any ideas how I can do this? TIA


davorg
Thaumaturge / Moderator

Jan 12, 2003, 11:23 PM

Post #2 of 2 (611 views)
Re: [wjbell] Reruning script from within a subroutine [In reply to] Can't Post

The best way would probably be to create another subroutine that displays the main index and then to call that.

--
Dave Cross, Perl Hacker, Trainer and Writer
http://www.dave.org.uk/
Get more help at Perl Monks


(This post was edited by davorg on Jan 12, 2003, 11:24 PM)

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives