LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
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 11-28-2012, 01:10 PM   #1
wilkos73
LQ Newbie
 
Registered: Nov 2012
Posts: 10

Rep: Reputation: Disabled
Need an apache subdirectory allow command


I am working on a website and just installed wordpress as an onsite blog. I am running into an issue where the website does not regognize the blog folder I created because the system is set up to add .php to end of a command it doesn't understand. Here is the coding from the htacess file:

# compress all text & html:

AddOutputFilterByType DEFLATE text/html text/plain text/xml

# Or, compress certain file types by extension:

<Files *.php>

Any thoughts on how I can amend the htacess file to allow my /blog/ folder to be read properly?
 
Old 11-28-2012, 04:21 PM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Hi,
Quote:
I am running into an issue where the website does not regognize the blog folder I created because the system is set up to add .php to end of a command it doesn't understand.
The .htaccess snippet you've posted has nothing to do with the above behavior. If I can understand well ypur description, it looks like "Multiviews" is enabled in apache "Options" directive.

Regards
 
Old 11-29-2012, 10:21 AM   #3
wilkos73
LQ Newbie
 
Registered: Nov 2012
Posts: 10

Original Poster
Rep: Reputation: Disabled
Will turning off the multiviews command fix this issue without harming the rest of my site?
 
Old 11-29-2012, 11:01 AM   #4
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Quote:
Originally Posted by wilkos73 View Post
Will turning off the multiviews command fix this issue without harming the rest of my site?
Depends if you want that functionality or not.
If you need it for the rest of your site, then disable it only for the specific direstory, e.g:
Code:
<Directory /path/to/blog>
Options -Multiviews
</Directory>
Note also, that by default Multiviews is disabled.

Regards
 
Old 11-29-2012, 11:50 AM   #5
wilkos73
LQ Newbie
 
Registered: Nov 2012
Posts: 10

Original Poster
Rep: Reputation: Disabled
I'll try that out. Thanks for the help.
 
Old 11-29-2012, 12:07 PM   #6
wilkos73
LQ Newbie
 
Registered: Nov 2012
Posts: 10

Original Poster
Rep: Reputation: Disabled
okay so when I added the script provided to my Htaccess it registered a 500 internal server error.
 
Old 11-29-2012, 12:28 PM   #7
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Quote:
Originally Posted by wilkos73 View Post
okay so when I added the script provided to my Htaccess it registered a 500 internal server error.
Check the apache error_log to find the reason for this error.
 
Old 11-29-2012, 12:34 PM   #8
wilkos73
LQ Newbie
 
Registered: Nov 2012
Posts: 10

Original Poster
Rep: Reputation: Disabled
Error Log:

[29-Nov-2012 12:52:12] PHP Warning: ksort() expects parameter 1 to be array, null given in /home/vne/visitnewengland.com/includes/calendar_include.php on line 155
[29-Nov-2012 12:52:12] PHP Warning: Invalid argument supplied for foreach() in /home/vne/visitnewengland.com/includes/calendar_include.php on line 157
[29-Nov-2012 12:52:12] PHP Warning: Invalid argument supplied for foreach() in /home/vne/visitnewengland.com/includes/calendar_include.php on line 167
[29-Nov-2012 13:14:09] PHP Warning: ksort() expects parameter 1 to be array, null given in /home/vne/visitnewengland.com/includes/calendar_include.php on line 155
[29-Nov-2012 13:14:09] PHP Warning: Invalid argument supplied for foreach() in /home/vne/visitnewengland.com/includes/calendar_include.php on line 157
[29-Nov-2012 13:14:09] PHP Warning: Invalid argument supplied for foreach() in /home/vne/visitnewengland.com/includes/calendar_include.php on line 167
[29-Nov-2012 13:19:13] PHP Warning: ksort() expects parameter 1 to be array, null given in /home/vne/visitnewengland.com/includes/calendar_include.php on line 155
[29-Nov-2012 13:19:13] PHP Warning: Invalid argument supplied for foreach() in /home/vne/visitnewengland.com/includes/calendar_include.php on line 157
[29-Nov-2012 13:19:13] PHP Warning: Invalid argument supplied for foreach() in /home/vne/visitnewengland.com/includes/calendar_include.php on line 167
 
Old 11-29-2012, 12:46 PM   #9
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
These are warnings (from php) not errors. Maybe the errors are logged in a different logfile.
Anyways, if you're going to use a .htaccess to remove Multiviews, then remove the opening <Directory ...> and the closing </Directory> directives (leave just the "Options ..." part)
 
Old 11-30-2012, 03:22 PM   #10
wilkos73
LQ Newbie
 
Registered: Nov 2012
Posts: 10

Original Poster
Rep: Reputation: Disabled
I tried this options and still had a 500 internal server error. I will try to locate the errors you requested to help me. Thank you for your assistance.
 
  


Reply



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
[SOLVED] redirecting from a subdirectory via apache compused Linux - Software 26 11-24-2011 07:30 AM
Newb Apache question. Mapping subdirectory. Hillun Linux - Server 1 09-15-2011 10:34 PM
403 Error In Subdirectory of Joomla Install (Apache conf newb) 2-tone-joe Linux - Server 1 08-01-2008 11:56 AM
Running .cgi and .pl scripts from any subdirectory in Apache b18b Linux - Networking 8 03-20-2006 02:43 PM
Apache subdirectory problems shane25119 Linux - Software 2 07-13-2005 10:34 AM

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

All times are GMT -5. The time now is 03:20 PM.

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
Open Source Consulting | Domain Registration