Have to add the index.php to the end of the url to avoid the 403 error Topic is solved

Need help installing Joomla! 3.x? For all Joomla! 3.x installation issues please use this forum.

Moderator: General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10
Locked
User avatar
BZone
Joomla! Apprentice
Joomla! Apprentice
Posts: 27
Joined: Wed May 29, 2013 11:03 pm

Have to add the index.php to the end of the url to avoid the 403 error

Post by BZone » Fri Aug 17, 2018 11:25 pm

I am having the same problem after a new installation in a subdirectory. I have to add the index.php to the end of the url to avoid the above 403 error. I have never had this happen before on the many installations I have performed. Is there a setting in the php.ini file that needs to be set perhaps?
Last edited by imanickam on Sat Aug 18, 2018 5:15 am, edited 1 time in total.
Reason: Split from the topic https://forum.joomla.org/viewtopic.php?f=707&t=964678. In the future, for your issues, please create separate topics.

sozzled
I've been banned!
Posts: 13639
Joined: Sun Jul 05, 2009 3:30 am
Location: Canberra, Australia

Re: 403 Forbidden Message

Post by sozzled » Sat Aug 18, 2018 3:00 am

BZone wrote:
Fri Aug 17, 2018 11:25 pm
I am having the same problem after a new installation in a subdirectory
A subdirectory of what? Are you saying that you've created a new J! website within an existing J! website (as a subdirectory residing within the file system of another J! website)? Is that what you're saying?

Have you made allowance for this new installation, created as a subdirectory under another J! website, to modify the .htaccess file as recommended in the J! documentation?

It would be easier to not have a new installation of J! as a subdirectory of another J! website. It's too easy to make mistakes when you're copying files from your PC to your site (and vice versa), it makes things more complicated when it comes to backing up your website, and it's easy to lose things. I wouldn't do it this way. How you arrange things is, of course, your choice.

User avatar
AMurray
Joomla! Exemplar
Joomla! Exemplar
Posts: 9739
Joined: Sat Feb 13, 2010 7:35 am
Location: Australia

Re: Have to add the index.php to the end of the url to avoid the 403 error

Post by AMurray » Sat Aug 18, 2018 7:40 am

maybe the OP just means several sites in the one webspace e.g. /public_html/site1, /public_html/site2 not /public_html/site1/site2. ???

(original question that the OP's question was attached to): viewtopic.php?f=707&t=964678
Regards - A Murray
General Support Moderator

sozzled
I've been banned!
Posts: 13639
Joined: Sun Jul 05, 2009 3:30 am
Location: Canberra, Australia

Re: Have to add the index.php to the end of the url to avoid the 403 error

Post by sozzled » Sat Aug 18, 2018 7:56 am

@AMurray: having had the experience of 30 or more years working with online discussion forums, "I have the same problem" is generally a shorthand way of writing, "I haven't got a clue and I'm too tired to figure it out." (See also, https://magazine.joomla.org/internation ... e-probleme). It doesn't matter where this topic originated; it doesn't matter if this is "the same problem" as what someone had 30 minutes or 30 years ago. Chances are, it's not "the same problem".

We can't help until we understand what the OP means by "subdirectory".

User avatar
leolam
Joomla! Master
Joomla! Master
Posts: 20652
Joined: Mon Aug 29, 2005 10:17 am
Location: Netherlands/ Germany/ S'pore/Bogor/ North America
Contact:

Re: Have to add the index.php to the end of the url to avoid the 403 error

Post by leolam » Sat Aug 18, 2018 8:56 am

@Sozzled "you crumpy old man " which of the 4 is applicable to you? :p

@BZone, does this happen on a vpd or dedi or on a shared server? (you have access to the apache.conf?)

Leo 8)
Joomla's #1 Professional Services Provider:
#Joomla Professional Support: https://gws-desk.com -
#Joomla Specialized Hosting Solutions: https://gws-host.com -

sozzled
I've been banned!
Posts: 13639
Joined: Sun Jul 05, 2009 3:30 am
Location: Canberra, Australia

Re: Have to add the index.php to the end of the url to avoid the 403 error

Post by sozzled » Sat Aug 18, 2018 9:15 am

@Leo: *heh-heh-heh* ... all of 'em! :D

User avatar
BZone
Joomla! Apprentice
Joomla! Apprentice
Posts: 27
Joined: Wed May 29, 2013 11:03 pm

Re: Have to add the index.php to the end of the url to avoid the 403 error

Post by BZone » Sat Aug 18, 2018 2:35 pm

Wow, the negativity here is astounding. First, let me say this is not my first rodeo, by splitting my reply to another topic off into this one, the wording does seem strange. I have been building websites for clubs and small businesses for nearly 20 years. I have been upgrading the original HTML websites to J! by building the CMS in a subdirectory of the root (htdocs) and then moving it into the root directory to replace the original site. Reduces site downtime to a minimum that way.
By posting a topic and getting a decent response that fixes the issue, others may gain the knowledge they need as well. If you haven't had this issue, then don't bother to respond. If you have and found the cause, I and others will appreciate you sharing your experience. If I find the solution my self, I will post it.
Apache server, I do have access to the php.ini file.

sozzled
I've been banned!
Posts: 13639
Joined: Sun Jul 05, 2009 3:30 am
Location: Canberra, Australia

Re: Have to add the index.php to the end of the url to avoid the 403 error

Post by sozzled » Sat Aug 18, 2018 6:36 pm

@BZone: there is no "negativity" here. @leolam and @AMurray are good people; I apologise for some of the off-topic public "panel discussion".

I have a different take on how to build websites. If you have one website (and only one website) then it is OK (I suppose) to put the filesystem for that website in the top-level/root/"htdocs"/"public_html folder. As soon as you create a subfolder within that filesystem to store a "development" website (i.e. a second website), you're going to run into strife.

I'm not condemning the practice of locating a website in the top-level/root folder. I disagree with the approach but that's something we can respectfully disagree with. @AMurray gives a good example of what I would describe as good allocation of webspace:
AMurray wrote:
Sat Aug 18, 2018 7:40 am
... several sites in the one webspace, e.g. /public_html/site1, /public_html/site2
In your case you have two websites where the files are located in
  • /htdocs
  • /htdocs/development
where I would approach it like this:
  • /htdocs/mywebsite
  • /htdocs/development
Anyway, when you create websites that are located within a folder of another website's filespace, you need to change the .htaccess file. You may also want to exclude the files in the subdirectory when you're backing up the "parent" site filespace. In my opinion, it becomes messy.

No negativity here. We don't learn if we don't ask questions. We also can't assist if we're operating without information. But one phrase that undermines methodical diagnosis in attempting to resolve any issue is when people write "I have the same problem" particularly when the circumstances are very different. The symptoms of the problem may be the same, perhaps, but not necessarily its cause(s).

Three people go to the doctor. The first one says, "I have a cough". The doctor says, "Take this medicine." The second person says, "I have the same problem". The doctor says, "Take the same medicine". The third person says, "I'm here because the other guys said you were a good doctor."

User avatar
BZone
Joomla! Apprentice
Joomla! Apprentice
Posts: 27
Joined: Wed May 29, 2013 11:03 pm

Re: Have to add the index.php to the end of the url to avoid the 403 error

Post by BZone » Sat Aug 18, 2018 8:13 pm

Thank you sozzled. I should have been more clear and provided an example as you did. Since the development website is temporary I do set it up as your first example but, now that I think about it, your second example does make more sense. I will do it that way from now on.
I found the cause of the issue was, in fact, the root .htaccess file. I eliminated it and all is well. It was an unneeded left-over from the first html site builder that I inherited the client's website from. I normally move the original website files to my private server in an archive folder just prior to moving the J! files to the root directory. I do not include the subdirectory but, mistakes can be made and your suggestion is a good one.
You are correct, "I have the same problem" was not a good choice of wording and I should have created a new post - my apologies.

sozzled
I've been banned!
Posts: 13639
Joined: Sun Jul 05, 2009 3:30 am
Location: Canberra, Australia

Re: Have to add the index.php to the end of the url to avoid the 403 error

Post by sozzled » Sat Aug 18, 2018 8:57 pm

Not a problem. Live a little, learn a little.

I don't always know why things go bump in the night—why 403 Forbidden errors occur—but I try to stay clear of common mistakes that people make. I vaguely remember my very first website; I place the files (a jumbled mess) directly under the webspace root and realised that it was a poor strategic choice. I treat every website I build as something completely separate from every other website I operate. In that way, if one of those sites fails, I can quarantine it (close it off) without affecting any other website.

A useful reference: when building the .htaccess file for a new J! website (on a UNIX-Apache webserver) look at the file htaccess.txt in the "top-level" folder of your website. Take note of lines 59-64 that may help in the situation you've described; not normally needed if you keep your websites "separated" in the way I described.


Locked

Return to “Installation Joomla! 3.x”