[SOLVED] Can't even get to login

postpar
Posts: 7
Joined: Mon Feb 26, 2018 8:35 pm

[SOLVED] Can't even get to login

Post by postpar »

I'm trying the quick start... I upload all the files, I get a very nice page saying “Website alive!
Click to login, the password is admin.”

I click to log in, and... http://(site-address)/loginURL gives me a 404. So does clicking on Home or Example.

The only uploads I can find are index.php and the themes folder. The instructions say to create a functions.php but don't say where or how.

Anyone? Docs just say it should work.

I have php 7.0.27, with zip, mbstring, and curl support, and mod_rewrite. (I also tried with php 5.6, and PHP-FPM shut off.)

Help?
postpar
Posts: 7
Joined: Mon Feb 26, 2018 8:35 pm

Re: Can't even get to login

Post by postpar »

The issue was that .htaccess already existed and WonderCMS was not appending to it. (CPanel automatically adds .htaccess to describe the php version.)

Sorry to bother you but hopefully someone else learns from my issue? (Might be a good idea to add somewhere in docs)
User avatar
wiz
Posts: 749
Joined: Sat Oct 30, 2010 12:23 am

Re: Can't even get to login

Post by wiz »

Hi postpar.

When you download WonderCMS (https://wondercms.com/latest), there is htaccess in the folder you have to upload for WonderCMS to work.

Please answer a couple of questions so we understand what happened and how we can do better in the future.
1. Did you miss uploading the htaccess file or simply didn't overwrite it? Was it hidden and did you have to click "display hidden files" on your computer? Or did cPanel prevent you from overwriting the file?
2. Did you fix this by re-uploading it, or did you copy paste the contents of the htaccess file? In other terms, how did you fix this?
3. Do you suggest the docs say WonderCMS includes an htaccess file (if that's missing)?

Answering the above will enable us to provide a better WonderCMS installation experience. Thanks postpar!
postpar
Posts: 7
Joined: Mon Feb 26, 2018 8:35 pm

Re: [SOLVED] Can't even get to login

Post by postpar »

.htaccess didn't show up. I use a Mac and it obeys UNIX conventions.

Yes, I think it makes sense to mention that in the docs! Absolutely! If nothing else, then as a troubleshooting step. (For that matter, you could try creating it if it's not seen, during the first run.)

I didn't even realize one was provided, I copied the contents from the web site. In any cpanel controlled site, it's important to leave the existing .htaccess contents alone, so erasing what was on the server would have been bad anyway.

Thanks for your quick reply and for your work in preventing this from happening to others! I've seen the gamut of reactions to this type of issue in other projects, but the usual response is “Well, you should have known to [exceptional issue goes here].”
User avatar
wiz
Posts: 749
Joined: Sat Oct 30, 2010 12:23 am

Re: [SOLVED] Can't even get to login

Post by wiz »

Added this to the Wiki in multiple places:
https://github.com/robiso/wondercms/wik ... mon-errors
https://github.com/robiso/wondercms/wik ... work---404

Also added the link to "List of common errors" on the first page of the WonderCMS wiki - https://github.com/robiso/wiki.
And an additional link to the list of common issues on the WonderCMS download page - https://wondercms.com/latest

I absolutely agree and try to make the install as seamless as possible.
An additional thanks to you for also helping other users by sharing your experience.

Just to make sure, is this page clear on how to fix your issue? https://github.com/robiso/wondercms/wik ... work---404
- included instructions for Windows 7/8/10, macOS Sierra + previous versions of macOS and instructions for Ubuntu.
postpar
Posts: 7
Joined: Mon Feb 26, 2018 8:35 pm

Re: [SOLVED] Can't even get to login

Post by postpar »

Wow. That is terrific and exactly what I'd want to see! Thank you!
User avatar
wiz
Posts: 749
Joined: Sat Oct 30, 2010 12:23 am

Re: [SOLVED] Can't even get to login

Post by wiz »

Most welcome and it wouldn't happen if it weren't for users like yourself. Cheers to you and to many more years of happy users!

To ensure setting "happiness levels" and setting general expectations for WonderCMS and our users, we recently added a "What to (or not to) expect of WonderCMS": https://github.com/robiso/wondercms#wha ... -wondercms

If possible, let me know what you think and if anything needs adding/removing? General opinion is also welcome. :)
postpar
Posts: 7
Joined: Mon Feb 26, 2018 8:35 pm

Re: [SOLVED] Can't even get to login

Post by postpar »

Wow. I really like that... well, other than lack of self updating... though given SourceForge's record I guess it makes sense.

My only real remaining concern is that CPanel / WHM does prepopulate the .htaccess files with important php stuff, and you're not supposed to replace the htaccess files but add to them. Hence my thought that either mentioning this before the “just upload!” step or perhaps auto-populating the .htaccess file would make sense. WordPress, which I realize is as LOT more intrusive (and bulky), does this and it seems to work well.

Now I have to move on to working on the theme. I like what I've seen so far.
User avatar
wiz
Posts: 749
Joined: Sat Oct 30, 2010 12:23 am

Re: [SOLVED] Can't even get to login

Post by wiz »

That is unusual (as a long time cPanel) user I have never noticed anything important generated and always choose to completely remove the default .htaccess (which brought no changes after deleting).

Any chance you could share the contents of your default cPanel .htaccess file and what might be already populated inside? After a short research, I think they might not be important, but I could be completely wrong.
As far as I know, WordPress completely replaces the existing .htaccess file (so in theory it's the same WonderCMS).

We could add an auto creating .htaccess functionality, but this might bring some other security issues:
https://stackoverflow.com/questions/635 ... ccess-file

If you need any help or have any questions regarding creating a theme, create a new topic as it will be easier to manage. If something is unclear, it'll be also added to the wiki.
postpar
Posts: 7
Joined: Mon Feb 26, 2018 8:35 pm

Re: [SOLVED] Can't even get to login

Post by postpar »

It's part of the new MultiPHP system as of version 68. WordPress appends rather than replacing, I believe. You can find a reference here -> https://documentation.cpanel.net/displa ... for+cPanel

Writing to .htaccess does cause security issues, all right.

That said, it might not matter in the end, because apparently CPanel writes to whatever .htaccess file is there if you make changes later.
https://forums.cpanel.net/threads/preve ... ss.598503/

The text written by CPanel:

# php -- BEGIN cPanel-generated handler, do not edit
# Set the “ea-php56” package as the default “PHP” programming language.
<IfModule mime_module>
AddType application/x-httpd-ea-php56 .php .php5 .phtml
</IfModule>
# php -- END cPanel-generated handler, do not edit
Post Reply