• Hi

    My website link is https://avirupchatterjee.com.
    To get the feed url in the format https://avirupchatterjee.com/feed I have included the following code in the header.

    <link rel="shortcut icon" href="<?php echo get_stylesheet_directory_uri(); ?>/favicon.ico" />
        <link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="<?php bloginfo('rss2_url'); ?>" />
        <link rel="alternate" type="text/xml" title="RSS .92" href="<?php bloginfo('rss_url'); ?>" />
        <link rel="alternate" type="application/atom+xml" title="Atom 0.3" href="<?php bloginfo('atom_url'); ?>" />
        <link rel="alternate" type="application/rss+xml" title="<?php bloginfo('name'); ?> RSS Comments Feed" href="<?php bloginfo(‘comments_rss2_url’); ?>" />

    But seems like something is wrong. As the https://avirupchatterjee.com/?feed=rss2 does not seem to work. It’s always redirecting me ONLY to “avirupchatterjee”

    My permalink is in custom mode “https://avirupchatterjee.com/%category%/%postname%/&#8221;

    Can anyone help me to fix this issue.

Viewing 13 replies - 1 through 13 (of 13 total)
  • @avirupchatterjee, In your theme’s header.php, remove the following line…

    <link rel="alternate" type="application/rss+xml" title="avirupchatterjee RSS Comments Feed" href="avirupchatterjee" />

    Thread Starter avirupchatterjee

    (@avirupchatterjee)

    @dipak

    Thanks for the reply. I removed the following line.

    <link rel="alternate" type="application/rss+xml" title="<?php bloginfo('name'); ?> RSS Comments Feed" href="<?php bloginfo(‘comments_rss2_url’); ?>" /

    Even then Its still redirecting me to “avirupchatterjee/”

    @avirupchatterjee, You don’t have to remove the above line, undo it.

    Paste the contents of your header.php file.

    Thread Starter avirupchatterjee

    (@avirupchatterjee)

    Thanks. I have removed the line. It’s still redirecting me to avirupchatterjee only. Please refer my current header code

    <?php
    /**
     * The Header for our theme
     *
     * Displays all of the <head> section and everything up till <div id="main">
     * @author Avirup Chatterjee
     * @package WordPress
     * @subpackage Twenty_Fourteen
     * @since Twenty Fourteen 1.0
     */
    ?><!DOCTYPE html>
    <!--[if IE 7]>
    <html class="ie ie7" <?php language_attributes(); ?>>
    <![endif]-->
    <!--[if IE 8]>
    <html class="ie ie8" <?php language_attributes(); ?>>
    <![endif]-->
    <!--[if !(IE 7) | !(IE 8) ]><!-->
    <html <?php language_attributes(); ?>>
    <!--<![endif]-->
    <head>
        <link rel="shortcut icon" href="<?php echo get_stylesheet_directory_uri(); ?>/favicon.ico" />
        <link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="<?php bloginfo('rss2_url'); ?>" />
        <link rel="alternate" type="text/xml" title="RSS .92" href="<?php bloginfo('rss_url'); ?>" />
        <link rel="alternate" type="application/atom+xml" title="Atom 0.3" href="<?php bloginfo('atom_url'); ?>" />
    	<meta charset="<?php bloginfo( 'charset' ); ?>">
    	<meta name="viewport" content="width=device-width">
    	<title><?php wp_title( '|', true, 'right' ); ?></title>
    	<meta name="alexaVerifyID" content="yBAN6o-fIj7KifhGNp4qribNPrQ"/>
    	<link rel="profile" href="https://gmpg.org/xfn/11">
    	<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>">
    	<!--[if lt IE 9]>
    	<script src="<?php echo get_template_directory_uri(); ?>/js/html5.js"></script>
    	<!-- jQuery library (served from Google) -->
        <script src="//ajax.googleapis.com/ajax/libs/jquery/1.9.0/jquery.min.js"></script>
        <!-- bxSlider Javascript file -->
        <script src="<?php bloginfo('stylesheet_directory'); ?>/js/libs/jquery.bxslider.min.js"></script>
        <script src="<?php bloginfo('stylesheet_directory'); ?>/js/libs/slidercall.js"></script>
    	<!-- <![endif]-->
    	<?php wp_head(); ?>
    </head>
    
    <body <?php body_class(); ?>>
    <div id="page" class="hfeed site">
    	<?php if ( get_header_image() ) : ?>
    	<div id="site-header">
    		<a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home">
    			<img src="<?php header_image(); ?>" width="<?php echo get_custom_header()->width; ?>" height="<?php echo get_custom_header()->height; ?>" alt="">
    		</a>
    	</div>
    	<?php endif; ?>
    <?php
    $facebook = "https://www.facebook.com/pages/avirupchatterjee/690758187637465";
    $twitter = "https://twitter.com/avirupBlogger";
    $instagram = "https://instagram.com/avirupavirup";
    $flickr = "https://www.flickr.com/photos/avirup_photography/sets/";
    $feed = "https://feeds.feedburner.com/avirupchatterjee";
    ?>
    
    	<header id="masthead" class="site-header" role="banner">
    		<div class="header-main">
    		    <div class="social-header">
    	         <a class="header-feed" href="<?php echo $feed; ?>" target="_blank" >
    			          <?php echo do_shortcode( '[genericon icon=feed size=1x]' ) ?></a>
    			 <a class="header-flickr" href="<?php echo $flickr; ?>" target="_blank" >
    			          <?php echo do_shortcode( '[genericon icon=flickr size=1x]' ) ?></a>
    			 <a class="header-instagram" href="<?php echo $instagram; ?>" target="_blank" >
    			          <?php echo do_shortcode( '[genericon icon=instagram size=1x]' ) ?></a>
    			 <a class="header-twitter" href="<?php echo $twitter; ?>" target="_blank" >
    			          <?php echo do_shortcode( '[genericon icon=twitter size=1x]' ) ?></a>
    	         <a class="header-facebook" href="<?php echo $facebook; ?>" target="_blank" >
    			          <?php echo do_shortcode( '[genericon icon=facebook size=1x]' ) ?></a>
    			 <div class="follow-me-button"> <?php echo do_shortcode("[subscribe2 size='30' hide='unsubscribe' link='Subscribe']"); ?>
    			 </div>
    	        </div>
    		    <h1 class="site-title">
    		    <a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home" title="avirupchatterjee">
    		    <img id="site-logo" src="<?php echo get_stylesheet_directory_uri(); ?>/images/site-logo-small-png.png" alt="avirupcatterjee" />
    		    </a></h1>
    
    			<nav id="primary-navigation" class="site-navigation primary-navigation" role="navigation">
    				<button class="menu-toggle"><?php _e( 'Primary Menu', 'twentyfourteen' ); ?></button>
    				<a class="screen-reader-text skip-link" href="#content"><?php _e( 'Skip to content', 'twentyfourteen' ); ?></a>
    				<?php wp_nav_menu( array( 'theme_location' => 'primary', 'menu_class' => 'nav-menu' ) ); ?>
    			</nav>
    
    	    </div>
    	</header><!-- #masthead -->
    
    	<div id="main" class="site-main">

    Thanks in advance.

    @avirupchatterjee, Remove the below 3 lines and try…

    <link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="<?php bloginfo('rss2_url'); ?>" />
    <link rel="alternate" type="text/xml" title="RSS .92" href="<?php bloginfo('rss_url'); ?>" />
    <link rel="alternate" type="application/atom+xml" title="Atom 0.3" href="<?php bloginfo('atom_url'); ?>" />
    Thread Starter avirupchatterjee

    (@avirupchatterjee)

    Removed 3 lines you have mentioned.

    tries following link
    https://avirupchatterjee.com/?feed=rss2

    Still redirecting me to only avirupchatterjee

    Thread Starter avirupchatterjee

    (@avirupchatterjee)

    Can anyone help me with this issue.

    Thanks in advance.

    @avirupchatterjee, Can you list the plugins you’ve installed.

    Thread Starter avirupchatterjee

    (@avirupchatterjee)

    1. Ajax Load More
    2. Akismet
    3. All In One SEO Pack
    4. Current Age
    5. Duplicator
    6. FD Feedburner Plugin
    7. Featured Images in RSS w/ Size and Position
    8. Genericon’d
    9. Google XML Sitemaps
    10. Jetpack by WordPress.com
    11. Subscribe2
    12. WordPress Database Backup
    13. WP-Mail-SMTP
    14. WPBeginner’s Compact Archives
    15. WPtouch Mobile Plugin

    @avirupchatterjee, Open .htaccess file located in the root of your WordPress installation and add the following lines :

    <IfModule mod_rewrite.c>
    RewriteEngine on
    RewriteCond %{HTTP_USER_AGENT} !FeedBurner [NC]
    RewriteCond %{HTTP_USER_AGENT} !FeedValidator [NC]
    RewriteRule ^feed/?([_0-9a-z-] )?/?$ https://feeds.feedburner.com/avirupchatterjee [R=302,NC,L]
    </IfModule>

    Once done, try to open https://avirupchatterjee.com/feed

    Thread Starter avirupchatterjee

    (@avirupchatterjee)

    Hi Dipak

    Thanks for your reply. I have already following code available in the .htaccess file.

    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>

    Can you please let me know how I will add the code you have provided.

    Thanks

    @avirupchatterjee, You’ve to add the given code below the code which is already exist.

    So finally, your .htaccess file should look something like…

    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>
    
    <IfModule mod_rewrite.c>
    RewriteEngine on
    RewriteCond %{HTTP_USER_AGENT} !FeedBurner [NC]
    RewriteCond %{HTTP_USER_AGENT} !FeedValidator [NC]
    RewriteRule ^feed/?([_0-9a-z-] )?/?$ https://feeds.feedburner.com/avirupchatterjee [R=302,NC,L]
    </IfModule>
    Thread Starter avirupchatterjee

    (@avirupchatterjee)

    Getting “Error 500 – Internal Server Error” after made the changes. I have reverted back to the old code in htaccess file.

Viewing 13 replies - 1 through 13 (of 13 total)
  • The topic ‘Unable to get the feed url for my website’ is closed to new replies.