• Resolved kusalo

    (@kusalo)


    Event titles in month view can sit a bit flat and overly uniform. I could use ‘full calendar’ with BG color options but I would like to stay with EM.

    I would like to add a ‘bullet’ to ‘tagged’ event titles.
    eg. if I wirte a title as: “zz3 My Event Title” I can alter this in section-dates.php [line ~140] by preg_match testing

    $EM_Event->output( get_option('dbem_calendar_large_pill_format')

    for ‘zz’ and replace zz3 with a span-dot using array colour[3]

    This works just fine but doesn’t roll over for grid and list view.
    I hope the concept is clear.

    1 – Where to mod the title for grid and list view or…
    2 – can you suggest a cleaner way to implement this.

    Thank you.
    Kusalo

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter kusalo

    (@kusalo)

    My coding skills fail me and I can’t find direct access to title; pre-load. I played with the template: event_grid_item_format.php but tweaking the placeholder stumped me 🙁

    I see that the title – on event creation – will allow html. This reads cleanly in both grid and list view and can be tweaked in …/calendar/section-dates.php for month view. A bit of a lumpy hack but it will do for now.

    I am generally finding my way with EM and appreciating overall. Thank you.

    This post has been up a week now …
    I will come back in a few days and mark as ‘resolved’ – unless I find a cleaner solution.

    Thread Starter kusalo

    (@kusalo)

    This item has had a bit of time along the way; like fiddling with a loose tooth 🙂
    I am sure there is a cleaner way to do this but I went with adding html to the title on event creation (img above)

    <span class="akEventDot" style="background:#FF0000"></span> ...your title
    //this works fine for grid and list
    /* calendar view...
    .\templates\calendar\section-dates.php
    ~ line 100 – to allow for html encoding
    */ 	
    if (strstr($event_text,'/span')) { // we have a 'dot' situation
    $event_text = str_replace('&lt;','<',$event_text);
    $event_text = str_replace('&gt;','>',$event_text);
            // replace the html encoding
    $event_text = str_replace('&quot;','"',$event_text);
    		}
    //.......................
    // ~ line 160 –
    change title format to:
    $EM_Event->output(get_option('dbem_rss_title_format'));
    [ORIGinal: $EM_Event->output(get_option('dbem_calendar_large_pill_format'));]

    I defined two classes dot and box. Of course icons could be added but I am happy with giving simple distinction to selected events.

    I hope this might be of some use?
    thx – Kusalo

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘mod event title; all views’ is closed to new replies.