I wish to produce a custom PHP file that shows posts from the specific category. Used to do some modification to my already heavily modified index.php and referred to it as indexa.php (only for testing). Now index.php is set up to exhibit ALL posts, while indexa.php is really a duplicate of index.php, but what it was once:

<?php query_posts("showposts=16&paged=$paged"); ?>

has become:

<?php query_posts("showposts=16&cat=5&paged=$paged"); ?>

I have submitted this indexa.php to my theme folder via FTP, but there's not a way I possibly could have it working. I have attempted to gain access to it through "http://nailian.ca/indexa.php". This can still display this content on index.php. I Quickly was like ok, imma try the entire url. And So I joined "http://nailian.ca/wp-content/themes/twentyeleven/indexa.php" within the address bar, now it returns in my experience "Fatal error: Call to undefined function get_header() in /home1/twondsky/public_html/nails/wordpress-content/styles/twentyeleven/indexa.php online 15"......

How do you get it done?

Thanks ahead of time ^_____^

The entire url does not return any fatal error, it redirects towards the home page.

It might be useful if you would publish the code out of your indexa.php file.

The mistake was fairly descriptive, indexa was attempting to call a function 'get_header()' that is undefined. In my experience, this could suggest your indexa.php file isn't together with a file that defines the get_header function. Have you remove any includes?

You cannot access the indexa.php directly such as this Wordpres is difficult-wired to visit the index.php file does not appear you devote the URL. (roughly how it operates, there is lots more into it than that)

I'd change tactics: relabel your present index.php to index.bak and focus on index.php directly until you are satisfied. Should you ruin, make use of the backup file to revive the web site.

Incidentally, your change looks good in my experience!