Project

General

Profile

Bug #11653 » 16786_followup.diff

Francois Suter, 2010-12-22 14:21

View differences:

typo3/sysext/version/ws/index.php (working copy)
if (t3lib_div::_POST('_previewLink')) {
$ttlHours = intval($GLOBALS['BE_USER']->getTSConfigVal('options.workspaces.previewLinkTTLHours'));
$ttlHours = ($ttlHours ? $ttlHours : 24*2);
$previewUrl = t3lib_BEfunc::getViewDomain($this->id) . 'index.php?ADMCMD_prev='.t3lib_BEfunc::compilePreviewKeyword('', $GLOBALS['BE_USER']->user['uid'],60*60*$ttlHours,$GLOBALS['BE_USER']->workspace).'&id='.intval($GLOBALS['BE_USER']->workspaceRec['db_mountpoints']);
$previewUrl = t3lib_BEfunc::getViewDomain($this->id) . '/index.php?ADMCMD_prev=' . t3lib_BEfunc::compilePreviewKeyword('', $GLOBALS['BE_USER']->user['uid'], 60*60*$ttlHours, $GLOBALS['BE_USER']->workspace) . '&id=' . intval($GLOBALS['BE_USER']->workspaceRec['db_mountpoints']);
$actionLinks.= '<br />Any user can browse the workspace frontend using this link for the next ' . $ttlHours . ' hours (does not require backend login):<br /><br /><a target="_blank" href="' . htmlspecialchars($previewUrl) . '">' . $previewUrl . '</a>';
} else {
$actionLinks.= '<input type="submit" name="_previewLink" value="Generate Workspace Preview Link" />';
(1-1/3)