- Posts: 1
- Thank you received: 0
Welcome to the LimeSurvey Community Forum
Ask the community, share ideas, and connect with other LimeSurvey users!
How to change admin url
- cbe11
- Topic Author
- Offline
- New Member
Less
More
7 years 6 months ago #142250
by cbe11
How to change admin url was created by cbe11
Hello
I would like to know how to change admin url: (hostname)/admin to another one (e.g. (hostname)/anotherRoute )
Thank you
I would like to know how to change admin url: (hostname)/admin to another one (e.g. (hostname)/anotherRoute )
Thank you
The topic has been locked.
- holch
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 11756
- Thank you received: 2753
7 years 6 months ago #142255
by holch
I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.
Replied by holch on topic How to change admin url
This is not possible within Limesurvey.
You might be able to do some redirection via htaccess files, but that has more to do with Apache then Limesurvey.
You might be able to do some redirection via htaccess files, but that has more to do with Apache then Limesurvey.
I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.
The topic has been locked.
- LouisGac
- Visitor
7 years 6 months ago - 7 years 6 months ago #142272
by LouisGac
Replied by LouisGac on topic How to change admin url
LimeSurvey being built on Yii, it should be possible to parameter a specific route in the config file:
www.yiiframework.com/doc/guide/1.1/en/to...arameterizing-routes
Be careful: The current plugin system has been built outside of Yii, so it will not work for them (we should do a rewrite of it in the future so plugins will inherit from the Yii classes).
www.yiiframework.com/doc/guide/1.1/en/to...arameterizing-routes
Be careful: The current plugin system has been built outside of Yii, so it will not work for them (we should do a rewrite of it in the future so plugins will inherit from the Yii classes).
Last edit: 7 years 6 months ago by LouisGac.
The topic has been locked.
- tassoman
- Offline
- Premium Member
Less
More
- Posts: 88
- Thank you received: 7
4 years 1 month ago #193813
by tassoman
«All your survey answers are belong to us »
Replied by tassoman on topic How to change admin url
Sorry for diggin an old post. I was searching the forums for this topic.
Are we nowadays able to parametrize Yii framework inside the configuration file yet?
Maybe will happen in 4.x branch?
Are we nowadays able to parametrize Yii framework inside the configuration file yet?
Maybe will happen in 4.x branch?
«All your survey answers are belong to us »
The topic has been locked.
- DenisChenu
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 13935
- Thank you received: 2551
4 years 1 month ago - 4 years 1 month ago #193819
by DenisChenu
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.
Replied by DenisChenu on topic How to change admin url
Yes, since Yii version ....
manual.limesurvey.org/Optional_settings#Yii_settings
See the default routes here : github.com/LimeSurvey/LimeSurvey/blob/ma...onfig/routes.php#L25
To find the best way : hack routes.php
When you find the best way : replace admin/index etc ... by null and use anything else for real final admin (i mean
'admin/index' =>null, 'admin/<action:\w+>/sa/<sa:\w+>/*'=>null ....
When you found : it can be great to have a sample on manual.limesurvey.org/Optional_settings#Yii_settings :)
manual.limesurvey.org/Optional_settings#Yii_settings
See the default routes here : github.com/LimeSurvey/LimeSurvey/blob/ma...onfig/routes.php#L25
To find the best way : hack routes.php
When you find the best way : replace admin/index etc ... by null and use anything else for real final admin (i mean
'admin/index' =>null, 'admin/<action:\w+>/sa/<sa:\w+>/*'=>null ....
When you found : it can be great to have a sample on manual.limesurvey.org/Optional_settings#Yii_settings :)
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.
Last edit: 4 years 1 month ago by DenisChenu.
The following user(s) said Thank You: tassoman
The topic has been locked.
- tassoman
- Offline
- Premium Member
Less
More
- Posts: 88
- Thank you received: 7
4 years 1 month ago - 4 years 1 month ago #193996
by tassoman
«All your survey answers are belong to us »
Replied by tassoman on topic How to change admin url
Well I tried adding my routes to [ 'rules' ] array inside config.php but nothing happened.
Then I've tried hacking routes.php either, but nothing happened...
Is there any Yii caching? I've tried deleting tmp/runtime content, but nothing happened...
Looks like changes are ignored. And it's debug=2 ... ? I'm lost. :dry:
Then I've tried hacking routes.php either, but nothing happened...
Is there any Yii caching? I've tried deleting tmp/runtime content, but nothing happened...
Looks like changes are ignored. And it's debug=2 ... ? I'm lost. :dry:
«All your survey answers are belong to us »
Last edit: 4 years 1 month ago by tassoman. Reason: bbcode messup with array syntax
The topic has been locked.
- DenisChenu
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 13935
- Thank you received: 2551
4 years 1 month ago #193997
by DenisChenu
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.
Replied by DenisChenu on topic How to change admin url
I never try then unsure ...
But 1st point : are you use url as path or get ? I think it must be path. Maybe with 'showScriptName' => false, ?
But 1st point : are you use url as path or get ? I think it must be path. Maybe with 'showScriptName' => false, ?
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.
- DenisChenu
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 13935
- Thank you received: 2551
4 years 1 month ago #193999
by DenisChenu
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.
Replied by DenisChenu on topic How to change admin url
Else update route to
//Admin Routes
work i can access to index.php/totoadmin/survey/sa/listsurveys for example,
But i can access to index.php/admin/survey/sa/listsurveys too ...
//Admin Routes
Code:
$route['totoadmin'] = "admin"; $route['totoadmin/index'] = "admin"; $route['totoadmin/<action:\w+>/sa/<sa:\w+>/*'] = 'admin/<action>/sa/<sa>'; $route['totoadmin/<action:\w+>/<sa:\w+>/*'] = 'admin/<action>/sa/<sa>'; //question $route['totoadmin/labels/<_action:\w+>'] = "admin/labels/index/<_action>"; $route['totoadmin/labels/<_action:\w+>/<_lid:\d+>'] = "admin/labels/index/<_action>/<_lid>"; //Expression Manager tests $route['totoadmin/expressions'] = "admin/expressions/index";
But i can access to index.php/admin/survey/sa/listsurveys too ...
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.
- tassoman
- Offline
- Premium Member
Less
More
- Posts: 88
- Thank you received: 7
4 years 1 month ago #194000
by tassoman
«All your survey answers are belong to us »
Replied by tassoman on topic How to change admin url
urlFormat => 'get' and showScriptName => false
I've tryed getting ls.local/?r=custom but I got unresolved path. (404)
Then /?r=admin got resolved to default
I've tryed getting ls.local/?r=custom but I got unresolved path. (404)
Then /?r=admin got resolved to default
«All your survey answers are belong to us »
The topic has been locked.
- DenisChenu
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 13935
- Thank you received: 2551
4 years 1 month ago #194001
by DenisChenu
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.
Replied by DenisChenu on topic How to change admin url
Unsure you can with urlFormat => 'get'.
Maybe ask on Yii forum ?
Maybe ask on Yii forum ?
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.