Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

survey URL ?lang=...

  • KompetenzZ
  • KompetenzZ's Avatar Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
5 years 1 month ago #180211 by KompetenzZ
survey URL ?lang=... was created by KompetenzZ
Hi community,

I can't find an answer to the following question: I have the URL to my survey, which is only in one language, for exmple let's say:
abc.limequery.com/519354?lang=de

I tested to leave the part "?lang=de" when I provide a link to the survey. Let's say: let's say:
abc.limequery.com/519354

The browser still finds the survey/URL.
Can I leave the part with the "?lang=de"? Because then the URL is a bit shorter, which is a bit advantageous.
Or is it not save when the "?lang=de" is removed? I just don't know why there is this "?lang=de" when my survey is only in one language anyway.

LS Version 3.14

Cheers kompetenzz
The topic has been locked.
More
5 years 1 month ago #180212 by jelo
Replied by jelo on topic survey URL ?lang=...
You can use the URL without the lang parameter.

The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
The topic has been locked.
  • KompetenzZ
  • KompetenzZ's Avatar Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
5 years 1 month ago #180218 by KompetenzZ
Replied by KompetenzZ on topic survey URL ?lang=...
Thank you :)

Cheers kompetenzz
The topic has been locked.
More
5 years 1 month ago #181122 by markusd1984
Replied by markusd1984 on topic survey URL ?lang=...
How can we remove this to be included from the url displayed?


Can we do this via the urlManager in application/config/config.php ?


When only one language is used this is unnecessary and removing it would be nice to make it cleaner :)
Thanks for any help you guys can give.
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
5 years 1 month ago #181123 by DenisChenu
Replied by DenisChenu on topic survey URL ?lang=...

markusd1984 wrote: Can we do this via the urlManager in application/config/config.php ?


When only one language is used this is unnecessary and removing it would be nice to make it cleaner :)
Thanks for any help you guys can give.

Feature request

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
More
5 years 1 month ago #181128 by markusd1984
Replied by markusd1984 on topic survey URL ?lang=...
Thanks Denis, I know how to submit a feature request, have done a few in the past,

Just thought given there are rules in the UrlManager, mentioned in one of the pages, I though it might be easily to add it there to remove the language parameter (or edit another file responsible for inserting it) without the need for a feature :).
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
5 years 1 month ago #181134 by DenisChenu
Replied by DenisChenu on topic survey URL ?lang=...
Maybe, maybe …

Personnaly i use this :
Code:
      'rules' => array (
          '<sid:\d+>/*' => array('survey/index','urlSuffix'=>'.html','matchValue'=>false),
          'p/<plugin:\w+>/<function:\w+>'=>array('plugins/direct'),
       ),
I don't see how to remove a param in www.yiiframework.com/doc/api/1.1/CUrlManager

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
More
5 years 1 month ago - 5 years 1 month ago #181143 by markusd1984
Replied by markusd1984 on topic survey URL ?lang=...
I thought it may be possible to build the url structure this way and tried using the language parameter <language:\w+> hence I asked the question.

I tried your rule since I had none but they had no affect at all.
Are yours different with the rule vs standard config?

I turned ShowScriptName off as well and have limesurvery.com/surveys/123456?lang=en


I'm trying to figure out what hands over the ?lang parameter, so we could simply comment it out to be not included.
Do you think it would be outside the CUrlManager.php ?
Last edit: 5 years 1 month ago by markusd1984.
The topic has been locked.
More
5 years 1 month ago #181144 by markusd1984
Replied by markusd1984 on topic survey URL ?lang=...
Found it in /application/views/admin/survey/surveySummary_view.php

I simply removed
Code:
,"lang"=>$oSurvey->language)
from
Code:
<div class="col-8">

which now renders the URL without the language parameter B)
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose