#!/usr/bin/perl ## Program name: pvconv.cgi version:1.71d ## ## Converts pre-1.70d podvars.pm files to 1.70d format ## Richard A. Chiswell. ## Released: 17 Feb 2000 ## http://www.beebware.com/ ## ## Copyright 2000 by Richard Chiswell ## Free to distribute, but you cannot charge for this work or any ## derivatives thereof. No warranties on this program are made or implied. # Place the path of your old podvars.pm here (add full path before the # filename if you're having troubles). Call the program from your # browser and save the resulting file. This will make the new version # of the podvars.pm file suitable for use with 1.70d. require "podvars.pm"; print "Content-Type:text/html\n\n"; $data=&build_page_data; print "Skip to view source version
"; print "HTML Formatted podvars.pm
This is ideal"; print "for Windows users who can cut'n'paste:
"; print ""; print "

"; print "Source code version
"; print "And now for everybody else, just rip the code out"; print "of the HTML source of this page, everything between the"; print "<!-- CODE SEGMENT --> sections:




\n\n"; print "\n\n"; print $data; print "
\n\n"; exit 0; sub build_page_data { if (!(defined($faqtable))) {$faqtable="white";} if (!(defined($faqtext))) {$faqtext="red";} if (!(defined($addtable))) {$addtable="#ffff00";} if ($logging==0) { $loggingline="#\$pod_logging = \"$logdir/$logfile\""; } else { print "\$pod_logging = \"$logdir/$logfile\""; } if (defined($whichamazon)) { $amazonline="\$pod_whichamazon = \"$whichamazon\";"; } else { $amazonline="#\$pod_whichamazon = \"\";"; } $text_return="return"; $text_qqtilde="qq~"; $text_tilde="~"; $data=qq~ ############################################################################# ## Configuration area ## change these variables for your site. ## 'Commented out' variables are prefixed by a single # ## Remarks/comments are prefixed by ## ############################################################################# sub pod_init { # This file is compatible with the following minimum version of POD \$pod_podvars=1.70; ############################################################################# ### Script configuration ############################################################################# ## Name of your script. For example, 'pod.cgi' or 'dir' \$pod_progname="$progname"; ## URL path to your script (ie /cgi-bin/pod/) \$pod_urlpath="$cgi_url"; ## Full path and script name ## Replace with #$pod_fullpath="$ENV{'SCRIPT_NAME'}"; ## to increase portability of the script. If you do this, you can ## ignore the settings of the two above variables. \$pod_fullpath="\$pod_urlpath\$pod_progname"; ## To log searches, insert the full path and filename of your logfile ## into pod_logging. Comment it out for no logging (default) $loggingline ## Where your header.html and footer.html files are located \$pod_templatedir = "$templatedir"; ## This variable changes the operation of the script drastically. ## If pod_usequery=1 then POD will expect to be called in the format ## of .../pod.cgi?dir=/Arts/Entertainment ## If pod_usequery=0 then POD will expect to be called in the format ## of .../pod.cgi/Arts/Entertainment \$pod_usequery=1; ## Only allow categories with the following prefixes. ## For example, 'Computers/Internet' will only allow categories with ## the prefix Computers/Internet to be listed. ## Leave commented out if you want the entire directory to be usable ## not used ATM # \@prefixes=''; ## If you have a HTTP proxy you wish the script to use, please define ## it here. If pod_proxy is undefined then the script doesn't use a proxy. #\$pod_proxy="http://proxy.sn.no:8001/"; ## To be 'cache friendly', the script now returns an Expires: header. ## Configure the amount of time you wish the returned HTML to be valid for ## here. ## Format: [+[lengthoftime][s|m|h|d|y]]|[now] ## E.g. +30s will expire after 30 seconds, +1d will expire after 1 day, ## +1000y will expiry in 1000 years! now will expire immediately #\$pod_expire_in="now"; # expire now \$pod_expire_in="+10m"; # expire in ten minutes ## To help identify your script to the Dmoz.org server, you can configure ## it to have a set User-Agent. You should have really no need to change ## this, but it's there if you need it. \$pod_useragent="POD_ODP/\$pod_version"; ## If you are having trouble with POD, set pod_debug to '1'. This will ## cause a lot of messages to appear when the script is run, but should ## help locate any problems. #\$pod_debug="1"; \$pod_debug="0"; ## If you know you have mod_perl installed on your server, uncomment ## this line to set pod_modperl to 1 and it will help speed up execution ## of the script. ## untested as of version 1.70d # \$pod_modperl="1"; ############################################################################# ### Style configuration ############################################################################# ## Where your personal homepage is (normally the root of your domain) \$pod_myhome = "$myhome"; ## Name of your Personal Open Directory \$pod_name = "$pod_name"; ## A shortened version of your POD (less than 10 characters ideally) \$pod_shortname = "MyPOD"; ## The default font face (not used ATM) #\$pod_cgi_fontface = "$fontface"; ## The default font size (not used ATM) #\$pod_cgi_fontsize = "$fontsize"; ## Change the title style \$pod_titlestyle = 'face="arial,helvetica" size="+1" color="#000088"'; ## Front header title \$pod_frontheader="\$pod_name"; ## Include your own cool icon tag here. If you don't want any cool ## designation apart from 'bolding', then set $pod_cgi_coolicon=''; ## If you want to keep the original icon, don't set this tag. #\$pod_cgi_coolicon='[Cool]  '; ## If you wish to delete the little Mozzies/Lizards from the bottom ## right of the page, set $pod_killmozzie to text/image you wish to ## replace Mozzie. Set to '' for nothing to appear, or just don't set ## the tag to keep mozzie. #\$pod_killmozzie='This is a Mozzie free site'; ## If internationalization isn't working by default in your POD ## then uncomment this setting: #\$pod_international=1; ## If you want the 'Editor login' box removed or replaced, enter the ## text below. Set to '' for nothing to appear, or just don't set the tag ## to keep the login box (which will redirect the user to the Dmoz server) ## not used ATM #\$pod_boxes_editorlogin=""; ## If you want the 'Link' box removed or replaced, enter the ## text below. Set to '' for nothing to appear, or just don't set the tag ## to keep the default link box ## not used ATM #\$pod_boxes_linklogin=""; ## Do you want the 'Become an editor' graphic or would you prefer the ## 'Standard attribution' as set out in the licence. Set the variable ## for the standard attribution - keep it commented out for the ## default operation. ## not used ATM #\$pod_boxes_attribution=""; ############################################################################# ### Table configuation ############################################################################# # pod_lighttable is the color setting of the top bar of the # two title bars at the top of the page. \$pod_lighttable = "$lighttable"; # pod_lighttableb is the color setting of the bottom bar of the # two title bars at the top of the page. \$pod_lighttableb = "$lighttableb"; # not used ATM #\$pod_darktable = "$darktable"; # pod_medtable is the color setting of the Amazon/Maxcomm bar # only applicable if you use the Amazon system \$pod_medtable = "$medtable"; # not used ATM #\$pod_tabletext = "$tabletext"; # pod_editortable is the background color of the bar which includes the # names of the category editors. It is also the color of the # description/faq section box \$pod_editortable = "#CCCCFF"; # pod_faqtable is the background color of the FAQ pages \$pod_faqtable="$faqtable"; # pod_faqtext is the color of the text on the FAQ pages \$pod_faqtext="$faqtext"; # pod_addtable is the background color of the table on the Add A Page # pages \$pod_addtable="$addtable"; ############################################################################# ### Amazon configuration ### Amazon automated book-linking requires use of the MaxComm script ### If you do not have access to this script, leave these variables alone ############################################################################# ## Which Amazon.Com link to use - comment out not to use auto book linking $amazonline ## Your Amazon associates ID \$pod_amazon_ID = "$amazon_ID"; ## Complete URL to your MaxComm script \$pod_maxcomm = "$maxcomm"; ## Name of your Amazon link (ie Amazon.com, Amazon.co.uk, etc) \$pod_bookstorename = "$bookstorename"; ## If the links to Amazon are missing the last character, uncomment ## out the below line. #\$pod_amazon_missing=1; } ############################################################################# ### Header and footer configuation ### ### Feel free to change this functions as appropriate to your uses. ### ### Please please keep the attribution to the authors in the code as it ### ### is a condition of your use of this software. ### ############################################################################# sub pod_page_header{ my \$pod_ph_text; my \$pod_header; \$pod_ph_text="
"; open (READIT, "\$pod_templatedir/header.html"); read (READIT, \$pod_header, 20000,0); close (READIT); return \$pod_ph_text.\$pod_header; } sub pod_page_footer{ my \$pod_pf_text; my \$pod_footer; open (READIT,"\$pod_templatedir/footer.html"); read (READIT, \$pod_footer, 20000,0); close (READIT); # Change the footer to what you'd like it to read, but we would appreciate # credit for the script *somewhere* on your Web site. # Not including this credit is a breach of the licencing terms of the Personal # Open Directory and action may be taken against you if attribution is not given. \$pod_pf_text=$text_qqtilde

Personal Open Directory is open source software by J. Grohol, R. Chiswell & R. Faulds Copyright 1999-2000. \$pod_version. All rights reserved.

$text_tilde; $text_return \$pod_page_footer.\$pod_pf_text; } ############################################################################# ### End of configuration system ############################################################################# ;1 ~; }