ssl enable

Does UNA come with an option to enable ssl so when http://domain.com is visited it will redirect(force) to https?

  • 1015
  • More
Replies (11)
    • Olá José,

      I'm running my UNA project on a server using https protocol. The same goes for UNA.io that also runs on UNA!

      • That's right, i have ssl certificate successfully installed on my server and works fine, but it only works when visitor types the secure url using the secure format https. I was looking for that feature available through UNA STUDIO, something similar to what joomla has in admin panel where it lets you "enable force ssl in joomla site": 

        image_transcoder.php?o=bx_froala_image&h=798&dpx=1&t=1546827351

        I guess if UNA doesn't have that option through admin panel, i could do it through .htaccess file, correct?

        • Hello Jose G!

          Yes, UNA doesn't have the similar option because it redirects automatically to the URL under it was installed. It is controlled by the function bx_check_redirect_to_correct_hostname from the file inc/utils.inc.php

          • Strange...mine doesn't auto redirect. I can type in non-secure address and it will bring up the site at http:// but images and icons are missing naturally because it's not keyed for nonsecure site only https

            • Jeremy, something like that was discussed here. https://una.io/page/view-discussion?id=1944

              • I have already performed those steps and currently my site is set like that however, it doesn't autoredirect

                • Not sure why you would need to edit any core files if you have properly enabled SSL AND created/installed your SSL Cert using Plesk/cPanel. The server should automatically redirect to the HTTPS:// domain.

                  It's also important to note that if you do successfully enable SSL for your website, you will need to reset your UNA license and create a new key/secret using the full https:// domain name or else you will not be able to connect to the market. 

                  • I found a solution for mine.

                    The following forces any http request to be rewritten using https. For example, the following code forces a request to http://example.com to load https://example.com. It also forces directly linked resources (images, css, etc.) to use https: 

                    <IfModule mod_rewrite.c>

                        RewriteEngine on

                        RewriteRule ^m/(.*)$  modules/index.php?r=$1 [QSA,L]

                        RewriteRule ^page/(.*)$  page.php?i=$1 [QSA,L]

                        RewriteRule ^s/([a-zA-Z0-9_]+)/([a-zA-Z0-9\.]+)  storage.php?o=$1&f=$2   [QSA,L]

                        RewriteCond %{HTTPS} !=on

                        RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

                    </IfModule>

                    • Joseg Sadel What is the difference between the one above and this one?

                      RewriteEngine On 

                      RewriteCond %{SERVER_PORT} 80 

                      RewriteRule ^(.*)$ https://www.yourdomain.com/$1 [R,L]

                      • I found a solution for mine.

                        The following forces any http request to be rewritten using https. For example, the following code forces a request to http://example.com to load https://example.com. It also forces directly linked resources (images, css, etc.) to use https: 

                            RewriteEngine on

                            RewriteRule ^m/(.*)$  modules/index.php?r=$1 [QSA,L]

                            RewriteRule ^page/(.*)$  page.php?i=$1 [QSA,L]

                            RewriteRule ^s/([a-zA-Z0-9_]+)/([a-zA-Z0-9\.]+)  storage.php?o=$1&f=$2   [QSA,L]

                            RewriteCond %{HTTPS} !=on

                            RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] 

                        Hi Jose,  what file do you enter the code above?  I've just started running v12.0.0,  the code still applies for this version?  thanks

                        • Hello Simon !

                          It should be applied in the root .htaccess file of UNA.

                          Login or Join to comment.