Making plugin unique to not conflict with plugins with the same name

Do you need the “View Details” link? It shouldn’t show up unless it’s a WP hosted plugin. Could you just name the plugin whatever you want, but change it with JS in the admin

function my_enqueue($hook) {
if ( 'plugins.php' != $hook ) {
    return;
}

wp_enqueue_script( 'my_custom_script', plugin_dir_url( __FILE__ ) . 'changeName.js', array( 'jquery' ), '1', true );
}
add_action( 'admin_enqueue_scripts', 'my_enqueue' );

Your changeName.js could look like this:

jQuery("#pluginId").html("Plugin Name the PM Likes");

Leave a Comment