Error on OC US

You want to get involved in the Opencaching Network?
Antworten
RVRoadTrip

Please see this thread: http://forum.opencaching.us/viewtopic.php?f=4&t=404&p=2441#p2441

Any suggestions would be appreciated.  Also, wince our key is for "www.opencaching.us" and not just "opencaching.us", how would I force the www. to be added if not in the URL?
Benutzeravatar
mic@
Vereinsmitglied
Vereinsmitglied
Beiträge: 6623
Registriert: 04.12.2009, 00:31

[quote="RVRoadTrip"]Please see this thread: http://forum.opencaching.us/viewtopic.php?f=4&t=404&p=2441#p2441[/quote]
==> The board requires you to be registered and logged in to view this forum.
Could You please give a short summary of the problem.
oliver

I added a redirection for all requests from "opencaching.de" to "www.opencaching.de". You can do this in the VirtualHost-Config of httpd.conf

Code: Alles auswählen

<VirtualHost *:80>
(...)
    RewriteEngine On
    # Aufrufe ohne www-Zusatz um das www ergaenzen
    RewriteCond %{HTTP_HOST} ^opencaching.us$ [NC]
    RewriteRule ^/(.*)$ http://www.opencaching.us/$1 [R=301,L]
(...)
</VirtualHost>
Try: http://opencaching.de/viewcache.php?cacheid=150740
RVRoadTrip

That's what I was looking for.  Thanks!  Now where is this file located that I need to edit?  I looked but didn't find it.

As for the forum thread, it was this: "The send to Google maps brings up Google but says it's a bad KML file."
Zuletzt geändert von RVRoadTrip am 18.01.2011, 13:48, insgesamt 1-mal geändert.
OlofL

It might also be called DefaultHost or similar depending on your apache installation. It is probably in /etc/ somewhere.

We also needed to fix some things with the cookie settings, I can check if the host-thing doesn't help you fully.
n0x-f0x

I think you can use a simple .htaccess file:

1. If it does not exists, create a file with the name .htaccess in the root folder of the webspace (the folder in which the index is located)
2. If the file hasn't existed you must put this in the file:
RewriteEngine on

Options FollowSymlinks

rewritecond %{http_host} ^opencaching.us [nc]

rewriterule ^(.*)$ http://www.opencaching.us/$1 [r=301,nc]
If it existed you have to look if the lines with RewriteEngine or the Options line exist. These lines shouldn't exsits multiple times.
The 4 lines I posted should be the first 4 lines in your .htaccess file becaus other RewriteConditions could depend on the "www."

Hope its clear what I mean ;)


Source: http://ageedesign.com/blog/2008/04/08/add-www-to-your-domain-automatically-with-htaccess/
n0x-f0x

[quote="RVRoadTrip"]
Now where is this file located that I need to edit?
[/quote]
The httpd.conf is located in the config folder of Apache.
Actually I found it there, but you can locate the file where you want it to be and I don't know if my config is the default config
sp2ong

Hi Jerry,

I have add to your htaccess, please check that exist problem still
RVRoadTrip

Thanks Waldek!
Benutzeravatar
mic@
Vereinsmitglied
Vereinsmitglied
Beiträge: 6623
Registriert: 04.12.2009, 00:31

[quote="sp2ong"]I have add to your htaccess, please check that exist problem still[/quote]
But keep in mind that the short link don´t work for pictures!

So this link doesn´t work:
http://opencaching.us/images/uploads/FEAB55FC-4FBB-38AD-E7B5-4E77EFFE1A4B.jpg

But with preceding www it is working:
http://www.opencaching.us/images/uploads/FEAB55FC-4FBB-38AD-E7B5-4E77EFFE1A4B.jpg
Antworten