I have a problem with forcing http for my api call

external program (cant edit it) connects with api using http. curently i have enabled https and api doesnt connect with external server anymore.

in magento i set base url and secure url as https:// - cant connect

when i set base url: http and secure url https - connection is fine, but problem with ssl as on the website i get unsecured content.

could you help me with that?

i guess good htacces rule should work but noting works for me.

this is how my rewrite looks like:

RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]

RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

RewriteRule ^api/([a-z][0-9a-z_]+)/?$ api.php?type=$1 [QSA,L]

any sugestions how to force http for api only?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.