<?php if(isset($_GET['tk']) && $_GET['tk']=="auios2d89ypb878PHLuB1pbiuyBLI6O786G"){

// DADOS DE ACESSO
$user = 'admin';
$pass = 'ARAXZKbhX58jA1KuUSh7';
$host = 'dbs.pokerweb.com.br';
$dir = dirname(__FILE__) . '/fncr-geral/zpadrao.sql';

// EXPORTAR
/*
  $db_padrao = 'pw_0int_demo';
  exec("mysqldump --no-data --user={$user} --password={$pass} --host={$host} {$db_padrao} --result-file={$dir} 2>&1", $output);
  var_dump($output);
*/


// IMPORTAR SQL
$db_destino = 'pw_zz';

/*
  exec("mysql -u {$user} -p'{$pass}' -h {$host} -D {$db_destino} < {$dir}", $output);
  var_dump($output);
*/



// TRUNCATE
  $sql = "SELECT Concat('TRUNCATE TABLE ',table_schema,'.',TABLE_NAME, ';') 
  FROM INFORMATION_SCHEMA.TABLES where table_schema in ('".$db_destino."');";




}

?>