markseinto Posted November 15, 2022 Share Posted November 15, 2022 (edited) Hi. I would like to uncheck the account creation for guests, it is checked by default and I just want to give the option to check/uncheck. How can I do it? Is that value on onepagecheckoutps.php? My prestashop is 1.7.7. Edited November 15, 2022 by markseinto ps version (see edit history) Link to comment Share on other sites More sharing options...
ps8modules Posted November 16, 2022 Share Posted November 16, 2022 No, it's in the module's tpl template. There are many similar One page checkout modules, so it is impossible to say exactly where it needs to be modified. Link to comment Share on other sites More sharing options...
markseinto Posted November 16, 2022 Author Share Posted November 16, 2022 Thank you for your answer. The module is onepagecheckoutps, just in case. I'm guessing this is the part of the code to edit, but I'm not sure: //add checkbox guest checkout if (Configuration::get('PS_GUEST_CHECKOUT_ENABLED')) { $new_field = new FieldControl(); $new_field->name = 'checkbox_create_account_guest'; $new_field->id_control = 'checkbox_create_account_guest'; $new_field->name_control = 'checkbox_create_account_guest'; $new_field->object = 'customer'; $new_field->description = $this->l('Create an account and enjoy the benefits of a registered customer.'); $new_field->type = 'isBool'; $new_field->size = '0'; $new_field->type_control = 'checkbox'; $new_field->default_value = (!$this->context->customer->isLogged() && !$this->context->customer->isGuest() ) ? (int) $this->config_vars['OPC_PRESEL_CREATE_ACCOUNT'] : '1'; $new_field->required = false; $new_field->is_custom = false; $new_field->active = true; $opc_fields[$new_field->object.'_'.$new_field->name] = $new_field; } Link to comment Share on other sites More sharing options...
ps8modules Posted November 16, 2022 Share Posted November 16, 2022 Hi, unfortunately it is not. Can you send me a link to the eshop in a private message? Link to comment Share on other sites More sharing options...
markseinto Posted November 21, 2022 Author Share Posted November 21, 2022 Oh ty I found out that it is one of the js files. 1 Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now