Changeset 187

Show
Ignore:
Timestamp:
04/16/08 13:21:16
Author:
dan
Message:

--

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • scout/trunk/cdl_0master.pl

    r182 r187  
    191191if ($format_category_value eq 'fixed-point') { 
    192192  #DWR 4/7/2008 
    193   # ADded parameters $FileCreationOption and $strObsKMLFilePath. 
    194   fixed_point($this_station_id_top_ts, $FileCreationOption, $strObsKMLFilePath ); 
     193  #Check to see if the institution specific directory exists. 
     194  my $strObsKMLDir = "$strObsKMLFilePath/$institution_code_value"; 
     195  if( ( -d "$strObsKMLFilePath/$institution_code_value" ) == 0 ) 
     196  { 
     197    if( mkdir( "$strObsKMLFilePath/$institution_code_value", 0777 ) == 0 ) 
     198    { 
     199      print( "ERROR::Unable to create directory: $strObsKMLFilePath/$institution_code_value.\n" ); 
     200      $strObsKMLDir = $strObsKMLFilePath; 
     201    } 
     202    else 
     203    { 
     204      $strObsKMLDir = "$strObsKMLFilePath/$institution_code_value"; 
     205      print( "Created directory: $strObsKMLDir\n" ); 
     206    } 
     207  }  
     208  # Added parameters $FileCreationOption and $strObsKMLFilePath. 
     209  fixed_point($this_station_id_top_ts, $FileCreationOption, $strObsKMLDir ); 
    195210} 
    196211elsif ($format_category_value eq 'moving-point-2D') {