Two issues with the Legal module

anton
New Member

I need every developer who signs up to check "Accept our Master Services Agreement"

https://www.freightos.com/freightos-master-services-agreement/

I enabled the Legal module and set it up to use a link, and now the check box appears in the Sign Up screen, BUT there are three issues:

1. The checkbox appears in the center with the text below - it's ugly - how can I customize this appearance?

2. The ToC link leads to https://dev-freightosdp.devportal.apigee.io/legal (the legal page) instead of of our Master Services Agreement link which I specified above.

3. How can I add target="_blank" to the T&C link?

4. How can I customize the label of the Accept checkbox?

5536-sign-up-legal-module-bug.png

Solved Solved
1 2 217
1 ACCEPTED SOLUTION

Great Questions @Anton+Bar ,

Regarding the checkbox appearance, You can write your own css inside your custom theme folder. For your site, I see "sites/all/themes/freightos_responsive/css/freightos_responsive.css" file. You can write custom css in that file.

For example,

body #user-register-form input#edit-legal-accept {
    float: left;
    width: 5%;    
    margin-top: 0px;
}

You can also breakdown custom css into multiple files. You can create a new css file inside css folder & reference it same in .info file of your custom theme something like below.

stylesheets[all][] = css/filename.css

Regarding ToC Link, I believe you are using legal module, It doesn't support the external link. But, there is a much simpler way to achieve what you want to achieve without a need for module like legal.

  • Disable legal module. Navigate to 'admin/modules'
  • Search for legal, disable module, save configuration.
  • Navigate to "admin/config/people/accounts/fields"
  • Add new Field, Label :Terms & Conditions, field_user_term_conditions, Boolean, Single on/off checkbox.

5542-screen-shot-2017-08-27-at-100410-pm.png

  • Choose on value as 1 and off value as 0
  • Configure label as below text ,
<a href="https://www.freightos.com/freightos-master-services-agreement" target="_blank">Accept Terms & Conditions of Use</a>
  • Select required field & display on registration form.
  • Select Use field label instead of the "On value" as label

5543-screen-shot-2017-08-27-at-100620-pm.png

  • Save Settings.

You can also create a field group called Terms & Conditions with fieldset widge & drag the newly created above field under the group in "admin/config/people/accounts/fields" . See screenshot below.

5544-screen-shot-2017-08-27-at-101052-pm.png

See the end result in action here.

Hope it helps. Keep us posted if any.

View solution in original post

2 REPLIES 2

Great Questions @Anton+Bar ,

Regarding the checkbox appearance, You can write your own css inside your custom theme folder. For your site, I see "sites/all/themes/freightos_responsive/css/freightos_responsive.css" file. You can write custom css in that file.

For example,

body #user-register-form input#edit-legal-accept {
    float: left;
    width: 5%;    
    margin-top: 0px;
}

You can also breakdown custom css into multiple files. You can create a new css file inside css folder & reference it same in .info file of your custom theme something like below.

stylesheets[all][] = css/filename.css

Regarding ToC Link, I believe you are using legal module, It doesn't support the external link. But, there is a much simpler way to achieve what you want to achieve without a need for module like legal.

  • Disable legal module. Navigate to 'admin/modules'
  • Search for legal, disable module, save configuration.
  • Navigate to "admin/config/people/accounts/fields"
  • Add new Field, Label :Terms & Conditions, field_user_term_conditions, Boolean, Single on/off checkbox.

5542-screen-shot-2017-08-27-at-100410-pm.png

  • Choose on value as 1 and off value as 0
  • Configure label as below text ,
<a href="https://www.freightos.com/freightos-master-services-agreement" target="_blank">Accept Terms & Conditions of Use</a>
  • Select required field & display on registration form.
  • Select Use field label instead of the "On value" as label

5543-screen-shot-2017-08-27-at-100620-pm.png

  • Save Settings.

You can also create a field group called Terms & Conditions with fieldset widge & drag the newly created above field under the group in "admin/config/people/accounts/fields" . See screenshot below.

5544-screen-shot-2017-08-27-at-101052-pm.png

See the end result in action here.

Hope it helps. Keep us posted if any.

THANKS, that's very! helpful!