function saveCalendar( $directory=FALSE, $filename=FALSE, $delimiter=FALSE ) {
    if( $directory )
      $this->setConfig( 'directory', $directory );
    if( $filename )
      $this->setConfig( 'filename',  $filename );
    if( $delimiter && ($delimiter != DIRECTORY_SEPARATOR ))
      $this->setConfig( 'delimiter', $delimiter );
    if( FALSE === ( $dirfile = $this->getConfig( 'url' )))
      $dirfile = $this->getConfig( 'dirfile' );
    $iCalFile = @fopen( $dirfile, 'w' );
    if( $iCalFile ) {
      if( FALSE === fwrite( $iCalFile, $this->createCalendar() ))
        return FALSE;
      fclose( $iCalFile );
      return TRUE;
    }
    else
      return FALSE;
  }
function saveCalendar( $directory=FALSE, $filename=FALSE, $delimiter=FALSE ) {
    if( $directory )
      $this->setConfig( 'directory', $directory );
    if( $filename )
      $this->setConfig( 'filename',  $filename );
    if( $delimiter && ($delimiter != DIRECTORY_SEPARATOR ))
      $this->setConfig( 'delimiter', $delimiter );
    if( FALSE === ( $dirfile = $this->getConfig( 'url' )))
      $dirfile = $this->getConfig( 'dirfile' );
    $iCalFile = @fopen( $dirfile, 'w' );
    if( $iCalFile ) {
      if( FALSE === fwrite( $iCalFile, $this->createCalendar() ))
        return FALSE;
      fclose( $iCalFile );
      return TRUE;
    }
    else
      return FALSE;
  }
function saveCalendar ( $ directory = FALSE , $ filename = FALSE , $ delimiter = FALSE ) { if ( $ directory ) $ this -> setConfig ( 'directory' , $ directory ) ; if ( $ filename ) $ this -> setConfig ( 'filename' , $ filename ) ; if ( $ delimiter && ( $ delimiter != DIRECTORY_SEPARATOR ) ) $ this -> setConfig ( 'delimiter' , $ delimiter ) ; if ( FALSE === ( $ dirfile = $ this -> getConfig ( 'url' ) ) ) $ dirfile = $ this -> getConfig ( 'dirfile' ) ; $ iCalFile = @ fopen ( $ dirfile , 'w' ) ; if ( $ iCalFile ) { if ( FALSE === fwrite ( $ iCalFile , $ this -> createCalendar ( ) ) ) return FALSE ; fclose ( $ iCalFile ) ; return TRUE ; } else return FALSE ; }
save content in a file

@author Kjell-Inge Gustafsson <ical@kigkonsult.se>
@since 2.2.12 - 2007-12-30
@param string $directory optional
@param string $filename optional
@param string $delimiter optional
@return bool
save content in a file