i4nd90
Forum Replies Created
-
Forum: Plugins
In reply to: [Event CLNDR] “No event listed”Hi there. You can define this in the options of the CLNDR instance like so (as seen in both the pre-packaged instances):
doneRendering: function() { var thisCLNDR = $(this)[0]["element"]; var thisMonthEvents = thisCLNDR.find(".event-item").length; if (thisMonthEvents == 0) { thisCLNDR.find(".event-listing").append( "<div style='text-align:center;' class='event-item'>No events listed</div>" ); } }
Ian
Forum: Plugins
In reply to: [Event CLNDR] Description Markup?I think simple BB code is a good idea for the description. I’ll implement and push an update in the next day or two.
Forum: Plugins
In reply to: [Newsletter - Send awesome emails from WordPress] Program errorsAgreed. I have warnings on while building a site. Most of us who have warnings on will know how to edit your code to get rid of them but it’s good practice to not have any warnings in the first place – they’re easy enough to avoid ??
Just came across the same. Found the answer here: https://www.thenewsletterplugin.com/plugins/newsletter/newsletter-documentation/subscription-form-shortcodes
The shortcode is [newsletter]
Forum: Plugins
In reply to: [Event CLNDR] Description Markup?Glad it’s of use to you ??
You can achieve what you’re after by adjusting the HTML template:
Taking the pre-packaged “Full size calendar” instance as an example, you would change this section of the code from
<% if (event.url) { %><a target="_blank" href="<%= event.url %>" <% } else { %><div <% } %> class="event-item"> <span class="event-item-date"> <% if (event.end != event.start) { startMY = moment(event.start).format("MM YY"); endMY = moment(event.end).format("MM YY"); if (startMY === endMY) { %> <%= moment(event.start).format("D") %>–<%= moment(event.end).format("D MMMM") %> <% } else { %> <%= moment(event.start).format("D MMMM") %> – <%= moment(event.end).format("D MMMM") %> <% } } else { %> <%= moment(event.start).format("D MMMM") %> <% } %> </span> <span class="event-item-name"><%= event.title %></span> <% if (event.time) { %> <span class="event-item-time"><%= event.time %></span> <% } %> <% if (event.desc) { %> <span class="event-item-desc"><%= event.desc %></span> <% } %> <% if (event.url) { %></a><% } else { %></div><% } %>
and replace it with
<div class="event-item"> <span class="event-item-date"> <% if (event.end != event.start) { startMY = moment(event.start).format("MM YY"); endMY = moment(event.end).format("MM YY"); if (startMY === endMY) { %> <%= moment(event.start).format("D") %>–<%= moment(event.end).format("D MMMM") %> <% } else { %> <%= moment(event.start).format("D MMMM") %> – <%= moment(event.end).format("D MMMM") %> <% } } else { %> <%= moment(event.start).format("D MMMM") %> <% } %> </span> <span class="event-item-name"><%= event.title %></span> <% if (event.time) { %> <span class="event-item-time"><%= event.time %></span> <% } %> <% if (event.desc) { %> <% if (event.url) { %><a target="_blank" href="<%= event.url %>"><% } %> <span class="event-item-desc"><%= event.desc %></span> <% if (event.url) { %></a><% } %> <% } %> </div>
Ian