WordPress.org

Ready to get started?Download WordPress

Forums

WP Calendar
[resolved] WP Calendar shortcodes (5 posts)

  1. scribe257
    Member
    Posted 3 years ago #

    Hi love the Calendar Plugin
    not a programmer so any help would be great
    want to output to a page the following
    posts that are in 2 different categories i'll try explaining
    i have 4 categories i use in the calendar and have with the help of others colour coded them
    some of the posts belong to 2 different categories and i want to show only the 2 that are in both i will try to gie example of what i want

    cat 1 10 posts with 3 in cat 4 as well
    cat 2 15 posts with 6 in cat 4 as well
    cat 3 12 posts with 7 in cat 4 as well

    when i use the {event_categories; exclude=x; sep=y} replacing the x with 3 should give me an output with cat4, cat2, cat 1 ( but doesnt)
    usng
    {events_print; categories=4;} give me the 17 outputs
    but using

    {events_print; categories=4; exclude=1,2;} should give me (by my thinking )
    only cat3 events that are in cat 4 as well (but it does not)

    ultimatly i wish a list in 2 parts like the following

  2. cat 1 posts in cat 4
  3. cat 2 posts in cat 4
  4. cat 3 posts in cat 4
  5. So someone please put me on the right track read all the help and dragged through the forums getting bit dishearted

    Please Help DSG

  • faebu
    Member
    Plugin Author

    Posted 3 years ago #

    The parameters include are only for event ids, but not for categories. There is no include/exclude mechanism for categories. All you can do is to explicitly include categories using the categorie parameter. If you specify more than one category, this will be queried using an OR condition.

    ultimatly i wish a list in 2 parts like the following
    # cat 1 posts in cat 4
    # cat 2 posts in cat 4
    # cat 3 posts in cat 4

    Therefore this is not possible using short codes. If you're programming PHP you could select the post ids from the database and then exlude the events you don't want.

    I think what you want is more a problem of your category design.

  • scribe257
    Member
    Posted 3 years ago #

    thank you for your quick reply
    as i am not a programmer i will have to give up on this particular part but it may be something you wish to add to future updates
    all i wanted to do was show all cat 4 in groups corisponding to the other categories they were in would be easier to navigate and view

    BUT THANKS FOR THE HELP
    will try to learn php

    This is the best plugin i use and has great potential for more

  • scribe257
    Member
    Posted 3 years ago #

    I really need some help with this dont care how it works as long as it does
    not got a clue about Mysql or Php

    As I said Need help

    I have reciently set up a website for a club i am a member of
    the site is for all the clubs in the same area
    I use the WP_CALENDAR for a list of meetings and have had help with bits of it

    But the Writer of the plugin says the output i what cant be done with the available commands

    Have looked at the MYPHPADMIN and found the entries for the plugin Below is the tables
    and Fields that i think will be required to give the desired output

    the following headers are in the 2 tables:-

    WP_FSEVENTS:-
    eventid
    subject
    tsfrom
    description

    WP_FSEVENTS_CATS:-
    catid
    eventid

    I have the following Categories which i wish to use:- 3,4,5,12

    Some of the events are in "2" caregories
    i would like to get an output that give me something like this:-

    Subject, tsfrom, description From category 12 but only if in 3
    12 but only if in 4
    12 but only if in 5

    The reson i wish this format is the categories 3,4,5 are all regular monthly or bymonthly events in my calendar
    but category 12 only happens once a year and is a visit to the events in the cat 3,4,5, so i wish to show these
    special visits in a page for each category

    If anyone can help i would be greatfull tried the forums and even tried mysql queries my self but just cant do it

  • faebu
    Member
    Plugin Author

    Posted 3 years ago #

    First of all: Please don't double post your request!

    You have to introduce more categories. What you need is imho very exotic and i think its more a conceptual problem of your categories.

    This is the only option you have, if you are not able to handle PHP and SQL. Even if the data modell is very simple (just these 2 tables), you have to consider, that more things have to be done (e.g. filters for output).

    Cheers!

  • Topic Closed

    This topic has been closed to new replies.

    About this Plugin

    About this Topic

    Tags