Post by supak111 » Thu Aug 08, 2019 1:29 pm

I was wondering if its possible to change the default contact form route? And if doing so would help with bots programed to find opencart contact forms and spam them? PS I don't feel like installing recapcha on this particle oc2 site

Can anyone tell me how to change route=information/contact to say route=information/reachus?

~ OC 3.0.3.2 and OCmods only ~


User avatar
Active Member

Posts

Joined
Fri Feb 13, 2015 12:09 pm

Post by pprmkr » Thu Aug 08, 2019 2:57 pm

Edit catalog/controller/information/contact.php

Change:

Code: Select all

class ControllerInformationContact extends Controller {
Into:

Code: Select all

class ControllerInformationReachus extends Controller {
Change:

Code: Select all

$this->response->redirect($this->url->link('information/contact/success'));
Into:

Code: Select all

$this->response->redirect($this->url->link('information/reachus/success'));
Change:

Code: Select all

'href' => $this->url->link('information/contact')
Into:

Code: Select all

'href' => $this->url->link('information/reachus')
Change:

Code: Select all

$data['action'] = $this->url->link('information/contact', '', true);
Into:

Code: Select all

$data['action'] = $this->url->link('information/reachus', '', true);
Change:

Code: Select all

'href' => $this->url->link('information/contact')
Into:

Code: Select all

'href' => $this->url->link('information/reachus')
Save file as: catalog/information/controller/reachus.php
Delete catalog/information/controller/contact.php

Edit catalog/controller/common/footer.php
Change:

Code: Select all

$data['contact'] = $this->url->link('information/contact');
Into:

Code: Select all

$data['contact'] = $this->url->link('information/reachus');

User avatar
Active Member

Posts

Joined
Sat Jan 08, 2011 11:05 pm
Location - Netherlands

Post by supak111 » Thu Aug 08, 2019 4:18 pm

Do you believe chaining the route of the contact form would help with spam bots?

~ OC 3.0.3.2 and OCmods only ~


User avatar
Active Member

Posts

Joined
Fri Feb 13, 2015 12:09 pm

Post by pprmkr » Thu Aug 08, 2019 5:10 pm

All those probing ?route=information/contact will get error/not found.

User avatar
Active Member

Posts

Joined
Sat Jan 08, 2011 11:05 pm
Location - Netherlands

Post by johnp » Thu Aug 08, 2019 5:53 pm

I use this extension plus Crawlprotect and have no spam or hack problems:

https://www.opencart.com/index.php?rout ... earch=spam

Opencart 1.5.6.5/OC Bootstrap Pro/VQMOD lover, user and geek.
Affordable Service £££ - Opencart Installs, Fixing, Development and Upgrades
Plus Ecommerce, Marketing, Mailing List Management and More
FREE Guidance and Advice at https://www.ecommerce-help.co.uk


User avatar
Active Member

Posts

Joined
Fri Mar 25, 2011 10:25 am
Location - Surrey, UK

Post by reda » Wed Jul 21, 2021 4:51 pm

After trying multiple solutions, all not working like : google captcha, opencart captcha, some other opencart extensions (CSRF), neither could help, I was still receiving spams contact form and registration. So I developed a combination of extensions and now I completely satisfied: No more spams!

https://www.opencart.com/index.php?rout ... n_id=42395
https://www.opencart.com/index.php?rout ... n_id=34713

Cheers

Newbie

Posts

Joined
Tue Sep 13, 2011 1:14 pm
Who is online

Users browsing this forum: No registered users and 40 guests