Title: Exclude RSS
Last modified: December 28, 2019

---

# Exclude RSS

 *  Resolved [georg](https://wordpress.org/support/users/fertila/)
 * (@fertila)
 * [6 years, 5 months ago](https://wordpress.org/support/topic/exclude-rss/)
 * I would like to exclude the external RSS Feed news.fertila.de from caching on
   my home under fertila.de. How can i do this in htaccess or WP LS Plugin? Thanks.
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fexclude-rss%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 9 replies - 1 through 9 (of 9 total)

 *  [Shivam](https://wordpress.org/support/users/ixaris/)
 * (@ixaris)
 * [6 years, 5 months ago](https://wordpress.org/support/topic/exclude-rss/#post-12276726)
 * Hi [@fertila](https://wordpress.org/support/users/fertila/) ,
 * You can utilize the Exclude Cache option, Here’s a detailed Wiki – [https://www.litespeedtech.com/support/wiki/doku.php/litespeed_wiki:cache:lscwp:configuration:excludes#do_not_cache_uris](https://www.litespeedtech.com/support/wiki/doku.php/litespeed_wiki:cache:lscwp:configuration:excludes#do_not_cache_uris)
 * Best Regards
 *  Thread Starter [georg](https://wordpress.org/support/users/fertila/)
 * (@fertila)
 * [6 years, 5 months ago](https://wordpress.org/support/topic/exclude-rss/#post-12276902)
 * Hi Shivam,
    thanks a lot for the reply and the hint. I had a look in the documentation
   already and tried to exclude ^news.fertila.de/feed/ However this does not work.
   The only way I could see is to exclude my home, which I do not want. Any other
   ideas? Best regards Georg
 *  [stanley@litespeed](https://wordpress.org/support/users/stanleylitespeed/)
 * (@stanleylitespeed)
 * [6 years, 5 months ago](https://wordpress.org/support/topic/exclude-rss/#post-12280086)
 * Hi [@fertila](https://wordpress.org/support/users/fertila/), the setting page`
   Do Not Cache URIs` are just working for the same root domain. If you’d like to
   exclude another domain from cache, you may try the following script, please try
   to put the following method on theme’s function.php:
 *     ```
       if ( method_exists( 'LiteSpeed_Cache_API', 'set_nocache' ) ) {
       	$actual_link = "http://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]";
   
       	if ( $actual_link === 'http://YOUR_ROOT_URL/' ) {
       		LiteSpeed_Cache_API::set_nocache( 'Disable root URL from cache' ) ;
       	}
       }
       ```
   
 *  Thread Starter [georg](https://wordpress.org/support/users/fertila/)
 * (@fertila)
 * [6 years, 5 months ago](https://wordpress.org/support/topic/exclude-rss/#post-12281938)
 * Hi [@stanleylitespeed](https://wordpress.org/support/users/stanleylitespeed/)
   
   thank you so much for the code snippet. I put
 *     ```
       if ( method_exists( 'LiteSpeed_Cache_API', 'set_nocache' ) ) {
       	$actual_link = "https://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]";
   
       	if ( $actual_link === 'https://news.fertila.de/' ) {
       		LiteSpeed_Cache_API::set_nocache( 'Disable root URL from cache' ) ;
       	}
       }
       ```
   
 * in my functions.php. However this does not seem to work. Anything else I might
   have to consider?
 * Georg
    -  This reply was modified 6 years, 5 months ago by [georg](https://wordpress.org/support/users/fertila/).
    -  This reply was modified 6 years, 5 months ago by [georg](https://wordpress.org/support/users/fertila/).
 *  [stanley@litespeed](https://wordpress.org/support/users/stanleylitespeed/)
 * (@stanleylitespeed)
 * [6 years, 5 months ago](https://wordpress.org/support/topic/exclude-rss/#post-12281946)
 * Did you purge the cache and rerun again? Also, can you check does LiteSpeed_Cache_API::
   set_nocache run inside the condition?
 *  Thread Starter [georg](https://wordpress.org/support/users/fertila/)
 * (@fertila)
 * [6 years, 5 months ago](https://wordpress.org/support/topic/exclude-rss/#post-12281955)
 * I just purged the cache. How would I check if LiteSpeed_Cache_API::set_nocache
   runs inside the condition?
 *  [stanley@litespeed](https://wordpress.org/support/users/stanleylitespeed/)
 * (@stanleylitespeed)
 * [6 years, 5 months ago](https://wordpress.org/support/topic/exclude-rss/#post-12281963)
 * You can put an error_log inside that condition to print out something on log 
   or check on the LiteSpeed debug log.
 *  Thread Starter [georg](https://wordpress.org/support/users/fertila/)
 * (@fertila)
 * [6 years, 5 months ago](https://wordpress.org/support/topic/exclude-rss/#post-12282001)
 * I cannot see nocache instances for this URL in the debug log.
 *  [stanley@litespeed](https://wordpress.org/support/users/stanleylitespeed/)
 * (@stanleylitespeed)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/exclude-rss/#post-12285825)
 * Could you try to simply put `LiteSpeed_Cache_API::set_nocache( 'Disable root 
   URL from cache' ) ;` on `functions.php`, purge all cache and see does that page
   loaded without cache hit.
 * If it’s still not working please [join our Slack channel and find me(Stanley Cheung at Litespeed)](https://join.slack.com/t/golitespeed/shared_invite/enQtMzE5ODgxMTUyNTgzLTNiNWQ1MWZlYmI4YjEzNTM4NjdiODY2YTQ0OWVlMzBlNGZkY2E3Y2E4MjIzNmNmZmU0ZjIyNWM1ZmNmMWRlOTk/)
   for reproducing the issue.

Viewing 9 replies - 1 through 9 (of 9 total)

The topic ‘Exclude RSS’ is closed to new replies.

 * ![](https://ps.w.org/litespeed-cache/assets/icon-256x256.png?rev=2554181)
 * [LiteSpeed Cache](https://wordpress.org/plugins/litespeed-cache/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/litespeed-cache/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/litespeed-cache/)
 * [Active Topics](https://wordpress.org/support/plugin/litespeed-cache/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/litespeed-cache/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/litespeed-cache/reviews/)

## Tags

 * [RSS](https://wordpress.org/support/topic-tag/rss/)

 * 9 replies
 * 3 participants
 * Last reply from: [stanley@litespeed](https://wordpress.org/support/users/stanleylitespeed/)
 * Last activity: [6 years, 4 months ago](https://wordpress.org/support/topic/exclude-rss/#post-12285825)
 * Status: resolved