Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
Can you make sure the SharePoint module is installed in VS 2017. Also try downloading the CSOM dlls from server and add reference them in your project.
Can you try creating a site collection with Team Site template on the UI and then activate the SharePoint Server Publishing Infrastructure site collection feature?
Can you create a new list, add a folder and an item? Go to Content and Structure and see if the folder is visible? This would isolate if the issue is across whole SharePoint or just with the specific list.
Have you tried Microsoft.SharePoint.Client.File.SaveBinaryDirect with clientContext.PendingRequest.RequestExecutor.WebRequest.UnsafeAuthenticatedConnectionSharing = true;? By the way, CSOM uses WCF services to talk to SharePoint so in your case server object model is a good choice. Moreover WCF runs over http which is an extra layer. Server object model apis talk directly to SQL Server SharePoint using binary code.
Please open the page in Google chrome and go to console and paste this ctx.overrideFilterQstring; to make sure the required information (in your case its heading) are there. Can you post that in your answer?
Can you confirm the headings that you like to have nicely formatted on the page exist in the url? If yes, could you also post the sample urls in your question?