Submit on click

  • Posts: 17
  • Thank you received: 1
6 years 1 month ago #288581

-- HikaShop version -- : 3.3.0
-- Joomla version -- : 3.8.5

Hello,

the option "submit on click" is turned on but it does not work.
What is wrong?

Thanks,
Nicole

Attachments:

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

  • Posts: 81361
  • Thank you received: 13037
  • MODERATOR
6 years 1 month ago #288612

Hi,

It works fine for me on your link.
Whenever I click outside of the input box after entering some text in it, your website will display the products results with that text.
monosnap.com/file/fBF7v6vVztAMZLKyVzgqEoTNCLXPvr

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

  • Posts: 17
  • Thank you received: 1
6 years 1 month ago #288620

Hello,

thanks for the answer.
On your demo side - demo.hikashop.com/index.php/en/ - it is enough to press enter.
I would like that too.

Thanks,
Nicole

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

  • Posts: 81361
  • Thank you received: 13037
  • MODERATOR
6 years 1 month ago #288621

Hi,

This comes from the way HTML and browsers works and how you configured your filter module.
When you have the focus on an input field and press enter, the browser will look for a button of the type "submit" in the form element where the input field is.
If it finds it, (and there is the "filter" button on our demo website filter module for that), it will trigger it as if you had clicked on it.
If it doesn't find it, it doesn't do anything.
So you would have to activate the display of the filter button in your filter module and then it would work.
Then, you can always add some CSS to had the button. The browser will still trigger it in that case.

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

  • Posts: 17
  • Thank you received: 1
6 years 1 month ago #288657

Hi Nicolas,

thanks for reply.
That's what I thought. I've already tried it, but there was no change.
Now I have tried again. It still does not work as it should. What do I overlook? Do you have a clue?

Thanks,
Nicole

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

  • Posts: 2143
  • Thank you received: 747
6 years 1 month ago #288658

Hi,

Please check your browser console, you have an error -- see also screenshot here:



Looks like you have two filter modules on the same page (module IDs 120 and 127), both of which have the same HTML ID, which can lead to unexpected results such as the form not working.
(Typically your original setting without button and just pressing "enter/return" key should work... it works for me, too.)


Need help with customisations of layouts, style or other site development? PM me!
(Don't forget to turn on "E-mail notification of new messages" )
Attachments:

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

  • Posts: 17
  • Thank you received: 1
6 years 1 month ago #288659

Thanks, lousyfool.

I have now deleted one module. There is only the ID 120. But unfortunately nothing has changed.
Can this be?

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

  • Posts: 81361
  • Thank you received: 13037
  • MODERATOR
6 years 1 month ago #288684

Hi,

I went and looked againt at the situation on your website.
You need to configure the filter module so that the button is displayed inside the form and not outside. There is a setting for that there.
Otherwise, if the button is outside, it won't be seen by the form.
The second thing is that, contrary to the demo website, you're using the new buttons system of HikaShop 3. And it uses a tags instead of input tags. And thus even though they looked like buttons, they aren't real buttons.
You'll have to edit the file "filter" of the view "product" via the menu Display>Views and change the lines:

<a href="#" id="hikashop_filter_button_<?php echo $this->params->get('main_div_name'); ?>" class="<?php echo $this->config->get('css_button', 'hikabtn'); ?>" onclick="document.getElementById('hikashop_filtered_<?php echo $this->params->get('main_div_name'); ?>').value='1';document.forms['hikashop_filter_form_<?php echo $this->params->get('main_div_name'); ?>'].submit(); return false;"><?php echo JText::_('FILTER'); ?></a>
to:
<input type="submit" id="hikashop_filter_button_<?php echo $this->params->get('main_div_name'); ?>" class="<?php echo $this->config->get('css_button', 'hikabtn'); ?>" onclick="document.getElementById('hikashop_filtered_<?php echo $this->params->get('main_div_name'); ?>').value='1';document.forms['hikashop_filter_form_<?php echo $this->params->get('main_div_name'); ?>'].submit(); return false;" value="<?php echo JText::_('FILTER'); ?>" />
Then it will work fine.

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

  • Posts: 17
  • Thank you received: 1
6 years 1 month ago #288694

Hi Nicolas,

sorry, but it does not work. The button is inside and the code is changed.
Did I forgot something?

Thanks,
Nicole

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

  • Posts: 81361
  • Thank you received: 13037
  • MODERATOR
6 years 1 month ago #288697

Hi,

I'm out of ideas. I've done the same thing on my end and it works fine.
If you switch to the default template of Joomla, does it work ?
It seems that there might be something linked to the template.

The following user(s) said Thank You: studio-n

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

  • Posts: 17
  • Thank you received: 1
6 years 1 month ago #288756

Hi,

thank you. It works.
The problem was BreezingForms. Now BreezingForms run in a frame and it works :)

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

  • Posts: 12953
  • Thank you received: 1778
6 years 1 month ago #288771

Hello,

Thank you for your feedback !

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

Time to create page: 0.092 seconds
Powered by Kunena Forum