Base URL override settings

I’ve moved a multi-journal site to a new server. The old url (very well) indexed by google was something like:
http://example.com/journals/index.php/slug
now the new url is
https://example.com/index.php/slug
and all old urls result in a 404 page.
Being on a shared server I cannot access the apache conf file. I’ve tried with an htaccess file like this:

RewriteEngine on  
RewriteRule http://example.com/journals/(.*) https://example.com/$1 [L]
RewriteRule http://example.com/journals/(.*) https://example.com/$1 [L]

but without success.
Now I would like to understand better the paragraph in config.inc on overriding the base url hoping it can help me solving my problem.
Any suggestions?

Hi @claudiotubertini

Your .htaccess rule was not being met. Please, test the following:

RewriteEngine on  
RewriteRule ^journals/(.*) https://example.com/$1 [L]

Best,
Israel

Thank you very much, it works