Wordpress - How to conditionally enqueue a stylesheet only for a certain page(s)?

I copy pasted your code into my dev environment, changed nothing but the page name, and it works just fine. Are you sure that it's not being enqueued and you just have it pointed wrong or that the page is not named incorrectly or something?


What you've got is right--you're just hooking it to the wrong action. Try the "wp" action instead of "init". When init runs, the is_page() won't work properly yet.

EDIT: I'm wrong. I thought you had add_my_stylesheet hooked to init, but you don't. is_page should work from the enqueue_scripts action. Sorry...carry on...