Open mauglee opened 6 years ago
Good idea, I'll see if I can find a good place for it. Sounds like a use case for a meta-box:
https://developer.wordpress.org/reference/functions/add_meta_box/
As of users perspective it would be better if there is some configurator: user selects the track from drop-down list; checks/unchecks some „human readable“ checkboxes, etc. And gets shortcode generated. Which then can be copy-pasted in any WP post or page. I understand that it is about some (more) coding for you, but you know... This would make your plugin more user-friendly.
Yes, I agree, it would be a valuable addition, but like you said, that is more work and it needs some thought too.
For example, the idea of selecting a track from a drop-down list is not going to work. An admin has access to all users' tracks. In my database, that's already something like a thousand tracks... way too many for a drop-down.
But I agree, something clever can be built. I'll give it some thought. In the next version, it will probably be just a meta box with shortcode parameter documentation.
I recommend to create a new menu item next to Options, Manage tracks, Your profile. This new item could be named „Shortcode“ and all configuration possibilities should be described there in a new page. And later on if some more advanced configurator will be created, we already have a place for it :)
Look, I started a little play with shortcode configurator. At the moment my mockup looks like this: If I'll find some time during this weekend, I do some programming to make it real :)
I quickly made it by myself :) Also pull request submitted. So you can close current "issue" now.
In WP administration zone would be great to have some memo on shortcode. At the moment you must find explanation somewhere else (plugin page, github, etc..). Great plugin!