Keyword

Redirect all links through site's domain not working

More
8 years 3 months ago #157090 by Dorothy Firsching
Replied by Dorothy Firsching on topic Redirect all links through site's domain not working
When I had used Admintools .htaccess maker, I put in an exception to allow access to that file.
That didn't work.
Nick at Akeeba also recommended that I turn to No "Protect against common file injection attacks". Still no luck.
I then replaced the .htaccess with the stock Joomla! .htaccess. No luck.
Do any changes need to be made to the stock .htaccess to allow it? Any reason it should be blocked by that?
Want to take a look or have me post anything?

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
8 years 3 months ago #157091 by Krikor Boghossian
Replied by Krikor Boghossian on topic Redirect all links through site's domain not working
I 'm on the default .htaccess file and it is working properly.
Can you share me your .htaccess so I can troubleshoot the issue?

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

More
8 years 3 months ago #157093 by Dorothy Firsching
Replied by Dorothy Firsching on topic Redirect all links through site's domain not working
Just this..

##
# READ THIS COMPLETELY IF YOU CHOOSE TO USE THIS FILE!
#
# The line 'Options +FollowSymLinks' may cause problems with some server configurations.
# It is required for the use of mod_rewrite, but it may have already been set by your
# server administrator in a way that disallows changing it in this .htaccess file.
# If using it causes your site to produce an error, comment it out (add # to the
# beginning of the line), reload your site in your browser and test your sef urls. If
# they work, then it has been set by your server administrator and you do not need to
# set it here.
##

## No directory listings
IndexIgnore *

## Can be commented out if causes errors, see notes above.
Options +FollowSymlinks
Options -Indexes

## Mod_rewrite in use.

RewriteEngine On

## Begin - Rewrite rules to block out some common exploits.
# If you experience problems on your site then comment out the operations listed
# below by adding a # to the beginning of the line.
# This attempts to block the most common type of exploit `attempts` on Joomla!
#
# Block any script trying to base64_encode data within the URL.
RewriteCond %{QUERY_STRING} base64_encode[^(]*\([^)]*\) [OR]
# Block any script that includes a <script> tag in URL.
RewriteCond %{QUERY_STRING} (<|%3C)([^s]*s)+cript.*(>|%3E) [NC,OR]
# Block any script trying to set a PHP GLOBALS variable via URL.
RewriteCond %{QUERY_STRING} GLOBALS(=|\[|\%[0-9A-Z]{0,2}) [OR]
# Block any script trying to modify a _REQUEST variable via URL.
RewriteCond %{QUERY_STRING} _REQUEST(=|\[|\%[0-9A-Z]{0,2})
# Return 403 Forbidden header and show the content of the root home page
RewriteRule .* index.php [F]
#
## End - Rewrite rules to block out some common exploits.

## Begin - Custom redirects
#
# If you need to redirect some pages, or set a canonical non-www to
# www redirect (or vice versa), place that code here. Ensure those
# redirects use the correct RewriteRule syntax and the [R=301,L] flags.
#
## End - Custom redirects

##
# Uncomment the following line if your webserver's URL
# is not directly related to physical file paths.
# Update Your Joomla! Directory (just / for root).
##

RewriteBase /~nvar4

## Begin - Joomla! core SEF Section.
#
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
#
# If the requested path and file is not /index.php and the request
# has not already been internally rewritten to the index.php script
RewriteCond %{REQUEST_URI} !^/index\.php
# and the requested path and file doesn't directly match a physical file
RewriteCond %{REQUEST_FILENAME} !-f
# and the requested path and file doesn't directly match a physical folder
RewriteCond %{REQUEST_FILENAME} !-d
# internally rewrite the request to the index.php script
RewriteRule .* index.php [L]
#
## End - Joomla! core SEF Section.

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
8 years 3 months ago #157117 by Krikor Boghossian
Replied by Krikor Boghossian on topic Redirect all links through site's domain not working
Replaced my .htaccess file with yours, the extension is working as expected.

I will look into it in other sites and get back to you.

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

More
8 years 3 months ago #157136 by Dorothy Firsching
Replied by Dorothy Firsching on topic Redirect all links through site's domain not working
Thanks... I have tested 2 sites with it and had no luck.

Please Log in or Create an account to join the conversation.

More
8 years 3 months ago #157139 by Dorothy Firsching
Replied by Dorothy Firsching on topic Redirect all links through site's domain not working
Wow..
I put it on another site, a Joomla 3.5.1 site, and with "redirect through site's domain" it gives a 404 Category not Found rather than a 403. (This was with the Admintools .htaccess file from earlier, but with Admintools disabled.)

Then, I used the Admintools .htaccess maker with adding modules/mod_jw_srfr/redir.php to "allow access to these files' and instead, it now links directly to the feed domain without an error (but not redirecting through the site's domain, either).
Both of these situations happen for both the feed we are looking for and the JoomlaWorks feed.

Going back to the stock .htaccess, it works but links to the feed site.
Re-disabling Admintools, it links to the feed site.
Restoring the Admintools .htaccess but with disabled Admintools, it links to the feed site.
And now enabling Admintools, it is working but linking to the feed site rather than redirecting through the site's domain, despite re-saving the module here and there.

Reinstalling Simple RSS (same, most recent version), turning off "redirect through" and saving, turning on "redirect through" and saving, and even switching to an entirely new browser (IE) to avoid caching issues, it links to the feed site.

So this is different behavior than on the other sites, both of which were Joomla! 3.6.2 with up to date versions of Admintools, while this one is a little behind on 3.5.1.... I will be upgrading it now but wanted to test this, as people are still awaiting a solution.

Thanks!

Please Log in or Create an account to join the conversation.

More
8 years 2 months ago #157257 by Dorothy Firsching
Replied by Dorothy Firsching on topic Redirect all links through site's domain not working
Can you show me somewhere where it is actually working, and what the result looks like? I just spent another hour with a colleague testing it and we can't get rid of the 403's. I would like to figure out whether the end result would be what we want, and I realize that after all this I have never seen it working.

Thanks,

Dorothy

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
8 years 2 months ago #157291 by Krikor Boghossian
Replied by Krikor Boghossian on topic Redirect all links through site's domain not working
I installed here, (lower right). It is a fresh download of the DEV build.
You 'll probably using the same version.
demo.getk2.org/blog-entry

It is on an NGINX server (no htaccess) and it is working as expected.
On my localhost (apache) it is working as expected.

I will upload it on an apache site and get back to you.

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

More
8 years 2 months ago #157396 by Dorothy Firsching
Replied by Dorothy Firsching on topic Redirect all links through site's domain not working
I looked at the link you provided. The behavior is the same as I get with the "redirect" choice off.
If you go to demo.getk2.org/blog-entry and click on, for example, the readmore for "Tabs and Sliders has a new home", you are sent to the www.joomlaworks.net website.

Selecting "redirect all links through site's domain", I had hoped, would make it appear as if the articles in the feed would actually be on the Joomla! site, not a link to the feed site.

So it looks like that "redirect" is turned off or it's action is the same as if it is turned off.

Thanks!

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
8 years 2 months ago #157399 by Krikor Boghossian
Replied by Krikor Boghossian on topic Redirect all links through site's domain not working
The actual link can be found at the bottom of this screenshot -> imgur.com/a/xCsfy it is

demo.getk2.org/modules/mod_jw_srfr/redir.php?url=http%3A%2F%2Ffeedproxy.google.com%2F%7Er%2Fjoomlaworks%2Fblog%2F%7E3%2FlALg53T-bXE%2F264-tabs-sliders-has-a-new-home

This URL will then redirect to the actual link which is in this case in this site.

This is why I asked if the /modules/mod_jw_srfr/redir.php file is accessible and can be executed.

I also tried it with this .htaccess file under PHP 5.6 and 7.0.x
gist.github.com/kricore/2691c7af3ad7a8b8cbe7f0b06c48f690

It works in the same way as the demo I sent you.
Can you send me the htaccess file you are using with Admin Tools?

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum