2014-06-20 26 views
0

我剛剛開始使用Kentico,在Kentico安裝後,我的sql服務器數據庫沒有安裝文件,但我得到的文件在本地存儲在數據庫(localdb)中。所以現在我想知道如何連接現有的數據庫(sql server)。當我嘗試更改Web配置時,但是當我們從Kentico Service Manager運行服務時存在問題。如何連接Kentico網站和數據庫

另外我還遇到了另一個問題,即如果管理員通過界面對文本進行了某些更改並且這些更改也應該反映在數據庫中,那麼如何才能實現這一點。因此,下次有人試圖訪問它將反映給他的網站。請讓我知道它。提前致謝。

回答

0

請參閱: Connecting your project to the database

Daabase Setup

Managed projects are connected to the database and contain Kentico EMS data by default. 
If you're using an unmanaged project, you must connect the project to the database manually. You have two options to connect your project to the database: 
entering the database credentials into the database setup wizard 
adding a connection string to your application's web.config 
Connection string template 

    <add name="CMSConnectionString" connectionString="Persist Security 
Info=False;database=DATABASE_NAME;server=SERVER_NAME;user 
id=USER_NAME;password=PASSWORD;Current Language=English;Connection Timeout=240;"/> 
+0

感謝您的答覆。現在我只想知道,Kentico如何做到這一點,如果我在項目中做了一些更改,那麼這些更改必須保存在數據庫中。讓我知道你是否理解我的查詢。 –

+0

如果您可以通過保存數據或更新文檔信息來澄清問題,那將是一件好事。 –