Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place. |
| Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
 |
GNU/Linux Basic Guide
This 255-page guide will provide you with the keys to understand the philosophy of free software, teach you how to use and handle it, and give you the tools required to move easily in the world of GNU/Linux. Many users and administrators will be taking their first steps with this GNU/Linux Basic guide and it will show you how to approach and solve the problems you encounter.
Click Here to receive this Complete Guide absolutely free. |
|
 |
03-25-2004, 07:39 PM
|
#1
|
|
Member
Registered: Mar 2004
Distribution: Slackware 9.1
Posts: 69
Rep:
|
Letting normal user change apache directory
I want to fool around with making websites but i dont want to have to log into root to change the files in /var/www/htdocs. is there a way of letting a normal user to change etc. the stuff in there? im running slackware 9.1 btw
|
|
|
|
03-25-2004, 07:56 PM
|
#2
|
|
Senior Member
Registered: Sep 2003
Location: Sweden
Distribution: Debian
Posts: 3,032
Rep:
|
The easiest - and safest - way is probably to user userdirs. With this setup a user can create a directory called public_html in his home directory and access it through http://yourhostname/~username. It usually works very well - check your Apache setup, the userdir might be set to something else than the standard ~/public_html.
If you absolutely must use the global html directory you can create a new group, change the ownership of the html directory and all subdirectories and files to this new group and then add users who should have access to this group.
Håkan
|
|
|
|
03-25-2004, 10:50 PM
|
#3
|
|
Member
Registered: Mar 2004
Distribution: Slackware 9.1
Posts: 69
Original Poster
Rep:
|
sorry for being a noob, but how do you set up userdir?
|
|
|
|
03-26-2004, 01:06 AM
|
#4
|
|
Senior Member
Registered: Nov 2002
Location: CA
Distribution: redhat 7.3
Posts: 1,430
Rep:
|
It might already been setup by default installation of apache (I think debian is like that, don't know about SuSE though). Try what hw-tph said and see if that worked or not. If it didn't, you need to have a play at your apache conf file (httpd.conf).
-twantrd
|
|
|
|
03-26-2004, 07:18 PM
|
#6
|
|
Senior Member
Registered: Sep 2003
Location: Sweden
Distribution: Debian
Posts: 3,032
Rep:
|
Sure, put an index.html in your webserver's document root with a Javascript refresh that takes the visitor to the other location. Examples are all over the web - start looking at the web design sites and tutorials. You don't have to do any fancy redirections by reconfiguring the server.
Håkan
|
|
|
|
03-27-2004, 07:50 PM
|
#8
|
|
Senior Member
Registered: Nov 2002
Location: CA
Distribution: redhat 7.3
Posts: 1,430
Rep:
|
Hi,
1. If you are getting a 'forbidden' error that means you have permission problems. You need to change your permissions to allow access.
2. First off, you do have php support built in apache right? Ok, assuming you do so, it should automatically pick up the index.php from "http://blehbleh/~user" as long as you placed index.php in your Directory Index (and that you do not have 'index.html' in that same folder).
-twantrd
|
|
|
|
03-27-2004, 07:54 PM
|
#9
|
|
Member
Registered: Mar 2004
Distribution: Slackware 9.1
Posts: 69
Original Poster
Rep:
|
when i go to http://blehbleh/~user/index.php it works fine, its just when i go to http://blehbleh/~user/ it gives me this:
403 Forbidden
You don't have permission to access /~user/ on this server.
oh, and when i go to http://blehbleh it goes to index.html
Last edited by nivek7; 03-27-2004 at 07:56 PM.
|
|
|
|
05-04-2004, 06:58 PM
|
#10
|
|
Member
Registered: May 2003
Posts: 80
Rep:
|
in your apache config file:
Code:
<IfModule mod_dir.c>
DirectoryIndex index.html index.php
</IfModule>
|
|
|
|
| Thread Tools |
Search this Thread |
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -5. The time now is 02:45 AM.
|
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|