[Skip to main content](#vessel-content)

#   Accept terms checked by default

##

- **[mojweb](/forum/user/5128-mojweb "View mojweb's Profile")**
- [![mojweb's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/5128-mojweb "View mojweb's Profile") Topic Author
- [ Offline](/forum/user/5128-mojweb)

Less More

- Posts: 432
- Thank you received: 22
-

10 years 1 month ago [\#251519](#251519) by [mojweb](/forum/user/5128-mojweb "View mojweb's Profile")  *[Accept terms checked by default](/forum/27-checkout/886741-accept-terms-checked-by-default#251519 "-- HikaShop version -- : 2.6.4  Can be configured that is check box for terms and conditions, checked by default? If not, how to override?")* was created by *[mojweb](/forum/user/5128-mojweb "View mojweb's Profile")*

-- HikaShop version -- : 2.6.4

Can be configured that is check box for terms and conditions, checked by default?
If not, how to override?

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI3LWNoZWNrb3V0Lzg4Njc0MS1hY2NlcHQtdGVybXMtY2hlY2tlZC1ieS1kZWZhdWx0P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[GW](/forum/user/33851-gw "View GW's Profile")**
- [![GW's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/33851-gw "View GW's Profile")
- [ Offline](/forum/user/33851-gw)

Less More

- Posts: 200
- Thank you received: 75
-
-

10 years 1 month ago [\#251548](#251548) by [GW](/forum/user/33851-gw "View GW's Profile")  Replied by *[GW](/forum/user/33851-gw "View GW's Profile")* on topic *[Accept terms checked by default](/forum/27-checkout/886741-accept-terms-checked-by-default#251548 "-- HikaShop version -- : 2.6.4  Can be configured that is check box for terms and conditions, checked by default? If not, how to override?")*

Hi,

there doesn't seem to be an option for that, but you can override it by going to "Display -&gt; Views".
Select the view "checkout" and your template, there you will find the view "terms" where the input box is defined on line 11: Code:

&lt;input class="hikashop_checkout_terms_checkbox" id="hikashop_checkout_terms_checkbox" type="checkbox" name="hikashop_checkout_terms" value="1" &lt;?php echo $this-&gt;terms_checked; ?&gt; /&gt;

You could replace the part **&lt;?php echo $this-&gt;terms\_checked; ?&gt;** by **checked="checked"**, then the checkbox will always be checked.

Hikashop actually stores this setting whether the terms are checked in the user's session so that if a user goes to another page and comes back to the terms, it will remember whether the box was checked or not, which it won't with the above solution. So if you want to remember the user's setting (which is probably not that important in this case since the user needs to accept the terms anyway to continue) but you could, instead of forcing the checkbox, set the session variable by adding something like this before line 11: Code:

&lt;?php $app = JFactory::getApplication(); if($app-&gt;getUserState( HIKASHOP_COMPONENT.'.checkout_terms')===null){ $app-&gt;setUserState(HIKASHOP_COMPONENT.'.checkout_terms',1); $this-&gt;terms(); } ?&gt;

Hope this helps. Kind regards,

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI3LWNoZWNrb3V0Lzg4Njc0MS1hY2NlcHQtdGVybXMtY2hlY2tlZC1ieS1kZWZhdWx0P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[kyratn](/forum/user/38342-kyratn "View kyratn's Profile")**
- [![kyratn's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/gallery/redswirl.jpg)](/forum/user/38342-kyratn "View kyratn's Profile")
- [ Offline](/forum/user/38342-kyratn)

Less More

- Posts: 1119
- Thank you received: 114
-
- [](http://kyra.lt)
-

10 years 1 month ago [\#251581](#251581) by [kyratn](/forum/user/38342-kyratn "View kyratn's Profile")  Replied by *[kyratn](/forum/user/38342-kyratn "View kyratn's Profile")* on topic *[Accept terms checked by default](/forum/27-checkout/886741-accept-terms-checked-by-default#251581 "-- HikaShop version -- : 2.6.4  Can be configured that is check box for terms and conditions, checked by default? If not, how to override?")*

Hi,

Hmm, what i did i added this:
Code:

checked="checked"

inside input and it does the job.

So question for u GW. What is the difference?

Thanks

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI3LWNoZWNrb3V0Lzg4Njc0MS1hY2NlcHQtdGVybXMtY2hlY2tlZC1ieS1kZWZhdWx0P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[GW](/forum/user/33851-gw "View GW's Profile")**
- [![GW's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/33851-gw "View GW's Profile")
- [ Offline](/forum/user/33851-gw)

Less More

- Posts: 200
- Thank you received: 75
-
-

10 years 1 month ago [\#251586](#251586) by [GW](/forum/user/33851-gw "View GW's Profile")  Replied by *[GW](/forum/user/33851-gw "View GW's Profile")* on topic *[Accept terms checked by default](/forum/27-checkout/886741-accept-terms-checked-by-default#251586 "-- HikaShop version -- : 2.6.4  Can be configured that is check box for terms and conditions, checked by default? If not, how to override?")*

Hi,

Hikashop stores the value of the T&amp;C checkbox in the user session (so whether it is checked or not).
This means if a user unchecks the T&amp;C, goes to another page, and then comes back to the T&amp;C, it will remember the setting from before and the checkbox will still be unchecked.

If you use **checked="checked"** however, it will simply always be checked and you don't use the remembered state anymore. So in the above situation, if a user unchecks the T&amp;C, goes to another page, comes back, it will be checked again (even though the user last unchecked it).
Like I said, probably not a problem for many, since by default the T&amp;C need to be checked to be able to continue with the checkout, but just thought I would give that solution for completeness.

Kind regards,

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI3LWNoZWNrb3V0Lzg4Njc0MS1hY2NlcHQtdGVybXMtY2hlY2tlZC1ieS1kZWZhdWx0P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[kyratn](/forum/user/38342-kyratn "View kyratn's Profile")**
- [![kyratn's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/gallery/redswirl.jpg)](/forum/user/38342-kyratn "View kyratn's Profile")
- [ Offline](/forum/user/38342-kyratn)

Less More

- Posts: 1119
- Thank you received: 114
-
- [](http://kyra.lt)
-

10 years 1 month ago [\#251587](#251587) by [kyratn](/forum/user/38342-kyratn "View kyratn's Profile")  Replied by *[kyratn](/forum/user/38342-kyratn "View kyratn's Profile")* on topic *[Accept terms checked by default](/forum/27-checkout/886741-accept-terms-checked-by-default#251587 "-- HikaShop version -- : 2.6.4  Can be configured that is check box for terms and conditions, checked by default? If not, how to override?")*

I see now. Thanks for explanation.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI3LWNoZWNrb3V0Lzg4Njc0MS1hY2NlcHQtdGVybXMtY2hlY2tlZC1ieS1kZWZhdWx0P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.059 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
