not able to run Tutorial: “Single Post Page”

Member | 8

I have trouble with the beginner tutorial…/single-post

May someone can help me out: I've did all steps in a row (twice) but here occurs an error message, I don't know how to interpret.
Following the instructions, I created the app/Presenters/PostPresenter.php
But there is a hint below the file content, I don't understand:
We have to set a correct namespaces App\Presenters for our presenter. It depends on presenter mapping.

The link to the file within the git repo shows the identical content like my config/common.neon

		*: App\*Module\Presenters\*Presenter

I also implemented the new template Post/show.latte, and the link within the Homepage/default.latte File, but unfortunately I do receive the following error, when I click on the Headline to reach the second page.
The first page is rendered without issue, basically nette is working, would I say.

Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator at to inform them of the time this error occurred, and the actions you performed just before this error.

More information about this error may be available in the server error log.

Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.

I double checked the file rights, file content, server is working (.htaccess looks correct in my eyes) and so on. The /Log folder has no entry (but I have proved, it's working). Investigating other examples, the RouterFactory.php does not need to adjusted, I guess.

What do I have to do, to fix this? Which information do I have missed in my puzzle?
Thank you in advance!

Last edited by mes (2022-01-23 02:19)

Member | 257

@mes Hi, the displayed error comes not from Nette application, but from Apache webserver. The issue is with the configuration of Apache (most likely .htaccess) file, not with you PHP-based application. Check the error log of Apache for more information.

Member | 8

@nightfish Thank you!
Your hint was valuable, for me. Now. I've learned now something about PHP Error Log and then verified the .htaccess redirection.

Finally: I missed the

	RewriteBase /

was commented out.
Now everything is working as expected.

May an adjustment within the source project is helpful?…ww/.htaccess#L12

David Grudl
Nette Core | 7734

The RewriteBase value can be different for everyone, so it's commented out to use autodetection, which works in most cases.