Bug #2557

Links rendered by the Router ignore application context

Added by Robert Lemke over 6 years ago. Updated almost 5 years ago.

Status:Resolved Start date:2009-02-04
Priority:Must have Due date:
Assigned To:Karsten Dambekalns % Done:

100%

Category:MVC
Target version:TYPO3 Flow Base Distribution - 1.0 alpha 1
PHP Version: Complexity:
Has patch: Affected Flow version:

Description

If the application context is != production, the URL usually includes the index_*.php segment:

http://myhost/index_dev.php/foo/bar/baz

The script filename is, however, removed in rendered links which leads to a context switch:

http://myhost/foo/bar/baz

Related issues

related to TYPO3.Flow - Bug #2751: Routing: generated links must keep index.php if needed Resolved 2009-03-03

Associated revisions

Revision a36605e9
Added by Karsten Dambekalns over 6 years ago

FLOW3:
  • the route() method now strips index*.php from the request URI if present, refs #2557
FLOW3, TYPO3v5 & Blog Distributions:
  • adjusted index.php so it uses FLOW3_CONTEXT from environment if set
  • adjusted .htaccess

Revision ee2b88c8
Added by Karsten Dambekalns over 6 years ago

FLOW3:
  • the route() method now strips index*.php from the request URI if present, refs #2557
FLOW3, TYPO3v5 & Blog Distributions:
  • adjusted index.php so it uses FLOW3_CONTEXT from environment if set
  • adjusted .htaccess

Revision 4ef766f5
Added by Karsten Dambekalns over 6 years ago

FLOW3:
  • the route() method now strips index*.php from the request URI if present, refs #2557
FLOW3, TYPO3v5 & Blog Distributions:
  • adjusted index.php so it uses FLOW3_CONTEXT from environment if set
  • adjusted .htaccess

Revision c1df49a2
Added by Karsten Dambekalns over 6 years ago

FLOW3:
  • changed request URI handling, fixes #2557

Revision 49ce65e7
Added by Karsten Dambekalns over 6 years ago

FLOW3:
  • changed request URI handling, fixes #2557

History

#1 Updated by Karsten Dambekalns over 6 years ago

Also the routing has hard-coded support only for index_dev.php, other contexts are not supported.

It would be nice to switch the context depending on an environment variable, this would be very useful for CLI calls. And Apache can set the environment variable as part of a rewrite rule, so that FLOW3 never sees the "URL-encoding" of the context. Hm, something like that.

#2 Updated by Karsten Dambekalns over 6 years ago

  • Status changed from New to Accepted
  • Assigned To set to Karsten Dambekalns

#3 Updated by Karsten Dambekalns over 6 years ago

  • Status changed from Accepted to Resolved
  • % Done changed from 0 to 100

Applied in changeset r1967.

Also available in: Atom PDF