I’m building an eCommerce website for a local community, and they require a ‘post code’ form on the homepage.
Users are not able to see products until they enter their post code, and if it’s a post code matching the relevant areas, the product page is displayed. I have a .csv file with a list of 5k post codes, but unfortunately I can’t use Webflow to check the form entry against a database with the post codes without some added code.
Not sure if there’s a way to do this - I’m happy to integrate 3rd party platforms to achieve this functionality.
Using Webflow + Foxy. Not sure if I can embed some sort of 3rd party form that re-directs to my chosen page (‘Browse All Products’ page) if the post code matches one in my CSV.
Really need a post code/zip functionality (like Postmates) on the home!
It’s certainly a possibility, but not as elegant as a post code box (as long as the user matches one of the post codes in the csv file, they can receive any of the products).
Will reach out to Josh, although this isn’t really a Foxy issue - I’m currently trying to find a 3rd party solution that will allow do a ‘check’ on a post code - if it matches my .csv file, it’ll redirect to my-test-website.com/all-products
Hi @PChalk1.
I think you’re right in that this needs to happen before sending product data to Foxy. I haven’t tested this yet, but you may be able to use something like this: Edit fiddle - JSFiddle - Code Playground It will obviously need to be customized some but hopefully that will help get you headed in the right direction.
As always, please don’t hesitate to reach out if we can help with anything.
Thanks for the input @foxy - I’m certainly investigating jsfiddle. I have limited js knowledge so hopefully the Stackoverflow post will help.
Essentially I’d like the post code form to verify a post code against a list of post codes (which I have saved in a .csv), and then re-direct to my ‘browse products’ page.
jsfiddle could be the answer - looks like it reveals a div, but I’m sure I can add ‘redirect’ code if the input matches a post code.
Thanks for the link! Looks like the functionality of that is still different - seems to re-direct to a page with /enteredcontent rather than verifying a postcode/phrase against a database and then re-directing to the www.exampleurl.com/browse-all page.
Hi @PChalk1.
The example I linked to would allow you to compare the input value against any number of values and set the url for each result. If hitting against an actual file is the issue, it’s definitely possible, but will require technology outside of Webflow. Hope you find what you’re looking for.
Putting this out there since my client has been looking for something like this too - we set up and its working well so far: http://deliverychecker.co/ - If you’re ok with using a 3rd party app its a good option.