New Orleans Stock Footage



#!/usr/bin/perl ############################################################################## # Random Text Version 1.0 # # Copyright 1996 Matt Wright mattw@worldwidemart.com # # Created 7/13/96 Last Modified 7/13/96 # # Scripts Archive at: http://www.worldwidemart.com/scripts/ # ############################################################################## # COPYRIGHT NOTICE # # Copyright 1996 Matthew M. Wright All Rights Reserved. # # # # Random Text may be used and modified free of charge by anyone so long as # # this copyright notice and the comments above remain intact. By using this # # code you agree to indemnify Matthew M. Wright from any liability that # # might arise from it's use. # # # # Selling the code for this program without prior written consent is # # expressly forbidden. In other words, please ask first before you try and # # make money off of my program. # # # # Obtain permission before redistributing this software over the Internet or # # in any other medium. In all cases copyright and header must remain intact # ############################################################################## # Define Variables # # This is the file in which all of your random text phrases are stored. # $random_file = "/home/customer/www/nolastockfootage.com/public_html/featured.txt"; # The delimiter specifies how each phrase is distinguished from another. For# # instance, the common fortune file (a Unix program) is delimited by a new # # line followed by two % signs on the next line and then a new line. This is# # a pretty good format and you can read more about it in the README file. # $delimiter = "\n\%\%\n"; # Done # ############################################################################## # Open the file containing phrases and read it in. open(FILE,"$random_file") || &error('open->random_file',$random_file); @FILE = ; close(FILE); # Join these lines from the file into one large string. $phrases = join('',@FILE); # Now split the large string according to the $delimiter. @phrases = split(/$delimiter/,$phrases); # Invoke srand; with a seed of the time and pid. If you are on a machine # which doesn't put the pid into $$ (ie. Macintosh, Win NT, etc...), change # this line to: srand(time ^ 22/7); srand(time ^ $$); # Now pluck our random phrase out of the @phrases array! But wait! This # only returns a number. $phrase = rand(@phrases); # Print out the Content-type header, so the browser knows what's going on. print "Content-type: text/html\n\n"; # Change this number into the text we want to return and print it! print $phrases[$phrase]; # All Done! exit; # Was there an error? If so, let's report that sucker so it can get fixed! sub error { ($error,$file) = @_; print <<"END_ERROR"; Content-type: text/html ERROR: Random File Unopenable

ERROR: Random File Unopenable

The random file, as specified in the \$random_file perl variable was unopenable.

END_ERROR if (-e $random_file) { print "The file was found on your system, so make sure that it is\n"; print "readable by the web server. This means you will need to\n"; print "execute the following command:

\n";
        print "    chmod 744 $random_file\n";
        print "
\n"; } else { print "The file was not found on your file system. This means that\n"; print "it has either not been created or the path you have specified\n"; print "in \$trrandom_file is incorrect.\n"; } exit; }


WHAT IS THIS PLACE?

NOLAStockFootage.com is a growing, independently-produced collection of royalty-free HD stock footage shot in and around the city of New Orleans, Louisiana.

Clips from this website may be licensed through the Pond5.com stock footage agency* and used in a wide variety of projects.

» License Agreement

ARE YOU A POND5 CONTRIBUTOR?

If you are an artist on Pond5 and would like a portfolio site like this one, visit MyPond5Portfolio.com for details!

  CONTACT

Have a question or special request?
Email:


RELATED SITES

Looking for other cities or topics? Browse through this list of other websites devoted to providing high-quality stock footage clips from other areas of the country.

» Click here to browse ...

CONNECT


A division of OrlowskiDesigns HD Stock Footage.