When the Classipress WordPress theme arrived it was one of the best premium themes for creating classified ad websites. Unfortunately somewhere along the way the AppTheme developers seemingly gave up on it with updates generally just bug fixes rather than big steps forward in the functionality of the theme itself. And support typically only comes only from the community forum on the AppThemes website (you need an account to see responses to user questions).

One of the issues that really bugged me with the theme was that whatever parent categories you create they all appear in the dropdown select menu when a user submits a listing.

Now that’s fine for most sites, but for one client who wanted three of their categories to not appear in that selection menu it was a problem. For a long time I tried to figure out where the coding was to make this happen as it wasn’t a basic feature within the admin settings.

So, if you’re running Classipress Version: 3.5.4 here’s a heavy-handed hack to make that happen:

Locate the file called form-listing-category-select.php which you’ll find in /wp-content/themes/classipress/

Find the piece of code that looks like this:

<?php cp_dropdown_categories_prices(); ?>

And between the ( ) add this:


so it now looks like this:

<?php cp_dropdown_categories_prices(‘exclude=159,158,78’); ?>

N.B. You will need to replace the numbers I’ve inputted i.e. 159,158,78 with the category IDs you wish to exclude from the dropdown.

You can find your category IDs in the WordPress admin area:

Ads > Categories

Hover over a category name and in the bottom of the browser a URL will appear. The ID you want is listed something like this:

Work through these steps and upload your edited file, the categories you wish to exclude will no longer appear in the create listing dropdown menu.

Whenever the developers do update Classipress, this edit will be lost so be sure to keep a copy as a reference.

**UPDATE** – AppThemes released a few incremental updates to Classipress – 3.5.5, 3.5.6 & 3.5.7 – all in the space of a few weeks. However the ability to update the category dropdown still isn’t a core feature so for now the hack is still relevant. If you’re updating your theme, any changes you made previously will be lost so be sure to keep a backup file of the code and then place it into the new theme file.

N.B. Changing core files is never recommended – this is a hack!