Skip to main content

Change Registration form order

More
13 years 1 month ago #118705 by deltafidesign
-- HikaShop version -- : 2.2.0
-- Joomla version -- : 3.1.5
-- PHP version -- : 5.1
-- Browser(s) name and version -- : every
-- Error-message(debug-mod must be tuned on) -- : none

Hi,

I would change the way the registration form displays "tabs" for Registration fields and for Adress fields.

I would show first Adress fields for Hikashop, then show the Registration fields.

How to?

Please Log in or Create an account to join the conversation.

More
13 years 1 month ago #118726 by Jerome
Hi,

You have to override the view "user | registration_bootstrap" (if you are using the bootstrap design mode, if not, override the view "user | registration").

You will be able to change all html element position.
The registration view use the view "user | custom_fields_bootstrap" (or "user | custom_fields") to display the user custom fields and the address (custom) fields.

Regards,

Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

More
13 years 1 month ago - 13 years 1 month ago #118845 by deltafidesign
Hi,

I've already edited registration_bootstrap this way:
Code:
defined('_JEXEC') or die('Restricted access'); ?><fieldset class="form-horizontal"> <textarea rows="4" cols="25" id="privacypolicy" class="inputbox" readonly=""><?php echo JText::_( 'PRIVACY_POLICY_TEXT' ); ?></textarea> <hr> <textarea rows="4" cols="25" id="termsconditions" class="inputbox" readonly=""><?php echo JText::_( 'TERMS_CONDITIONS_TEXT' ); ?></textarea> <hr><br /> <p><?php echo JText::_( 'CONSENT_PRIVACY_TEXT' ); ?></p> <br />

This way I can show 2 text area fields, one for privacy policy and another one for terms and conditions. After those 2 text areas I would like to show 2 radio fields (yes or not) to accept those policy and terms. I've created 2 radio fields in user Tab. But those are shown after the core registration fields.

How can I show those 2 custom radio fields soon after the 2 texarea I've created in the view and put them all the the bottom of the registration form, also after the address fields?
Last edit: 13 years 1 month ago by deltafidesign.

Please Log in or Create an account to join the conversation.

More
13 years 1 month ago #118854 by nicolas
You need to move the lines:
$this->type = 'user';
echo $this->loadTemplate();

after the lines:
$this->type = 'address';
echo $this->loadTemplate();

Please Log in or Create an account to join the conversation.

More
13 years 1 month ago #118859 by deltafidesign
Thanks Nicolas, I've solved this way:
Code:
<?php $this->type = 'address'; echo $this->loadTemplate(); ?> <textarea rows="4" cols="25" id="privacypolicy" class="inputbox" readonly=""><?php echo JText::_( 'PRIVACY_POLICY_TEXT' ); ?></textarea> <hr> <textarea rows="4" cols="25" id="termsconditions" class="inputbox" readonly=""><?php echo JText::_( 'TERMS_CONDITIONS_TEXT' ); ?></textarea> <hr><br /> <p><?php echo JText::_( 'CONSENT_PRIVACY_TEXT' ); ?></p> <br /> <?php $this->type = 'user'; echo $this->loadTemplate(); ?>

Please Log in or Create an account to join the conversation.

More
13 years 1 month ago #118883 by deltafidesign
Now I need to insert 2 other custom fields into the registration tab after password fields. How to?

Please Log in or Create an account to join the conversation.

More
13 years 1 month ago #118900 by Jerome
Hi,

By creating the custom fields and change their position (the ordering) ?

Regards,

Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

More
13 years 1 month ago - 13 years 1 month ago #118914 by deltafidesign

Jerome wrote: By creating the custom fields and change their position (the ordering) ?


How can I change their order if they are into user table and I want them to be shown into Registration tab fields (name, username, email, password etc...)

I've created those fields in user tab because no "registration" tab is allowed between options. Any solution?
Last edit: 13 years 1 month ago by deltafidesign.

Please Log in or Create an account to join the conversation.

More
13 years 1 month ago #118923 by Jerome
Hi,

User custom fields are displayed thanks to this part of code:
Code:
<?php $this->type = 'user'; echo $this->loadTemplate(); ?>
So where you place it, the user custom field will be displayed.

Regards,

Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

More
13 years 1 month ago #118927 by deltafidesign
I already tryed to move that piece of code at top, so before default registration fields (username, email etc..) I can display first custom fields but when I try to put it I got a blank page. Maybe a syntax error, I think I put the code into a wrong position...

That's where I tryed to put it, soon after:
Code:
defined('_JEXEC') or die('Restricted access'); ?><fieldset class="form-horizontal"> <?php if(!$this->simplified_registration){ ?> <?php $this->type = 'user'; echo $this->loadTemplate(); ?>

Where can I move it so it can display custom fields before "registration" default fields?

Please Log in or Create an account to join the conversation.

More
13 years 1 month ago #118928 by deltafidesign
I think I've solved this way:
Code:
<?php $this->setLayout('custom_fields_bootstrap'); $this->type = 'user'; echo $this->loadTemplate(); ?>

Missing the first line if move at the top of the form. Seems work fine now
The following user(s) said Thank You: Jerome

Please Log in or Create an account to join the conversation.

More
8 years 4 months ago #292473 by dvddvd
Hello, in the current version: How to put first Address information and at the end of the registration?

Please Log in or Create an account to join the conversation.

More
8 years 4 months ago #292483 by nicolas
Hi,

I'm not sure what you're asking.
If you want to change the order of the custom address fields, you can do that in the menu Display>Custom fields.
If you want to change the order of other fields or the address position, with the new checkout, you'll have to edit the file "sub_block_login_registration" via the menu Display>Views.
The exact modification will depend on what you exactly want to do.
The following user(s) said Thank You: dvddvd

Please Log in or Create an account to join the conversation.

More
8 years 4 months ago #292486 by dvddvd
Thanks Nicolas, was this. I can't find sub_block_login_registration.

Please Log in or Create an account to join the conversation.

More
8 years 4 months ago #292489 by nicolas
Hi,

I don't see how it can't be there with recent versions of HikaShop as that's the view file displaying the registration for the new checkout:
monosnap.com/file/U3CU61MKrsoeFvf5ZudardbejjVHvK

Please Log in or Create an account to join the conversation.

More
8 years 4 months ago #292526 by dvddvd
Yes, i found It, thanks very much

Please Log in or Create an account to join the conversation.

Time to create page: 0.219 seconds
Powered by Kunena Forum