Making WordPress.org

Opened 8 months ago

Closed 8 months ago

Last modified 8 months ago

#7430 closed defect (bug) (fixed)

Plugin Categories should work with Tags

Reported by: dufresnesteven's profile dufresnesteven Owned by:
Milestone: Priority: normal
Component: Plugin Directory Keywords: has-patch
Cc:

Description

If you are browsing the directory using tags and apply a plugin taxonomy (ie: community), you lose the tag as a search filter.

How to Reproduce:

  1. Visit https://wordpress.org/plugins/tags/ecommerce/.
  2. Confirm you can see relevant "ecommerce" results.
  3. Click "Community".
  4. Notice you are no longer viewing "Community" plugins that relate to the "ecommerce" tag. You are simply viewing community plugins.

Change History (12)

This ticket was mentioned in PR #198 on WordPress/wordpress.org by @dd32.


8 months ago
#2

  • Keywords has-patch added

@dd32 commented on PR #198:


8 months ago
#3

On URLs such as this: https://wordpress.org/plugins/tags/ecommerce/?plugin_business_model=community the theme 404's.

We currently don't support empty archives, except for searches.

https://github.com/WordPress/wordpress.org/assets/767313/73263497-1d54-45ce-9b7d-aaf834831122

@dd32 commented on PR #198:


8 months ago
#4

The other option would be retaining the filter in the redirect from tags => search.

Personally I feel like the only way to make this actually "nice" is to remove the individual "archives" and instead move to a single "search archive with filters".

#5 @dd32
8 months ago

In 13190:

Plugin Directory: Enable the Community/Comercial filters on Search results.

See #2753, #7430.

@dd32 commented on PR #198:


8 months ago
#6

After talking with @StevenDufresne we came to the conclusion that:

  • A request for /tags/something/?model=community should return an empty result-set, and not redirect to search.
  • A request for /tags/no-plugins-in-this-tag/ should redirect to search. (As it currently does)

The above effectively does this, this is a bit more complicated than I'd have liked, as due to the way WordPress handles taxonomy archives, it needed some juggling.

https://github.com/WordPress/wordpress.org/assets/767313/ccdb16ca-daac-4d00-bdee-d092c9b1ee4a

#7 @dd32
8 months ago

In 13192:

Plugin Directory: Register plugin_tags and plugin_contributors taxonomies first.

This helps with template routing, as it ensures they're returned by get_queried_object() in preference to other taxonomies.

See #7430.

#8 @dd32
8 months ago

In 13194:

SEO: Canonical: Support basic multi-taxonomy queries.

This isn't perfect, and will definately have edge-cases.

See #7430.

#9 @dd32
8 months ago

In 13195:

Plugin Directory: Remoev the query_var for taxonomies which are internal and not intended on being queried.

This allows the SEO canonical code to avoid including it in the generated URL.

See #7430.

#10 @dd32
8 months ago

In 13196:

Plugin Directory: Allow tags to be filtered by taxonomies.

This adjusts the styles and templates to simplify the behaviour, allowing for an "empty" archive to be displayed.

Closes https://github.com/WordPress/wordpress.org/pull/198.
See #7430.

#11 @dd32
8 months ago

  • Resolution set to fixed
  • Status changed from new to closed

#12 @dd32
8 months ago

In 13221:

Plugin Directory: Register the plugin_tags taxonomy before plugin_category.

Followup to [13192].
See #7430.

Note: See TracTickets for help on using tickets.