• Home
  • Textbooks
  • CGI/Perl (Web Warrior Series)
  • Redirection

CGI/Perl (Web Warrior Series)

Diane Zak

Chapter 12

Redirection - all with Video Answers

Educators


Chapter Questions

Problem 1

You can use a CGI script to redirect a browser to another location.
a. true
b. false

Check back soon!

Problem 2

Which of the following can be used to redirect a browser?
a. a META tag in an HTML document
b. a Location header in a CGI script
c. a Refresh header in a CGI script
d. All of the above.

Check back soon!
01:03

Problem 3

The______header tells the computer to redirect the user’s browser
after a specified number of seconds have elapsed.
a. Content-type
b. Location
c. Redirect
d. Refresh

Vysakh M
Vysakh M
Numerade Educator

Problem 4

Which of the following headers can you use to redirect the user’s browser
immediately?
a. Content-type
b. Location
c. Redirect
d. Both b and c.

Check back soon!

Problem 5

Which of the following headers is used together with the Content-type header?
a. Location
b. Redirect
c. Refresh
d. All of the above.

Check back soon!

Problem 6

Which of the following statements tells the computer to redirect the user’s
browser immediately? a. "Redirect: 0; URL=http://yourservername/public_html/ toms. html \n";
b. print "Refresh: 0; URL=http://yourservername/public_html/ toms. html \n";
c. print "Location: http://yourservername/public_html/ toms. htm $\backslash \mathrm{n} \backslash \mathrm{n}$ ";
d. Both b and c.

Check back soon!

Problem 7

Write a Location header that directs the user's browser to the following URL: http://yourservername/cgi-bin/chap12/pay.cgi.

Check back soon!

Problem 8

Write a Location header that directs the user's browser to the following URL: http://yourservername/public_html/chap12/harper.html.

Check back soon!

Problem 9

Write a Refresh header that tells the computer to wait five seconds before redirecting the browser to the following URL: http://yourservername/cgi-bin/ chap 12/pay.cgi.

Check back soon!

Problem 10

Write a Refresh header that tells the computer to wait 10 seconds before redirecting the browser to the following URL: http://yourservername/public_html/ chap 12/harper.html.

Check back soon!