[TYPO3-english] how to remove the trailing slash from url's
Xavier Perseguers
typo3 at perseguers.ch
Thu Jan 8 15:04:40 CET 2009
Hi,
Rupali wrote:
> i uploaded a file named 'class_ux_tx_realurl.php' inder ext/realurl:
> wrote following code there:
>
> <?php
> class ux_tx_realurl extends tx_realurl {
> function encodeSpURL(&$params, &$ref) {
> parent::encodeSpURL($params, $ref);
> echo 'encode:';
> debug($params['LD']['totalURL']);
> }
> function decodeSpURL($params, &$ref) {
> echo 'decode:';
> debug($params['LD']['totalURL']);
> parent::decodeSpURL($params, $ref);
> }
> }
> ?>
>
> [snip]
>
> now i am getting following warning:
> Warning: Cannot modify header information - headers already sent by (output
> started at /kunden/
> brainfruit.de/WebRoot/brainfruit.com/www/typo3conf/class_ux_tx_realurl.php:11)
> in /kunden/
> brainfruit.de/WebRoot/brainfruit.com/www/typo3/sysext/cms/tslib/class.tslib_fe.phpon
> line 3226
>
>
> what should i do?
Not sending headers after having sent something to the browser :-) That
is simply not using echo and debug when the method you call afterwards
is issuing header() call.
A quick look on Google tells you everything why it does not work:
http://www.tech-recipes.com/rx/1489/solve-php-error-cannot-modify-header-information-headers-already-sent/
--
Xavier Perseguers
http://xavier.perseguers.ch/en/tutorials/typo3.html
More information about the TYPO3-english
mailing list