Support » Plugin: Events Manager » Locations cat.

Viewing 14 replies - 1 through 14 (of 14 total)
  • Plugin Author Marcus

    (@netweblogic)

    NetWebLogic Support

    You’d probably need to code this out, because we don’t have location list placeholders, nor do we have shortcodes to list custom taxonomies you create yourself.

    Is it possible to write a function: “Locations Categories” similarly to “Events Categories” ?
    May you help or show how?

    Take a look at this, it should help you create a shortcode that does what you want:
    http://pastebin.com/UMipT093

    And where I can add categories of locations?
    How I can show this categories on my homepage?

    Maybe I misunderstood what you meant. If all you want to do is list events by category, you can use a event_list shortcode with a category attribute. Like this:

    [events_list category="1"]

    In this example, 1 is the ID of the category you want to show.

    You can use that shortcode on the homepage or any other page.

    yep You don’t understood me ):
    I would like put in order all my locations, but “locations” haven’t category and tag functions as like “events” has.
    It`s clear?

    Then you’d need to use the code I linked to originally, which allows you to create lists that combine locations with categories.

    If you want to add categories / tags directly to locations – rather than combine them with the existing categories – you need to look into creating a custom taxonomy for the custom post type ‘location’.

    If you want to add categories / tags directly to locations

    YEAP!

    look into creating a custom taxonomy for the custom post type ‘location’.

    I got no idea “how” ):
    Could you help me?
    I`m so sorry for my stupid questions but I just began to learn php programming language.
    I know, very well, HTML and CSS also I can write some functions, conditions on JS (jQuery) …

    angelo_nwl

    (@angelo_nwl)

    NetWebLogic Support

    I think you can modify the snippet above share by caimin. – http://pastebin.com/UMipT093

    I did it.

    // register taxonom
    add_action( ‘init’, ‘rmcc_create_taxonomies’, 0 );
    function rmcc_create_taxonomies() {
    // cats taxonomy
    $labels = array(
    ‘name’ => _x( ‘Cats’, ‘taxonomy general name’ ),
    ‘singular_name’ => _x( ‘Cat’, ‘taxonomy singular name’ ),
    ‘search_items’ => __( ‘Search Cat’ ),
    ‘all_items’ => __( ‘All Cat’ ),
    ‘parent_item’ => __( ‘Parent Cat’ ),
    ‘parent_item_colon’ => __( ‘Parent Cat:’ ),
    ‘edit_item’ => __( ‘Edit Cat’ ),
    ‘update_item’ => __( ‘Update Cat’ ),
    ‘add_new_item’ => __( ‘Add New Cat’ ),
    ‘new_item_name’ => __( ‘New Cat’ ),
    ‘menu_name’ => __( ‘Категории мест’ ),
    );
    register_taxonomy(
    ‘cats’,
    ‘event’,
    array(
    ‘hierarchical’ => true,
    ‘labels’ => $labels,
    ‘query_var’ => true,
    ‘rewrite’ => true,
    ‘show_admin_column’ => true
    )
    );
    }

    resolved!

    OH no ):
    Links such as MYSITE/cats/clubs don`t work
    Could You help me fix it?

    I mean I can create some other categories but links are broken

    // Custom Taxonomy Code
    add_action( 'init', 'build_taxonomies', 0 );
    function build_taxonomies() {
        register_taxonomy( 'cats', EM_POST_TYPE_EVENT, array( 'hierarchical' => true, 'label' => 'Categories', 'query_var' => true, 'rewrite' => true ) );
    }

    Have you tried re-saving your permalinks (Settings > Permalinks)?

    thnx 🙂

Viewing 14 replies - 1 through 14 (of 14 total)
  • The topic ‘Locations cat.’ is closed to new replies.