-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[TASK] Import current TER version, 0.1.0
- Loading branch information
0 parents
commit f586b1c
Showing
5 changed files
with
77 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
<?php | ||
|
||
class tx_forcerealurls { | ||
|
||
function check($params,$pObj) { | ||
if ($pObj->siteScript && $pObj->config['config']['tx_realurl_enable'] && ( | ||
substr($pObj->siteScript, 0, 9) == 'index.php' || | ||
substr($pObj->siteScript, 0, 1) == '?' | ||
)) { | ||
$baseURL = $pObj->config['config']['baseURL']; | ||
$LD = $pObj->tmpl->linkData($pObj->page,'',$pObj->no_cache,'','',t3lib_div::getIndpEnv('QUERY_STRING')); | ||
$url = $baseURL.$LD['totalURL']; | ||
|
||
header('HTTP/1.1 301 Moved Permanently'); | ||
header('Location: '.$url); | ||
|
||
exit; | ||
} | ||
} | ||
} | ||
|
||
?> |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
<?php | ||
|
||
/*************************************************************** | ||
* Extension Manager/Repository config file for ext "forcerealurls". | ||
* | ||
* Auto generated 11-03-2014 09:35 | ||
* | ||
* Manual updates: | ||
* Only the data in the array - everything else is removed by next | ||
* writing. "version" and "dependencies" must not be touched! | ||
***************************************************************/ | ||
|
||
$EM_CONF[$_EXTKEY] = array ( | ||
'title' => 'Force RealURLs', | ||
'description' => 'Checks if a page is trying to be accessed by an old style URL, and does a 301 redirect to the appropriate URL if so', | ||
'category' => 'fe', | ||
'shy' => 0, | ||
'version' => '0.1.0', | ||
'dependencies' => '', | ||
'conflicts' => '', | ||
'priority' => '', | ||
'loadOrder' => '', | ||
'module' => '', | ||
'state' => 'beta', | ||
'uploadfolder' => 0, | ||
'createDirs' => '', | ||
'modify_tables' => '', | ||
'clearcacheonload' => 0, | ||
'lockType' => '', | ||
'author' => 'Christian Jul Jensen', | ||
'author_email' => 'julle(at)typo3.org', | ||
'author_company' => '', | ||
'CGLcompliance' => NULL, | ||
'CGLcompliance_note' => NULL, | ||
'constraints' => | ||
array ( | ||
'depends' => | ||
array ( | ||
'cms' => '', | ||
'php' => '3.0.0-0.0.0', | ||
'typo3' => '3.7.0-0.0.0', | ||
), | ||
'conflicts' => | ||
array ( | ||
), | ||
'suggests' => | ||
array ( | ||
), | ||
), | ||
); | ||
|
||
?> |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<?php | ||
$TYPO3_CONF_VARS['SC_OPTIONS']['tslib/class.tslib_fe.php']['isOutputting']['tx_forcerealurls'] = 'EXT:forcerealurls/class.tx_forcerealurls.php:tx_forcerealurls->check'; | ||
?> |