=== Voertuig Voorraad ===
Contributors: voertuigwp
Tags: hexon, car dealer, occasions, leads, inventory
Requires at least: 6.9
Tested up to: 7.1
Requires PHP: 8.1
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Hexon stock on your site and every enquiry in one lead inbox, for car dealers.

== Description ==

Voertuig Voorraad is the free plugin of VoertuigWP, for car dealers in the Netherlands and Belgium who publish their stock through Hexon. Hexon sends every vehicle to your WordPress site as soon as you add, change or sell it, and every enquiry from your site lands in one lead inbox.

What the plugin does:

* **Hexon import.** Your site receives the stock from Hexon Doorlinken Voorraad, with the photos in a background queue, a log of every push, and sold vehicles marked through the labels you use in Hexon.
* **Short link for Hexon.** A fixed address `/voertuig/<number>` for the field "URL pattern on dealer website" in Hexon, which forwards to the page of the vehicle.
* **Setup check.** Shows whether the first push came in, whether the labels and photos arrive, and which settings in Hexon need to be on.
* **Switching help.** The vehicle addresses of your previous Hexon plugin redirect to the new pages with a 301, so you keep your place in search engines.
* **Listing and vehicle pages.** A list and a detail page as blocks, as Elementor widgets and as shortcodes for Bricks, Divi and other builders, with templates your theme can override. It works with block themes and classic themes. The videos of a vehicle on YouTube or Vimeo show below the photos; the player loads only when the visitor clicks.
* **Contact form.** With the vehicle attached, spam protection, and a confirmation mail to the customer.
* **Lead inbox.** One list with filters on type, status and vehicle; statuses from new to sold or lost; notes; assigning a lead to a salesperson; a mail for every new lead; CSV export; and where each lead came from (UTM and source).
* **Connectors.** Leads from Contact Form 7, Gravity Forms and Elementor Forms go to the same inbox.
* **Modules page.** An overview of what VoertuigWP Pro and VoertuigWP Marketing add.

VoertuigWP works with every stock system that publishes through Hexon Doorlinken Voorraad, such as VWE Advertentiemanager, Autodata WheelerDelta, AutotelexPro, Mobilox, WinCar, DealerConnections and Vindat. Hexon keeps [the list of stock systems](https://www.hexon.nl/diensten/dv/softwareleveranciers/) it takes the stock from.

VoertuigWP Pro and VoertuigWP Marketing are separate, paid plugins that add modules, such as filters and search, trade-in, lease, test drive planning, WhatsApp click leads and social posts. This plugin works fully without them and contains no locked features.

== Installation ==

1. Install VoertuigWP from Plugins › Add New and activate it.
2. The setup wizard opens. Fill in your company: its name, address and e-mail show on your site and in the mails to customers.
3. In the step Hexon, the wizard shows the URL endpoint, the username and the password of your site. Enter these in Hexon, in the link (koppeling) to your website, and send a test push from Hexon. The wizard ticks off the push, the labels and the photos as they arrive.
4. Choose the listing page: an existing page, or let the wizard make one with the list block. The addresses of your vehicles start with the address of that page (by default `/aanbod/`).
5. Send a test mail, to see that mail from your site arrives.

Every step can be skipped and done later under VoertuigWP › Settings.

== Frequently Asked Questions ==

= Do I need a Hexon account? =

Yes. VoertuigWP receives your stock from Hexon Doorlinken Voorraad. Without Hexon, the lead inbox, the forms and the connectors still work, but there is no stock.

= Does it work with my stock system? =

Yes, if your stock system publishes through Hexon Doorlinken Voorraad, as some fifty do; see the list of Hexon in the description. If it does not, ask your supplier for a link with Hexon.

= Which settings do I need in Hexon? =

In the link to your website: the URL endpoint, the username and the password, and the other settings the plugin lists, such as "URL pattern on dealer website" (`https://<your site>/voertuig/[voertuignr_hexon]`) and "Send overlays seperate". They are in the setup wizard and under VoertuigWP › Settings, on the tab Hexon, each with a copy button. The checks on VoertuigWP › Status show whether the pushes, labels and photos come in.

= The mail of a new lead does not arrive =

WordPress sends mail through your hosting, and that mail often ends up in spam or is not sent at all. Install a plugin that sends mail through an SMTP service, such as WP Mail SMTP or FluentSMTP, and send a test mail from the setup wizard. Every lead is in the inbox, also when the mail did not arrive.

= I come from another Hexon plugin =

The switching help redirects the old addresses of your vehicles by itself, without a list from you. It recognises the addresses of Poslogic and Tussendoor, and any address that ends in the Hexon number of a vehicle. Keep the old plugin's posts in the database until search engines know the new addresses: the switching help reads them.

= Where is the personal data of a lead stored? =

In the plugin's own database tables on your site, and nowhere else: not in logs, addresses or error messages. Leads are part of the Export Personal Data and Erase Personal Data tools of WordPress. Uninstalling the plugin deletes your data only when you turn that on in the settings.

= Does it work on multisite? =

Yes, activated on each site separately; network-wide activation is refused. Every site has its own stock, leads and Hexon login.

== Screenshots ==

1. The lead inbox with a lead open: the vehicle, the status, the salesperson and the timeline.
2. The overview: the numbers of the day, the leads to pick up and the state of the Hexon link.
3. The listing page on the site, in a block theme.
4. A vehicle page with the photo gallery and the contact form.
5. The setup wizard at the step Hexon, with the details to enter in Hexon.
6. The lead inbox on a phone.
7. The push log on the Status page: every push from Hexon with its result.

== External services ==

VoertuigWP talks to the services below. It sends nothing to the maker of the plugin, and has no tracking.

= Hexon =

When you have entered the login of your site in Hexon, Hexon sends each vehicle to your site. A push lists the photos of the vehicle; your site then downloads those photos from the hosts of Hexon: `hexon.nl` and `export.dv.nl`, and their subdomains. Only the address of the photo is requested, from your server; no data about your visitors or leads is sent. Hexon is a service of Hexon BV: [terms](https://www.hexon.nl/algemene-voorwaarden), [privacy policy](https://www.hexon.nl/privacyverklaring).

= Captcha =

The forms of VoertuigWP can use a captcha. It is off by default; the site owner turns it on by choosing one of the services below and entering the keys of their own account. Only the chosen service is used.

When a visitor first touches a form, the browser loads the script of the service, which can see the visitor's IP address and browser details. When the form is sent, the site sends the answer of the captcha and the secret key to the service to check it. No other form data is sent.

* Cloudflare Turnstile, by Cloudflare, Inc., from `challenges.cloudflare.com`: [terms](https://www.cloudflare.com/website-terms/), [privacy policy](https://www.cloudflare.com/privacypolicy/).
* Google reCAPTCHA v2, by Google LLC, from `www.google.com`: [terms](https://policies.google.com/terms), [privacy policy](https://policies.google.com/privacy).
* hCaptcha, by Intuition Machines, Inc., from `js.hcaptcha.com` and `api.hcaptcha.com`: [terms](https://www.hcaptcha.com/terms), [privacy policy](https://www.hcaptcha.com/privacy).

= Videos =

When Hexon sends a video of a vehicle on YouTube or Vimeo, the vehicle page shows a link to it. The page loads nothing from YouTube or Vimeo, not even a preview image, until the visitor clicks the link. Then the browser loads the player of the service, which can see the visitor's IP address and browser details and may set cookies. The player comes from `youtube-nocookie.com` for YouTube and from `player.vimeo.com`, with Do Not Track on, for Vimeo. No data about your leads is sent.

* YouTube, by Google LLC: [terms](https://www.youtube.com/t/terms), [privacy policy](https://policies.google.com/privacy).
* Vimeo, by Vimeo.com, Inc.: [terms](https://vimeo.com/terms), [privacy policy](https://vimeo.com/privacy).

== Source code ==

The admin screens are a React app. Its source is in the plugin, in `admin/src/`; the built files are in `assets/admin/`. It is built with `@wordpress/scripts` 30.26.2:

`wp-scripts build admin/src/index.js --output-path=assets/admin`

The build bundles `@wordpress/dataviews` 10.1.7; React and the other WordPress packages come from WordPress itself. All other JavaScript and CSS in the plugin is written by hand and not minified.

== Changelog ==

= 1.0.0 =
* First release.
