It seems that 500 error is cause by .htaccess file in joomla instalaltions that I enabled.

here is the code, can someone tell me what causes this?

Code:

##
# @version $Id: htaccess.txt 9795 2008-01-02 11:33:07Z rmuilwijk $
# @package Joomla
# @copyright Copyright (C) 2005 - 2008 Open Source Matters. All rights reserved.
# @license http://www.gnu.org/copyleft/gpl.html GNU/GPL
# Joomla! is Free Software
##
#####################################################
# READ THIS COMPLETELY IF YOU CHOOSE TO USE THIS FILE
#
# The line just below this section: 'Options +FollowSymLinks' may cause problems
# with some server configurations. It is required for use of mod_rewrite, but may already
# be set by your server administrator in a way that dissallows changing it in
# your .htaccess file. If using it causes your server to error out, comment it out (add # to
# beginning of line), reload your site in your browser and test your sef url's. If they work,
# it has been set by your server administrator and you do not need it set here.
#
# Only use one of the two SEF sections that follow. Lines that can be uncommented
# (and thus used) have only one #. Lines with two #'s should not be uncommented
# In the section that you don't use, all lines should start with #
#
#####################################################
## Can be commented out if causes errors, see notes above.
Options +FollowSymLinks
#
# mod_rewrite in use
RewriteEngine On
# Uncomment following line if your webserver's URL
# is not directly related to physical file paths.
# Update Your Joomla! Directory (just / for root)
# RewriteBase /
########## Begin - Joomla! core SEF Section
#
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !^/index.php
RewriteCond %{REQUEST_URI} (/|\.php|\.html|\.htm|\.feed|\.pdf|\.raw|/[^.]*)$ [NC]
RewriteRule (.*) index.php
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization},L]
#
########## End - Joomla! core SEF Section
########## Begin - Rewrite rules to block out some common exploits
## If you experience problems on your site block out the operations listed below
## This attempts to block the most common type of exploit `attempts` to Joomla!
#
# Block out any script trying to set a mosConfig value through the URL
RewriteCond %{QUERY_STRING} mosConfig_[a-zA-Z_]{1,21}(=|\%3D) [OR]
# Block out any script trying to base64_encode crap to send via URL
RewriteCond %{QUERY_STRING} base64_encode.*\(.*\) [OR]
# Block out any script that includes a <script> tag in URL
RewriteCond %{QUERY_STRING} (\<|%3C).*script.*(\>|%3E) [NC,OR]
# Block out any script trying to set a PHP GLOBALS variable via URL
RewriteCond %{QUERY_STRING} GLOBALS(=|\[|\%[0-9A-Z]{0,2}) [OR]
# Block out any script trying to modify a _REQUEST variable via URL
RewriteCond %{QUERY_STRING} _REQUEST(=|\[|\%[0-9A-Z]{0,2})
# Send all blocked request to homepage with 403 Forbidden error!
RewriteRule ^(.*)$ index.php [F,L]
#
########## End - Rewrite rules to block out some common exploits

I understand that this is ISPconfig security feature that only server admin and reseller can add additional Apache directives into the site's virtual host container manually so that is why .htaccess is disabled?

If you have added AllowOverride All within your apache2.conf or httpd.conf, .htaccess files are allowed on your server in any website.
I think that the internal 500 error occured because you did not have AllowOverride All within your Apache configuration yet.

Personally, i think it is more safe to set AllowOverride None instead of AllowOverride All. AllowOverride None means that .htaccess files are not allowed, but if you use ISPConfig, you can add the following to the Apache directive field for your Joomla site within ISPConfig:

I created a client with admin account then 1 website with 1 user I assigned the user to admin for the site. I set max domains to 1 so the user could not create second domain (actually that would work forreseller correct me if I'm wrog but the logic is the same. If I neet a user to have 1 domain I write 1)

Now the bug happens when you trie to add additional apache directives you get error like I said before, the ispconfig changes the max domain to 2 and you can save the site profile.

I consider this a bug if ispconfig needs to have max 2 to host 1 site I should not be able to create the site from start. Now I discoved this when tried to add additional apache directives.

I created a client with admin account then 1 website with 1 user I assigned the user to admin for the site. I set max domains to 1 so the user could not create second domain (actually that would work forreseller correct me if I'm wrog but the logic is the same. If I neet a user to have 1 domain I write 1)

Click to expand...

Thats not a bug, its totally correct.

The first domain is the website itself, you entered it in the site settings. You can not add a second domain as you limited the number of domains to 1.

The first domain is the website itself, you entered it in the site settings. You can not add a second domain as you limited the number of domains to 1.

Click to expand...

Yes I entered 1 but ISPconfig when I pasted the code to add apache directives increased it to 2. Now I wan't my user that has 1 website to have 1 website ONLY, but in website settings "Basis " tab I see max domain = 2

Yes, the client have 2 domains already:www.yourdomain.tld and a co-domain yourdomain.tld (without www), which is necesarry to deliver e-mail to e-mailadresses on your domain @yourdomain.tld. This means also that the site can be visited at http://www.yourdomain.tld and http://yourdomain.tld. This is normal and you have nothing to worry about.