Bug #30892

t3lib_befunc::getViewDomain returns wrong or no domain

Added by Thomas Pilgaard Carlsen over 9 years ago. Updated over 2 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
-
Start date:
2011-10-13
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
4.5
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

Issue 1:
If the TYPO3 BE hostname is not configured as a sys_domain record t3lib_befunc::getViewDomain will always return TYPO3 BE hostname and not the first domain of the root line of the page which is being previewed.

Issue 2:
If the TYPO3 BE hostname is configured as a sys_domain but the current root line does not contain a valid domain record t3lib_befunc::getViewDomain will return only 'http://' ie. no domain. I would think the logical thing would be to return the TYPO3 BE hostname.


Files

class.t3lib_befunc.diff (1.03 KB) class.t3lib_befunc.diff Jaume Prat, 2011-10-18 16:27
t3lib_befunc.diff (1.01 KB) t3lib_befunc.diff Diff-patch Jaume Prat, 2011-11-21 22:54

Related issues

Related to TYPO3 Core - Bug #34820: t3lib_befunc::getViewDomain does not respect http/https schemeClosed2012-03-14

Actions
#1

Updated by Jaume Prat over 9 years ago

I have a similar problem with my TYPO3 project. I needed to fix the class t3lib_befunc in core.

I'm looking forward to your feedback.

#2

Updated by Jaume Prat about 9 years ago

  • Assignee set to Christian Kuhn
#3

Updated by Christian Kuhn about 9 years ago

  • Assignee deleted (Christian Kuhn)
#4

Updated by Jaume Prat about 9 years ago

This patch is the correct and solves the problem. Please ignore the last one

#5

Updated by Jaume Prat about 9 years ago

Steps To Reproduce this issue:

With a multidomain Webpage(s) in one TYPO3-Instance:

  • add more than 1 domain in your Rootpage, for example:
  • put domain1 at the first position
  • in Backend with domain2 (www.domain2.com/typo3) try to preview a page.

You will be always redirect to domain1 (!)

With this patch you will be redirect to domain2 if you try to preview a page with domain2 and search if domain2 exist in your rootline.

Could anybody try this patch?

THX!

#6

Updated by Mr. Jenkins about 9 years ago

  • Status changed from New to Under Review

Patch set 1 of change I8118d2c932b2a9d6c3d2dae51c5707a6371784d8 has been pushed to the review server.
It is available at http://review.typo3.org/6830

#7

Updated by Steffen Gebert about 9 years ago

  • Assignee deleted (TYPO3 Release Team)
  • Target version deleted (4.6.1)
#8

Updated by Gerrit Code Review about 9 years ago

Patch set 2 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/6830

#9

Updated by Georg Ringer about 9 years ago

is it possible that this is still not fully fixed?

My page tree:

. Tree 1 < -- Domain: fo.local
... Tree 1b
. Tree 2 < -- Domain: trunk.local
... Tree 2b

My backend domain: trunk.local and if i am on page "Tree 1b" I still get the trunc.local as preview domain but this should be fo.local as trunk.local is only valid for the other page tree.

problem is imo because ::getDomainStartPage() will deliver a result for trunk.local but first there should be a check if this domain is valid for the current rootline

#10

Updated by Gerrit Code Review about 9 years ago

Patch set 3 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/6830

#11

Updated by Gerrit Code Review about 9 years ago

Patch set 4 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/6830

#12

Updated by Gerrit Code Review about 9 years ago

Patch set 5 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/6830

#13

Updated by Jaume Prat almost 9 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
#14

Updated by Gerrit Code Review almost 9 years ago

  • Status changed from Resolved to Under Review

Patch set 1 for branch TYPO3_4-5 has been pushed to the review server.
It is available at http://review.typo3.org/9317

#15

Updated by Gerrit Code Review almost 9 years ago

Patch set 1 for branch TYPO3_4-6 has been pushed to the review server.
It is available at http://review.typo3.org/9319

#16

Updated by Gerrit Code Review almost 9 years ago

Patch set 2 for branch TYPO3_4-6 has been pushed to the review server.
It is available at http://review.typo3.org/9319

#17

Updated by Gerrit Code Review almost 9 years ago

Patch set 3 for branch TYPO3_4-6 has been pushed to the review server.
It is available at http://review.typo3.org/9319

#18

Updated by Gerrit Code Review almost 9 years ago

Patch set 2 for branch TYPO3_4-5 has been pushed to the review server.
It is available at http://review.typo3.org/9317

#19

Updated by Gerrit Code Review almost 9 years ago

Patch set 4 for branch TYPO3_4-6 has been pushed to the review server.
It is available at http://review.typo3.org/9319

#20

Updated by Jaume Prat almost 9 years ago

  • Status changed from Under Review to Resolved
#21

Updated by Gerrit Code Review almost 9 years ago

  • Status changed from Resolved to Under Review

Patch set 3 for branch TYPO3_4-5 has been pushed to the review server.
It is available at http://review.typo3.org/9317

#22

Updated by Jaume Prat almost 9 years ago

  • Status changed from Under Review to Resolved
#23

Updated by Benni Mack over 2 years ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF