When I go to the dashboard>settings>permalinks and click save changes, this code disappears
It sounds like WordPress is overwriting your htaccess file when you save. Thus, your changes are gone.
Perhaps set this up outside of the htaccess in the apache config? Or ask your host to do this for you. Then WP can’t overwrite it 🙂
Related Posts:
- How Do I Set the Page Title Dynamically?
- Is sanitize_title enough to generate post slugs?
- Robots.txt not updating
- Adding rel=”next” & rel=”prev” for paginated archives
- NoFollow Entire Website
- Creating 301 Redirects for Post, Page, Category and Image URLs?
- How do I set up a custom URL shortener for my posts?
- Does the ‘WordPress Order’ feature, within the WordPress Dashboard, have any impact on site architecture?
- SEO – Two WordPress websites on same domain name
- add post content in meta description in yoast
- Migrating from other CMS to WP – losing SEO juice?
- Blog not indexed [closed]
- Remove date from Google Search Results Description
- Duplicate Australian E-Commerce site
- Add image tags to native WordPress XML Sitemaps
- What does short_ping do?
- Disallow author with robots.txt
- Seo WordPress Pages on google [closed]
- Hard code a domain into Yoast SEO canonical URLs
- How to remove duplicate blog title
- Change Site Title and Description html tags if not home page
- Set different Canonical url programmatically for every post
- What does it mean by “Home page / Archives” in JetPack Site Stats? [closed]
- WordPress Blog and SEO
- Will using REST API impact SEO? [closed]
- How to Appease the Google PageSpeed Gods with regards to image optimization?
- robots.txt Not Updating
- is it good to use WordPress in the same url extension in terms of seo?
- How to solve Robots.txt problem with WordPress fresh install?
- Yoast SEO: title tags are repeating my website name and slogan [closed]
- How to ensure that a landing page created with WordPress does not enter the sitemap?
- How may I see all the pages on my wordpress website and see when they were created?
- Reactjs headless WordPress theme configure SEO
- Search Console detects Category Pagination data as Duplicate Meta Description
- SEO optimization gone not so well
- Google PageSpeed Enable Compression isn’t working?
- Automatic SEO for wordpress [closed]
- How to hide sensitve page from google spiders and non-membres in wordpress!
- Theme compression/ minifying or W3 Total Cache – which should I use? [closed]
- Custom Canonical URLs
- ASCII titles with Yoast SEO plugin
- What is/are the best thing(s) I can do to make my WordPress blog more popular? [closed]
- how to set title of each page or post for SEO
- Search Engine Visibility checkbox after indexed
- how to 301 redirect from a plugin folder
- best way to stop this wordpress duplicate content
- Embed sitemap in a page
- charset problem in wordpress because of nginx config
- Is Shared server effect SEO
- wp_strip_all_tags [closed]
- How to stop showing my under development site on Google Search [closed]
- Updating old website links to new website links [closed]
- Search results show a different site [closed]
- Fix description of website on Google Search result
- SEO is not working on pages [closed]
- Google isn’t able to search my website
- Pinging or sitemap plugin: which practice is better
- How do I create custom tags for WordPress SEO? [closed]
- The inner mechanism of WP SEO plugins
- Does having two installations of WordPress negatively affect SEO? [closed]
- Maintain SEO of a website while migrating it to WordPress?
- Word Press Permalink Change
- WordPress Meta Title Separator
- Yoast SEO plugin – Sitemap links greyed out & page priority
- Customizing SERP content for WordPress Blog
- Pages and posts with Rel Canonical issues across entire site
- How to dissallow all wordpress posts in robots.txt?
- I have redesigned a website and my blog page has different permalinks
- WordPress site for increase SEO ranking in other e-commerce store
- Remove Noindex?
- WordPress Embed Page no-index meta data missing
- WordPress built-in compression of images? How well does it compare to Photoshop or Shortpixel?
- Unlimited false pages showing in Sitemap?
- Sitemap not containing all pages
- How to add blog in default WordPress post type for SEO standard rule?
- Metatag Discription on site [closed]
- Not sure if to keep this or not (noindex question)
- Facing Problem with Description in Post and Home Page in WordPress
- My blog name refer to different domain in SERP
- Sub category text in the URL of wordpress site
- Change WordPress url for newly formed posts or pages
- Best Way To Structure 3 Tiered Site
- deeplink juggernaut – remove settings
- How to change the post title to h1 [closed]
- special XML to wordpress posts
- wordpress theme: on site seo [closed]
- Tagline showing instead of meta description!
- Not Being Indexed by Search Engines [closed]
- Disallow /cgi-bin or not? [closed]
- Dispise all efforts, open graph is a total mess
- Google Tag Manage – to use or not to use
- Multiple Domains Same Install Different Static Pages
- Post title not output correctly
- How to Make your Category Titles have H1 tags?
- Can I delete the redirection in WordPress after switching URLs manually?
- Hide my staging subdomains from search results without impacting the visibility of the root domain
- If a landing page is my home page, and it shouldn’t contain navigation links, then how should it lead to other pages? [closed]
- How to improve WordPress website SEO and traffic, and or fix SEO issues
- Yoasts plugin sitemap not detecting correct category URL format
- How to fix Links do not have descriptive text PageSpeed Insights