Jump to content

Form action in TPL file, need it changed to produce https instead of http


Recommended Posts

I edited my frontcontroller.php by changing publick $ssl; --> public $ssl =true; this made my entire site Secure. 

 

3 forms initally showed up that were http and not https

<form id="productsSortForm" action="http://www.domain.com/18-big-boat-blocks">

<form action="http://www.domain.com/18-big-boat-blocks" method="get" class="nbrItemPage pagination">

<form action="http://www.domain.com/18-big-boat-blocks" method="get" class="pagination">

The top one was corrected by changing it to <form id="productsSortForm" action="{$link->getPageLink('search',true)|escape:'html':'UTF-8'}"> However I am still unable to change the last two:

<form action="{if !is_array($requestNb)}{$requestNb}{else}{$requestNb.requestUrl}{/if}" method="get" class="nbrItemPage pagination">

<form action="{if !is_array($requestNb)}{$requestNb}{else}{$requestNb.requestUrl}{/if}" method="get" class="pagination">

Does anyone know how to make these form actions produce https? This would make my entire site show the green padlock instead of yellow for category and product pages.

 

Thank you!

Edited by generalexperts (see edit history)
Link to comment
Share on other sites

I haven't tested this, but it should work.

<form action="{if !is_array($requestNb)}{$requestNb|replace:'http':'https'}{else}{$requestNb.requestUrl|replace:'http':'https'}{/if}" method="get" class="nbrItemPage pagination">

<form action="{if !is_array($requestNb)}{$requestNb|replace:'http':'https'}{else}{$requestNb.requestUrl|replace:'http':'https'}{/if}" method="get" class="pagination">
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...