0
This discussion建議使用基本控制器並覆蓋OnActionExecuting
。 This one提到覆蓋ExecuteCore
。在ViewStart中設置Thread.CurrentUICulture是個好主意嗎?
我發現我可以在_ViewStart.cshtml
中設置它。這些方法之一是否比其他方法更受歡迎?目前還沒有登錄功能,但我正在考慮在會話中存儲文化(來自數據庫)並在ViewStart中讀取會話值。