I am new to wordpress theme. I have created a wordpress theme by creating index.php and style.css. This theme is actually a blog theme. So, i have designed all the section in index.php and that is my front page and i have write the php code to display the blog post from the wordpress automaticaly. It works fine.
My question is, when i click on the title of the blog post it goes to the next page which indicates mysitenamedomain/post-id and i seems nothing on that page. whether i want to create a single.php page to display the title, content etc on that page?
In single.php you have to use
loop
Here is documentation: Codex
Try: (in
single.php
):Of course you have to style it.
login admin panel and create a new post here by clicking the “POST” menu of dashboard, put the post title and post content here and then save it . after that check single page on website it will display the title , content etc