1

I am finding some problems after the migration of my Joomla site from local server to my remote Linux server.

The website is this one: lnx.erusma.org

The problem is that if, in the SEO option of my administration pannel, I disable the URL SEF options it work well (as is now) but if I activate this option to have better links it give me the following error every time that I click on a link: No input file specified

I think that maybe it could depend by my .htacces file configuration that is the following one:

##
# @package      Joomla
# @copyright    Copyright (C) 2005 - 2013 Open Source Matters. All rights reserved.
# @license      GNU General Public License version 2 or later; see LICENSE.txt
##

##
# 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.
##

## Can be commented out if causes errors, see notes above.
#Options +FollowSymLinks

## Mod_rewrite in use.

RewriteEngine On

## 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 base64_encode data within the URL.
RewriteCond %{QUERY_STRING} base64_encode[^(]*\([^)]*\) [OR]
# Block out any script that includes a <script> tag in URL.
RewriteCond %{QUERY_STRING} (<|%3C)([^s]*s)+cript.*(>|%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})
# Return 403 Forbidden header and show the content of the root homepage
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 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.
#
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 request is for something within the component folder,
# or for the site root, or for an extensionless URL, or the
# requested URL ends with one of the listed extensions
RewriteCond %{REQUEST_URI} /component/|(/[^.]*|\.(php|html?|feed|pdf|vcf|raw))$ [NC]
# 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.

Can you help me to solve this problem?

Tnx

Andrea

AndreaNobili
  • 40,955
  • 107
  • 324
  • 596
  • is the website *lnx.erusma.org* or *erusma.org* cause the first one which you specified in your question doesn't work – Lodder Sep 18 '13 at 19:11
  • It is lnx.erusma.org, erusma.org is an old version on a Windows server that I will delete when I finish to work on the lnx.erusma.org version (that will take his place at the official URL erusma.org) – AndreaNobili Sep 18 '13 at 19:14
  • do you have **mod_rewrite** turned on? – Lodder Sep 18 '13 at 19:16
  • In the .htaccess file seems yes, or do you mean something else? I have to see it on my web server? – AndreaNobili Sep 18 '13 at 19:20

1 Answers1

2

Ensure you have Apache's mod_rewrite turned on. I'm not sure if you have WHM or anything like that o your server but to check if it's turned on, read this:

How to check if mod_rewrite is enabled in php?

If it still doesn't work, try the following:

  1. Rename htaccess.txt to .htaccess
  2. Open the file and find the line that has “# RewriteBase /”
  3. Remove the # sign to uncomment
  4. Upload the .htaccess file
  5. Enable SEF again in Global Configuration
  6. Refresh browser and check to see if it is working.

Update:

Also try the following:

Bellow RewriteEngine on put

RewriteCond %{REQUEST_URI} ^/index\.php/
RewriteRule ^index.php/(.*) /$1 [R=301,L]
Community
  • 1
  • 1
Lodder
  • 19,758
  • 10
  • 59
  • 100
  • I do this but don't work. In your opinion the problem may depend on whether that the actual URL to reach the website is LNX.erusma.org (because it is on my lnx server) and not erusma.org (that now points to the Windows version of the server and contain the old version of the website)? – AndreaNobili Sep 18 '13 at 19:37
  • No, it shouldn't point to the old server. Transferring a site to a completely different server is easy and should require no edits to the site files. I believe it's a server related issue. Is your host GoDaddy? – Lodder Sep 18 '13 at 19:40
  • No it is Aruba (an italian company) that offer me a Linux+Windows space, now the erusma.org domain point to the Windows server and the lnx.erusma.org point to the linux server. When I end to work on the website I switch and the erusma.org domain will point to the linux server...I don't know if this mechanism can create problem – AndreaNobili Sep 18 '13 at 19:42
  • Do you have URL rewriting turned on or off in the Global Configuration? – Lodder Sep 18 '13 at 19:44
  • What can I do to see it? – AndreaNobili Sep 18 '13 at 19:46
  • It's the option below Search Friendly URL's in the Joomla backend. Also, see my updated answer – Lodder Sep 18 '13 at 19:48
  • GREAT !!! Seems to work now !!! What magic ha you do with these 2 new lines in the .htaccess file? can you explain me? – AndreaNobili Sep 18 '13 at 19:52
  • 1
    Glad it works :) It basically redidects the url. So for example it will redirect **lnx.erusma.org/index.php/health** to **lnx.erusma.org/health**. It's also better for search engine optimization. Seeing as this solved your problem, please accept the answer by click the "tick" icons on the left. – Lodder Sep 18 '13 at 19:57