The Moz Q&A Forum

    • Forum
    • Questions
    • My Q&A
    • Users
    • Ask the Community

    Welcome to the Q&A Forum

    Browse the forum for helpful insights and fresh discussions about all things SEO.

    1. SEO and Digital Marketing Q&A Forum
    2. Categories
    3. Technical SEO Issues
    4. Help Setting Up 301 Redirects from Coldfusion Site to Wordpress Site.

    Help Setting Up 301 Redirects from Coldfusion Site to Wordpress Site.

    Technical SEO Issues
    3 2 143
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as question
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • MarketHubb
      MarketHubb last edited by

      I have created a new website and need to redirect all of the previous pages to the new one. The old website was built in coldfusion and the new site is built in wordpress.

      One of the pages I'm trying to redirect is www.norriseal.com/products.cfm to http://norrisealwellmark.com/products/.

      This is what I have in my .htaccess file

      <ifmodule mod_rewrite.c="">Options +FollowSymlinks
      RewriteEngine On
      RewriteBase /
      Redirect 301 /products.cfm http://norrisealwellmark.com/products/</ifmodule>

      The result of this redirect is http://norrisealwellmark.com/products.cfm

      How do I prevent the .cfm from appending to the destination URL?

      1 Reply Last reply Reply Quote 1
      • BritneyMuller
        BritneyMuller last edited by

        Hi Chris,

        Are you still using ColdFusion?

        It sounds like you're on a Windows server, yeah? If so, adding this to your web.config file should do the trick:

        <match url="(.*)"><conditions><add matchtype="IsFile" negate="true"><add matchtype="IsDirectory" negate="true"></add></add></conditions>
            <action type="Rewrite" url="{R:1}.cfm"></action></match>

        Otherwise, adding the following to your web.config for WordPress should work:

         <rulename="company cfm"=""><matchurl="^company (.*)$"=""><conditionslogicalgrouping="matchall"><addinput="{request_filename}"matchtype="isfile"negate="true"><addinput="{request_filename}"matchtype="isdirectory"negate="true"><actiontype="rewrite"url="{r:1}.cfm"></actiontype="rewrite"url="{r:1}.cfm"></addinput="{request_filename}"matchtype="isdirectory"negate="true"></addinput="{request_filename}"matchtype="isfile"negate="true"></conditionslogicalgrouping="matchall"></matchurl="^company></rulename="company> 
        
        1 Reply Last reply Reply Quote 1
        • MarketHubb
          MarketHubb last edited by

          Hey Britney,

          No, the old (ColdFusion) site and the new (PHP) site are on the same linux (CentOS) server.

          The 301 redirect rule I described above in my original post is applying '.cfm' to the end of the destination URL - thats the main issue we're trying to tackle here.

          Thanks for responding!

          1 Reply Last reply Reply Quote 0
          • 1 / 1
          • First post
            Last post
          • Redirecting old html site to new wordpress site
            briandee
            briandee
            0
            3
            326

          • Redirect a 301 Redirect
            RedCaffeine
            RedCaffeine
            0
            5
            98

          • 301 Redirect Help
            dhidalgo1
            dhidalgo1
            1
            3
            115

          • Static site to wordpress - avoiding 301 redirects
            OlegKorneitchouk
            OlegKorneitchouk
            0
            9
            423

          • 301 redirecting old content from one site to updated content on a different site
            OlegKorneitchouk
            OlegKorneitchouk
            0
            2
            207

          • If I redirect my WordPress blog to my main site, will it help my main site's SEO?
            AspenFasteners
            AspenFasteners
            0
            3
            869

          • Wordpress 301 redirects
            KeriMorgret
            KeriMorgret
            0
            5
            916

          • 301 Redirect Help
            hiphound
            hiphound
            0
            3
            891

          Get started with Moz Pro!

          Unlock the power of advanced SEO tools and data-driven insights.

          Start my free trial
          Products
          • Moz Pro
          • Moz Local
          • Moz API
          • Moz Data
          • STAT
          • Product Updates
          Moz Solutions
          • SMB Solutions
          • Agency Solutions
          • Enterprise Solutions
          • Digital Marketers
          Free SEO Tools
          • Domain Authority Checker
          • Link Explorer
          • Keyword Explorer
          • Competitive Research
          • Brand Authority Checker
          • Local Citation Checker
          • MozBar Extension
          • MozCast
          Resources
          • Blog
          • SEO Learning Center
          • Help Hub
          • Beginner's Guide to SEO
          • How-to Guides
          • Moz Academy
          • API Docs
          About Moz
          • About
          • Team
          • Careers
          • Contact
          Why Moz
          • Case Studies
          • Testimonials
          Get Involved
          • Become an Affiliate
          • MozCon
          • Webinars
          • Practical Marketer Series
          • MozPod
          Connect with us

          Contact the Help team

          Join our newsletter
          Moz logo
          © 2021 - 2026 SEOMoz, Inc., a Ziff Davis company. All rights reserved. Moz is a registered trademark of SEOMoz, Inc.
          • Accessibility
          • Terms of Use
          • Privacy