Copy link to clipboard
Copied
I have a link on my site http://www.mysite.com/ssl/oldpage.cfm that I have renamed to http://www.mysite.com/ssl/newpage.cfm.
Many of my users have the old page bookmarked etc..................
Is there a way to put code in the application.cfm that says if user trys to go to old page automatically redirect them to the new page?
Copy link to clipboard
Copied
Not in the application CFC.
But there is a great place to put code like that in most web server configurations.
If not that, then the next level would be defining the "missing template handler" in the ColdFusion administrator.
Finally, if you can't do either or those, keep the old file, but replace all of it's code with a <cfheader...> redirect (or a <cflocation...> permanent redirect if you are on a new version of ColdFusion.
But, really, this is a web server level task and that is the best place to put this if you have contorl of yours.