OK a complete newbie. I’ve downloaded the Plainkit. I’ve then dragged the downloaded folder into the Terminal (I have no idea what Terminal is) and copy and pasted “php -S localhost:8000 kirby/router.php” and pressed return. I’ve then gone to my browser and typed in http://localhost:8000. The web page displays the following
Warning : Unknown: failed to open stream: No such file or directory in Unknown on line 0
Fatal error : Unknown: Failed opening required ‘kirby/router.php’ (include_path=’.:’) in Unknown on line 0
Is that suppose to happen?
So then I have used Fetch FTP app to upload the downloaded file to a sub-folder on my server. www.xyz.co.uk/test But when I visit this address in my browser it just says:
This page is currently offline. We are very sorry for the inconvenience and will fix it as soon as possible.
Advice for developers and administrators:
Change the PHP version to 7.3, 7.4 or 8.0 (PHP 7.4 is recommended)
So I’m at a lose to know how to instal or get started with Kirby.
This error message means that the server you uploaded the folder to does not have PHP 7.3+ enabled. Usually, you can change the PHP version on the server by going to the Dashboard and change the version. What is your hosting service?
As regards your first try:
Are you on a Mac? Have you made sure you were really in the downloaded folder in your Terminal (a terminal is a basically a computer program that lets you execute commands on your computer).
First attempt on my Mac. I’ve taken a screenshot of what I see in Terminal.
Presumably the purpose of this is to create a server thingy on my Mac, for me to create my site before uploading my site and making it live?
Second attempt on my web hosting. If I can find the CPanel dashboard how or where do I change the the PHP version? What should I change the version to? Do I have to upload anything?
Once you stop the server with Ctrl-C, you cannot connect to it anymore, with ls -la I just wanted to see what is in the folder and why it can’t find the router.php file. But the /kirby folder is there and then probably also the router.php inside it. You can find out if that is indeed the case by typing
ls -la kirby
This will output the content of the /kirby folder.
Or you go to that folder in your Finder and check what’s inside it.
If you are not happy with using the command line, an app like MAMP might be better suited?
Urm, what does “command line” mean? I’ve downloaded the free trial of MAMP app (whatever that is) and opened it. Now what do I do? This is the window i get? Does MAMP allow me to set up a local server on my Mac to build my site before transfering it to my web hosting?
Going back to the Terminal attempt. I tried a couple of times to do the Terminal approach, but instead of pressing Ctrl-C quit Terminal. A warning popped-up saying something but I didn’t read it. Could Terminal have started something / a local server that is still running and this be coursing a conflict?
I’ve quit MAMP. Gone to my browser and visited http://localhost:8888 and it now says that it can not connect to the server.
… oh it appears I have to have the MAMP app running and have pressed Start for it to work. Is that correct?
If I’m working on more than website at a time, how does MAMP deal with that?
Also, for now, I want the free MAMP app not the Pro version, but in the MAMP app it still only gives me 14 day trial. Also in the MAMP app (not the pro version) how do I get it to work? Where do I choose the folder with the downloaded Plainkit?
You can then point the document root to the parent folder e.g. a folder www or htdocs or whatever inside the desktop folder.
Then you can reach subfolders of this parent folder with http://localhost:8888/name-of-subfolder.
And yes, the MAMP app has to be running and the server be started with the Start button, otherwise it doesn’t work.
In the Pro version you can define local hosts e.g. plainkit.test etc that then point to a particular folder and would then be reachable in the browser under http.//plainkit.test, but that feature is not available in the free version.
There are of course other local dev environment options available, as pointed out in the cookbook recipe I linked to. But for a first test, Mamp free should be enough.
Thank you for your continued help! I realise I am a newbie and numpty!
The MAMP website forces the user to download both MAMP and MAMP Pro. I have deleted MAMP Pro. When I open MAMP it still says something about being on a 14 trial, can I ignore that? How do I get MAMP (as oppose to the Pro version) to work? What do I do? I don’t understand a single word in this window:
It won’t allow me to click in the Document Root window
I have changed the name of the “plainkit-main” folder to “clientA”. I have created a folder on my Mac desktop called “Local server” and put the clientA folder inside it. Then in MAMP changed the document root pointing to the “Local server” folder.