Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Background script

Posted on 1997-03-21
1
206 Views
Last Modified: 2013-12-25
How can I run a CGI script in the background.  Meaning not have a page displayed. I want to send the script some data,
have it do something and depending on the result, bring up one of two pages.  

Right now the only way I can do it is have the form execute the script. The script does it's thing and then writes a page saying it was successful or not.  I have a meta tag in the script which executes the next page after 1 second.  I would like to skip the message in between part.  

Hope I have explained this well.
0
Comment
Question by:wspoulin
1 Comment
 
LVL 4

Accepted Solution

by:
furu earned 100 total points
ID: 1827774
What you need to do is output
Location: http://www.domain.com/file.html
as the header. That is instead of
Content-Type: text/html

An example:
---------------------------
#!user/bin/perl  
if (condition 1) {
 print "Location: http://www.domain.com/file1.html\n\n";
}
elsif (condition 2) {
 print "Location: http://www.domain.com/file2.html\n\n";
}
else {
 print "Location: http://www.domain.com/error.html\n\n";
}
------------------------------------------------------------
 HTH
 

0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It is becoming increasingly popular to have a front-page slider on a web site. Nearly every TV website,  magazine or online news has one on their site, and even some e-commerce sites have one. Today you can use sliders with Joomla, WordPress or …
I hope you'll find this tutorial useful and interesting. So let's try to extend Tcl with a new package.  For anyone more deeply interested please check out the book "Practical Programming in Tcl and Tk". It's really one of the best written books abo…
Learn the basics of modules and packages in Python. Every Python file is a module, ending in the suffix: .py: Modules are a collection of functions and variables.: Packages are a collection of modules.: Module functions and variables are accessed us…
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question