/**
  * Saves a record based on its data array.
  *
  * @param string $table The table name for the record to save.
  * @param integer $uid The UID for the record to save.
  * @return void
  */
 public function doSave($table, $uid)
 {
     $data = $this->TSFE_EDIT['data'];
     if (!empty($data)) {
         $this->initializeTceMain();
         $this->tce->start($data, array());
         $this->tce->process_uploads($_FILES);
         $this->tce->process_datamap();
         // Save the new UID back into TSFE_EDIT
         $newUID = $this->tce->substNEWwithIDs['NEW'];
         if ($newUID) {
             $GLOBALS['BE_USER']->frontendEdit->TSFE_EDIT['newUID'] = $newUID;
         }
     }
 }
 /**
  * Clear all caches
  *
  * WARNING: Only use during development!!!!
  * It's not a runtime function. If you use it during development keep in mind,
  * that functionality may depend on the cached content. So the use can lead to
  * irritating results.
  *
  * @return	void
  */
 public static function clearAllCaches()
 {
     require_once PATH_t3lib . 'class.t3lib_tcemain.php';
     $tce = new t3lib_tcemain();
     $tce->admin = TRUE;
     $tce->clear_cacheCmd('all');
 }