How to add “Template” option in page attributes panel?

I am new in WordPress. In my theme, I do not have “Template” option in ‘Page Attributes panel’. I want to add this option.

I tried to solve this problem from the following post. But It did not work for me. I am using “WordPress 3.6”.

Adding a Template to the Page Attributes Panel for both Posts and Pages?

I already made a new template file(sunrise.php), which contains –

Template Name: Sunrise

And, I added the php code in my function.php file, from the above link. But, I did not find the template selecting option in my “Page Attributes” panel. Below, I have added an image of my new page present condition. Thanks, in advance.

Solutions Collecting From Web of "How to add “Template” option in page attributes panel?"

If there is everything OK with your template file (it should be placed in root directory of your theme) and the comment is correct then there can be one more thing…

There is/was some mysterious bug, that was preventing template select from appearing. You can read about this bug here:

It’s closed, because it could not be reproduced, so… it’s still not solved.

The good news is that there was workaround for this bug. If you switch to some other theme, and then get back to your theme, then the contents of page template select should be refreshed and correct.

PS. You really shouldn’t be using so old WP 😉