LinkGenerator and persistent parameters

3 years ago

lutor
Member | 27
+
0
-

Hi,
I have recently noticed, that LinkGenerator does not preserve persistent parameters when generating links, which I thought he is doing – $refUrl entering into the process of routing contains persistent parameters, but during constructing url they disappear.

Is this expected behaviour? I do understand, that LinkGenerator is typically used for generating link in email etc. where you typically don't want to pass current state of components, but in some cases I would like to have such behaviour – generate with keeping persistent parameters.

Thanks.

3 years ago

Jan Tvrdík
Nette guru | 2547
+
+1
-

Is this expected behaviour?

Yes.

3 years ago

Filip Procházka
Moderator | 4693
+
+2
-

@lutor the LinkGenerator is meant to be completely independent of presenters.