Viewing 6 replies - 1 through 6 (of 6 total)
  • Thread Starter MakSider

    (@maksider)

    Also using [collabpress 31] or [collabpress id=31] (one per page) site hangs and I see not complete page. If use twice: … [collabpress] … [collabpress 31] – all projects are displayed twice in the post beginning.

    Thread Starter MakSider

    (@maksider)

    collabpress/includes/menus/dashboard.php on line 155
    required() some ‘…/content-.php’ file. Added
    if ( $cp->view != ” )
    into beginning of
    line 144 collabpress/includes/menus/dashboard.php
    (right before ‘cp_load_template( $template );’).
    Page with ‘[collabpress 31]’ or ‘[collabpress id=31]’ is now generated, but without 31-st project or any other one.

    Thread Starter MakSider

    (@maksider)

    Can anyone use IDs at all? How?

    I’ve read your post, but i serisously does not understand why you would use an id inside shortcode.
    This is a very bad way of thinking the developpement.
    This amazing plugin (not mine, i’m just an user like you), let you insert in a page, with a really simple shortcode, all the Collabpress system.
    So, why whould you have an id ? If you do this, you will need to create a new page for each new project .. There will be no more automatic process .. If you do this, you break the main functionnalities of this plugin.
    Maybe that you have a really good reason, that make you want to use id inside shortcode, but i’m pretty sure that there is a very better solution, in copying templates files to your theme folder, and then edit them. You can recreate or rewrite all the functions beeing called from there .. THIS IS how you have to modifiy the plugin.
    Else, you can also create a “sub-plugin”, which will ‘extends’ the collabpress plugin (work only if the plugin is written with classes (don’t remember this is the case here :p)
    If you’re not familiar with plugin or shortcode creation, i strongly recommened to change the way.

    Maybe that you should consider explaining why you want to use IDs in shortcodes, instead of modifying templates files.

    Cheers.

    Thread Starter MakSider

    (@maksider)

    This was the reason for my question.

    Well …. if you read the given function, you’ll see that the data ID is extracted, but not used in the function.

    I can read this:

    if ( cp_check_permissions( 'shortcode_user_role' ) ) {
        	cp_admin_menu_page_load();
        } else {

    But it should be something like this :

    if ( cp_check_permissions( 'shortcode_user_role' ) ) {
        	cp_admin_menu_page_load($atts);
        } else {

    It means that they created the shortcode, but they didnt activated yet.
    If you look at the cp_admin_menu_page_load function, you’ll see that nothing is written to check the current item ID, and then use it the template view.
    I think that this shortcode is in current developpement by the plugin team. You should wait before using it, or rewrite your own custom cp_admin_menu_page_load function ??

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘shortcode id usage’ is closed to new replies.