Wrox Programmer Forums
|
BOOK: Professional Search Engine Optimization with ASP.NET ISBN: 978-0-470-13147-3
This is the forum to discuss the Wrox book Professional Search Engine Optimization with ASP.NET: A Developer's Guide to SEO by Cristian Darie, Jaimie Sirovich; ISBN: 9780470131473
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional Search Engine Optimization with ASP.NET ISBN: 978-0-470-13147-3 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old November 19th, 2007, 01:18 PM
Registered User
 
Join Date: Nov 2007
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default URL Redirections

I see on page 123 a section on redirections that is of great interest to me however I am unable to get the sample project to work to illustrate this. When a request for "catalog.html" is made, the application should send the user to "catalog.aspx" yet I am directed to the 404 page instead. I downloaded both the ISAPI Rewrite and UrlRewriter.NET applications and am not sure what exactly to do with them.

I really just want the easiest way to forward a user from an .html page to an .aspx page and eliminate the duplicate content issue from coming up. I know I could use the http-equiv but I want to figure out the 301 method for the reasons in the book.

Thanks

 
Old January 16th, 2008, 12:54 AM
Registered User
 
Join Date: Jan 2008
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

have you had any luck figuring that out yet? im just beginning the book myself this week. will post if it works for me.

Coming soon...
www.TheFreeDatingSite.com
 
Old January 16th, 2008, 09:37 AM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

Hey guys.

This is weird as I don't remember having this issue when I worked through the book. I will take a look at my source files when I get home tonight and hopefully have an answer for you.

Thanks!
-Doug

================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
================================================== =========
.: Wrox Technical Editor :.
Wrox Books 24 x 7
================================================== =========
 
Old January 16th, 2008, 08:36 PM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

Ok. I am assuming here, but I think this is why you can't get this to work.

In the intro chapter Christian and Jamie have you configure IIS and your hosts file so that you access the site through http://seoasp/

What I imagine you are doing is accessing the site through VWD so that you have a url that looks like http://localhost:xxxx/<mysite>/ and I imagine that you have your rewrite rule something like:

<rewrite url="^/catalog.html$" to="/catalog.aspx" processing="stop"/>

The problem with this rule is that urlRewriter is waiting for this url: http://mysite/catalog.htm but if you ahve accessed the site from VWD the url you are actually going to is: http://localhost:xxxx/<mysite>/catalog.html

A simple adjustment to your rewrite rule will clear this up:
<rewrite url="^/<yoursite>/catalog.html$" to="/<yoursite>/catalog.aspx" processing="stop"/>

The above sample worked on my dev box with a url of http://localhost:5485/seoasp/catalog.html

The reason I did not catch this problem when I was editing the book is because I had configured the site to run as Jamie and Christian had instructed. Nevertheless this should clear up your problem!

hth.
-Doug

================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
================================================== =========
.: Wrox Technical Editor :.
Wrox Books 24 x 7
================================================== =========





Similar Threads
Thread Thread Starter Forum Replies Last Post
URL Redirect based on given URL somnath.kartic VS.NET 2002/2003 1 August 2nd, 2012 08:21 AM
URL rewriting with URL forwarding mtabyana BOOK: Professional Search Engine Optimization with PHP: A Dev's Guide to SEO ISBN: 978-0-470-10092-9 0 October 22nd, 2007 08:22 AM
URL mani_he Pro PHP 11 December 9th, 2004 02:10 AM
extract URL from Favorites (.URL Files) PhilHawks VB.NET 2002/2003 Basics 2 November 2nd, 2004 04:35 AM
Tomcat IIS multiple redirections publicStatic Apache Tomcat 0 October 4th, 2004 11:42 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.