WordPress.org

Ready to get started?Download WordPress

Forums

Invoice King Pro
[resolved] Possible way to make "default details" tab first (2 posts)

  1. cmwwebfx
    Member
    Posted 5 months ago #

    Hi Ash,

    Because this plugin will be used with different contractors I have displayed:none on some of the tabs as I don't want them fiddling with settings. For this setup I have only "default details" and "email settings" only showing for this setup.

    Question is:
    Is there a way I can have the settings show on launch the "default details" tab to be active on launch. If you can point me in the right direction I will change this on my end and see how it goes.

    Thanks for that,

    Ciaran

    http://wordpress.org/plugins/invoice-king-pro/

  2. Ash Durham
    Member
    Plugin Author

    Posted 5 months ago #

    Hey Ciaran,

    The easiest (and only real) way would be to move the 'active' class onto the tab and the container. You could write your own JS script to modify this and have the script load on the settings page. This would then ensure that you could still update the plugin with future releases.

    Something like:

    $(".invkp_tabs .invkp_invoice_settings").removeClass('active');
    $(".invkp_tabs .invkp_default_details").addClass('active');
    
    $("#invkp_invoice_settings").removeClass('active');
    $("#invkp_default_details").addClass('active');

    would do the job. Even:

    $(".invkp_tabs .invkp_default_details").trigger('click');

    should do what your after. Of course, if your happy to make those change via hardcoding them on the /includes/screens/settings.php file then that would work also.

    As I'm sure you would imagine, that isn't something that can or should be changed in the mainstream plugin release as its quite a particular function that is only suited to you so a personal fix for this is the only way to go ;)

    Give the above a go and let me know.

    Thanks

    Ash

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.