Klassifieds for WooCommerce

Description

Klassifieds for WooCommerce imports the classified ads of a kleinanzeigen.de
account into your shop. Your ad becomes a WooCommerce product carrying its
title, description, price, images and location, and can be brought back in step
with its ad whenever you ask: prices follow, changed texts follow, and an ad that
has disappeared upstream is taken out of the catalogue instead of being sold on.

The only credential the plugin needs is the public account ID — the one that
appears in the account’s own kleinanzeigen.de URL. There is no login, no OAuth
and no password to store.

Products appear as soon as their text data has been read; their images follow
within a few minutes, fetched by a background job.

What it does

  • Imports ads as WooCommerce products of their own product type — a simple
    and a variable classified product, so ads with variants stay variable.
  • Brings products back in step with their ads when you start a sync from the
    plugin’s dashboard: new ads are created, changed ads are updated, and ads that
    have vanished upstream are deactivated and fall back to plain products rather
    than being deleted.
  • Restores a product automatically when its ad comes back.
  • Keeps the shop tidy: a product whose ad has been gone for more than 30 days
    is deleted, together with its images. This housekeeping is the “Cleanup
    regularly” setting on the Tools tab, on by default.
  • Maps ad content to your shop: category, label and keyword mapping is
    configured in the plugin’s settings.

Images are stored in your media library

Each ad image is downloaded once, as WebP, and stored in your media library like
an image you upload yourself, so your shop serves it from its own address. A
typical photo takes about 30 KB, plus the sizes WordPress makes of it.

A site can keep the images off its disk instead: tick “Show images from
kleinanzeigen.de instead of copying them” on the plugin’s General settings tab.
Its product pages then load every image from kleinanzeigen.de, so each visitor’s
browser sends kleinanzeigen.de the visitor’s IP address, their browser’s user
agent and your shop’s address. If you switch it on, say so in your privacy
policy. The klassifieds_hotlink_images filter overrides the setting.
Ticking it applies to images fetched from then on: the ones already stored stay
in your media library until their product is removed, which the “Cleanup
regularly” setting on the Tools tab (on by default) does once its ad has been
inactive for more than 30 days. Unticking it again stores the linked images in
the background, one product at a time; until a product’s turn comes, its images
still load from kleinanzeigen.de.

How the work is scheduled

Imports and syncs run in the background through WordPress’s own scheduler
(WP-Cron), which advances when your site receives traffic. On a shop that is
still quiet, that can be slow and irregular. There are two ways to make it
steady, neither of them required:

  • Set up a system cron for wp-cron.php — the usual approach for any WordPress
    site that cares about timing.
  • Or switch on the optional trigger service described below.

External services

This plugin contacts two third-party services. Both are called from your server,
never from a visitor’s browser, unless you switch on hotlinking (see “Images are
stored in your media library” above). One is required for the plugin to do
anything at all; the other is optional and switched off by default.

kleinanzeigen.de — the source of the ads and the reason the plugin exists.
The plugin requests the public account page and the public ad pages of the
account ID you enter, reads the ad data from them and downloads the ad images.
What is sent is the account ID and the ad IDs, as part of the URL of an ordinary
HTTP request; no data about your shop, your customers or your visitors is
transmitted.

Requests happen while an import or sync you started is running, and from the
background job that downloads the images of any product still missing them. Once
the items an import brought in are in the store — their text data and their
images alike — no further requests are made until you
manually trigger a sync from the plugin’s dashboard page.

Terms of use: https://themen.kleinanzeigen.de/nutzungsbedingungen/
Privacy policy: https://themen.kleinanzeigen.de/datenschutzerklaerung/

pinger.webpremiere.de — an optional trigger service run by the plugin
author, for shops whose own traffic is too thin to drive WordPress’s
scheduler reliably. It is switched off by default and nothing is sent unless you
turn it on under Klassifieds Settings.

When you switch it on, and then once a day while it is on, your server sends the
service one request. It carries your site address, the plugin version, whether
the free or the Pro edition is running, and a fixed token that marks the request
as coming from this plugin (the same in every copy, so it identifies nothing).
Like every web request, it also passes your server’s IP address, the time, and
the user agent WordPress sends, which names the WordPress version and your site
address. Beyond that, nothing is sent: no content of your shop or your ads, and
no data about your customers or your visitors.

The service then requests wp-cron.php on your site about once a minute, which
lets WordPress run its scheduled work on time. Those requests carry no data.

The service keeps one entry per site: the site address, the plugin version, the
edition and the time of the last registration. It does not keep the IP address.
The entry is deleted as soon as you switch the service off or deactivate the
plugin, and automatically once a site has not registered for four days. The
server’s access log, which records every request with its IP address, is
deleted after seven days. The plugin author sees the list of registered sites
in order to run the service; it is used for nothing else and passed on to no
one. The service runs on the author’s own server in Germany. To have your entry
removed, or to ask what is stored about your site, write to info@webpremiere.de.

The plugin works without it — imports and syncs simply advance whenever
WordPress’s own scheduler runs.

Terms: https://klassifieds.webpremiere.de/en/agb/
Privacy policy: https://klassifieds.webpremiere.de/en/datenschutz/

Source code and building

Two parts of the plugin are compiled, and their sources ship with it:

  • build/, the onboarding screen, is built from src/ with
    @wordpress/scripts.
  • admin/css/style-admin-klassifieds.css is built with Tailwind CSS from
    admin/css/style-admin-klassifieds-input.css, which imports
    the files in admin/css/parts/.

To rebuild them, run these in the plugin’s folder, with Node.js and npm installed:

  • npm install
  • npm run build rebuilds build/ from src/
  • npm run tw:build rebuilds admin/css/style-admin-klassifieds.css

The PHP libraries in vendor/ are installed with Composer, from composer.json
and composer.lock: composer install --no-dev --optimize-autoloader.

Klassifieds Pro

A paid add-on runs the synchronization unattended, so products follow their ads
without anyone starting a run, and adds a distributed sync worker, screenshots,
e-mail reports and discount pricing. It is not required and it unlocks nothing
here — everything described above works on its own.
See https://klassifieds.webpremiere.de

Screenshots

Installation

  1. Install and activate WooCommerce. Klassifieds for WooCommerce does not run without it.
  2. Upload the plugin to /wp-content/plugins/, or install it through the Plugins screen in WordPress.
  3. Activate the plugin through the Plugins screen.
  4. Open Klassifieds Settings, read and confirm the terms of use.
  5. Enter your kleinanzeigen.de account ID. The import starts by itself a few seconds later and runs in the background.

Requirements: WordPress 6.7 or newer, PHP 8.1 or newer, WooCommerce.

FAQ

Where do I find my account ID?

Open your kleinanzeigen.de profile page. The account ID is the number in that
page’s address. It is public — it is not a login and not a password.

To avoid typos, you can also enter the URL of any of your ad pages on
https://kleinanzeigen.de instead of the account ID. The plugin does the rest.

Does the plugin need my kleinanzeigen.de password?

No. The plugin reads public pages only and stores no credentials for
kleinanzeigen.de.

Why is my import going slowly?

Background work runs through WordPress’s scheduler, which only advances when
your site receives traffic. On a new shop with few visitors that can be slow and
irregular. Set up a system cron for wp-cron.php, or switch on the optional
trigger service under Klassifieds Settings.

Are the ad images copied into my media library?

Yes, by default, as WebP: a typical photo takes about 30 KB, plus the sizes
WordPress makes of it. To keep them off your disk, tick “Show images from
kleinanzeigen.de instead of copying them” on the General settings tab; your
visitors’ browsers then load them from kleinanzeigen.de (see “Images are stored
in your media library” above).

What happens when an ad is deleted on kleinanzeigen.de?

Its product is deactivated and falls back to a plain WooCommerce product. It is
not deleted, and its previous state is kept, so the product is restored if the
ad reappears. If the ad stays gone for more than 30 days, the “Cleanup
regularly” setting on the Tools tab (on by default) deletes the product for good.

Can I edit an imported product by hand?

Yes, but a later sync will bring the fields that come from the ad back in line
with the ad. Fields the plugin does not own — your own categories, labels and
the mapping you configured — are left alone.

What does the plugin remove when I uninstall it?

Its own database tables, options and scheduled events, and its folder under
wp-content/uploads/. Products created from ads stay in your shop as ordinary
WooCommerce products, and so do their ad data, the labels and the “specials”
and “rent” attributes. To remove those too, add this line to wp-config.php
before you delete the plugin:

define( 'KLASSIFIEDS_REMOVE_ALL_DATA', true );

The products themselves are never deleted.

Reviews

There are no reviews for this plugin.

Contributors & Developers

“Klassifieds for WooCommerce” is open source software. The following people have contributed to this plugin.

Contributors

“Klassifieds for WooCommerce” has been translated into 1 locale. Thank you to the translators for their contributions.

Translate “Klassifieds for WooCommerce” into your language.

Interested in development?

Browse the code, check out the SVN repository, or subscribe to the development log by RSS.

Changelog

0.9.217

  • New: a product that has no main category gets the categories its ad has on kleinanzeigen.de. A job works through such products every minute, as many as fit its time budget; each one loads its ad’s page once. The “Missing Main Category” count on the dashboard follows.
  • Fixed: the dashboard’s price and main category counts did not update when the job that settles them had finished; they showed the old number until the page was reloaded.
  • The menu icon is the new mark: the K in the disc.

0.9.216

  • New: an imported product is put into the main category kleinanzeigen.de lists for its ad and into its subcategories (Immobilien > Häuser zum Kauf). The categories are created with the product, in addition to your category keywords.
  • A recovered product gets them too, but only when its ad’s page has been loaded already: recovering does not fetch every ad again.
  • Klassifieds Pro: a “Categories” checkbox on the Sync tab (on by default) switches this off, and the sync gives a product that has no main category the categories that exist.

0.9.215

  • The plugin’s icon is the new mark: the violet disc with the drawn K. Only the icon changed; the code is the same as 0.9.214.

0.9.214

  • Fixed: on sites where another plugin puts its own Tailwind reset on every admin page (Astra Pro’s addon does), the setup wizard did not slide to its next step and the buttons of its first page did nothing.

0.9.213

  • New: a site without an account whose setup wizard was skipped shows a card with a link that opens the wizard again.
  • Fixed: after the account was removed, the dashboard’s summary kept its name and “Loading data…” until the page was reloaded. The dashboard renders again as soon as the account is gone.

0.9.212

  • New: a full-screen setup wizard replaces the old screen of a site without an account. It asks whether you have a PRO package, a few questions about your shop, the account ID and the terms of use, and waits while the import begins.
  • Fixed: an ad’s address or the app’s share text in the account ID field ended in a server error. The ID is read out of whatever was typed.
  • Fixed: on slow connections the checkboxes of the terms of use flickered while they were saved.
  • Changed: the progress bar of the installer stays readable over its dark bar.
  • Fixed: the wizard’s “Wait” step froze the page when the import began.
  • Fixed: after a cleanup some ads stayed active. The image job went on for minutes and saved products it had loaded before the cleanup deactivated them; it now checks the account and the product before each download and reloads the product before it saves.
  • Fixed: the dashboard now sees a cleanup from its start, so its summary no longer keeps the old account name.

0.9.211

  • Fixed: on the onboarding screen in the dark scheme, a checked box of the terms of use showed a white tick on a pale box. The tick is dark there now.
  • Changed: the dashboard starts in the light scheme. The switch in the header turns the dark scheme on and the browser remembers it.

0.9.210

  • Changed: special terms in the inline editor, such as “sale” and “rent”, look like the state counts on the dashboard: the state colour darkened until the text reads on it, and in the dark scheme a lighter, softly glowing edge. One variable, --klassifieds-state-ink, sets the text colour of all of them.

0.9.209

  • Changed: the installer screen keeps the offer to go Pro at the bottom, without a frame of its own, and the circle behind the percentage takes the palette’s line colour in both schemes.

0.9.208

  • Fixed: on the settings screen a checked checkbox showed no tick in the light scheme, so an option looked unchecked. WordPress 7.1 draws a white tick on a filled box, and the pale background hid it. Checked boxes are filled with the accent colour and the tick has the surface colour.

Older releases are listed in changelog.txt, which ships with the plugin.