[wp-trac] [WordPress Trac] #60992: Plugin management: AJAX plugin activation consequences
WordPress Trac
noreply at wordpress.org
Tue Apr 16 11:10:45 UTC 2024
#60992: Plugin management: AJAX plugin activation consequences
--------------------------+------------------------------
Reporter: jeherve | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Plugins | Version: 6.5
Severity: normal | Resolution:
Keywords: | Focuses:
--------------------------+------------------------------
Comment (by jeherve):
Replying to [comment:10 justlevine]:
> With redirect hijacking aside, **we're now left with the justifiable
issue of guiding people to the next actionable step from the plugin
activation screen.**
Yes, I think it may be best to focus on that specific issue in this
ticket. As we can see from the discussion above, we could talk about many
different approaches to plugin onboarding / redirect hijacking / whatever
we may want to call it. I don't think that should be the main point of
this ticket though. The issue at hand is, **when you activate a plugin,
you no longer have any guidance as to what to do next.**
This is true regardless of the plugin, and whether that plugin needs
onboarding or not.
- If your plugin registers a CPT, the dedicated admin menu will not appear
until you refresh.
- If your plugin registers a settings page, that page will not be visible
or accessible until you refresh.
> A step up from this would be allowing users to provide an
`activation_success_message` that could be displayed on the screen. This
would also fill the gap caused by the lack of new links in the Admin
Menu/Bar
I'm afraid the current implementation will not allow us to do that, since
even if plugin authors were to hook into a potential new filter, that code
would not run until a page refresh.
> A simple, non-intrusive solve that's also forward-compatible with
whatever other reactive Admin UI updates would be changing the success
notices to add something along the lines of 'Go to your
<link>Dashboard</link> to see the changes'.
I wonder if it would be possible to have 2 different post-activation
behaviors based on the plugin's details:
- If the plugin has a declared dependency, keep the behavior introduced in
WordPress 6.5 ; site owners remain on the Plugin install screen and
install other plugins.
- If the plugin does not declare dependency, redirect site owners to the
Plugins screen like we did in WordPress 6.4 and earlier. This option would
offer a similar result to your proposal, except site owners would not have
to read and click to be redirected and thus refresh the screen.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/60992#comment:12>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list