Ignore:
Timestamp:
Apr 7, 2010, 10:41:03 PM (15 years ago)
Author:
Pieter Naber
Message:

Code van David om te schrijven naar een bestand

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/inc/KMLFile.class.php

    r7692 r7700  
    9090        }
    9191
     92        /*
     93         * Function: write
     94         * Parameters: string $filename
     95         * Function: Write KMLFile to a KML file
     96         */
    9297        public function write($filename) {
    93                 // TODO: Write KMLFile to a KML file
     98                trigger_log(SYSLOG_DEBUG, 'Opening the file "' . $filename . '"', __FILE__, __LINE__);
     99                $file = fopen("$filename","w")
     100                        or exit(trigger_log(SYSLOG_ERR, 'Opening the file "' . $filename . '"', __FILE__, __LINE__));
     101
     102                trigger_log(SYSLOG_DEBUG, 'Writing file "' . $filename . '"', __FILE__, __LINE__);
     103                fwrite($file,$toString());
     104
     105                trigger_log(SYSLOG_DEBUG, 'Closing file "' . $filename . '"', __FILE__, __LINE__);
     106                fclose($file);
    94107        }
    95108
Note: See TracChangeset for help on using the changeset viewer.