cloudjun

web application input & display chinese characters

The backend database is sql server 2000.

1) in web.config, set encoding to utf-8
2) in sql server, set field type to nchar, nvarchar or ntext
3) in the application data access layer, if using stored procedure, just set the input/output parameter to nchar, nvarchar or ntext; if using plain sql, use sth like "insert into employee_table(names, age) values(N'myname', 22)"

sql server will change uft-8 to ucs-2 and vise versa automatically.

posted on 2006-04-19 13:46 jun 阅读(90) 评论(0)  编辑 收藏 网摘





标题  
姓名  
主页
Email (博主才能看到) 
验证码 *  看不清,换一张 [登录][注册]
内容(请不要发表任何与政治相关的内容)  
  登录  使用高级评论  新用户注册  返回页首  恢复上次提交      
Google站内搜索

相关文章:

相关链接: