Recently, all of sudden I got the error message
It's quite weird because it's built-in page, and nothing was changed. Windows events log and SharePoint log doesn't show anything about it.An error occurred during the processing of /sites/site1/Documents/Forms/AllItems.aspx. Code blocks are not allowed in this file.
kaevans says this can be fixed through adding PageParserPath in web.config file. However, after adding it, the error below popped up.
An error occurred during the processing of /sites/site1/Documents/Forms/AllItems.aspx. The server block is not well formed.
Troubleshoot issues with Microsoft SharePoint Foundation.
I think it's caused by some other reason. Since no idea what caused that issue, I created another list view (as default view) through SharePoint Designer, then, Bang! Everything is OK now.