[zi-cvs] packages/com.zzoss.zic dev_application_import.php,1.7,1.8

Sandro Zic <[email protected]> Sun, 04 Apr 2004 09:45:39 +0000
Newsgroups gmane.comp.php.zzoss.installer.cvs
Message-ID <[email protected]>
Update of /cvsroot/zzossinstaller/packages/com.zzoss.zic
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24649/com.zzoss.zic

Modified Files:
	dev_application_import.php 
Log Message:
check if distri and app XML in data path exists if no others are provided

Index: dev_application_import.php
===================================================================
RCS file: /cvsroot/zzossinstaller/packages/com.zzoss.zic/dev_application_import.php,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** dev_application_import.php	4 Apr 2004 08:53:38 -0000	1.7
--- dev_application_import.php	4 Apr 2004 09:45:36 -0000	1.8
***************
*** 120,123 ****
--- 120,142 ----
  <?php
  if(isset($_REQUEST['distribution']) && isset($_REQUEST['application'])){
+     
+     // check if we need to display the descriptors from the data directory
+     if(
+         !isset($_REQUEST['ZI_VALUES']['path_distribution_xml']) ||
+         !strlen($_REQUEST['ZI_VALUES']['path_distribution_xml'])){
+         $distri_xml = $zi_registry->getDistributionPath().'distribution.xml';
+         if(file_exists($distri_xml)){
+             $_REQUEST['ZI_VALUES']['path_distribution_xml'] = $distri_xml;
+         }
+     }
+     if(
+         !isset($_REQUEST['ZI_VALUES']['path_application_xml']) ||
+         !strlen($_REQUEST['ZI_VALUES']['path_application_xml'])){
+         $app_xml = $zi_registry->getApplicationPath().'application.xml';
+         if(file_exists($app_xml)){
+             $_REQUEST['ZI_VALUES']['path_application_xml'] = $app_xml;
+         }
+     }
+     
      $application = $zi_registry->getApplication();
      ?>



-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click