<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Anything Access</title>
	<atom:link href="https://anythingaccess.com/feed/" rel="self" type="application/rss+xml" />
	<link>https://anythingaccess.com</link>
	<description>Business Automation</description>
	<lastBuildDate>Sun, 15 Feb 2026 13:19:12 +0000</lastBuildDate>
	<language>en-GB</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	

<image>
	<url>https://anythingaccess.com/wp-content/uploads/2025/01/cropped-Logo-White-32x32.png</url>
	<title>Anything Access</title>
	<link>https://anythingaccess.com</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Course Status</title>
		<link>https://anythingaccess.com/course-status/</link>
		
		<dc:creator><![CDATA[admin]]></dc:creator>
		<pubDate>Sun, 08 Feb 2026 12:21:55 +0000</pubDate>
				<category><![CDATA[Wordpress]]></category>
		<guid isPermaLink="false">https://anythingaccess.com/?p=1866</guid>

					<description><![CDATA[After integrating AI into my golf club&#8217;s website, I noticed a recurring question from users: &#8220;Is the course open today?&#8221; While we use BRS Golf to notify members of the course status, this system often misses visitors or members who have opted out of emails. To bridge this gap, I developed a simple Course Status [&#8230;]]]></description>
										<content:encoded><![CDATA[
<p>After integrating AI into my golf club&#8217;s website, I noticed a recurring question from users: &#8220;Is the course open today?&#8221;<br><br>While we use <a href="https://www.brsgolf.com/" target="_blank" rel="noopener">BRS Golf</a> to notify members of the course status, this system often misses visitors or members who have opted out of emails. To bridge this gap, I developed a simple Course Status plugin. It adds a clear status box to the homepage, displaying today’s conditions with the flexibility to set updates for future dates. If no status is entered the status will show Course Open.<br></p>



<figure class="wp-block-image size-full"><a href="https://tramoregolfclub.com" target="_blank" rel="noopener"><img fetchpriority="high" decoding="async" width="751" height="263" src="https://anythingaccess.com/wp-content/uploads/2026/02/image-1.png" alt="" class="wp-image-1868" srcset="https://anythingaccess.com/wp-content/uploads/2026/02/image-1.png 751w, https://anythingaccess.com/wp-content/uploads/2026/02/image-1-300x105.png 300w" sizes="(max-width: 751px) 100vw, 751px" /></a></figure>



<p>Want to implement this on your own site? You can find the full code and setup instructions below.</p>



<div style="height:30px" aria-hidden="true" class="wp-block-spacer"></div>



<h2 class="wp-block-heading has-upper-heading-font-size">Course Status php plugin</h2>



<pre class="wp-block-code"><code>&lt;?php
/**
 * Plugin Name: Golf Course Status Manager
 * Description: Allows logged-in users to set golf course status by date and display it via shortcode.
 * Version: 1.0
 * Author: Anything Access
 */

if (!defined('ABSPATH')) exit;

/**
 * Add admin menu
 */
add_action('admin_menu', function () {
    add_menu_page(
        'Golf Course Status',
        'Golf Course Status',
        'edit_posts',
        'golf-course-status',
        'gcs_admin_page',
        'dashicons-flag',
        26
    );
});

/**
 * Admin page UI
 */
function gcs_admin_page() {
    if (!current_user_can('edit_posts')) return;

    $statuses = get_option('gcs_statuses', &#91;]);

    if (isset($_POST&#91;'gcs_save'])) {
        check_admin_referer('gcs_save_status');

        $date   = sanitize_text_field($_POST&#91;'gcs_date']);
        $status = sanitize_text_field($_POST&#91;'gcs_status']);

        if ($status !== '') {
            $statuses&#91;$date] = $status;
        } else {
            unset($statuses&#91;$date]); // blank = assume open
        }

        update_option('gcs_statuses', $statuses);

        echo '&lt;div class="updated"&gt;&lt;p&gt;Status saved.&lt;/p&gt;&lt;/div&gt;';
    }

    $today = date('Y-m-d');
    ?&gt;

    &lt;div class="wrap"&gt;
        &lt;h1&gt;Golf Course Status&lt;/h1&gt;

        &lt;form method="post"&gt;
            &lt;?php wp_nonce_field('gcs_save_status'); ?&gt;

            &lt;table class="form-table"&gt;
                &lt;tr&gt;
                    &lt;th scope="row"&gt;Date&lt;/th&gt;
                    &lt;td&gt;
                        &lt;input type="date" name="gcs_date" value="&lt;?php echo esc_attr($today); ?&gt;" required&gt;
                    &lt;/td&gt;
                &lt;/tr&gt;
                &lt;tr&gt;
                    &lt;th scope="row"&gt;Status&lt;/th&gt;
                    &lt;td&gt;
                        &lt;input type="text"
                               name="gcs_status"
                               placeholder="e.g. Closed, Winter Greens"
                               style="width:320px;"&gt;
                        &lt;p class="description"&gt;
                            Leave blank to assume &lt;strong&gt;Course Open&lt;/strong&gt;
                        &lt;/p&gt;
                    &lt;/td&gt;
                &lt;/tr&gt;
            &lt;/table&gt;

            &lt;p&gt;
                &lt;button type="submit" name="gcs_save" class="button button-primary"&gt;
                    Save Status
                &lt;/button&gt;
            &lt;/p&gt;
        &lt;/form&gt;

        &lt;?php if (!empty($statuses)) : ?&gt;
            &lt;h2&gt;Existing Statuses&lt;/h2&gt;
            &lt;ul&gt;
                &lt;?php foreach ($statuses as $date =&gt; $status) : ?&gt;
                    &lt;li&gt;
                        &lt;strong&gt;&lt;?php echo esc_html($date); ?&gt;:&lt;/strong&gt;
                        &lt;?php echo esc_html($status); ?&gt;
                    &lt;/li&gt;
                &lt;?php endforeach; ?&gt;
            &lt;/ul&gt;
        &lt;?php endif; ?&gt;
    &lt;/div&gt;

    &lt;?php
}

/**
 * Shortcode output
 * Usage:
 * &#91;golf_course_status]
 * &#91;golf_course_status date="2026-02-12" color="#cc0000"]
 */
add_shortcode('golf_course_status', function ($atts) {

    $atts = shortcode_atts(&#91;
        'date'  =&gt; date('Y-m-d'),
        'color' =&gt; '#006400',
    ], $atts);

    $statuses = get_option('gcs_statuses', &#91;]);

    // Date formatting
    $date_obj = DateTime::createFromFormat('Y-m-d', $atts&#91;'date']);

    if ($date_obj) {
    $day_name  = $date_obj-&gt;format('D');   // Fri
    // 'j' = day without leading zero, 'S' = suffix (st, rd, th), 'M' = Month
    $nice_date = $date_obj-&gt;format('jS M'); // 7th Feb
} else {
    $day_name  = '';
    $nice_date = $atts&#91;'date'];
}

    // Determine output
    if (isset($statuses&#91;$atts&#91;'date']]) &amp;&amp; $statuses&#91;$atts&#91;'date']] !== '') {
    $output = $day_name . '  ' . $nice_date . ' ' . $statuses&#91;$atts&#91;'date']];
	} else {
    $output = $day_name . '  ' . $nice_date . ' Course Open';
}

    return sprintf(
        '&lt;span class="golf-course-status" style="color:%s;font-weight:bold;"&gt;%s&lt;/span&gt;',
        esc_attr($atts&#91;'color']),
        esc_html($output)
    );
});
/**
 * Front-end shortcode to update golf course status
 * Usage: &#91;golf_course_status_editor]
 */
add_shortcode('golf_course_status_editor', function () {

   $statuses = get_option('gcs_statuses', &#91;]);
    $today    = date('Y-m-d');
    $message  = '';

    if (isset($_POST&#91;'gcs_front_save'])) {
        check_admin_referer('gcs_front_save_status');

        $date   = sanitize_text_field($_POST&#91;'gcs_date']);
        $status = sanitize_text_field($_POST&#91;'gcs_status']);

        if ($status !== '') {
            $statuses&#91;$date] = $status;
        } else {
            unset($statuses&#91;$date]);
        }

        update_option('gcs_statuses', $statuses);
        $message = '&lt;p style="color:green;font-weight:bold;"&gt;Status updated.&lt;/p&gt;';
    }

    ob_start();
    ?&gt;
    &lt;form method="post" class="gcs-front-form"&gt;
        &lt;?php wp_nonce_field('gcs_front_save_status'); ?&gt;

        &lt;?php echo $message; ?&gt;

        &lt;p&gt;
            &lt;label&gt;
                &lt;strong&gt;Date&lt;/strong&gt;&lt;br&gt;
                &lt;input type="date" name="gcs_date" value="&lt;?php echo esc_attr($today); ?&gt;" required&gt;
            &lt;/label&gt;
        &lt;/p&gt;

        &lt;p&gt;
            &lt;label&gt;
                &lt;strong&gt;Status&lt;/strong&gt;&lt;br&gt;
                &lt;input type="text"
                       name="gcs_status"
                       placeholder="e.g. Closed, Winter Greens"
                       style="width:260px;"&gt;
            &lt;/label&gt;&lt;br&gt;
            &lt;small&gt;Leave blank to assume Course Open&lt;/small&gt;
        &lt;/p&gt;

        &lt;p&gt;
            &lt;button type="submit" name="gcs_front_save" class="button button-primary"&gt;
                Update Status
            &lt;/button&gt;
        &lt;/p&gt;
    &lt;/form&gt;
    &lt;?php

    return ob_get_clean();
});
</code></pre>



<p><a href="https://anythingaccess.com/posts-by-category/#wordpress" data-type="link" data-id="https://anythingaccess.com/posts-by-category/#wordpress">Wordpress Plugins</a></p>



<h2 class="wp-block-heading has-body-default-font-size">WP Fastest Cache ?</h2>



<p>If you use WP Fastest Cache you will notice that the front page does not refresh when you have updated the status. This is expected behaviour as the page is cached. You can add this function to the end of the plugin which will clear the Cache</p>



<pre class="wp-block-code"><code>function gcs_clear_cache() {
    if (class_exists('WpFastestCache')) {
        global $wp_fastest_cache;
        if (method_exists($wp_fastest_cache, 'deleteCache')) {
            $wp_fastest_cache->deleteCache(true);
        }
    }
}</code></pre>



<p>You will need to call this function from the update status</p>



<p>After this Line &#8220;update_option(&#8216;gcs_statuses&#8217;, $statuses);&#8221;<br>Add this line &#8220;gcs_clear_cache();&#8221;</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Logging AI Queries</title>
		<link>https://anythingaccess.com/logging-ai-queries/</link>
		
		<dc:creator><![CDATA[admin]]></dc:creator>
		<pubDate>Sun, 25 Jan 2026 14:09:59 +0000</pubDate>
				<category><![CDATA[ChatGPT]]></category>
		<category><![CDATA[Wordpress]]></category>
		<guid isPermaLink="false">https://anythingaccess.com/?p=1859</guid>

					<description><![CDATA[You need to implement a process for logging AI Queries. This will allow you to enhance your content or finetune the Vector Store to ensure you are generating responses for your customers. Using Open AI the system already logs the question and the response. If you have your own OpenAI account you will have the [&#8230;]]]></description>
										<content:encoded><![CDATA[
<p>You need to implement a process for logging AI Queries. This will allow you to enhance your content or finetune the Vector Store to ensure you are generating responses for your customers. Using Open AI the system already logs the question and the response. If you have your own <a href="https://openai.com/" target="_blank" rel="noopener">OpenAI</a> account you will have the option under dashboard to see the Logs</p>



<figure class="wp-block-image size-large"><img decoding="async" width="1024" height="406" src="https://anythingaccess.com/wp-content/uploads/2026/01/image-1-1024x406.png" alt="" class="wp-image-1860" srcset="https://anythingaccess.com/wp-content/uploads/2026/01/image-1-1024x406.png 1024w, https://anythingaccess.com/wp-content/uploads/2026/01/image-1-300x119.png 300w, https://anythingaccess.com/wp-content/uploads/2026/01/image-1-768x305.png 768w, https://anythingaccess.com/wp-content/uploads/2026/01/image-1.png 1114w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>



<p>If you have installed <a href="https://meowapps.com/ai-engine/" target="_blank" rel="noopener">AI Engine</a> for Wordpress you may have this configured for multiple customer accounts. You can use this plugin which logs the questions asked by your customers or visitors and the Admin of the Site can view these.</p>



<h2 class="wp-block-heading">Plugin for Logging AI Queries</h2>



<pre class="wp-block-code"><code>&lt;?php
/**
 * Plugin Name: Logging AI Queries (Admin + CSV)
 * Description: Logs AI Engine chatbot user questions into a custom DB table + admin viewer, CSV export, clear table.
 * Version: 1.1
 * Author: Anything Access
 * Author URI: https://anythingaccess.com
 */

if (!defined('ABSPATH')) exit;

define('MWAIQL_TABLE', 'mwai_questions');

/**
 * 1) Create table on activation
 */
register_activation_hook(__FILE__, function () {
  global $wpdb;
  $table = $wpdb->prefix . MWAIQL_TABLE;
  $charset_collate = $wpdb->get_charset_collate();

  require_once ABSPATH . 'wp-admin/includes/upgrade.php';

  $sql = "CREATE TABLE $table (
    id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT,
    created_at DATETIME NOT NULL,
    user_id BIGINT UNSIGNED NULL,
    chatbot_id VARCHAR(64) NULL,
    chat_id VARCHAR(128) NULL,
    page_url TEXT NULL,
    question LONGTEXT NOT NULL,
    PRIMARY KEY (id),
    KEY created_at (created_at),
    KEY user_id (user_id),
    KEY chatbot_id (chatbot_id)
  ) $charset_collate;";

  dbDelta($sql);
});

/**
 * 2) Log questions via AI Engine filter (best-effort)
 */
add_filter('mwai_ai_query', function ($query) {
  // Only log text chat messages
  if (!class_exists('Meow_MWAI_Query_Text') || !($query instanceof Meow_MWAI_Query_Text)) {
    return $query;
  }

  // Optional: only log chatbot scope (uncomment if you want to strictly log chatbot only)
  // if (!empty($query->scope) &amp;&amp; $query->scope !== 'chatbot') return $query;

  $question = method_exists($query, 'get_message') ? $query->get_message() : '';
  $question = is_string($question) ? trim($question) : '';

  if ($question === '') return $query;

  global $wpdb;
  $table = $wpdb->prefix . MWAIQL_TABLE;

  // Property names can vary; these are best-effort
  $chatbot_id = property_exists($query, 'botId') ? $query->botId : null;
  $chat_id    = property_exists($query, 'chatId') ? $query->chatId : null;

  $page_url = '';
  if (!empty($_SERVER&#91;'HTTP_HOST']) &amp;&amp; !empty($_SERVER&#91;'REQUEST_URI'])) {
    $page_url = (is_ssl() ? 'https://' : 'http://') . $_SERVER&#91;'HTTP_HOST'] . $_SERVER&#91;'REQUEST_URI'];
  }

  $wpdb->insert(
    $table,
    &#91;
      'created_at' => current_time('mysql'),
      'user_id'    => get_current_user_id() ?: null,
      'chatbot_id' => $chatbot_id ? (string)$chatbot_id : null,
      'chat_id'    => $chat_id ? (string)$chat_id : null,
      'page_url'   => $page_url ?: null,
      'question'   => $question,
    ],
    &#91;'%s','%d','%s','%s','%s','%s']
  );

  return $query;
}, 10, 1);

/**
 * 3) Admin menu
 */
add_action('admin_menu', function () {
  add_menu_page(
    'AI Queries',
    'AI Queries',
    'manage_options',
    'mwai-queries',
    'mwaiql_render_admin_page',
    'dashicons-format-chat',
    58
  );
});

/**
 * 4) Admin page renderer
 */
function mwaiql_render_admin_page() {
  if (!current_user_can('manage_options')) {
    wp_die('You do not have permission to access this page.');
  }

  global $wpdb;
  $table = $wpdb->prefix . MWAIQL_TABLE;

  // Pagination
  $per_page = 50;
  $paged = isset($_GET&#91;'paged']) ? max(1, intval($_GET&#91;'paged'])) : 1;
  $offset = ($paged - 1) * $per_page;

  $total = (int) $wpdb->get_var("SELECT COUNT(*) FROM $table");
  $rows  = $wpdb->get_results($wpdb->prepare(
    "SELECT * FROM $table ORDER BY created_at DESC, id DESC LIMIT %d OFFSET %d",
    $per_page,
    $offset
  ));

  $total_pages = max(1, (int) ceil($total / $per_page));

  // Action URLs
  $export_url = wp_nonce_url(
    admin_url('admin-post.php?action=mwaiql_export_csv'),
    'mwaiql_export_csv'
  );

  $clear_url = wp_nonce_url(
    admin_url('admin-post.php?action=mwaiql_clear_table'),
    'mwaiql_clear_table'
  );

  $msg = '';
  if (!empty($_GET&#91;'mwaiql_msg'])) {
    $msg = sanitize_text_field($_GET&#91;'mwaiql_msg']);
  }

  echo '&lt;div class="wrap">';
  echo '&lt;h1>AI Queries&lt;/h1>';

  if ($msg) {
    echo '&lt;div class="notice notice-success is-dismissible">&lt;p>' . esc_html($msg) . '&lt;/p>&lt;/div>';
  }

  echo '&lt;p style="display:flex; gap:10px; align-items:center;">';
  echo '&lt;a class="button button-primary" href="' . esc_url($export_url) . '">Export CSV&lt;/a>';
  echo '&lt;a class="button button-secondary" href="' . esc_url($clear_url) . '" onclick="return confirm(\'Really clear ALL logged AI questions?\');">Clear Table&lt;/a>';
  echo '&lt;span style="margin-left:auto;">Total: &lt;strong>' . number_format_i18n($total) . '&lt;/strong>&lt;/span>';
  echo '&lt;/p>';

  echo '&lt;table class="widefat fixed striped" style="margin-top:10px;">';
  echo '&lt;thead>&lt;tr>';
  echo '&lt;th style="width:70px;">ID&lt;/th>';
  echo '&lt;th style="width:160px;">Date&lt;/th>';
  echo '&lt;th style="width:90px;">User ID&lt;/th>';
  echo '&lt;th style="width:110px;">Chatbot&lt;/th>';
  echo '&lt;th>Question&lt;/th>';
  echo '&lt;th style="width:28%;">Page URL&lt;/th>';
  echo '&lt;/tr>&lt;/thead>&lt;tbody>';

  if (empty($rows)) {
    echo '&lt;tr>&lt;td colspan="6">No queries logged yet.&lt;/td>&lt;/tr>';
  } else {
    foreach ($rows as $r) {
      $url = !empty($r->page_url) ? esc_url($r->page_url) : '';
      $q   = !empty($r->question) ? $r->question : '';
      $q_short = mb_strlen($q) > 300 ? (mb_substr($q, 0, 300) . '…') : $q;

      echo '&lt;tr>';
      echo '&lt;td>' . esc_html($r->id) . '&lt;/td>';
      echo '&lt;td>' . esc_html($r->created_at) . '&lt;/td>';
      echo '&lt;td>' . esc_html($r->user_id ?? '') . '&lt;/td>';
      echo '&lt;td>' . esc_html($r->chatbot_id ?? '') . '&lt;/td>';
      echo '&lt;td title="' . esc_attr($q) . '">' . esc_html($q_short) . '&lt;/td>';
      echo '&lt;td>';
      if ($url) {
        echo '&lt;a href="' . $url . '" target="_blank" rel="noopener noreferrer">' . esc_html($r->page_url) . '&lt;/a>';
      }
      echo '&lt;/td>';
      echo '&lt;/tr>';
    }
  }

  echo '&lt;/tbody>&lt;/table>';

  // Pagination links
  if ($total_pages > 1) {
    $base_url = remove_query_arg(&#91;'paged','mwaiql_msg'], menu_page_url('mwai-queries', false));
    echo '&lt;div style="margin-top:12px;">';
    echo paginate_links(&#91;
      'base'      => add_query_arg('paged', '%#%', $base_url),
      'format'    => '',
      'prev_text' => '« Prev',
      'next_text' => 'Next »',
      'total'     => $total_pages,
      'current'   => $paged,
    ]);
    echo '&lt;/div>';
  }

  echo '&lt;/div>';
}

/**
 * 5) Export CSV handler
 */
add_action('admin_post_mwaiql_export_csv', function () {
  if (!current_user_can('manage_options')) {
    wp_die('Forbidden');
  }
  check_admin_referer('mwaiql_export_csv');

  global $wpdb;
  $table = $wpdb->prefix . MWAIQL_TABLE;

  $rows = $wpdb->get_results("SELECT id, created_at, user_id, chatbot_id, chat_id, page_url, question FROM $table ORDER BY created_at DESC, id DESC", ARRAY_A);

  nocache_headers();
  header('Content-Type: text/csv; charset=utf-8');
  header('Content-Disposition: attachment; filename="ai-queries-' . gmdate('Y-m-d') . '.csv"');

  $out = fopen('php://output', 'w');

  // UTF-8 BOM for Excel compatibility
  fprintf($out, chr(0xEF).chr(0xBB).chr(0xBF));

  fputcsv($out, &#91;'id','created_at','user_id','chatbot_id','chat_id','page_url','question']);

  foreach ($rows as $r) {
    // Ensure newlines don't break CSV rows (fputcsv handles it, but normalize anyway)
    $r&#91;'question'] = is_string($r&#91;'question']) ? str_replace(&#91;"\r\n","\r"], &#91;"\n","\n"], $r&#91;'question']) : $r&#91;'question'];
    fputcsv($out, $r);
  }

  fclose($out);
  exit;
});

/**
 * 6) Clear table handler
 */
add_action('admin_post_mwaiql_clear_table', function () {
  if (!current_user_can('manage_options')) {
    wp_die('Forbidden');
  }
  check_admin_referer('mwaiql_clear_table');

  global $wpdb;
  $table = $wpdb->prefix . MWAIQL_TABLE;

  // Fast clear
  $wpdb->query("TRUNCATE TABLE $table");

  $redirect = add_query_arg(
    &#91;'page' => 'mwai-queries', 'mwaiql_msg' => rawurlencode('Table cleared.')],
    admin_url('admin.php')
  );
  wp_safe_redirect($redirect);
  exit;
});
</code></pre>



<p>Related Content to Logging AI Queries  <a href="https://anythingaccess.com/using-ai-in-your-business/">https://anythingaccess.com/using-ai-in-your-business/</a></p>



<p>Read other  <a href="https://anythingaccess.com/posts-by-category/#wordpress">wordpress</a> Plugin posts</p>



<p></p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Using AI in your Business</title>
		<link>https://anythingaccess.com/using-ai-in-your-business/</link>
		
		<dc:creator><![CDATA[admin]]></dc:creator>
		<pubDate>Mon, 19 Jan 2026 20:07:28 +0000</pubDate>
				<category><![CDATA[ChatGPT]]></category>
		<category><![CDATA[Wordpress]]></category>
		<guid isPermaLink="false">https://anythingaccess.com/?p=1853</guid>

					<description><![CDATA[Building your own AI Model I’ve been working with OpenAI and AI Engine for WordPress to create an AI assistant that answers questions using only our own content. That content includes: Technical manuals, Internal PDFs and Website and help materialThe important part is trust, the AI cannot pull answers from the internet or make things up.Every [&#8230;]]]></description>
										<content:encoded><![CDATA[
<p><strong>Building your own AI Model</strong><br><br>I’ve been working with OpenAI and AI Engine for WordPress to create an AI assistant that answers questions using only our own content. That content includes: Technical manuals, Internal PDFs and Website and help material<br>The important part is trust, the AI cannot pull answers from the internet or make things up.<br>Every response is grounded in documentation we already own and control.<br><br>This changes how documentation gets used.<br>Instead of:<br>– Searching through PDFs<br>– Guessing which version is correct<br>– Re-answering the same support questions<br>You can simply ask a question and get a consistent, approved answer.<br><br>How long does something like this take? For a typical business with organised documentation:<br>– Initial setup: a few hours<br>– Content loading and testing: 1–2 days<br>– Refinement and tuning: ongoing, but incremental<br><br>This is something you can implement on your site quickly or house internally behind a user login to allow internal staff to provide answers to customer queries consistently. I’m documenting the setup steps and the real costs involved — including OpenAI usage, hosting I am also working on a WordPress plugin to record what the users are asking to ensure that users get a quality response. Drop me an email if you would like more information.</p>



<figure class="wp-block-image size-large"><img decoding="async" width="1024" height="372" src="https://anythingaccess.com/wp-content/uploads/2026/01/image-1024x372.png" alt="Using AI in your Business" class="wp-image-1854" srcset="https://anythingaccess.com/wp-content/uploads/2026/01/image-1024x372.png 1024w, https://anythingaccess.com/wp-content/uploads/2026/01/image-300x109.png 300w, https://anythingaccess.com/wp-content/uploads/2026/01/image-768x279.png 768w, https://anythingaccess.com/wp-content/uploads/2026/01/image.png 1274w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>



<p>#Ai-Engine #Openai</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Alice in Wonderland</title>
		<link>https://anythingaccess.com/alice-in-wonderland/</link>
		
		<dc:creator><![CDATA[admin]]></dc:creator>
		<pubDate>Sat, 20 Dec 2025 13:47:36 +0000</pubDate>
				<category><![CDATA[ChatGPT]]></category>
		<category><![CDATA[Wordpress]]></category>
		<guid isPermaLink="false">https://anythingaccess.com/?p=1758</guid>

					<description><![CDATA[I have recently started to use AI on this site and restricted it to the content of my blog posts or pages. IF you navigate to home you can test out my AI. As a test I have created a new bot and used loaded the text from Lewis Carroll which are public-domain works. I [&#8230;]]]></description>
										<content:encoded><![CDATA[
<p>I have recently started to use AI on this site and restricted it to the content of my blog posts or pages. IF you navigate to home you can test out my AI.</p>



<p>As a test I have created a new bot and used loaded the text from Lewis Carroll which are public-domain works. I have edited some of the content to test if the AI will find the answers from the text.</p>



<p>These are instructions i gave AI</p>



<pre class="wp-block-code"><code>You are a documentation-only assistant.

You MUST answer using ONLY the content provided in the retrieved context
from the vector store.

You are NOT allowed to:
- Use general world knowledge
- Use prior training data
- Make assumptions or inferences beyond the retrieved content
- Fill in missing information

If the retrieved context does NOT contain the answer, you MUST respond
with EXACTLY the following sentence and nothing else:

"I don’t have that information in the available documentation."

When an answer IS provided:
- Quote or paraphrase only from the retrieved context
- Do NOT add explanations beyond what is explicitly stated
</code></pre>


<div class='mwai-chatbot-container' data-params='{&quot;aiName&quot;:&quot;Alice&quot;,&quot;userName&quot;:&quot;User: &quot;,&quot;guestName&quot;:&quot;Guest:&quot;,&quot;aiAvatar&quot;:true,&quot;aiAvatarUrl&quot;:&quot;avatar-woman-indian.svg&quot;,&quot;textSend&quot;:&quot;Send&quot;,&quot;textClear&quot;:&quot;Clear&quot;,&quot;imageUpload&quot;:false,&quot;fileUpload&quot;:false,&quot;multiUpload&quot;:false,&quot;maxUploads&quot;:1,&quot;fileUploads&quot;:0,&quot;mode&quot;:&quot;chat&quot;,&quot;textInputPlaceholder&quot;:&quot;Type your message...&quot;,&quot;textInputMaxLength&quot;:512,&quot;textCompliance&quot;:&quot;&quot;,&quot;startSentence&quot;:&quot;Hi! Tell me what you would like to know about Alice in Wonderland &quot;,&quot;localMemory&quot;:true,&quot;themeId&quot;:&quot;chatgpt&quot;,&quot;window&quot;:false,&quot;icon&quot;:&quot;&quot;,&quot;iconText&quot;:&quot;&quot;,&quot;iconTextDelay&quot;:1,&quot;iconAlt&quot;:&quot;AI Engine Chatbot&quot;,&quot;iconPosition&quot;:&quot;bottom-right&quot;,&quot;centerOpen&quot;:false,&quot;width&quot;:&quot;&quot;,&quot;openDelay&quot;:&quot;&quot;,&quot;iconBubble&quot;:false,&quot;windowAnimation&quot;:&quot;zoom&quot;,&quot;fullscreen&quot;:false,&quot;copyButton&quot;:false,&quot;headerSubtitle&quot;:&quot;Discuss with&quot;,&quot;containerType&quot;:&quot;standard&quot;,&quot;headerType&quot;:&quot;standard&quot;,&quot;messagesType&quot;:&quot;standard&quot;,&quot;inputType&quot;:&quot;standard&quot;,&quot;footerType&quot;:&quot;standard&quot;}' data-system='{&quot;botId&quot;:&quot;chatbot-bvpz0k&quot;,&quot;customId&quot;:null,&quot;userData&quot;:null,&quot;sessionId&quot;:&quot;6992ac95228a0&quot;,&quot;restNonce&quot;:null,&quot;contextId&quot;:1758,&quot;pluginUrl&quot;:&quot;https:\/\/anythingaccess.com\/wp-content\/plugins\/ai-engine-pro\/&quot;,&quot;restUrl&quot;:&quot;https:\/\/anythingaccess.com\/wp-json&quot;,&quot;stream&quot;:true,&quot;debugMode&quot;:false,&quot;eventLogs&quot;:false,&quot;speech_recognition&quot;:false,&quot;speech_synthesis&quot;:false,&quot;typewriter&quot;:false,&quot;crossSite&quot;:false,&quot;actions&quot;:[],&quot;blocks&quot;:[],&quot;shortcuts&quot;:[]}' data-theme='{&quot;type&quot;:&quot;internal&quot;,&quot;name&quot;:&quot;ChatGPT&quot;,&quot;themeId&quot;:&quot;chatgpt&quot;,&quot;settings&quot;:[],&quot;style&quot;:&quot;&quot;,&quot;cssUrl&quot;:&quot;https:\/\/anythingaccess.com\/wp-content\/plugins\/ai-engine-pro\/themes\/chatgpt.css&quot;}'></div>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Auto Creating Continuous List forms</title>
		<link>https://anythingaccess.com/auto-creating-continuous-list-forms/</link>
		
		<dc:creator><![CDATA[Pat]]></dc:creator>
		<pubDate>Thu, 04 Sep 2025 21:18:00 +0000</pubDate>
				<category><![CDATA[Access]]></category>
		<category><![CDATA[Access VBA]]></category>
		<guid isPermaLink="false">https://anythingaccess.com/?p=1670</guid>

					<description><![CDATA[Often when analysing data , I import the data into access and use this code to make a list forms from the tables in my access database. The code will read all the fields from the tables and allow a user to set focus fields in the table. These focus fields are given an order [&#8230;]]]></description>
										<content:encoded><![CDATA[
<p>Often when analysing data , I import the data into access and  use this code to make a list forms from the tables in my access database. The code will read all the fields from the tables and allow a user to set focus fields in the table. These focus fields are given an order and then used in the wildcard search of the table.</p>



<p>Coupled with the code I use to make record forms which allow the user to view a complete record on a page. User can edit or review the content of the data quickly. It also allows the users to update the table structure and recreate the forms without referring to any development resource.</p>



<p>I will post the code for the Record Form in the next post</p>



<h2 class="wp-block-heading">VBA Function to Make List Forms</h2>



<pre class="wp-block-code"><code>Public Sub GenerateListForm(TableName As String, Optional BackgroundColor As Long = 16777164)
'Auto creates list forms
    Const FORM_WIDTH_TWIPS As Long = 31680
    Const CHAR_TO_TWIPS As Long = 120
    Const MIN_CHARS As Long = 10
    Const MAX_CHARS As Long = 150

    Dim db As DAO.Database
    Dim rsMeta As DAO.Recordset
    Dim frm As Form
    Dim newFormName As String
    Dim leftPos As Long, fieldWidth As Long
    Dim fieldName As String, maxLen As Long
    Dim label As Control, textbox As Control
    Dim whereParts As Collection, searchSQL As String

    On Error GoTo ErrHandler

    Set db = CurrentDb()
    Set rsMeta = db.OpenRecordset("SELECT * FROM tblFieldDefs WHERE TableName='" &amp; TableName &amp; "' ORDER BY FieldOrder")

    If rsMeta.EOF Then
        MsgBox "No metadata found for table '" &amp; TableName &amp; "'", vbExclamation
        Exit Sub
    End If

    ' Prepare form
    newFormName = "frm" &amp; TableName
    DoCmd.CopyObject , newFormName, acForm, "frmListNew"
    DoCmd.OpenForm newFormName, acDesign
    Set frm = Forms(newFormName)

    Set whereParts = New Collection
    leftPos = 100

    Do While Not rsMeta.EOF
        fieldName = rsMeta!FieldName
        maxLen = GetMaxFieldLength(TableName, fieldName)

        If maxLen &lt; MIN_CHARS Then maxLen = MIN_CHARS
        If maxLen &gt; MAX_CHARS Then maxLen = MAX_CHARS

        fieldWidth = maxLen * CHAR_TO_TWIPS

        ' Check if control fits on form
        If leftPos + fieldWidth &gt; FORM_WIDTH_TWIPS Then
            MsgBox "Field '" &amp; fieldName &amp; "' skipped – not enough room on form.", vbInformation
            rsMeta.MoveNext
            Continue Do
        End If

        ' Create label
        Set label = CreateControl(frm.Name, acLabel, acHeader, , , leftPos, 100, fieldWidth, 300)
        label.Caption = fieldName
        label.FontName = "Segoe UI Semibold"
        label.FontSize = 9
        label.ControlTipText = Nz(rsMeta!Description, "")

        ' Create textbox
        Set textbox = CreateControl(frm.Name, acTextBox, acDetail, , fieldName, leftPos, 0, fieldWidth, 300)
        textbox.Name = "txt" &amp; fieldName
        textbox.ControlSource = fieldName
        textbox.FontName = "Segoe UI"
        textbox.FontSize = 9
        textbox.BackColor = BackgroundColor

        ' Add to search clause if marked focus
        If rsMeta!Focus = True Then
            whereParts.Add "&#91;" &amp; fieldName &amp; "] LIKE '*' &amp; Forms!" &amp; newFormName &amp; "!txtSearch &amp; '*'"
        End If

        leftPos = leftPos + fieldWidth
        rsMeta.MoveNext
    Loop

    ' Build RecordSource
    searchSQL = "SELECT * FROM &#91;" &amp; TableName &amp; "]"
    If whereParts.Count &gt; 0 Then
        Dim part As Variant, condition As String
        For Each part In whereParts
            condition = condition &amp; part &amp; " OR "
        Next
        condition = Left(condition, Len(condition) - 4)
        searchSQL = searchSQL &amp; " WHERE " &amp; condition
    End If

    frm.RecordSource = searchSQL

    DoCmd.Close acForm, newFormName, acSaveYes
    DoCmd.OpenForm newFormName, acNormal
    Exit Sub

ErrHandler:
    MsgBox "Error: " &amp; Err.Description, vbCritical
End Sub

Private Function GetMaxFieldLength(tbl As String, fld As String) As Long
    Dim rs As DAO.Recordset
    On Error GoTo Fail
    Set rs = CurrentDb.OpenRecordset("SELECT MAX(LEN(&#91;" &amp; fld &amp; "])) AS MaxLen FROM &#91;" &amp; tbl &amp; "]")
    If Not rs.EOF Then
        GetMaxFieldLength = Nz(rs!MaxLen, 0)
    Else
        GetMaxFieldLength = 0
    End If
    rs.Close
    Exit Function
Fail:
    GetMaxFieldLength = 0
End Function</code></pre>



<p>Other Access <a href="https://anythingaccess.com/posts-by-category/#access" data-type="link" data-id="https://anythingaccess.com/posts-by-category/#access">Posts</a></p>



<p></p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>List of all fields in an Access Database</title>
		<link>https://anythingaccess.com/list-of-all-fields-in-an-access-database/</link>
		
		<dc:creator><![CDATA[Pat]]></dc:creator>
		<pubDate>Wed, 03 Sep 2025 21:35:00 +0000</pubDate>
				<category><![CDATA[Access]]></category>
		<guid isPermaLink="false">https://anythingaccess.com/?p=1674</guid>

					<description><![CDATA[I use this code to make a table which lists all the tables in an access database with the field names. I used this table as the source for making both Record and List form views. Details of the code for these other forms are listing in later posts VBA Function ; list of all [&#8230;]]]></description>
										<content:encoded><![CDATA[
<p>I use this code to make a table which lists all the tables in an access database with the field names. I used this table as the source for making both Record and List form views.</p>



<p>Details of the code for these other forms are listing in later posts</p>



<h2 class="wp-block-heading" style="font-size:23px">VBA Function ;  list of all  Fields in an access database</h2>



<pre class="wp-block-code"><code>Private Sub CreateFieldDefsTable()
    Dim db As DAO.Database
    Set db = CurrentDb()

    db.Execute "CREATE TABLE tblFieldDefs (" &amp; _
               "TableName TEXT(255), " &amp; _
               "FieldName TEXT(255), " &amp; _
               "FieldOrder LONG, " &amp; _
               "Focus YESNO, " &amp; _
               "FocusOrder LONG, " &amp; _
               "&#91;Delete] YESNO, " &amp; _
               "TableType TEXT(50), " &amp; _
               "Description MEMO,KeyField YESNO)", dbFailOnError

    MsgBox "Created table: tblFieldDefs", vbInformation
End Sub</code></pre>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Easy Method to Maintain Hole Sponsors</title>
		<link>https://anythingaccess.com/easy-method-to-maintain-hole-sponsors/</link>
		
		<dc:creator><![CDATA[Pat]]></dc:creator>
		<pubDate>Sun, 17 Aug 2025 14:39:00 +0000</pubDate>
				<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[Golf Hole sponsors]]></category>
		<guid isPermaLink="false">https://anythingaccess.com/?p=1524</guid>

					<description><![CDATA[In our club we needed an easy method to maintain hole sponsors, as part of our sponsorship program we added a short-code to display their social media / logo and other details on the results page. We also maintain a page with a full listing of the sponsors. On the sponsor configuration we specify the [&#8230;]]]></description>
										<content:encoded><![CDATA[
<p>In our <a href="http://tramoregolfclub.com" target="_blank" rel="noopener">club</a> we needed an easy method to maintain hole sponsors, as part of our sponsorship program we added a short-code to display their social media / logo and other details on the results page. We also maintain a page with a full listing of the sponsors.</p>



<p>On the sponsor configuration we specify the last competition or event that they have sponsored , once a year has passed the sponsor will automatically be removed from the sponsor page and the short-code for results will return just the business name with no back-link benefits.</p>



<p>We also have a detailed guide for each of our golf holes with the hole layout and video guide. The objective of the club is get sponsors for each hole whereby they can add their name to the hole markers and be listed as a sponsor. To make it easy for the administrators to add or change a hole sponsor I added a directory which shows the Page name and the associated sponsor as shown below.</p>



<figure class="wp-block-image size-full"><img decoding="async" width="892" height="509" src="https://anythingaccess.com/wp-content/uploads/2025/03/image-9.png" alt="Easy method to maintain hole sponsors" class="wp-image-1525" srcset="https://anythingaccess.com/wp-content/uploads/2025/03/image-9.png 892w, https://anythingaccess.com/wp-content/uploads/2025/03/image-9-300x171.png 300w, https://anythingaccess.com/wp-content/uploads/2025/03/image-9-768x438.png 768w" sizes="(max-width: 892px) 100vw, 892px" /></figure>



<p>A short-code on the selected page will lookup this listing to return the correct sponsor for the page. An excerpt from the page in design mode is shown below with the short-code added.</p>



<figure class="wp-block-image size-full"><img decoding="async" width="955" height="308" src="https://anythingaccess.com/wp-content/uploads/2025/03/image-10.png" alt="Hole shortcode" class="wp-image-1526" srcset="https://anythingaccess.com/wp-content/uploads/2025/03/image-10.png 955w, https://anythingaccess.com/wp-content/uploads/2025/03/image-10-300x97.png 300w, https://anythingaccess.com/wp-content/uploads/2025/03/image-10-768x248.png 768w" sizes="(max-width: 955px) 100vw, 955px" /></figure>



<p>While designing this I was fixated on the club , but ideally it can be used to have different sponsors for different pages with a simple update method.</p>



<h4 class="wp-block-heading">Plugin &#8211; Easy method to maintain hole sponsors</h4>



<pre class="wp-block-code has-extra-small-font-size"><code>&lt;?php
/*
Plugin Name: Golf Hole Sponsors
Description: Assign sponsors to golf holes and display them dynamically with caching.
Version: 1.8
Author: Anything Access
Author URI: https://anythingaccess.com
*/
if (!defined('ABSPATH')) {
    exit; // Exit if accessed directly.
}

class GolfHoleSponsors {
    private $option_key = 'golf_hole_sponsors';
    private $cache_key = 'hole_sponsor_cache';
    private $cache_expiration = 12 * HOUR_IN_SECONDS;

    public function __construct() {
        add_action('admin_menu', &#91;$this, 'create_admin_page']);
        add_action('admin_init', &#91;$this, 'register_settings']);
        add_shortcode('hole_sponsor', &#91;$this, 'display_sponsor']);
        add_action('save_post_sponsors', &#91;$this, 'clear_cache']);
    }

    public function create_admin_page() {
        add_submenu_page('edit.php?post_type=sponsors', 'Hole Sponsors', 'Hole Sponsors', 'manage_options', 'hole_sponsors', &#91;$this, 'admin_page_content']);
    }

    public function register_settings() {
        register_setting('hole_sponsors_group', $this-&gt;option_key);
    }

    public function display_sponsor($atts) {
        $post_id = get_the_ID();
        $sponsors = get_option($this-&gt;option_key, &#91;]);
        $sponsor_id = $sponsors&#91;$post_id] ?? $sponsors&#91;'default'] ?? null;

        if ($sponsor_id) {
            $post = get_post($sponsor_id);
            if ($post) {
                return apply_filters('the_content', $post-&gt;post_content);
            }
        }
        return 'No sponsor available';
    }
	public function clear_cache() {
		delete_transient($this-&gt;cache_key);
	}
    public function admin_page_content() {
        $sponsors = get_posts(&#91;
            'post_type' =&gt; 'sponsors',
            'numberposts' =&gt; -1,
            'orderby' =&gt; 'title',
            'order' =&gt; 'ASC'
        ]);
        $options = get_option($this-&gt;option_key, &#91;]);

        if (isset($_POST&#91;'clear_table'])) {
            update_option($this-&gt;option_key, &#91;]);
            delete_transient($this-&gt;cache_key);
            $options = &#91;];
        }

        if (isset($_POST&#91;'remove_hole'])) {
            $hole_to_remove = $_POST&#91;'remove_hole'];
            if (isset($options&#91;$hole_to_remove])) {
                unset($options&#91;$hole_to_remove]);
                update_option($this-&gt;option_key, $options);
                delete_transient($this-&gt;cache_key);
            }
        }

        if (isset($_POST&#91;'save_sponsors'])) {
            $updated_options = $options;
            if (!empty($_POST&#91;'holes']) &amp;&amp; is_array($_POST&#91;'holes'])) {
                foreach ($_POST&#91;'holes'] as $hole_id =&gt; $sponsor_id) {
                    if (!empty($hole_id) &amp;&amp; !empty($sponsor_id)) {
                        $updated_options&#91;$hole_id] = intval($sponsor_id);
                    }
                }
            }
            if (isset($_POST&#91;'new_hole']) &amp;&amp; isset($_POST&#91;'new_sponsor']) &amp;&amp; !empty($_POST&#91;'new_hole']) &amp;&amp; !empty($_POST&#91;'new_sponsor'])) {
                $updated_options&#91;$_POST&#91;'new_hole']] = intval($_POST&#91;'new_sponsor']);
            }
            $updated_options&#91;'default'] = intval($_POST&#91;'default_sponsor'] ?? '');
            update_option($this-&gt;option_key, $updated_options);
            delete_transient($this-&gt;cache_key);
            $options = $updated_options;
        }
        ?&gt;
        &lt;div class="wrap"&gt;
            &lt;h1&gt;Hole Sponsors&lt;/h1&gt;
            &lt;form method="post" action=""&gt;
                &lt;input type="hidden" name="clear_table" value="1"&gt;
                &lt;?php submit_button('Clear Table'); ?&gt;
            &lt;/form&gt;
            &lt;form method="post" action=""&gt;
                &lt;input type="hidden" name="save_sponsors" value="1"&gt;
                &lt;?php settings_fields('hole_sponsors_group'); ?&gt;
                &lt;table class="form-table"&gt;
                    &lt;tr&gt;
                        &lt;th&gt;Golf Hole&lt;/th&gt;
                        &lt;th&gt;Sponsor&lt;/th&gt;
                        &lt;th&gt;Action&lt;/th&gt;
                    &lt;/tr&gt;
                    &lt;?php foreach ($options as $hole_id =&gt; $sponsor_id): ?&gt;
                        &lt;?php if ($hole_id !== 'default'): ?&gt;
                            &lt;tr&gt;
                                &lt;td&gt;
                                    &lt;?php echo get_the_title($hole_id); ?&gt;
                                    &lt;input type="hidden" name="holes&#91;&lt;?php echo $hole_id; ?&gt;]" value="&lt;?php echo $hole_id; ?&gt;"&gt;
                                &lt;/td&gt;
                                &lt;td&gt;
                                    &lt;select name="holes&#91;&lt;?php echo $hole_id; ?&gt;]"&gt;
                                        &lt;option value=""&gt;-- Select Sponsor --&lt;/option&gt;
                                        &lt;?php foreach ($sponsors as $sponsor): ?&gt;
                                            &lt;option value="&lt;?php echo $sponsor-&gt;ID; ?&gt;" &lt;?php selected($sponsor_id, $sponsor-&gt;ID); ?&gt;&gt;
                                                &lt;?php echo esc_html($sponsor-&gt;post_title); ?&gt;
                                            &lt;/option&gt;
                                        &lt;?php endforeach; ?&gt;
                                    &lt;/select&gt;
                                &lt;/td&gt;
                                &lt;td&gt;
                                    &lt;form method="post" action=""&gt;
                                        &lt;input type="hidden" name="remove_hole" value="&lt;?php echo $hole_id; ?&gt;"&gt;
                                        &lt;?php submit_button('Remove', 'delete', 'submit', false); ?&gt;
                                    &lt;/form&gt;
                                &lt;/td&gt;
                            &lt;/tr&gt;
                        &lt;?php endif; ?&gt;
                    &lt;?php endforeach; ?&gt;
                &lt;/table&gt;
                &lt;h2&gt;Add New Hole Sponsor&lt;/h2&gt;
                &lt;select name="new_hole"&gt;
                    &lt;option value=""&gt;-- Select Hole --&lt;/option&gt;
                    &lt;?php foreach (get_pages() as $hole): ?&gt;
                        &lt;option value="&lt;?php echo $hole-&gt;ID; ?&gt;"&gt;&lt;?php echo esc_html($hole-&gt;post_title); ?&gt;&lt;/option&gt;
                    &lt;?php endforeach; ?&gt;
                &lt;/select&gt;
                &lt;select name="new_sponsor"&gt;
                    &lt;option value=""&gt;-- Select Sponsor --&lt;/option&gt;
                    &lt;?php foreach ($sponsors as $sponsor): ?&gt;
                        &lt;option value="&lt;?php echo $sponsor-&gt;ID; ?&gt;"&gt;&lt;?php echo esc_html($sponsor-&gt;post_title); ?&gt;&lt;/option&gt;
                    &lt;?php endforeach; ?&gt;
                &lt;/select&gt;
                &lt;?php submit_button('Add Sponsor'); ?&gt;
                &lt;h2&gt;Default Sponsor&lt;/h2&gt;
                &lt;select name="default_sponsor"&gt;
                    &lt;option value=""&gt;-- Select Default Sponsor --&lt;/option&gt;
                    &lt;?php foreach ($sponsors as $sponsor): ?&gt;
                        &lt;option value="&lt;?php echo $sponsor-&gt;ID; ?&gt;" &lt;?php selected($options&#91;'default'] ?? '', $sponsor-&gt;ID); ?&gt;&gt;
                            &lt;?php echo esc_html($sponsor-&gt;post_title); ?&gt;
                        &lt;/option&gt;
                    &lt;?php endforeach; ?&gt;
                &lt;/select&gt;
                &lt;?php submit_button('Save Sponsors'); ?&gt;
            &lt;/form&gt;
        &lt;/div&gt;
        &lt;?php
    }
}

new GolfHoleSponsors();

//END OF EASY METHOD TO MAINTAIN HOLE SPONSORS</code></pre>



<p>This plugin will require the <a href="https://anythingaccess.com/adding-sponsors-details-to-your-wordpress-posts">sponsor </a>director plugin to operate correctly.</p>



<p>You can view all our <a href="/category/wordpress">wordpress posts here </a></p>



<p></p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Lotto Ticket Generator</title>
		<link>https://anythingaccess.com/lotto-ticket-generator/</link>
		
		<dc:creator><![CDATA[Pat]]></dc:creator>
		<pubDate>Tue, 22 Jul 2025 20:29:36 +0000</pubDate>
				<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[lotto]]></category>
		<category><![CDATA[wordpress]]></category>
		<guid isPermaLink="false">https://anythingaccess.com/?p=1688</guid>

					<description><![CDATA[A few users have asked for a working sample of the lotto ticket generator. This code normally requires a user to be logged into to word press to be able to generate a ticket. This is a working version the you can test without logging into wordpress. I have disabled the email option on this [&#8230;]]]></description>
										<content:encoded><![CDATA[
<p>A few users have asked for a working sample of the lotto ticket generator. This code normally requires a user to be logged into to word press to be able to generate a ticket. This is a working version the you can test without logging into wordpress.</p>



	<style>
			/* Force name/email inputs to be slightly narrower so they never hit the card edge */
		#buyer_name,
		#buyer_email {
		  width: 90% !important;
		  max-width: 90% !important;
		  margin-left: auto;
		  margin-right: auto;
		  display: block;
		}

	  .lotto-card { 
		max-width: 820px; 
		width: min(820px, 100%); 
		margin: 0 auto; 
		overflow: hidden; /* keeps child focus/outline inside */
	  }

	  /* ✅ Add this line right here */
	  .entry-content .lotto-card { overflow: hidden; }

	  .lotto-card .card { 
		border: 1px solid #e5e7eb; 
		border-radius: 12px; 
		padding: 16px; 
		overflow: hidden; 
	  }

	  .lotto-card h2 { margin: 0 0 10px; font-size: 18px; }
	  .lotto-row { 
		display: grid; 
		grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); 
		gap: 12px; 
		overflow: hidden; 
	  }
	  .lotto-row > .lotto-field { min-width: 0; overflow: hidden; }
	  .lotto-field label { display: block; font-weight: 600; margin-bottom: 6px; }
	  .lotto-field input, .lotto-field select { 
		width: 100% !important; 
		max-width: 100% !important; 
		min-width: 0 !important; 
		box-sizing: border-box;
		padding: 8px 10px; 
		border: 1px solid #d1d5db; 
		border-radius: 8px; 
	  }
	  @media (max-width: 420px) {
		.lotto-row { grid-template-columns: 1fr !important; }
	  }
	</style>


    <div class="lotto-card">
      
      <div class="card">
        <form method="post" class="lotto-form">
          <style>.lotto-hide-qty{display:none !important;}</style>

          <input type="hidden" id="lotto_form_nonce" name="lotto_form_nonce" value="74083bea6b" /><input type="hidden" name="_wp_http_referer" value="/feed/" />
          <div class="lotto-field" style="margin-bottom:10px;">
            <label for="purchase_option">Purchase Option</label>
            <select name="purchase_option" id="purchase_option" required>
              <option value="">-- Select --</option>
                              <option
                  value="15_line_20"
                  data-lines="15"
                  data-weeks="1"
                  data-price="20"
                                  >15 Line (€20)</option>
                              <option
                  value="Annual"
                  data-lines="1"
                  data-weeks="52"
                  data-price="80"
                                  >52 Weeks (€80)</option>
                          </select>
          </div>

          <div class="lotto-row lotto-hide-qty" style="display:none">
            <div class="lotto-field">
              <label for="user_lines">Number of lines</label>
              <input id="user_lines" name="user_lines" type="number" min="1" max="100"
                     value="" placeholder="e.g. 3">
            </div>
            <div class="lotto-field">
              <label for="user_weeks">Number of weeks</label>
              <input id="user_weeks" name="user_weeks" type="number" min="1" max="52"
                     value="" placeholder="e.g. 10">
            </div>
          </div>

          <div class="lotto-row" style="margin-top:10px;">
            <div class="lotto-field">
              <label for="buyer_name">Your name</label>
              <input id="buyer_name" name="buyer_name" type="text" required
                     value="" placeholder="Full name">
            </div>
            <div class="lotto-field">
              <label for="buyer_email">Email</label>
              <input id="buyer_email" name="buyer_email" type="email" required
                     value="" placeholder="you@example.com">
            </div>
          </div>

         <div class="lotto-actions"
     style="display:flex;
            justify-content:center;
            gap:24px;
            align-items:center;
            margin-top:24px;
            padding-top:12px;">
    
    <button
        type="button"
        id="quickpick_btn"
        class="button"
        style="padding:12px 28px; font-size:16px;"
    >
        Quick Pick
    </button>

    <input
        type="submit"
        class="button button-primary"
        value="Submit"
        style="padding:12px 32px; font-size:16px;"
    >
</div>



          <div id="lines-container" class="lotto-lines" style="margin-top:10px;"></div>

          
        </form>
      </div>
      <div class="lotto-card" style="margin-top:16px;">
        <h3 style="margin:0 0 10px;">My Sales Export</h3>
        		  <div style="margin-top:16px;">
			<a href="https://anythingaccess.com/wp-login.php?redirect_to=%2Ffeed%2F" class="button button-primary">
			   Log in to continue
			</a>
		  </div>
		      </div>

    </div>

    <script>
    (function(){
      const select = document.getElementById('purchase_option');
      const linesContainer = document.getElementById('lines-container');
      const inputLines = document.getElementById('user_lines');
      const inputWeeks = document.getElementById('user_weeks');
      const quickBtn = document.getElementById('quickpick_btn');
      const form = document.querySelector('.lotto-form');
      const maxLines = 100;

      function createLineInputs(lineNum, values = []) {
        let html = '<div class="line-set">';
        html += '<div style="font-weight:600;margin-bottom:6px;">Line ' + lineNum + '</div>';
        for (let i = 0; i < 4; i++) {
          const val = values[i] || '';
          html += '<input type="number" name="line' + lineNum + 'n' + (i+1) + '" min="1" max="31" required value="' + val + '" style="width:90px;margin-right:6px;border:1px solid #d1d5db;border-radius:8px;padding:8px 10px;">';
        }
        html += '</div>';
        return html;
      }

      function renderLines(count) {
        linesContainer.innerHTML = '';
        count = Math.max(1, Math.min(parseInt(count || 1, 10), maxLines));
        for (let i = 1; i <= count; i++) {
          linesContainer.insertAdjacentHTML('beforeend', createLineInputs(i));
        }
      }

      function getSelectedConfig() {
        const opt = select.selectedOptions[0];
        return {
          lines: opt?.dataset?.lines ? parseInt(opt.dataset.lines, 10) : null,
          weeks: opt?.dataset?.weeks ? parseInt(opt.dataset.weeks, 10) : null,
          price: opt?.dataset?.price ? parseFloat(opt.dataset.price) : null
        };
      }

	function updateFromSelection() {
	  const cfg = getSelectedConfig();

	  // Lines: fixed option locks value and max to cfg.lines; custom uses global maxLines
	  inputLines.min = 1;
	  if (cfg.lines) {
		inputLines.value = cfg.lines;
		inputLines.readOnly = true;
		inputLines.max = cfg.lines;
	  } else {
		inputLines.readOnly = false;
		if (!inputLines.value) inputLines.value = '';
		inputLines.max = maxLines; // global cap (e.g., 100)
	  }

	  // Weeks (unchanged logic)
	  if (cfg.weeks) {
		inputWeeks.value = cfg.weeks;
		inputWeeks.readOnly = true;
	  } else {
		if (!inputWeeks.value) inputWeeks.value = '';
		inputWeeks.readOnly = false;
	  }

	  const linesToRender = inputLines.value || cfg.lines || 1;
	  renderLines(linesToRender);
	}


      function getUnique4() {
        const nums = [];
        while (nums.length < 4) {
          const n = Math.floor(Math.random() * 31) + 1;
          if (!nums.includes(n)) nums.push(n);
        }
        return nums;
      }

      function quickPick() {
        const count = parseInt(inputLines.value || 1, 10);
        linesContainer.innerHTML = '';
        const safeCount = Math.max(1, Math.min(count || 1, maxLines));
        for (let i = 1; i <= safeCount; i++) {
          linesContainer.insertAdjacentHTML('beforeend', createLineInputs(i, getUnique4()));
        }
      }

      // prevent double submits
      if (form) {
        form.addEventListener('submit', function(){
          const btn = form.querySelector('input[type="submit"], button[type="submit"]');
          if (btn) {
            btn.disabled = true;
            if (btn.tagName === 'INPUT') btn.value = 'Submitting...';
            else btn.textContent = 'Submitting...';
          }
        });
      }

      select.addEventListener('change', updateFromSelection);
      inputLines.addEventListener('input', () => renderLines(inputLines.value));
      quickBtn.addEventListener('click', quickPick);

      // initial render
      updateFromSelection();
      const existingLines = parseInt(0, 10) || 0;
      if (!getSelectedConfig().lines && existingLines > 0) { renderLines(existingLines); }
    })();
    </script>
    



<p>I have disabled the email option on this test , but a html email would be sent to your email address that looks like this.</p>



<figure class="wp-block-image size-large"><img decoding="async" width="569" height="1024" src="https://anythingaccess.com/wp-content/uploads/2025/07/1000007144-569x1024.png" alt="Lotto Ticket Generator" class="wp-image-1694" srcset="https://anythingaccess.com/wp-content/uploads/2025/07/1000007144-569x1024.png 569w, https://anythingaccess.com/wp-content/uploads/2025/07/1000007144-167x300.png 167w, https://anythingaccess.com/wp-content/uploads/2025/07/1000007144-768x1382.png 768w, https://anythingaccess.com/wp-content/uploads/2025/07/1000007144-853x1536.png 853w, https://anythingaccess.com/wp-content/uploads/2025/07/1000007144.png 1080w" sizes="(max-width: 569px) 100vw, 569px" /></figure>



<p>If you need this for your club &#8211; drop me an email on our contact page and i will send you the code.</p>



<p>You can register as many sellers as you require , they can load this on their mobile phone and take the payment in cash. The system records every sale to system database on your wordpress site. You can then print a report showing who has sold tickets and verify the money received.</p>



<p>In my club we export from the bar system and from manual sales using this app and import the sales into <a href="http://lottoraiser.ie" data-type="link" data-id="lottoraiser.ie" target="_blank" rel="noopener">lottoraiser.ie</a>. Exported tickets remain in the database and can be re-exported if required.</p>



<p>Previous lotto <a href="https://anythingaccess.com/making-your-own-lottery-application/" data-type="link" data-id="https://anythingaccess.com/making-your-own-lottery-application/">post</a> , also if you already have an online lottery application , you might be interested in our free <a href="/offline-club-lotto-automation">offline lottery application</a></p>


<p>[lotto]</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Competition Listing Plugin</title>
		<link>https://anythingaccess.com/competition-listing-plugin/</link>
		
		<dc:creator><![CDATA[Pat]]></dc:creator>
		<pubDate>Tue, 15 Jul 2025 12:39:00 +0000</pubDate>
				<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[competition Listing]]></category>
		<category><![CDATA[wordpress]]></category>
		<guid isPermaLink="false">https://anythingaccess.com/?p=1501</guid>

					<description><![CDATA[I created a competition listing plugin for WordPress to allow our club to list the upcoming competitions and if the event was sponsored link it to the predefined sponsor. To use this plugin you will need to add the Sponsor Plugin The plugin will only list competitions in the future and if you have a [&#8230;]]]></description>
										<content:encoded><![CDATA[
<p>I created a competition listing plugin for WordPress to allow our club to list the upcoming competitions and if the event was sponsored link it to the predefined sponsor.</p>



<p>To use this plugin you will need to add the <a href="/adding-sponsors-details-to-your-wordpress-posts">Sponsor Plugin</a></p>



<figure class="wp-block-image size-large"><img decoding="async" width="1024" height="463" src="https://anythingaccess.com/wp-content/uploads/2025/03/image-4-1024x463.png" alt="Competition Listing Plugin" class="wp-image-1503" srcset="https://anythingaccess.com/wp-content/uploads/2025/03/image-4-1024x463.png 1024w, https://anythingaccess.com/wp-content/uploads/2025/03/image-4-300x136.png 300w, https://anythingaccess.com/wp-content/uploads/2025/03/image-4-768x348.png 768w, https://anythingaccess.com/wp-content/uploads/2025/03/image-4.png 1485w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>



<p>The plugin will only list competitions in the future and if you have a sponsor  you can link it to the sponsor as shown below</p>



<figure class="wp-block-image size-full"><a href="robynjonescreative.com"><img decoding="async" width="969" height="562" src="https://anythingaccess.com/wp-content/uploads/2025/03/image-5.png" alt="Sponsor display" class="wp-image-1504" srcset="https://anythingaccess.com/wp-content/uploads/2025/03/image-5.png 969w, https://anythingaccess.com/wp-content/uploads/2025/03/image-5-300x174.png 300w, https://anythingaccess.com/wp-content/uploads/2025/03/image-5-768x445.png 768w" sizes="(max-width: 969px) 100vw, 969px" /></a></figure>



<p>To add competitions and link a sponsor &#8211; goto your WordPress admin page. Select Competitions and populate the data. The Sponsor requires the sponsors to be already added to the site.</p>



<figure class="wp-block-image size-full"><img decoding="async" width="774" height="288" src="https://anythingaccess.com/wp-content/uploads/2025/03/image-6.png" alt="Admin settings" class="wp-image-1505" srcset="https://anythingaccess.com/wp-content/uploads/2025/03/image-6.png 774w, https://anythingaccess.com/wp-content/uploads/2025/03/image-6-300x112.png 300w, https://anythingaccess.com/wp-content/uploads/2025/03/image-6-768x286.png 768w" sizes="(max-width: 774px) 100vw, 774px" /></figure>



<h4 class="wp-block-heading">Php Plugin Code &#8211; Competition Listing Plugin</h4>



<pre class="wp-block-code has-extra-small-font-size"><code>&lt;?php
/*
Plugin Name: Sponsor Directory
Description: Manage and display sponsors dynamically in WordPress posts using shortcodes.
Version: 1.98
Author: Anything Access
Author URI: https://anythingaccess.com
License: GPL2
*/

// Register Custom Post Type for Sponsors
function create_sponsor_post_type() {
    register_post_type('sponsors', array(
        'labels' => array(
            'name' => __('Sponsors'),
            'singular_name' => __('Sponsor')
        ),
        'public' => true,
        'has_archive' => true,
        'menu_icon' => 'dashicons-awards',
        'supports' => array('title', 'editor', 'thumbnail'),
        'show_in_rest' => true,
    ));
}
add_action('init', 'create_sponsor_post_type');

// Add Custom Meta Fields
function add_sponsor_meta_boxes() {
    add_meta_box('sponsor_details', 'Sponsor Details', 'sponsor_meta_callback', 'sponsors', 'normal', 'high');
}
add_action('add_meta_boxes', 'add_sponsor_meta_boxes');

function sponsor_meta_callback($post) {
    // Retrieve existing meta values
    $website = get_post_meta($post->ID, 'sponsor_website', true);
    $phone = get_post_meta($post->ID, 'sponsor_phone', true);
    $facebook = get_post_meta($post->ID, 'sponsor_facebook', true);
    $twitter = get_post_meta($post->ID, 'sponsor_twitter', true);
    $instagram = get_post_meta($post->ID, 'sponsor_instagram', true);
    $linkedin = get_post_meta($post->ID, 'sponsor_linkedin', true);
    $last_event_date = get_post_meta($post->ID, 'sponsor_last_event_date', true); // New field
	$businessname = get_post_meta($post->ID, 'sponsor_business_name', true);
	$tiktok = get_post_meta($post->ID, 'sponsor_tiktok', true);
	$email = get_post_meta($post->ID, 'sponsor_email', true);
	
    echo '&lt;label>Website:&lt;/label>&lt;br/>
          &lt;input type="text" name="sponsor_website" value="' . esc_attr($website) . '" size="50" />&lt;br/>
          &lt;label>Phone:&lt;/label>&lt;br/>
          &lt;input type="text" name="sponsor_phone" value="' . esc_attr($phone) . '" size="50" />&lt;br/>
          &lt;label>Facebook:&lt;/label>&lt;br/>
          &lt;input type="text" name="sponsor_facebook" value="' . esc_attr($facebook) . '" size="50" />&lt;br/>
          &lt;label>Twitter:&lt;/label>&lt;br/>
          &lt;input type="text" name="sponsor_twitter" value="' . esc_attr($twitter) . '" size="50" />&lt;br/>
          &lt;label>Instagram:&lt;/label>&lt;br/>
          &lt;input type="text" name="sponsor_instagram" value="' . esc_attr($instagram) . '" size="50" />&lt;br/>
		  &lt;label>Tiktok:&lt;/label>&lt;br/>
		  &lt;input type="text" name="sponsor_tiktok" value="' . esc_attr($tiktok) . '" size="50" />&lt;br/>
		  &lt;label>Business Name:&lt;/label>&lt;br/>
          &lt;input type="text" name="sponsor_business_name" value="' . esc_attr($businessname) . '" size="50" />&lt;br/>
          &lt;label>LinkedIn:&lt;/label>&lt;br/>
          &lt;input type="text" name="sponsor_linkedin" value="' . esc_attr($linkedin) . '" size="50" />&lt;br/>
          &lt;label>Email:&lt;/label>&lt;br/>
          &lt;input type="text" name="sponsor_email" value="' . esc_attr($email) . '" size="50" />&lt;br/>
          &lt;label>&lt;strong>Last Sponsored Event Date:&lt;/strong>&lt;/label>&lt;br/>
          &lt;input type="date" name="sponsor_last_event_date" value="' . esc_attr($last_event_date) . '" />&lt;br/>';
}


// Save Meta Data
function save_sponsor_meta($post_id) {
    if (defined('DOING_AUTOSAVE') &amp;&amp; DOING_AUTOSAVE) return;
    if (isset($_POST&#91;'sponsor_website'])) update_post_meta($post_id, 'sponsor_website', sanitize_text_field($_POST&#91;'sponsor_website']));
    if (isset($_POST&#91;'sponsor_phone'])) update_post_meta($post_id, 'sponsor_phone', sanitize_text_field($_POST&#91;'sponsor_phone']));
    if (isset($_POST&#91;'sponsor_facebook'])) update_post_meta($post_id, 'sponsor_facebook', sanitize_text_field($_POST&#91;'sponsor_facebook']));
    if (isset($_POST&#91;'sponsor_twitter'])) update_post_meta($post_id, 'sponsor_twitter', sanitize_text_field($_POST&#91;'sponsor_twitter']));
    if (isset($_POST&#91;'sponsor_instagram'])) update_post_meta($post_id, 'sponsor_instagram', sanitize_text_field($_POST&#91;'sponsor_instagram']));
	if (isset($_POST&#91;'sponsor_linkedin'])) update_post_meta($post_id, 'sponsor_linkedin', sanitize_text_field($_POST&#91;'sponsor_linkedin']));
	if (isset($_POST&#91;'sponsor_business_name'])) update_post_meta($post_id, 'sponsor_business_name', sanitize_text_field($_POST&#91;'sponsor_business_name']));
	if (isset($_POST&#91;'sponsor_last_event_date'])) update_post_meta($post_id, 'sponsor_last_event_date', sanitize_text_field($_POST&#91;'sponsor_last_event_date']));
	if (isset($_POST&#91;'sponsor_tiktok'])) update_post_meta($post_id, 'sponsor_tiktok', sanitize_text_field($_POST&#91;'sponsor_tiktok']));
	if (isset($_POST&#91;'sponsor_email'])) update_post_meta($post_id, 'sponsor_email', sanitize_text_field($_POST&#91;'sponsor_email']));
}
add_action('save_post', 'save_sponsor_meta');

// Main Function to Fetch and Display Sponsor Info
function display_sponsor_info($atts) {
    $atts = shortcode_atts(array('name' => ''), $atts);
    $sponsor_name = sanitize_text_field($atts&#91;'name']);

    $args = array(
        'post_type'      => 'sponsors',
        'posts_per_page' => 1,
        'title'          => $sponsor_name
    );

    $query = new WP_Query($args);

    if ($query->have_posts()) {
        ob_start();
        while ($query->have_posts()) {
            $query->the_post();

            $last_event_date = get_post_meta(get_the_ID(), 'sponsor_last_event_date', true);
            $one_year_ago = date('Y-m-d', strtotime('-1 year'));
			$businessname = get_post_meta(get_the_ID(), 'sponsor_business_name', true);

            // If last sponsored event is over a year old, return only "Sponsored by: Sponsor Name"
            if ($last_event_date &amp;&amp; $last_event_date &lt; $one_year_ago) {
                echo "&lt;p>Sponsored by: " . $businessname . "&lt;/p>";
            } else {
                // Otherwise, return the full description
                $desc = apply_filters('the_content', get_the_content());
                if (!empty($desc)) {
                    echo "&lt;p>" . $desc . "&lt;/p>";
                }
            }
        }

        wp_reset_postdata();
        return ob_get_clean();
    }

    return "&lt;p>Sponsor not found.&lt;/p>";
}


// Shortcode Buffer Fix - Ensures Content Doesn't Flash
function sponsor_shortcode_buffer($atts) {
    return display_sponsor_info($atts); // Show sponsor directly in the content
}

// Register the shortcode
add_shortcode('sponsor', 'sponsor_shortcode_buffer');

// count sponsors function
function count_posts_with_sponsor($sponsor_name) {
    global $wpdb;

    // Search for sponsor name in post content
    $query = $wpdb->prepare("
        SELECT COUNT(ID) FROM $wpdb->posts 
        WHERE post_status = 'publish' 
        AND post_type = 'post' 
        AND post_content LIKE %s", 
        '%' . $wpdb->esc_like($sponsor_name) . '%'
    );

    return $wpdb->get_var($query);
}
//Export the sponsors 
function export_sponsors_csv() {
    if (!current_user_can('manage_options')) {
        wp_die(__('You do not have permission to access this page.'));
    }

    // Set headers to force CSV download
    header('Content-Type: text/csv; charset=utf-8');
    header('Content-Disposition: attachment; filename="sponsors.csv"');
    header('Pragma: no-cache');
    header('Expires: 0');

    // Open output stream
    $output = fopen('php://output', 'w');

    // Add column headers
    fputcsv($output, &#91;'Business Name','Shortcode','Last Sponsor Date','No of Ads','Website', 'Phone', 'Facebook', 'Twitter', 'Instagram', 'Last Update']);

    // Query sponsors
    $args = &#91;
        'post_type'      => 'sponsors',
        'posts_per_page' => -1
    ];
    $query = new WP_Query($args);

    if ($query->have_posts()) {
        while ($query->have_posts()) {
            $query->the_post();
            $sponsor_id   = get_the_ID();
            $sponsor_name = get_the_title($sponsor_id); // Use sponsor name

            // Use your existing function to count post mentions
            $usage_count = count_posts_with_sponsor($sponsor_name);

            // Get last updated date
            $last_updated = get_the_modified_date('Y-m-d H:i:s', $sponsor_id);

            fputcsv($output, &#91;
                get_post_meta($sponsor_id, 'sponsor_business_name', true),
				$sponsor_name,
				get_post_meta($sponsor_id, 'sponsor_last_event_date', true),
				$usage_count,
                get_post_meta($sponsor_id, 'sponsor_website', true),
                get_post_meta($sponsor_id, 'sponsor_phone', true),
                get_post_meta($sponsor_id, 'sponsor_facebook', true),
                get_post_meta($sponsor_id, 'sponsor_twitter', true),
                get_post_meta($sponsor_id, 'sponsor_instagram', true),
               
                $last_updated
            ]);
        }
    }

    fclose($output);
    exit;
}
add_action('admin_post_export_sponsors_csv', 'export_sponsors_csv');

// Make sure this is registered properly
add_action('admin_post_export_sponsors_csv', 'export_sponsors_csv');



//add sponsor export option to menu
function add_sponsor_post_count_column($columns) {
    $columns&#91;'sponsor_post_count'] = 'Posts Mentioning';
    return $columns;
}
add_filter('manage_sponsors_posts_columns', 'add_sponsor_post_count_column');

function show_sponsor_post_count_column($column, $post_id) {
    if ($column == 'sponsor_post_count') {
        $sponsor_name = get_the_title($post_id);
        echo count_posts_with_sponsor($sponsor_name);
    }
}
add_action('manage_sponsors_posts_custom_column', 'show_sponsor_post_count_column', 10, 2);

function export_sponsors_page() {
    ?>
    &lt;div class="wrap">
        &lt;h1>Export Sponsors&lt;/h1>
        &lt;p>Click the button below to download a CSV of all sponsors.&lt;/p>
        &lt;a href="&lt;?php echo esc_url(admin_url('admin-post.php?action=export_sponsors_csv')); ?>" class="button button-primary">
            Download Sponsors CSV
        &lt;/a>
    &lt;/div>
    &lt;?php
}

function add_sponsors_export_menu() {
    add_submenu_page(
        'edit.php?post_type=sponsors', // Adds under "Sponsors" menu
        'Export Sponsors',
        'Export Sponsors',
        'manage_options',
        'export_sponsors',
        'export_sponsors_page'
    );
}
add_action('admin_menu', 'add_sponsors_export_menu');

//1.95
function list_recent_sponsors() {
    $one_year_ago = date('Y-m-d', strtotime('-1 year'));
    
   $args = &#91;
        'post_type'      => 'sponsors',
        'posts_per_page' => -1,
        'meta_query'     => &#91;
            &#91;
                'key'     => 'sponsor_last_event_date',
                'value'   => $one_year_ago,
                'compare' => '>=',
                'type'    => 'DATE'
            ]
        ],
        'orderby'  => 'title', // Sort by sponsor name (post title)
        'order'    => 'ASC' // Ascending order (A-Z)
    ];
    
    $query = new WP_Query($args);

    if ($query->have_posts()) {
        $output = '&lt;ul class="recent-sponsors">';
        
        while ($query->have_posts()) {
            $query->the_post();
            $sponsor_name  = get_the_title();
            $sponsor_website = get_post_meta(get_the_ID(), 'sponsor_website', true);
            $last_event_date = get_post_meta(get_the_ID(), 'sponsor_last_event_date', true);
			$business_name  = get_post_meta(get_the_ID(), 'sponsor_business_name', true);
            $sponsor_tiktok = get_post_meta(get_the_ID(), 'sponsor_tiktok', true);
			$sponsor_instagram = get_post_meta(get_the_ID(), 'sponsor_instagram', true);
			$sponsor_facebook = get_post_meta(get_the_ID(), 'sponsor_facebook', true);
			$sponsor_email = get_post_meta(get_the_ID(), 'sponsor_email', true);
			$sponsor_phone = get_post_meta(get_the_ID(), 'sponsor_phone', true);
			$sponsor_linkedin = get_post_meta(get_the_ID(), 'sponsor_linkedin', true);
			$sponsor_twitter = get_post_meta(get_the_ID(), 'sponsor_twitter', true);
			
            $output .= '&lt;li>';

   $output .= '&lt;a href="' . esc_url(home_url('/sponsor/' . sanitize_title($sponsor_name))) . '" target="_blank">&lt;strong>' . esc_html($business_name) . '&lt;/strong>&lt;/a>';

// Adding an SVG for a web
if ($sponsor_website) {
    ob_start();  // Start output buffering

    ?>
    &lt;a href="&lt;?php echo esc_url($sponsor_website); ?>" target="_blank" style="display:inline-block;">
        &lt;div class="icon-bg custom-social-icon" style="display:inline-block; vertical-align:middle;">
            &lt;svg width="24" height="24" viewBox="0 0 24 24" version="1.1" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false">
    &lt;path d="M12.02,10.18v3.72v0.01h5.51c-0.26,1.57-1.67,4.22-5.5,4.22c-3.31,0-6.01-2.75-6.01-6.12s2.7-6.12,6.01-6.12 c1.87,0,3.13,0.8,3.85,1.48l2.84-2.76C16.99,2.99,14.73,2,12.03,2c-5.52,0-10,4.48-10,10s4.48,10,10,10c5.77,0,9.6-4.06,9.6-9.77 c0-0.83-0.11-1.42-0.25-2.05H12.02z">&lt;/path>
&lt;/svg>


        &lt;/div>
    &lt;/a>
    &lt;?php

    $output .= ob_get_clean();  // Capture the output and add it to $output
}
//tiktok
if ($sponsor_tiktok) {
    ob_start();  // Start output buffering

    ?>
    &lt;a href="&lt;?php echo esc_url($sponsor_tiktok); ?>" target="_blank" style="display:inline-block;">
        &lt;div class="icon-bg custom-social-icon" style="display:inline-block; vertical-align:middle;">
            &lt;svg width="24" height="24" viewBox="0 0 24 24" fill="black" xmlns="http://www.w3.org/2000/svg">
            &lt;path d="M12 2a10 10 0 100 20 10 10 0 000-20zm3.75 5.125c.513 1.393 1.69 2.417 3.125 2.75v2.375a5.995 5.995 0 01-3.125-.875v4.625c0 2.205-1.79 4-4 4s-4-1.795-4-4 1.79-4 4-4c.183 0 .363.015.539.038v2.416a2.01 2.01 0 00-.539-.064 2.001 2.001 0 00-2 2c0 1.104.896 2 2 2s2-.896 2-2V7.75h2.5z"/>
        &lt;/svg>
        &lt;/div>
    &lt;/a>
    &lt;?php

    $output .= ob_get_clean();  // Capture the output and add it to $output
}
//instagram
if ($sponsor_instagram) {
    ob_start();  // Start output buffering

    ?>
    &lt;a href="&lt;?php echo esc_url($sponsor_instagram); ?>" target="_blank" style="display:inline-block;">
        &lt;div class="icon-bg custom-social-icon" style="display:inline-block; vertical-align:middle;">
            &lt;svg width="24" height="24" viewBox="0 0 24 24" fill="black" xmlns="http://www.w3.org/2000/svg">
            &lt;path d="M12 2.163c3.204 0 3.584.012 4.85.07 3.252.148 4.771 1.691 4.92 4.92.058 1.267.07 1.647.07 4.85s-.012 3.584-.07 4.85c-.149 3.229-1.668 4.771-4.92 4.92-1.266.058-1.646.07-4.85.07s-3.584-.012-4.85-.07c-3.229-.149-4.771-1.691-4.92-4.92C2.175 15.583 2.163 15.203 2.163 12s.012-3.584.07-4.85c.149-3.229 1.691-4.771 4.92-4.92 1.267-.058 1.647-.07 4.85-.07M12 0C8.741 0 8.332.012 7.053.07 2.94.25.25 2.94.07 7.053.012 8.332 0 8.741 0 12s.012 3.668.07 4.947c.18 4.113 2.87 6.803 6.983 6.983 1.279.058 1.688.07 4.947.07s3.668-.012 4.947-.07c4.113-.18 6.803-2.87 6.983-6.983.058-1.279.07-1.688.07-4.947s-.012-3.668-.07-4.947C23.75 2.94 21.06.25 16.947.07 15.668.012 15.259 0 12 0zm0 5.838a6.162 6.162 0 100 12.324 6.162 6.162 0 000-12.324zm0 10.162a3.999 3.999 0 110-7.998 3.999 3.999 0 010 7.998zM18.406 4.594a1.44 1.44 0 11-2.88 0 1.44 1.44 0 012.88 0z"/>
        &lt;/svg>
        &lt;/div>
    &lt;/a>
    &lt;?php

    $output .= ob_get_clean();  // Capture the output and add it to $output
}
//facebook
if ($sponsor_facebook) {
    ob_start();  // Start output buffering

    ?>
    &lt;a href="&lt;?php echo esc_url($sponsor_facebook); ?>" target="_blank" style="display:inline-block;">
        &lt;div class="icon-bg custom-social-icon" style="display:inline-block; vertical-align:middle;">
			&lt;svg width="24" height="24" viewBox="0 0 24 24" fill="currentColor" xmlns="http://www.w3.org/2000/svg">
			&lt;path d="M22.675 0h-21.35C.595 0 0 .595 0 1.325v21.351C0 23.405.595 24 1.325 24H12.82v-9.294H9.692V11.08h3.128V8.412c0-3.1 1.892-4.786 4.659-4.786 1.325 0 2.463.099 2.795.143v3.24h-1.919c-1.505 0-1.796.716-1.796 1.764v2.307h3.589l-.467 3.625h-3.122V24h6.127c.73 0 1.325-.595 1.325-1.324V1.325C24 .595 23.405 0 22.675 0z"/>
			&lt;/svg>
        &lt;/div>
    &lt;/a>
    &lt;?php

    $output .= ob_get_clean();  // Capture the output and add it to $output
}

//email
if ($sponsor_email) {
    ob_start();  // Start output buffering

    ?>
    &lt;a href="&lt;?php echo esc_url($sponsor_email); ?>" target="_blank" style="display:inline-block;">
        &lt;div class="icon-bg custom-social-icon" style="display:inline-block; vertical-align:middle;">
			&lt;svg width="800px" height="800px" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
&lt;path d="M4 9.00005L10.2 13.65C11.2667 14.45 12.7333 14.45 13.8 13.65L20 9" stroke="#000000" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
&lt;path d="M3 9.17681C3 8.45047 3.39378 7.78123 4.02871 7.42849L11.0287 3.5396C11.6328 3.20402 12.3672 3.20402 12.9713 3.5396L19.9713 7.42849C20.6062 7.78123 21 8.45047 21 9.17681V17C21 18.1046 20.1046 19 19 19H5C3.89543 19 3 18.1046 3 17V9.17681Z" stroke="#000000" stroke-width="2" stroke-linecap="round"/>
&lt;/svg>
        &lt;/div>
    &lt;/a>
    &lt;?php

    $output .= ob_get_clean();  // Capture the output and add it to $output
}
//LinkedIn
if ($sponsor_linkedin) {
    ob_start();  // Start output buffering

    ?>
    &lt;a href="&lt;?php echo esc_url($sponsor_linkedin); ?>" target="_blank" style="display:inline-block;">
        &lt;div class="icon-bg custom-social-icon" style="display:inline-block; vertical-align:middle;">
			&lt;svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
  &lt;path d="M22.23 0H1.77C.79 0 0 .79 0 1.77v20.46c0 .98.79 1.77 1.77 1.77h20.46c.98 0 1.77-.79 1.77-1.77V1.77C24 .79 23.21 0 22.23 0zM7.14 20.45H3.56V9h3.58v11.45zm-1.79-12.98c-1.13 0-1.91-.77-1.91-1.73 0-.98.78-1.73 1.91-1.73s1.91.75 1.91 1.73c0 .96-.78 1.73-1.91 1.73zm14.89 12.98h-3.58v-5.94c0-1.42-.51-2.39-1.79-2.39-.97 0-1.55.66-1.81 1.3-.09.22-.12.53-.12.83v6.2h-3.58V9h3.58v1.56c.47-.71 1.28-1.76 3.11-1.76 2.28 0 4.11 1.48 4.11 4.67v6.98z"/>
&lt;/svg>

        &lt;/div>
    &lt;/a>
    &lt;?php

    $output .= ob_get_clean();  // Capture the output and add it to $output
}

//twitter
if ($sponsor_twitter) {
    ob_start();  // Start output buffering

    ?>
    &lt;a href="&lt;?php echo esc_url($sponsor_twitter); ?>" target="_blank" style="display:inline-block;">
        &lt;div class="icon-bg custom-social-icon" style="display:inline-block; vertical-align:middle;">
			&lt;svg width="24" height="24" viewBox="0 0 24 24" version="1.1" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false">&lt;path d="M13.982 10.622 20.54 3h-1.554l-5.693 6.618L8.745 3H3.5l6.876 10.007L3.5 21h1.554l6.012-6.989L15.868 21h5.245l-7.131-10.378Zm-2.128 2.474-.697-.997-5.543-7.93H8l4.474 6.4.697.996 5.815 8.318h-2.387l-4.745-6.787Z">&lt;/path>&lt;/svg>

        &lt;/div>
    &lt;/a>
    &lt;?php

    $output .= ob_get_clean();  // Capture the output and add it to $output
}
//phone
if ($sponsor_phone) {
    ob_start();  // Start output buffering

    ?>
    &lt;a href="&lt;?php echo esc_url($sponsor_phone); ?>" target="_blank" style="display:inline-block;">
        &lt;div class="icon-bg custom-social-icon" style="display:inline-block; vertical-align:middle;">
			&lt;svg xmlns="http://www.w3.org/2000/svg"  viewBox="0 0 50 50" width="50px" height="50px">&lt;path d="M 14 3.9902344 C 8.4886661 3.9902344 4 8.4789008 4 13.990234 L 4 35.990234 C 4 41.501568 8.4886661 45.990234 14 45.990234 L 36 45.990234 C 41.511334 45.990234 46 41.501568 46 35.990234 L 46 13.990234 C 46 8.4789008 41.511334 3.9902344 36 3.9902344 L 14 3.9902344 z M 18.005859 12.033203 C 18.633859 12.060203 19.210594 12.414031 19.558594 12.957031 C 19.954594 13.575031 20.569141 14.534156 21.369141 15.785156 C 22.099141 16.926156 22.150047 18.399844 21.498047 19.589844 L 20.033203 21.673828 C 19.637203 22.237828 19.558219 22.959703 19.824219 23.595703 C 20.238219 24.585703 21.040797 26.107203 22.466797 27.533203 C 23.892797 28.959203 25.414297 29.761781 26.404297 30.175781 C 27.040297 30.441781 27.762172 30.362797 28.326172 29.966797 L 30.410156 28.501953 C 31.600156 27.849953 33.073844 27.901859 34.214844 28.630859 C 35.465844 29.430859 36.424969 30.045406 37.042969 30.441406 C 37.585969 30.789406 37.939797 31.366141 37.966797 31.994141 C 38.120797 35.558141 35.359641 37.001953 34.556641 37.001953 C 34.000641 37.001953 27.316344 37.761656 19.777344 30.222656 C 12.238344 22.683656 12.998047 15.999359 12.998047 15.443359 C 12.998047 14.640359 14.441859 11.879203 18.005859 12.033203 z"/>&lt;/svg>


        &lt;/div>
    &lt;/a>
    &lt;?php

    $output .= ob_get_clean();  // Capture the output and add it to $output
}
// Add last event date for admins
if (current_user_can('administrator')) {
    $output .= ' -- (Last Sponsored: ' . esc_html($last_event_date) . ')';
}

$output .= '&lt;/li>';



        }
        
        $output .= '&lt;/ul>';
    } else {
        $output = '&lt;p>No recent sponsors found.&lt;/p>';
    }

    wp_reset_postdata();
    
    return $output;
}
add_shortcode('recent_sponsors', 'list_recent_sponsors');

?></code></pre>



<p>If you are having issues getting this working drop me an email.</p>



<p>Other&nbsp;<a href="https://anythingaccess.com/category/wordpress">WordPress Plugin Posts</a></p>



<p>This has been deployed to this <a href="https://tramoregolfclub.com/home/open-and-members-competitions/" target="_blank" rel="noopener">site</a></p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Adding Sponsors details to your Wordpress Posts</title>
		<link>https://anythingaccess.com/adding-sponsors-details-to-your-wordpress-posts/</link>
		
		<dc:creator><![CDATA[Pat]]></dc:creator>
		<pubDate>Fri, 27 Jun 2025 17:09:00 +0000</pubDate>
				<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[Golf Sponsors]]></category>
		<category><![CDATA[wordpress]]></category>
		<guid isPermaLink="false">https://anythingaccess.com/?p=1462</guid>

					<description><![CDATA[If you&#8217;re running a club or organization and working with sponsors, you know how important it is to keep track of their details. Whether you&#8217;re adding sponsors details to your posts, newsletters, or website content, it can get a little overwhelming trying to manage all the contact info and social media links. That’s why I’ve [&#8230;]]]></description>
										<content:encoded><![CDATA[
<p>If you&#8217;re running a club or organization and working with sponsors, you know how important it is to keep track of their details. Whether you&#8217;re adding sponsors details to your posts, newsletters, or website content, it can get a little overwhelming trying to manage all the contact info and social media links. That’s why I’ve created a simple WordPress plugin to help clubs like yours keep things organized.</p>



<div style="height:32px" aria-hidden="true" class="wp-block-spacer"></div>



<h3 class="wp-block-heading">What Does the Plugin Do?</h3>



<p>This plugin makes it easy to store and display sponsors details, like contact information and social media links, directly in your WordPress posts. It’s perfect for when you need to include your sponsor’s info in every post but don’t want to manually copy and paste it over and over again.</p>



<p>Once you’ve entered the sponsor&#8217;s details—contact info, website links, and social media accounts—you can use a shortcode to automatically add their info to any post. No more worrying about forgotten or outdated links. The plugin even makes sure those social media links are verified, so you can feel confident that you’re sharing accurate, up-to-date details.</p>



<figure class="wp-block-image size-large"><img decoding="async" width="1024" height="265" src="https://anythingaccess.com/wp-content/uploads/2025/02/image-6-1024x265.png" alt="Sponsors Details" class="wp-image-1464" srcset="https://anythingaccess.com/wp-content/uploads/2025/02/image-6-1024x265.png 1024w, https://anythingaccess.com/wp-content/uploads/2025/02/image-6-300x78.png 300w, https://anythingaccess.com/wp-content/uploads/2025/02/image-6-768x199.png 768w, https://anythingaccess.com/wp-content/uploads/2025/02/image-6.png 1125w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>



<h3 class="wp-block-heading">How Does It Work?</h3>



<p>Once installed, the plugin gives you a place in your WordPress dashboard where you can enter all the sponsors details. You can add things like their name, contact email, phone number, and links to their social media profiles (like Facebook, Instagram, or Twitter). You can even add a brief description or anything else that’s relevant to the sponsor.</p>



<p>When you&#8217;re writing a post or updating a page, you just add the shortcode at the end of the content. That’s it! The sponsors details will automatically appear, neatly and consistently. No need to manually re-enter anything each time.</p>



<div style="height:40px" aria-hidden="true" class="wp-block-spacer"></div>



<h3 class="wp-block-heading">Benefits of this plugin</h3>



<ol class="wp-block-list">
<li><strong>Saves Time</strong>: Instead of going back to each post or page to update sponsors details, you only need to do it once. The shortcode pulls in the details automatically each time you add it to a post.</li>



<li><strong>Keeps It Consistent</strong>: If you have multiple sponsors, it helps keep everything uniform. Whether you&#8217;re featuring one sponsor or several, each one will appear in the same format every time.</li>



<li><strong>Verified Social Links</strong>: It’s easy to forget about updating a link or double-checking it’s correct. The plugin helps verify that your sponsor’s social media links are still active and accurate.</li>



<li><strong>User-Friendly</strong>: You don’t need to be a tech expert to use this plugin. It’s designed to be simple, so anyone managing the site can update sponsor details without any hassle.</li>
</ol>



<div style="height:30px" aria-hidden="true" class="wp-block-spacer"></div>



<h3 class="wp-block-heading">How to Set It Up</h3>



<p>Setting up the plugin is simple. Just install it from the WordPress plugin directory, activate it, and you&#8217;ll find a new section in your dashboard to add sponsor details.</p>



<p>When you’re working on a post and want to add a sponsor’s information, all you need to do is insert the shortcode where you want it to appear. The sponsor’s details will be automatically inserted—no extra effort needed.</p>



<div style="height:35px" aria-hidden="true" class="wp-block-spacer"></div>



<h3 class="wp-block-heading">Sample Blog post</h3>



<figure class="wp-block-image size-full has-custom-border"><img decoding="async" width="842" height="456" src="https://anythingaccess.com/wp-content/uploads/2025/06/image.png" alt="" class="wp-image-1470" style="border-width:1px" srcset="https://anythingaccess.com/wp-content/uploads/2025/06/image.png 842w, https://anythingaccess.com/wp-content/uploads/2025/06/image-300x162.png 300w, https://anythingaccess.com/wp-content/uploads/2025/06/image-768x416.png 768w" sizes="(max-width: 842px) 100vw, 842px" /></figure>



<p>The sponsor for this competition was Heineken which has been setup on the Sponsor page.</p>



<figure class="wp-block-image size-large has-custom-border"><img decoding="async" width="1024" height="542" src="https://anythingaccess.com/wp-content/uploads/2025/06/image-1-1024x542.png" alt="" class="wp-image-1472" style="border-width:1px" srcset="https://anythingaccess.com/wp-content/uploads/2025/06/image-1-1024x542.png 1024w, https://anythingaccess.com/wp-content/uploads/2025/06/image-1-300x159.png 300w, https://anythingaccess.com/wp-content/uploads/2025/06/image-1-768x406.png 768w, https://anythingaccess.com/wp-content/uploads/2025/06/image-1.png 1091w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>



<p>In this example I used the social icons in the WP Theme which only display if populated. The published post is shown below. If you use the social  from the theme you shouldn&#8217;t populate the entries for the sponsor as they will appear twice.</p>



<figure class="wp-block-image size-full has-custom-border"><img decoding="async" width="746" height="698" src="https://anythingaccess.com/wp-content/uploads/2025/06/image-2.png" alt="" class="wp-image-1473" style="border-width:1px" srcset="https://anythingaccess.com/wp-content/uploads/2025/06/image-2.png 746w, https://anythingaccess.com/wp-content/uploads/2025/06/image-2-300x281.png 300w" sizes="(max-width: 746px) 100vw, 746px" /></figure>



<div style="height:26px" aria-hidden="true" class="wp-block-spacer"></div>



<h3 class="wp-block-heading">Listing of Current Sponsors</h3>



<p>When you setup a sponsor you can enter the full business name of the sponsor and the date of sponsorship. A shortcode is available to show the current list of sponsors which will only list sponsors who have sponsored the club in the last year.</p>



<p>This shortcode lists the companies alphabetically and hyperlinks the company name to their website. If you are logged in as an admin user you will also see the last sponsorship date.</p>



<div style="height:28px" aria-hidden="true" class="wp-block-spacer"></div>



<h3 class="wp-block-heading">Wrapping It Up</h3>



<p>Managing sponsor information doesn’t need to be complicated. With this plugin, your club can keep everything organized and up-to-date with minimal effort. It’s a practical tool that saves time and ensures you’re always sharing the right details with your audience.</p>



<p>If you’re looking for an easier way to display sponsor information, this plugin could be just what you need. Give it a try and let me know if you have any questions or suggestions!</p>



<div style="height:28px" aria-hidden="true" class="wp-block-spacer"></div>



<h5 class="wp-block-heading">Sponsors Details Plugin Code</h5>



<pre class="wp-block-code has-extra-small-font-size"><code>&lt;?php
/*
Plugin Name: Sponsor Directory
Description: Manage and display sponsors dynamically in WordPress posts using shortcodes.
Version: 3.1
Author: Anything Access
Author URI: https://anythingaccess.com
License: GPL2
*/

// Register Custom Post Type for Sponsors
function create_sponsor_post_type() {
    register_post_type('sponsors', array(
        'labels' => array(
            'name' => __('Sponsors'),
            'singular_name' => __('Sponsor')
        ),
        'public' => true,
        'has_archive' => true,
        'menu_icon' => 'dashicons-awards',
        'supports' => array('title', 'editor', 'thumbnail'),
        'show_in_rest' => true,
    ));
}
add_action('init', 'create_sponsor_post_type');

// Add Custom Meta Fields
function add_sponsor_meta_boxes() {
    add_meta_box('sponsor_details', 'Sponsor Details', 'sponsor_meta_callback', 'sponsors', 'normal', 'high');
}
add_action('add_meta_boxes', 'add_sponsor_meta_boxes');

function sponsor_meta_callback($post) {
    // Retrieve existing meta values
    $website = get_post_meta($post->ID, 'sponsor_website', true);
    $phone = get_post_meta($post->ID, 'sponsor_phone', true);
    $facebook = get_post_meta($post->ID, 'sponsor_facebook', true);
    $twitter = get_post_meta($post->ID, 'sponsor_twitter', true);
    $instagram = get_post_meta($post->ID, 'sponsor_instagram', true);
    $linkedin = get_post_meta($post->ID, 'sponsor_linkedin', true);
    $last_event_date = get_post_meta($post->ID, 'sponsor_last_event_date', true); // New field
	$businessname = get_post_meta($post->ID, 'sponsor_business_name', true);
	$tiktok = get_post_meta($post->ID, 'sponsor_tiktok', true);
	$email = get_post_meta($post->ID, 'sponsor_email', true);
	
    echo '&lt;label>Website:&lt;/label>&lt;br/>
          &lt;input type="text" name="sponsor_website" value="' . esc_attr($website) . '" size="50" />&lt;br/>
          &lt;label>Phone:&lt;/label>&lt;br/>
          &lt;input type="text" name="sponsor_phone" value="' . esc_attr($phone) . '" size="50" />&lt;br/>
          &lt;label>Facebook:&lt;/label>&lt;br/>
          &lt;input type="text" name="sponsor_facebook" value="' . esc_attr($facebook) . '" size="50" />&lt;br/>
          &lt;label>Twitter:&lt;/label>&lt;br/>
          &lt;input type="text" name="sponsor_twitter" value="' . esc_attr($twitter) . '" size="50" />&lt;br/>
          &lt;label>Instagram:&lt;/label>&lt;br/>
          &lt;input type="text" name="sponsor_instagram" value="' . esc_attr($instagram) . '" size="50" />&lt;br/>
		  &lt;label>Tiktok:&lt;/label>&lt;br/>
		  &lt;input type="text" name="sponsor_tiktok" value="' . esc_attr($tiktok) . '" size="50" />&lt;br/>
		  &lt;label>Business Name:&lt;/label>&lt;br/>
          &lt;input type="text" name="sponsor_business_name" value="' . esc_attr($businessname) . '" size="50" />&lt;br/>
          &lt;label>LinkedIn:&lt;/label>&lt;br/>
          &lt;input type="text" name="sponsor_linkedin" value="' . esc_attr($linkedin) . '" size="50" />&lt;br/>
          &lt;label>Email:&lt;/label>&lt;br/>
          &lt;input type="text" name="sponsor_email" value="' . esc_attr($email) . '" size="50" />&lt;br/>
          &lt;label>&lt;strong>Last Sponsored Event Date:&lt;/strong>&lt;/label>&lt;br/>
          &lt;input type="date" name="sponsor_last_event_date" value="' . esc_attr($last_event_date) . '" />&lt;br/>';
}


// Save Meta Data
function save_sponsor_meta($post_id) {
    if (defined('DOING_AUTOSAVE') &amp;&amp; DOING_AUTOSAVE) return;
    if (isset($_POST&#91;'sponsor_website'])) update_post_meta($post_id, 'sponsor_website', sanitize_text_field($_POST&#91;'sponsor_website']));
    if (isset($_POST&#91;'sponsor_phone'])) update_post_meta($post_id, 'sponsor_phone', sanitize_text_field($_POST&#91;'sponsor_phone']));
    if (isset($_POST&#91;'sponsor_facebook'])) update_post_meta($post_id, 'sponsor_facebook', sanitize_text_field($_POST&#91;'sponsor_facebook']));
    if (isset($_POST&#91;'sponsor_twitter'])) update_post_meta($post_id, 'sponsor_twitter', sanitize_text_field($_POST&#91;'sponsor_twitter']));
    if (isset($_POST&#91;'sponsor_instagram'])) update_post_meta($post_id, 'sponsor_instagram', sanitize_text_field($_POST&#91;'sponsor_instagram']));
	if (isset($_POST&#91;'sponsor_linkedin'])) update_post_meta($post_id, 'sponsor_linkedin', sanitize_text_field($_POST&#91;'sponsor_linkedin']));
	if (isset($_POST&#91;'sponsor_business_name'])) update_post_meta($post_id, 'sponsor_business_name', sanitize_text_field($_POST&#91;'sponsor_business_name']));
	if (isset($_POST&#91;'sponsor_last_event_date'])) update_post_meta($post_id, 'sponsor_last_event_date', sanitize_text_field($_POST&#91;'sponsor_last_event_date']));
	if (isset($_POST&#91;'sponsor_tiktok'])) update_post_meta($post_id, 'sponsor_tiktok', sanitize_text_field($_POST&#91;'sponsor_tiktok']));
	if (isset($_POST&#91;'sponsor_email'])) update_post_meta($post_id, 'sponsor_email', sanitize_text_field($_POST&#91;'sponsor_email']));
}
add_action('save_post', 'save_sponsor_meta');

// Main Function to Fetch and Display Sponsor Info
function display_sponsor_info($atts) {
    $atts = shortcode_atts(array('name' => ''), $atts);
    $sponsor_name = sanitize_text_field($atts&#91;'name']);

    $args = array(
        'post_type'      => 'sponsors',
        'posts_per_page' => 1,
        'title'          => $sponsor_name
    );

    $query = new WP_Query($args);

    if ($query->have_posts()) {
        ob_start();
        while ($query->have_posts()) {
            $query->the_post();

            $last_event_date = get_post_meta(get_the_ID(), 'sponsor_last_event_date', true);
            $one_year_ago = date('Y-m-d', strtotime('-1 year'));
			$businessname = get_post_meta(get_the_ID(), 'sponsor_business_name', true);

            // If last sponsored event is over a year old, return only "Sponsored by: Sponsor Name"
            if ($last_event_date &amp;&amp; $last_event_date &lt; $one_year_ago) {
                echo "&lt;p>Sponsored by: " . $businessname . "&lt;/p>";
            } else {
                // Otherwise, return the full description
                $desc = apply_filters('the_content', get_the_content());
                if (!empty($desc)) {
                    echo "&lt;p>" . $desc . "&lt;/p>";
                }
            }
        }

        wp_reset_postdata();
        return ob_get_clean();
    }

    return "&lt;p>Sponsor not found.&lt;/p>";
}


// Shortcode Buffer Fix - Ensures Content Doesn't Flash
function sponsor_shortcode_buffer($atts) {
    return display_sponsor_info($atts); // Show sponsor directly in the content
}

// Register the shortcode
add_shortcode('sponsor', 'sponsor_shortcode_buffer');

// count sponsors function
function count_posts_with_sponsor($sponsor_name) {
    global $wpdb;

    // Search for sponsor name in post content
    $query = $wpdb->prepare("
        SELECT COUNT(ID) FROM $wpdb->posts 
        WHERE post_status = 'publish' 
        AND post_type = 'post' 
        AND post_content LIKE %s", 
        '%' . $wpdb->esc_like($sponsor_name) . '%'
    );

    return $wpdb->get_var($query);
}
//Export the sponsors 
function export_sponsors_csv() {
    if (!current_user_can('manage_options')) {
        wp_die(__('You do not have permission to access this page.'));
    }

    // Set headers to force CSV download
    header('Content-Type: text/csv; charset=utf-8');
    header('Content-Disposition: attachment; filename="sponsors.csv"');
    header('Pragma: no-cache');
    header('Expires: 0');

    // Open output stream
    $output = fopen('php://output', 'w');

    // Add column headers
    fputcsv($output, &#91;'Business Name','Shortcode','Last Sponsor Date','No of Ads','Website', 'Phone', 'Facebook', 'Twitter', 'Instagram', 'Last Update']);

    // Query sponsors
    $args = &#91;
        'post_type'      => 'sponsors',
        'posts_per_page' => -1
    ];
    $query = new WP_Query($args);

    if ($query->have_posts()) {
        while ($query->have_posts()) {
            $query->the_post();
            $sponsor_id   = get_the_ID();
            $sponsor_name = get_the_title($sponsor_id); // Use sponsor name

            // Use your existing function to count post mentions
            $usage_count = count_posts_with_sponsor($sponsor_name);

            // Get last updated date
            $last_updated = get_the_modified_date('Y-m-d H:i:s', $sponsor_id);

            fputcsv($output, &#91;
                get_post_meta($sponsor_id, 'sponsor_business_name', true),
				$sponsor_name,
				get_post_meta($sponsor_id, 'sponsor_last_event_date', true),
				$usage_count,
                get_post_meta($sponsor_id, 'sponsor_website', true),
                get_post_meta($sponsor_id, 'sponsor_phone', true),
                get_post_meta($sponsor_id, 'sponsor_facebook', true),
                get_post_meta($sponsor_id, 'sponsor_twitter', true),
                get_post_meta($sponsor_id, 'sponsor_instagram', true),
               
                $last_updated
            ]);
        }
    }

    fclose($output);
    exit;
}
add_action('admin_post_export_sponsors_csv', 'export_sponsors_csv');

// Make sure this is registered properly
add_action('admin_post_export_sponsors_csv', 'export_sponsors_csv');



//add sponsor export option to menu
function add_sponsor_post_count_column($columns) {
    $columns&#91;'sponsor_post_count'] = 'Posts Mentioning';
    return $columns;
}
add_filter('manage_sponsors_posts_columns', 'add_sponsor_post_count_column');

function show_sponsor_post_count_column($column, $post_id) {
    if ($column == 'sponsor_post_count') {
        $sponsor_name = get_the_title($post_id);
        echo count_posts_with_sponsor($sponsor_name);
    }
}
add_action('manage_sponsors_posts_custom_column', 'show_sponsor_post_count_column', 10, 2);

function export_sponsors_page() {
    ?>
    &lt;div class="wrap">
        &lt;h1>Export Sponsors&lt;/h1>
        &lt;p>Click the button below to download a CSV of all sponsors.&lt;/p>
        &lt;a href="&lt;?php echo esc_url(admin_url('admin-post.php?action=export_sponsors_csv')); ?>" class="button button-primary">
            Download Sponsors CSV
        &lt;/a>
    &lt;/div>
    &lt;?php
}

function add_sponsors_export_menu() {
    add_submenu_page(
        'edit.php?post_type=sponsors', // Adds under "Sponsors" menu
        'Export Sponsors',
        'Export Sponsors',
        'manage_options',
        'export_sponsors',
        'export_sponsors_page'
    );
}
add_action('admin_menu', 'add_sponsors_export_menu');

//1.95
function list_recent_sponsors() {
    $one_year_ago = date('Y-m-d', strtotime('-1 year'));
    
   $args = &#91;
        'post_type'      => 'sponsors',
        'posts_per_page' => -1,
        'meta_query'     => &#91;
            &#91;
                'key'     => 'sponsor_last_event_date',
                'value'   => $one_year_ago,
                'compare' => '>=',
                'type'    => 'DATE'
            ]
        ],
        'orderby'  => 'title', // Sort by sponsor name (post title)
        'order'    => 'ASC' // Ascending order (A-Z)
    ];
    
    $query = new WP_Query($args);

    if ($query->have_posts()) {
        $output = '&lt;ul class="recent-sponsors">';
        
        while ($query->have_posts()) {
            $query->the_post();
            $sponsor_name  = get_the_title();
            $sponsor_website = get_post_meta(get_the_ID(), 'sponsor_website', true);
            $last_event_date = get_post_meta(get_the_ID(), 'sponsor_last_event_date', true);
			$business_name  = get_post_meta(get_the_ID(), 'sponsor_business_name', true);
            $sponsor_tiktok = get_post_meta(get_the_ID(), 'sponsor_tiktok', true);
			$sponsor_instagram = get_post_meta(get_the_ID(), 'sponsor_instagram', true);
			$sponsor_facebook = get_post_meta(get_the_ID(), 'sponsor_facebook', true);
			$sponsor_email = get_post_meta(get_the_ID(), 'sponsor_email', true);
			$sponsor_phone = get_post_meta(get_the_ID(), 'sponsor_phone', true);
			$sponsor_linkedin = get_post_meta(get_the_ID(), 'sponsor_linkedin', true);
			$sponsor_twitter = get_post_meta(get_the_ID(), 'sponsor_twitter', true);
			
            $output .= '&lt;li>';

   $output .= '&lt;a href="' . esc_url(home_url('/sponsor/' . sanitize_title($sponsor_name))) . '" target="_blank">&lt;strong>' . esc_html($business_name) . '&lt;/strong>&lt;/a>';

// Adding an SVG for a web
if ($sponsor_website) {
    ob_start();  // Start output buffering

    ?>
    &lt;a href="&lt;?php echo esc_url($sponsor_website); ?>" target="_blank" style="display:inline-block;">
        &lt;div class="icon-bg custom-social-icon" style="display:inline-block; vertical-align:middle;">
            &lt;svg width="24" height="24" viewBox="0 0 24 24" version="1.1" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false">
    &lt;path d="M12.02,10.18v3.72v0.01h5.51c-0.26,1.57-1.67,4.22-5.5,4.22c-3.31,0-6.01-2.75-6.01-6.12s2.7-6.12,6.01-6.12 c1.87,0,3.13,0.8,3.85,1.48l2.84-2.76C16.99,2.99,14.73,2,12.03,2c-5.52,0-10,4.48-10,10s4.48,10,10,10c5.77,0,9.6-4.06,9.6-9.77 c0-0.83-0.11-1.42-0.25-2.05H12.02z">&lt;/path>
&lt;/svg>


        &lt;/div>
    &lt;/a>
    &lt;?php

    $output .= ob_get_clean();  // Capture the output and add it to $output
}
//tiktok
if ($sponsor_tiktok) {
    ob_start();  // Start output buffering

    ?>
    &lt;a href="&lt;?php echo esc_url($sponsor_tiktok); ?>" target="_blank" style="display:inline-block;">
        &lt;div class="icon-bg custom-social-icon" style="display:inline-block; vertical-align:middle;">
            &lt;svg width="24" height="24" viewBox="0 0 24 24" fill="black" xmlns="http://www.w3.org/2000/svg">
            &lt;path d="M12 2a10 10 0 100 20 10 10 0 000-20zm3.75 5.125c.513 1.393 1.69 2.417 3.125 2.75v2.375a5.995 5.995 0 01-3.125-.875v4.625c0 2.205-1.79 4-4 4s-4-1.795-4-4 1.79-4 4-4c.183 0 .363.015.539.038v2.416a2.01 2.01 0 00-.539-.064 2.001 2.001 0 00-2 2c0 1.104.896 2 2 2s2-.896 2-2V7.75h2.5z"/>
        &lt;/svg>
        &lt;/div>
    &lt;/a>
    &lt;?php

    $output .= ob_get_clean();  // Capture the output and add it to $output
}
//instagram
if ($sponsor_instagram) {
    ob_start();  // Start output buffering

    ?>
    &lt;a href="&lt;?php echo esc_url($sponsor_instagram); ?>" target="_blank" style="display:inline-block;">
        &lt;div class="icon-bg custom-social-icon" style="display:inline-block; vertical-align:middle;">
            &lt;svg width="24" height="24" viewBox="0 0 24 24" fill="black" xmlns="http://www.w3.org/2000/svg">
            &lt;path d="M12 2.163c3.204 0 3.584.012 4.85.07 3.252.148 4.771 1.691 4.92 4.92.058 1.267.07 1.647.07 4.85s-.012 3.584-.07 4.85c-.149 3.229-1.668 4.771-4.92 4.92-1.266.058-1.646.07-4.85.07s-3.584-.012-4.85-.07c-3.229-.149-4.771-1.691-4.92-4.92C2.175 15.583 2.163 15.203 2.163 12s.012-3.584.07-4.85c.149-3.229 1.691-4.771 4.92-4.92 1.267-.058 1.647-.07 4.85-.07M12 0C8.741 0 8.332.012 7.053.07 2.94.25.25 2.94.07 7.053.012 8.332 0 8.741 0 12s.012 3.668.07 4.947c.18 4.113 2.87 6.803 6.983 6.983 1.279.058 1.688.07 4.947.07s3.668-.012 4.947-.07c4.113-.18 6.803-2.87 6.983-6.983.058-1.279.07-1.688.07-4.947s-.012-3.668-.07-4.947C23.75 2.94 21.06.25 16.947.07 15.668.012 15.259 0 12 0zm0 5.838a6.162 6.162 0 100 12.324 6.162 6.162 0 000-12.324zm0 10.162a3.999 3.999 0 110-7.998 3.999 3.999 0 010 7.998zM18.406 4.594a1.44 1.44 0 11-2.88 0 1.44 1.44 0 012.88 0z"/>
        &lt;/svg>
        &lt;/div>
    &lt;/a>
    &lt;?php

    $output .= ob_get_clean();  // Capture the output and add it to $output
}
//facebook
if ($sponsor_facebook) {
    ob_start();  // Start output buffering

    ?>
    &lt;a href="&lt;?php echo esc_url($sponsor_facebook); ?>" target="_blank" style="display:inline-block;">
        &lt;div class="icon-bg custom-social-icon" style="display:inline-block; vertical-align:middle;">
			&lt;svg width="24" height="24" viewBox="0 0 24 24" fill="currentColor" xmlns="http://www.w3.org/2000/svg">
			&lt;path d="M22.675 0h-21.35C.595 0 0 .595 0 1.325v21.351C0 23.405.595 24 1.325 24H12.82v-9.294H9.692V11.08h3.128V8.412c0-3.1 1.892-4.786 4.659-4.786 1.325 0 2.463.099 2.795.143v3.24h-1.919c-1.505 0-1.796.716-1.796 1.764v2.307h3.589l-.467 3.625h-3.122V24h6.127c.73 0 1.325-.595 1.325-1.324V1.325C24 .595 23.405 0 22.675 0z"/>
			&lt;/svg>
        &lt;/div>
    &lt;/a>
    &lt;?php

    $output .= ob_get_clean();  // Capture the output and add it to $output
}

//email
if ($sponsor_email) {
    ob_start();  // Start output buffering

    ?>
    &lt;a href="&lt;?php echo esc_url($sponsor_email); ?>" target="_blank" style="display:inline-block;">
        &lt;div class="icon-bg custom-social-icon" style="display:inline-block; vertical-align:middle;">
			&lt;svg width="800px" height="800px" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
&lt;path d="M4 9.00005L10.2 13.65C11.2667 14.45 12.7333 14.45 13.8 13.65L20 9" stroke="#000000" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
&lt;path d="M3 9.17681C3 8.45047 3.39378 7.78123 4.02871 7.42849L11.0287 3.5396C11.6328 3.20402 12.3672 3.20402 12.9713 3.5396L19.9713 7.42849C20.6062 7.78123 21 8.45047 21 9.17681V17C21 18.1046 20.1046 19 19 19H5C3.89543 19 3 18.1046 3 17V9.17681Z" stroke="#000000" stroke-width="2" stroke-linecap="round"/>
&lt;/svg>
        &lt;/div>
    &lt;/a>
    &lt;?php

    $output .= ob_get_clean();  // Capture the output and add it to $output
}
//LinkedIn
if ($sponsor_linkedin) {
    ob_start();  // Start output buffering

    ?>
    &lt;a href="&lt;?php echo esc_url($sponsor_linkedin); ?>" target="_blank" style="display:inline-block;">
        &lt;div class="icon-bg custom-social-icon" style="display:inline-block; vertical-align:middle;">
			&lt;svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
  &lt;path d="M22.23 0H1.77C.79 0 0 .79 0 1.77v20.46c0 .98.79 1.77 1.77 1.77h20.46c.98 0 1.77-.79 1.77-1.77V1.77C24 .79 23.21 0 22.23 0zM7.14 20.45H3.56V9h3.58v11.45zm-1.79-12.98c-1.13 0-1.91-.77-1.91-1.73 0-.98.78-1.73 1.91-1.73s1.91.75 1.91 1.73c0 .96-.78 1.73-1.91 1.73zm14.89 12.98h-3.58v-5.94c0-1.42-.51-2.39-1.79-2.39-.97 0-1.55.66-1.81 1.3-.09.22-.12.53-.12.83v6.2h-3.58V9h3.58v1.56c.47-.71 1.28-1.76 3.11-1.76 2.28 0 4.11 1.48 4.11 4.67v6.98z"/>
&lt;/svg>

        &lt;/div>
    &lt;/a>
    &lt;?php

    $output .= ob_get_clean();  // Capture the output and add it to $output
}

//twitter
if ($sponsor_twitter) {
    ob_start();  // Start output buffering

    ?>
    &lt;a href="&lt;?php echo esc_url($sponsor_twitter); ?>" target="_blank" style="display:inline-block;">
        &lt;div class="icon-bg custom-social-icon" style="display:inline-block; vertical-align:middle;">
			&lt;svg width="24" height="24" viewBox="0 0 24 24" version="1.1" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false">&lt;path d="M13.982 10.622 20.54 3h-1.554l-5.693 6.618L8.745 3H3.5l6.876 10.007L3.5 21h1.554l6.012-6.989L15.868 21h5.245l-7.131-10.378Zm-2.128 2.474-.697-.997-5.543-7.93H8l4.474 6.4.697.996 5.815 8.318h-2.387l-4.745-6.787Z">&lt;/path>&lt;/svg>

        &lt;/div>
    &lt;/a>
    &lt;?php

    $output .= ob_get_clean();  // Capture the output and add it to $output
}
//phone
if ($sponsor_phone) {
    ob_start();  // Start output buffering

    ?>
    &lt;a href="&lt;?php echo esc_url($sponsor_phone); ?>" target="_blank" style="display:inline-block;">
        &lt;div class="icon-bg custom-social-icon" style="display:inline-block; vertical-align:middle;">
			&lt;svg xmlns="http://www.w3.org/2000/svg"  viewBox="0 0 50 50" width="50px" height="50px">&lt;path d="M 14 3.9902344 C 8.4886661 3.9902344 4 8.4789008 4 13.990234 L 4 35.990234 C 4 41.501568 8.4886661 45.990234 14 45.990234 L 36 45.990234 C 41.511334 45.990234 46 41.501568 46 35.990234 L 46 13.990234 C 46 8.4789008 41.511334 3.9902344 36 3.9902344 L 14 3.9902344 z M 18.005859 12.033203 C 18.633859 12.060203 19.210594 12.414031 19.558594 12.957031 C 19.954594 13.575031 20.569141 14.534156 21.369141 15.785156 C 22.099141 16.926156 22.150047 18.399844 21.498047 19.589844 L 20.033203 21.673828 C 19.637203 22.237828 19.558219 22.959703 19.824219 23.595703 C 20.238219 24.585703 21.040797 26.107203 22.466797 27.533203 C 23.892797 28.959203 25.414297 29.761781 26.404297 30.175781 C 27.040297 30.441781 27.762172 30.362797 28.326172 29.966797 L 30.410156 28.501953 C 31.600156 27.849953 33.073844 27.901859 34.214844 28.630859 C 35.465844 29.430859 36.424969 30.045406 37.042969 30.441406 C 37.585969 30.789406 37.939797 31.366141 37.966797 31.994141 C 38.120797 35.558141 35.359641 37.001953 34.556641 37.001953 C 34.000641 37.001953 27.316344 37.761656 19.777344 30.222656 C 12.238344 22.683656 12.998047 15.999359 12.998047 15.443359 C 12.998047 14.640359 14.441859 11.879203 18.005859 12.033203 z"/>&lt;/svg>


        &lt;/div>
    &lt;/a>
    &lt;?php

    $output .= ob_get_clean();  // Capture the output and add it to $output
}
// Add last event date for admins
if (current_user_can('administrator')) {
    $output .= ' -- (Last Sponsored: ' . esc_html($last_event_date) . ')';
}

$output .= '&lt;/li>';



        }
        
        $output .= '&lt;/ul>';
    } else {
        $output = '&lt;p>No recent sponsors found.&lt;/p>';
    }

    wp_reset_postdata();
    
    return $output;
}
add_shortcode('recent_sponsors', 'list_recent_sponsors');

?></code></pre>



<p>I have removed or commented out sections of this code i no longer require to expand its functionality. If you are having issues getting this working drop me an email.</p>



<p>Other <a href="/category/wordpress">WordPress Plugin Posts</a></p>



<p>Other <a href="https://wordpress.org/plugins/tags/sponsors/" target="_blank" data-type="link" data-id="https://wordpress.org/plugins/tags/sponsors/" rel="noreferrer noopener">WordPress Plugins </a>which may satisfy your requirements</p>
]]></content:encoded>
					
		
		
			</item>
	</channel>
</rss>
