Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeUsing DNN Platf...Using DNN Platf...Administration ...Administration ...Problem with HumanFriendly URLs resulting in 404 page not foundProblem with HumanFriendly URLs resulting in 404 page not found
Previous
 
Next
New Post
6/2/2008 7:17 PM
 

We have been developing a site recently with DNN and did not have any trouble with the HumanFriendly URL setting on any of our development servers (both XP with IIS 5) or our staging server (Windows Server 2003 with IIS 6).  We bundled up the site and passed it off to the client for install on their own development server/production server, however, all requests for pages result in a 404 "page not found" type error page from DNN.

On all our development servers, we have both "Use Friendly Urls" turned on in the host settings, along with the urlFormat="HumanFriendly" attribute in the web.config for the DNNFriendlyUrl provider.  On the client's servers, however, the site works fine when neither of these are set, or if the host settings "Use Friendly Urls" is set, but once the HumanFriendly attribute is added to the web.config, that's when we get the 404 error pages along with an HttpException in the DNN Event Viewer.

The only difference between the client's setup and our own development/staging setup is that there is a Microsoft ISA firewall involved on their setup.  I am not sure if that's causing any issues, though, as the client is seeing the same 404 error pages as we are and they are behind the firewall.  We've also had the client add both IPs to the PortalAlias table (the one we are using from outside the firewall, and the one they are using inside the firewall) but it doesn't seem to have made a difference.  We've also had them check to make sure that the "Verify that file exists" setting in IIS is turned off, which it is... and I'm pretty sure we wouldn't even be getting to the point where we get a 404 HttpException in the DNN log if that was enabled in IIS.

Does this problem sound familiar to anyone?  We are kind of at a loss on how to fix it... we've tried just about everything we can think of.

 
New Post
6/2/2008 9:32 PM
 

Just a hunch, but worth trying. Make sure no compression is enabled on the IIS or within DNN host setting.


Affordable DotNetNuke Hosting Affordable DNN Hosting & Support - www.ihostasp.net
Slavic Kozyuk
IHOST, LLC
Call toll-free: 1.800.593.0238
 
New Post
6/3/2008 10:51 AM
 

In your clients setup, are they running the site through the asp.net development server using VS 2005 rather than IIS or are you using a specific port in IIS ?

I've seen the same problem on an XP development machine I think this is a slight bug with the DNN URL Friendly provider where the port number (as used by the asp.net development server) is omitted in the rewritten url, I.e localhost:3276/default.aspx?TabId=30 gets re-written to localhost/home.aspx  notice the missing port number. Run this through IIS or replace the port number manually and it works fine .  NB You may experience the same issue if a specific port is used in IIS although I haven't tested that. Someone needs to fix the code in the provider.

 
New Post
6/3/2008 11:41 AM
 

Thanks for the suggestions, guys.

We are having them check the compression setting.

As far as the port number, that is also one of the differences but we added the port number as part of the alias in the PortalAlias table, and the URLs are being rewritten with the port number.  We also tried it on one of our dev machines with an alternate port, and this method worked fine.

 
New Post
6/3/2008 2:56 PM
 

Miranda wrote

As far as the port number, that is also one of the differences but we added the port number as part of the alias in the PortalAlias table, and the URLs are being rewritten with the port number.  We also tried it on one of our dev machines with an alternate port, and this method worked fine.

After days of debugging...

My personal dev server had always been running on port 80, and only had localhost in my PortalAlias table. My co-worker's dev server was at one point running on port 8080, but he switched it to port 80 later on.  He still had both localhost:8080 and localhost in his PortalAlias table, though. Our staging server was running on port 80, as well.  The client was trying to set up under an alternate port on their dev server, so we gave them instructions on how to edit the PortalAlias table to include their ip:port info.  They never attempted to set it up under port 80, so only had the alternate port info in the PortalAlias table.  Everything worked but the human friendly URLs, as described in the original post.

In an attempt to reproduce their problem, I downloaded the exact files we'd sent them from our staging server to my local dev server and set it up also using an alternate port, 8080.  I was now able to reproduce the 404 errors from the human friendly URLs.  I switched back to port 80, and everything was fine.  My co-worker double checked his setup running on 8080, and it was still fine.  We set up a second instance of the site on our staging server on port 8080, and it was also fine.

So, now we have a staging server that works fine on the regular and an alternate port, we have 1 dev server that works fine on an alternate port, and we have my dev server that works on the regular port but not on an alternate port.  So, my boss says, "try running your server on both 80 and 8080."  So, I set up IIS to run on both ports, I added the second entry to the PortalAlias table, and restarted IIS.  The site now worked on both ports!  I then removed port 80 from IIS so that it was only running on 8080 again, and it still works.  Whaaaaat?

Then I realized, the only thing that was different was before when I was swapping between 80 and 8080, I was changing the same entry in the PortalAlias table from localhost to localhost:8080 and back again, but when I set it up to run on both ports, I had 2 entries.  When I went back to only running on 8080, I left both entries in the table.  To confirm that having both the address with the alternate port and with no port at all was the issue, I removed the localhost entry from PortalAlias (leaving localhost:8080) and the site promptly broke.

So, to summarize all this craziness: 

We needed to have both "server.com" and "server.com:8080" in the PortalAlias table so that URLs like "http://server.com:8080/home.aspx" would work, even if we weren't even running a server on port 80.

I hope this helps someone else in the future!

 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Administration ...Administration ...Problem with HumanFriendly URLs resulting in 404 page not foundProblem with HumanFriendly URLs resulting in 404 page not found


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out