Problem with creating page for the path of page display of a view I created a library content type. Its view is library__view; this view has a page display whose path is library, which has a contextual filter on the subject of the books(e.g. math, physics).

I created a page in my theme folder, and renamed it page--library.tpl.php. I also embedded library__view using this line.

views_embed_view('library__view','page');


The problem is that library/math does not show math books (while it works right in the view administrative menu).

What is wrong with this? What is the filename of a view whose path is specified to be in a certain URL (e.g. page--library.tpl.php, library.tpl.php)?
I infer: you have created the view for listing the contents of library content type, now you are embedding that view in the page template file for theming the contents listed on the page created by view. If this is the case than you are doing the things in incorrect way.

Possible cases for creating the template file for views page:
1. Theme the contents rendered by views on http://www.yourdomain.com/library page: For this you need to create template file as per the views template suggestion, also its best to create the template for view from the suggestion generated by view at Theme: Information as below:


The suggestions for creating the template in the below image is based upon the "test-contact" page I have created in views:


2. Theming the content created for library content type: If you want to theme the contents that is rendered while creating a nodes of library type than you need to create the node--library.tpl.php. This template will be just for theming the contents of library content type created originally (not for the content listed on library page created from views) and it wont have any impact on your views page.


  Now coming to your issue of page at `library/math' does not show math books: 



Check if the result in your created view displayed correctly (to confirm that the contextual filter is working fine) on passing math as argument to "Preview with contextual filters" (present at bottom of view).
Make sure that the path of page that you are creating from view is
/library, and for testing purpose you can try changing the path
temporarily to /library123 (If changing the path, than test the
result at yourdomain.com/library123/math page)
Remove the template you have created for embedding the view (as it doesn't seems to be needed, at least as of now)
Clear the cache and check again (not needed logically but no problem for testing purpose)