\n"; echo "\n"; echo "\t\n"; echo "\t\n"; echo "
".$clang->gT("Export Label Set")."
\n"; echo "
".$clang->gT("Error")."
\n".$clang->gT("No LID has been provided. Cannot dump label set.")."
\n"; echo "
\n"; echo "\t
\n"; echo "\n"; exit; } $dumphead = "# LimeSurvey Label Set Dump\n" . "# DBVersion $dbversionnumber\n" . "# This is a dumped label set from the LimeSurvey Script\n" . "# http://www.limesurvey.org/\n" . "# Do not change this header!\n"; //1: Questions Table $qquery = "SELECT * FROM {$dbprefix}labelsets WHERE lid=$lid"; $qdump = BuildCSVFromQuery($qquery); //2: Answers table $aquery = "SELECT lid, code, title, sortorder, language FROM {$dbprefix}labels WHERE lid=$lid"; $adump = BuildCSVFromQuery($aquery); $fn = "limesurvey_labelset_$lid.csv"; header("Content-Type: application/download"); header("Content-Disposition: attachment; filename=$fn"); header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); // Date in the past header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); header("Cache-Control: must-revalidate, post-check=0, pre-check=0"); header("Pragma: cache"); // HTTP/1.0 echo $dumphead, $qdump, $adump; exit; ?>