LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-12-2011, 09:02 AM   #1
pawelch
LQ Newbie
 
Registered: Jul 2010
Posts: 26

Rep: Reputation: 0
[mod_rewrite] nothing happens ahen ruls are included


Hi guys,
I have just installed apache with mod rewrite to give it try. I am using Ubuntu and my website is visible with http://localhost/ URL. I was trying to add:

RewriteEngine On
RewriteCond %{SERVER_PORT} 80
RewriteRule ^(.*)$ https://www.example.com/$1 [R,L]

to apache2.conf but it did not work and did not give any results. the log file did not contain any errors.
What should I do?

thank you
 
Old 05-12-2011, 11:17 AM   #2
vivaystn
LQ Newbie
 
Registered: Feb 2011
Posts: 5

Rep: Reputation: 0
In your apache config file add this AccessFileName .htaccess then cut the mentioned 3 lines and put them in the file .htaccess (you should create it if not exist) under apache2 folder. You need .htaccess because is checked on every click on your site and the config is checked only on server start.

Did that help?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
mod_rewrite delmoras Linux - Newbie 1 01-12-2009 11:16 AM
mod_rewrite basarab1310 Linux - Newbie 1 11-06-2008 07:57 AM
Help with mod_rewrite MicahCarrick Linux - Software 3 05-23-2007 08:09 PM
mod_rewrite mr_dizzle Linux - General 1 02-02-2006 07:32 PM
how to make iptables firewall ruls for squide proxy AZIMBD03 Linux - Security 1 03-22-2004 11:12 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 11:51 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration