OSpam hidden field is shown only in Hikashop register not in contact form

  • Posts: 63
  • Thank you received: 6
3 years 2 months ago #335287

-- HikaShop version -- : 4.4.3
-- Joomla version -- : 3.10.1
-- PHP version -- : 7.4.16

Hi,

We installed OSpam-a-not it all works but at the pop-up form from Hikashop it does not hide the honeypot field, see screenshot under the “REGISTREREN” button.
Trying to add the following code with F12 Firefox Inspector.
Before:
<input type="text" name="your_address" value="">
After:
<input type="text" name="your_name" value="" style="display:none">
This hides the Honeypot field.

There is a directory under plugins/system/ospamanot no clue what to do there :) to add this code.

We now have 2 questions:
1. We do not know if the honeypot is still working when we add this code no idea how to test this.
2. Also we like to know where the plugin is located to add this code, I tried to search with Extplorer under plugins but there is no OSpam or Joomlashack directory closest we came with Everything on our webserver.

So the question is, if this code is a good solution where to add it and if not where to add the good solution :)

Attachments:

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

  • Posts: 82867
  • Thank you received: 13374
  • MODERATOR
3 years 2 months ago #335288

Hi,

I don't know how that extension works.
I looked a bit at the plugin install package, but it has several sub plugins a library, and many files.
I don't know what code you're trying to add to the plugin. The only code you have in your message in the HTML of an input field. I don't see a reason to add it to the plugin.
I suppose that you would normally want to add that to the form you want to add the honypot system to.
And in that case, to do that, you want to activate the "Display view files" setting of the HikaShop configuration to check which view file is used for the contact form. Then, you can edit it via the menu Display>Views in the HikaShop backend to add the input field HTML in the form so that the plugin can check if it has been filled by a bot or not.
However, that's only a supposition since as I said, I don't know how that plugin works.

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

  • Posts: 63
  • Thank you received: 6
3 years 2 months ago #335441

Hi Nicolas,

I am not a code expert and just tried to add the code mentioned below via inspector (F12) because honeypot (under Registreren button) should be invisible and only bot can see/fill-in.

In parallel to this topic, I also send email to the developer from O-Spam his name is Bill this is their reply:
Looking closer, it looks like the Hikashop page is not proper/expected html. OSpam-a-not adds the style tag to the end of the <head> tag. The Hikashop page does not have a <head> tag, so the style tag can't be added.


Regards,

Wella

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

  • Posts: 82867
  • Thank you received: 13374
  • MODERATOR
3 years 2 months ago #335443

Hi,

Look here:
i.imgur.com/hYbUiM7.png
You can see the head tag on the third row of the HTML of the HikaShop contact page.
So either he doesn't know what he is talking about or he meant something else or didn't understand what you wanted because the head tag is on the HikaShop contact page.
In fact, that head tag is added by the template, not HikaShop, so even if it wasn't there, the problem would be with the template.
Also, I don't see what the style being added to the head of the page has anything to do with adding an anti spam to a form. I suppose that he must have misunderstood your problem.

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

  • Posts: 63
  • Thank you received: 6
3 years 2 months ago #335457

Hi Nicoals,


Thank you for the reply.

I think I'm not that clear there are 2 type of forms - the Contact and the Registration:
It is not the Contact form as shown on your image (that works perfect), it is the Register form (REGISTER button).
The Register form gets 5 out of 10 times the extra field from O-Spam see following url and screenshot.

Click the REGISTER button right above:
www.2install.nl/menu/glasvezel-fiber

See attachment under Registreren there is the extra field.




Regards,

Wella

Attachments:

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

  • Posts: 82867
  • Thank you received: 13374
  • MODERATOR
3 years 2 months ago #335460

Hi,

Ok, now I understand your issue and what the person from OSpam is saying.
When you click on the "register" button, the registration form opens in a popup.
I suppose this is done with a modal extension or something provided by your template.
The way this modal mechanism works is that it loads the registration from from the registration page of HikaShop but strips all the headers of the page:
i.imgur.com/FByTjJM.png
And apparently, OSpam adds the CSS to hide the hidden input in the header of the page and that's why it's missing from the registration popup and you still see the hidden input from OSpam.
The solution is to use another modal mechanism with an iframe directly calling the registration page of HikaShop with the ?tmpl=component parameter added to it (and making sure that the component.php file of the template displays the headers, which it normally should).
Another simpler solution would be for OSpam to add the display:none; CSS directly as an attribute of the HTML it adds to the form. That would circumvent the fact that the header can be missing with the modal mechanism you're using. But that will require OSpam to agree to the modification or tell you what to do exactly.

Either way, there is not much I can do for you and none of this is coming from us. All I can propose is to not use a popup but the normal registration page of HikaShop, which won't have that problematic since the headers of the page are always displayed by the template in that case.

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

Time to create page: 0.063 seconds
Powered by Kunena Forum