On January 3, 2015 at 7:36 PM, "Nick Kew" <n...@webthing.com> wrote:
>
>On Sat, 03 Jan 2015 12:19:38 -0500
>ghalvor...@hushmail.com wrote:
>
>> I'm making a guess here.  Are you asking whether I assign Host: 
>as being example.com or www.example.com?  Here's the script from 
>each.  They are slightly different, but the result is the same.
>
>Not actually the same ...

Yes, I noticed that. I noticed the difference later on in composing the 
message, but forgot to modify the first sentence during proofreading.

>
>> 
>> $ telnet www.example.com 80
>> Trying 104.236.xxx.yyy...
>> Connected to example.com.
>> Escape character is '^]'.
>> get / http/1.1
>> Host: www.example.com
>> 
>> HTTP/1.0 301 Moved Permanently
>> Date: Sat, 03 Jan 2015 17:07:37 GMT
>> Server: Apache/2.4.10 (Ubuntu)
>> X-Powered-By: PHP/5.5.12-2ubuntu4.1
>> X-Pingback: http://example.com/xmlrpc.php
>> Location: http://example.com/
>> Content-Length: 0
>> Connection: close
>> Content-Type: text/html; charset=UTF-8
>
>That redirect is issued by your PHP script.
>
>> $ telnet www.example.com 80
>> Trying 104.236.xxx.yyy...
>> Connected to example.com.
>> Escape character is '^]'.
>> GET / HTTP/1.1
>> Host: example.com
>> 
>> HTTP/1.1 301 Moved Permanently
>> Date: Sat, 03 Jan 2015 17:06:38 GMT
>> Server: Apache/2.4.10 (Ubuntu)
>> Location: http://www.example.com//
>> Content-Length: 317
>> Content-Type: text/html; charset=iso-8859-1
>
>... whereas that looks like a server redirection
>with a stray extra slash, and is probably generated
>from your apache configuration.
>
>Decide which you want to use, then configure your server
>and your PHP to agree on it.
>

That file, xmlprc.php is something generated by wordpress.  I'm in no way 
familiar with how wordpress works.  So this may be a wordpress configuration 
issue.  The simplest may be to reinstall wordpress and hope it works.  I'm not 
sure why these two behave differently (www.example.com vs example.com) I always 
thought the extra four letters were something that Apache knew how to deal 
with.  It's hard to guarantee that the user will user type or omit the 'www.'  
What should be done about this?

>-- 
>Nick Kew
>
>-------------------------------------------------------------------
>--
>To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
>For additional commands, e-mail: users-h...@httpd.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org

Reply via email to