<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Trying to Filter Webpage Search Results by Subdirectory in Blog, Website &amp; Page Publishing</title>
    <link>https://community.hubspot.com/t5/Blog-Website-Page-Publishing/Trying-to-Filter-Webpage-Search-Results-by-Subdirectory/m-p/980079#M12350</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/765377"&gt;@RayOfSunshine&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This probably depends on what you consider a "custom search bar" to be. If you're asking whether this can be done with a setting within HubSpot or the default modules, then no.&amp;nbsp;However, this could likely be done by cloning and modifying the default search input module with some code and creating designated search result pages.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In the cloned version, you would need to add a hidden input field for pathPrefix and in the value attribute, you would add your subdirectory. This would be placed inside the &amp;lt;form&amp;gt; element (with a customized action attribute):&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;&amp;lt;form action="/Option1/search"&amp;gt;
...
&amp;lt;input type="hidden" name="pathPrefix" value="Option1"&amp;gt;
....
&amp;lt;/form&amp;gt;&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Then you would need to set up a page for your search results, which would be a regular website page (instead of a system page) but it would contain a search results module. Note that the URL of the search results page would need to follow what you have in the action attribute of the form element (i.e. &lt;A href="http://www.example.com/Option1/search" target="_blank" rel="noopener"&gt;www.example.com/Option1/search&lt;/A&gt; ).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Obviously you would need to make sure that the cloned search input is present in the header/footer (or wherever it will be placed) instead of the default search input module.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In your case, you would need to do this twice (create a customized version for each of the options you mentioned).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;No javascript needed&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hope this helps!&lt;/P&gt;</description>
    <pubDate>Wed, 22 May 2024 01:56:36 GMT</pubDate>
    <dc:creator>evaldas</dc:creator>
    <dc:date>2024-05-22T01:56:36Z</dc:date>
    <item>
      <title>Trying to Filter Webpage Search Results by Subdirectory</title>
      <link>https://community.hubspot.com/t5/Blog-Website-Page-Publishing/Trying-to-Filter-Webpage-Search-Results-by-Subdirectory/m-p/979935#M12345</link>
      <description>&lt;P&gt;I'm working on a website experience with two diverse experiences. &lt;A href="http://www.example.com/Option1" target="_blank" rel="noopener"&gt;www.example.com/Option1&lt;/A&gt; and &lt;A href="http://www.example.com/Option2" target="_blank" rel="noopener"&gt;www.example.com/Option2&lt;/A&gt;. Additionally, I have blogs that are specific to the experiences at example.com/blog/Option1/BlogName and example.com/blog/Option2. At some point, the start point for the user journey will be a "choose your own adventure" page that is example.com/choose and has a CTA attached to the home page of each option.&lt;BR /&gt;&lt;BR /&gt;Currently, Hubspot visual editor allows my top nav menu search bar to filter between types of content (website pages, landing pages, etc.), but I'm wondering what the best approach to filtering these blogs by experience would be. Considerations to include are SEO impact and user experience.&lt;BR /&gt;&lt;BR /&gt;Is there a way to accomplish this without using a custom search bar and JavaScript to do the content slug filtering?&lt;/P&gt;</description>
      <pubDate>Tue, 21 May 2024 18:49:33 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/Blog-Website-Page-Publishing/Trying-to-Filter-Webpage-Search-Results-by-Subdirectory/m-p/979935#M12345</guid>
      <dc:creator>RayOfSunshine</dc:creator>
      <dc:date>2024-05-21T18:49:33Z</dc:date>
    </item>
    <item>
      <title>Re: Trying to Filter Webpage Search Results by Subdirectory</title>
      <link>https://community.hubspot.com/t5/Blog-Website-Page-Publishing/Trying-to-Filter-Webpage-Search-Results-by-Subdirectory/m-p/980079#M12350</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.hubspot.com/t5/user/viewprofilepage/user-id/765377"&gt;@RayOfSunshine&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This probably depends on what you consider a "custom search bar" to be. If you're asking whether this can be done with a setting within HubSpot or the default modules, then no.&amp;nbsp;However, this could likely be done by cloning and modifying the default search input module with some code and creating designated search result pages.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In the cloned version, you would need to add a hidden input field for pathPrefix and in the value attribute, you would add your subdirectory. This would be placed inside the &amp;lt;form&amp;gt; element (with a customized action attribute):&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;&amp;lt;form action="/Option1/search"&amp;gt;
...
&amp;lt;input type="hidden" name="pathPrefix" value="Option1"&amp;gt;
....
&amp;lt;/form&amp;gt;&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Then you would need to set up a page for your search results, which would be a regular website page (instead of a system page) but it would contain a search results module. Note that the URL of the search results page would need to follow what you have in the action attribute of the form element (i.e. &lt;A href="http://www.example.com/Option1/search" target="_blank" rel="noopener"&gt;www.example.com/Option1/search&lt;/A&gt; ).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Obviously you would need to make sure that the cloned search input is present in the header/footer (or wherever it will be placed) instead of the default search input module.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In your case, you would need to do this twice (create a customized version for each of the options you mentioned).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;No javascript needed&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hope this helps!&lt;/P&gt;</description>
      <pubDate>Wed, 22 May 2024 01:56:36 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/Blog-Website-Page-Publishing/Trying-to-Filter-Webpage-Search-Results-by-Subdirectory/m-p/980079#M12350</guid>
      <dc:creator>evaldas</dc:creator>
      <dc:date>2024-05-22T01:56:36Z</dc:date>
    </item>
    <item>
      <title>Re: Trying to Filter Webpage Search Results by Subdirectory</title>
      <link>https://community.hubspot.com/t5/Blog-Website-Page-Publishing/Trying-to-Filter-Webpage-Search-Results-by-Subdirectory/m-p/980494#M12355</link>
      <description>&lt;P&gt;Thank you for the response. That helps a bunch. A "custom search bar" to me is anything that requires enough customization that if it broke, it would take a front-end dev or someone who's moderately familiar with html or javascript to debug and repair. I'll keep your response in mind and if I end up using it, I'll be sure to mark it as the solution so you get the credit.&lt;/P&gt;</description>
      <pubDate>Wed, 22 May 2024 14:24:48 GMT</pubDate>
      <guid>https://community.hubspot.com/t5/Blog-Website-Page-Publishing/Trying-to-Filter-Webpage-Search-Results-by-Subdirectory/m-p/980494#M12355</guid>
      <dc:creator>RayOfSunshine</dc:creator>
      <dc:date>2024-05-22T14:24:48Z</dc:date>
    </item>
  </channel>
</rss>

