Answer the question
In order to leave comments, you need to log in
When you go to the record, opens the main page. How to deal with it?
Good day.
Such a problem, I created my own template, I have already pulled most of the pages, but I just can’t make it go to the post page, it opens the main page. Maybe I'm being stupid and missing something, I just started doing this recently.
Here is the code for displaying the entry on the main page
Answer the question
In order to leave comments, you need to log in
Hello!
1) post your code not as a screenshot, but as code. This will help if you need to make any changes to your code. No one will sit and copy it from your screen.
2) The reasons may be the following:
- you incorrectly named your template for the custom record archive, which is why the VI does not see it. Diagnostics - install the Query Monitor plugin and see which template is connected. The solution is to study the template hierarchy and name your template correctly according to the code.
- you're doing a 301 redirect somewhere. For example, some plugin a la Yoast SEO or at the htaccess level, etc.
I don’t see any problems in your code, which is indicated on the screen. The cycle is correctly created. And for sure, it should not produce PHP errors.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question