<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Indexing add-on blocks]]></title><description><![CDATA[<p dir="auto">I'm using WP Page Editor's Accordion addon block to create an FAQ page.  However, the contents of this page is not indexed at all.</p>
<p dir="auto"><img src="/forum/assets/uploads/files/1699348864803-screenshot-2023-11-07-112022.png" alt="Screenshot 2023-11-07 112022.png" class=" img-fluid img-markdown" /></p>
<p dir="auto">Why is this and how can I change this behaviour?</p>
]]></description><link>https://fulltextsearch.org/forum/topic/162/indexing-add-on-blocks</link><generator>RSS for Node</generator><lastBuildDate>Wed, 12 Aug 2026 06:21:18 GMT</lastBuildDate><atom:link href="https://fulltextsearch.org/forum/topic/162.rss" rel="self" type="application/rss+xml"/><pubDate>Tue, 07 Nov 2023 09:21:34 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Indexing add-on blocks on Tue, 07 Nov 2023 11:22:50 GMT]]></title><description><![CDATA[<p dir="auto">Here is the accordion.php code that creates the faq entries.</p>
<p dir="auto"><a href="/forum/assets/uploads/files/1699355995254-accordion.php.txt">accordion.php.txt</a></p>
<p dir="auto">I added the code from the documentation to my function.php in the child theme, but of course this is not a post type I'm dealing with, but a page with an add-on.</p>
<pre><code>/**
 * This snippet adds metadata of "employee" post to search index
 */ 
add_filter('wpfts_index_post', function($index, $post)
{ 
    global $wpdb;

    // Basic tokens 
    /* 
     * This piece of code was commented out intentionally to display things
     * which was already done before in the caller code
    $index['post_title'] = $post-&gt;post_title;
    $index['post_content'] = strip_tags($post-&gt;post_content);
    */
    if ($post-&gt;post_type == 'employee') {
        // Adding new token "employee_data" specially for posts of type "employee"
        $data = array(); 
        $data[] = get_post_meta($post-&gt;ID, 'address', true);
        $data[] = get_post_meta($post-&gt;ID, 'phone', true); 
        $data[] = get_post_meta($post-&gt;ID, 'name', true);
        $data[] = get_post_meta($post-&gt;ID, 'function', true);
        $index['employee_data'] = implode(' ', $data);
    } 
    return $index; 
}, 3, 2);
</code></pre>
]]></description><link>https://fulltextsearch.org/forum/post/417</link><guid isPermaLink="true">https://fulltextsearch.org/forum/post/417</guid><dc:creator><![CDATA[Lifeboy]]></dc:creator><pubDate>Tue, 07 Nov 2023 11:22:50 GMT</pubDate></item></channel></rss>