########## perl modules ############
use TeamSite::Config;
use OLG::tpl_utils;
########## perl modules ############
my $iwhome = TeamSite::Config::iwgethome();
my $iwmount = TeamSite::Config::iwgetmount();
($iwcfg) = "$iwhome/bin/iwconfig";
my $dcrpath = iwpt_get_dcr_name();
$dcrpath =~ s#\.iwmnt#iwmnt#g;
my $dcr_name = iwpt_get_dcr_name("basename");
my $prefix = getLOB($dcrpath);
my $prefDir = uc($prefix);
my $templatename = getDataType($dcrpath);
my $contentname = $dcr_name;
$dcrpath =~ m/\/([^\/]+)\/data/;
my $ofile = "generated/component/".$templatename."/".$prefix."_".$cont
+entname.".xml";
(my $hostname = `$iwcfg iwwebd host`) =~ s#\n$##;
my $edit_path = "http://".$hostname."/iw-cc/edit?vpath=".$dcrpath;
$edit_path =~ s#$iwmount##g;
(my $bellca = `$iwcfg iwwebd bellca`) =~ s#\n$##;
my $endtag = "]"."]>";
my $cdata = "<!"."[CDATA[";
############ Build the initial media lists
my @media_ids = ();
my $filelist = 'generated/filelist/';
my $media_file = $filelist.$prefix."_".$contentname."_images.txt";
my @matches = getImageList( iwpt_get_dcr_name() );
############ Build the region array
my @region_array = ("default");
my $item_region = join(',',@region_array);
############
In this code, "use CGI" is not used. So how will the progrma understand the environment variables ?
variable is defined as ($iwcfg) , why do we need bracket around variable name, what does it do ? There are my variables declred with brackets as well. So what does it do when there are brackets around variable name ?
Whats the point in declaring my variables at the top level in program. Since my variables are used for localalization of the sciope, why is it at the top ?
Whats the point in declaring "$dcrpath" and "my $dcrpath" at the same level ? Are they different from each other ?
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.