Jump to content

  • You cannot start a new topic
  • You cannot reply to this topic

Alias Domain Without Https Rate Topic   - - - - -

 
  • becomarius
  • Senior Member
  • Members
  • Join Date: 09-Feb 12
  • 215 posts

Posted 23 January 2018 - 05:01 PM #1

Hy all again

 

I have:

https://www.domain1.com

http://www.domain2.com

 

so here are my htaccess file

DirectoryIndex index.html index.php

<IfModule mod_headers.c>

	<IfModule mod_rewrite.c>
		AddEncoding gzip .gz
		RewriteCond %{REQUEST_FILENAME} \.(js|css)$
		RewriteCond %{HTTP:Accept-encoding} gzip
		RewriteCond %{REQUEST_FILENAME}.gz -f
RewriteCond %{REQUEST_URI} !^/[0-9]+\..+\.cpaneldcv$
RewriteCond %{REQUEST_URI} !^/[A-F0-9]{32}\.txt(?:\ Comodo\ DCV)?$
		RewriteRule ^(.*)$ $1.gz [QSA,L]
	</IfModule>

	<FilesMatch .*\.css.gz$>
	<ifmodule mod_expires.c="">
		<filesmatch "\.(ico|gif|jpg|jpeg|png|swf|css|js|html?|xml|txt)$"="">
			ExpiresActive On
			ExpiresDefault "access plus 10 years"
			Header unset ETag
			FileETag None
			Header set Connection keep-alive
			Header append Vary User-Agent
			Header append Vary: Accept-Encoding
			Header append Cache-Control public
	</filesmatch>
		</ifmodule>
	<ifmodule mod_headers.c="">
		<filesmatch "\.(ico|gif|jpg|jpeg|png|swf|css|js|html?|xml|txt)$"="">
			Header unset ETag
			FileETag None
			Header set Connection keep-alive
			Header append Vary User-Agent
			Header append Vary: Accept-Encoding
			Header append Cache-Control public
	</filesmatch>
		</ifmodule>
	<ifmodule !mod_expires.c="">
			RewriteCond %{REQUEST_FILENAME} -f
			RewriteRule ^(.*\.(ico|gif|jpg|jpeg|png|swf|js|css|html?|xml|txt|pdf))$ smartoptimizer/?$1
		</ifmodule>

		ForceType text/css
		Header set Content-Encoding: gzip
		Header set Cache-control: private
	</FilesMatch>

	<FilesMatch .*\.js.gz$>
		<IfModule mod_expires.c>
			Header unset ETag
			FileETag None
			ExpiresActive On
			ExpiresDefault "access plus 1 year"
		</IfModule>
		
		ForceType text/javascript
		Header set Content-Encoding: gzip
		Header set Cache-control: private
	</FilesMatch>

	<FilesMatch "\.(ttf|ttc|otf|eot|woff|css)$">
		Header set Access-Control-Allow-Origin "*"
	</FilesMatch>
</IfModule>

<IfModule mod_rewrite.c>
RewriteEngine on
# Please note that RewriteBase setting is obsolete use it only in case you experience  some problems with SEO addon.
# Some hostings require RewriteBase to be uncommented
# Example:
# Your store url is http://www.yourcompany.com/store/cart
# So "RewriteBase" should be:
# RewriteBase /store/cart
# RewriteBase /
RewriteEngine on
RewriteCond %{HTTPS} !=on
RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
Options -MultiViews

RewriteCond %{REQUEST_URI} !^/[0-9]+\..+\.cpaneldcv$
RewriteCond %{REQUEST_URI} !^/[A-F0-9]{32}\.txt(?:\ Comodo\ DCV)?$
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]

RewriteCond %{REQUEST_URI} ^api/(.*)$ [or]
RewriteCond %{REQUEST_URI} .*/api/(.*)$
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !^/[0-9]+\..+\.cpaneldcv$
RewriteCond %{REQUEST_URI} !^/[A-F0-9]{32}\.txt(?:\ Comodo\ DCV)?$
RewriteRule .*api/(.*)$ api.php?_d=$1&ajax_custom=1 [L,QSA]

RewriteCond %{REQUEST_URI} \.(png|gif|ico|swf|jpe?g|js|css|ttf|svg|eot|woff|yml|xml)$ [or]
RewriteCond %{REQUEST_URI} store_closed.html$
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !^/[0-9]+\..+\.cpaneldcv$
RewriteCond %{REQUEST_URI} !^/[A-F0-9]{32}\.txt(?:\ Comodo\ DCV)?$
RewriteRule ^(.*?)\/(.*)$ $2 [L]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !^/[0-9]+\..+\.cpaneldcv$
RewriteCond %{REQUEST_URI} !^/[A-F0-9]{32}\.txt(?:\ Comodo\ DCV)?$
RewriteRule . index.php [L,QSA]

</IfModule>

# php -- BEGIN cPanel-generated handler, do not edit
# NOTE this account's php is controlled via FPM and the vhost, this is a place holder.
# Do not edit. This next line is to support the cPanel php wrapper (php_cli).
# AddType application/x-httpd-ea-php56 .php .phtml
# php -- END cPanel-generated handler, do not edit 

I now, everythings redirects to https pages... and i want to remain that

But i want an exception for my alias domain2.com ...that is without https and can`t be

 

Obvious domain1.com it is Cscart 4.2.4

 

So.. http://www.domain2.com that without SSL i want to be ALIAS for https://www.domain1.com


CS Cart lovers


 
  • becomarius
  • Senior Member
  • Members
  • Join Date: 09-Feb 12
  • 215 posts

Posted 18 April 2018 - 07:34 PM #2

No one an idee ?!


CS Cart lovers