Bug fix and update rss feed.
authorSteve Sutton <steve@gaslightmedia.com>
Thu, 20 Jul 2017 14:06:31 +0000 (10:06 -0400)
committerSteve Sutton <steve@gaslightmedia.com>
Thu, 20 Jul 2017 14:06:31 +0000 (10:06 -0400)
Bug fix for the event name search.
Update rss feed with media:content for image and intro.

index.php
models/front/events/baseAction.php
models/front/events/rssFeed.php
readme.txt
views/front/events/rssFeed.xml

index 234c1c5..bf86c02 100644 (file)
--- a/index.php
+++ b/index.php
@@ -3,7 +3,7 @@
  * Plugin Name: GLM Members Database Events
  * Plugin URI: http://www.gaslightmedia.com/
  * Description: Gaslight Media Members Database.
- * Version: 1.6.52
+ * Version: 1.6.53
  * Author: Chuck Scott
  * Author URI: http://www.gaslightmedia.com/
  * License: GPL2
@@ -20,7 +20,7 @@
  * @package glmMembersDatabaseEventsAddOn
  * @author Chuck Scott <cscott@gaslightmedia.com>
  * @license http://www.gaslightmedia.com Gaslightmedia
- * @version 1.6.52
+ * @version 1.6.53
  */
 
 /*
@@ -38,7 +38,7 @@
  *  so that we're sure the other add-ons see an up to date
  *  version from this plugin.
  */
-define('GLM_MEMBERS_EVENTS_PLUGIN_VERSION', '1.6.52');
+define('GLM_MEMBERS_EVENTS_PLUGIN_VERSION', '1.6.53');
 define('GLM_MEMBERS_EVENTS_PLUGIN_DB_VERSION', '0.1.2');
 
 // This is the minimum version of the GLM Members DB plugin require for this plugin.
index 3f05263..9e094dc 100644 (file)
@@ -289,7 +289,7 @@ abstract class GlmMembersFront_events_baseAction extends GlmDataEvents
                     )
                 ";
             $order  = "T.id";
-            $order .= " LIMIT 2 OFFSET 0";
+            //$order .= " LIMIT 2 OFFSET 0";
         } else if ( $limit = filter_var( $limit, FILTER_VALIDATE_INT ) ) {
             // Need to get the event id's for the next $limit number of events.
             $whereParts[] .= "T.id
index fa367ef..8a17491 100644 (file)
@@ -66,13 +66,17 @@ class GlmMembersFront_events_rssFeed extends GlmMembersFront_events_baseAction
         $viewPath = GLM_MEMBERS_EVENTS_PLUGIN_PATH . '/views';
         $smarty->template->setTemplateDir($viewPath);
 
+        // Get the main event page
+        $eventListPageId = get_option('glm_members_database_option_event_list_id');
+
         $smarty->templateAssign('eventUrlBase', get_bloginfo('url') . '/event-detail/');
         $smarty->templateAssign('title', 'Events');
-        $smarty->templateAssign('link', 'main_event_page_url');
+        $smarty->templateAssign('link', get_permalink( $eventListPageId ) );
         $smarty->templateAssign('description', 'Calendar of Events');
         $smarty->templateAssign('pubDate', date('r'));
         $smarty->templateAssign('language', 'en-EN');
         $smarty->templateAssign('generator', 'Gaslight Media Event Feed Generator');
+        $smarty->templateAssign('imageUrlBase', GLM_MEMBERS_PLUGIN_MEDIA_URL .  '/images/medium/' );
 
         $smarty->templateAssign('items', $events);
 
index 19bc5a0..ee6064c 100644 (file)
@@ -25,6 +25,9 @@ e.g.
 1. Activate the plugin through the 'Plugins' menu in WordPress
 
 == Changelog ==
+= 1.6.53 =
+* Update rssFeed so it has event intro and media:content for images.
+
 = 1.6.52 =
 * fix for ical feed ORGANIZER line
 
index c16fcb5..063be92 100644 (file)
@@ -1,7 +1,8 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<rss 
+<rss
     xmlns:content="http://purl.org/rss/1.0/modules/content/"
     xmlns:glmEvent="http://www.gaslightmedia.com/rss"
+    xmlns:media="http://search.yahoo.com/mrss/"
     version="2.0">
     <channel>
         <title>
             <description>
                 <![CDATA[ {$item.descr} ]]>
             </description>
+            <glmEvent:intro>
+                <![CDATA[ {$item.intro} ]]>
+            </glmEvent:intro>
+            {if $item.image}
+            <media:content medium="image" url="{$imageUrlBase}{$item.image}"></media:content>
+            {/if}
             <pubDate>{$item.starting_timestamp|date_format:"%m/%d/%Y"}</pubDate>
             <glmEvent:startDay>
                 {$item.starting_timestamp|date_format:"%D"}