將 ASP.NET 2.0 與 JavaScript 搭配使用
http://msdn.microsoft.com/zh-tw/library/dd182016.aspx
ClientScriptManager 類別
http://msdn.microsoft.com/zh-tw/library/0skaxdwf%28v=vs.80%29.aspx
ASP.NET中一些JavaScript的使用技巧
http://blog.kkbruce.net/2009/08/aspnetjavascript.html#.T33kIdV4VvQ
ASP.Net Get & Post
http://www.dotblogs.com.tw/sam/archive/2010/05/14/15222.aspx
http://www.dotblogs.com.tw/jimmyyu/archive/2010/10/16/difference-between-get-
and-post.aspx
--
※ 發信站: 批踢踢兔(ptt2.cc)
◆ From: 61.224.50.80
2012/04/06
2012/04/05
Visual Studio .config 加解密
http://msdn.microsoft.com/zh-tw/library/ms254494.aspx
http://www.dotblogs.com.tw/yc421206/archive/2009/04/15/8010.aspx
WinForm:
// Takes the executable file name without the
// .config extension.
try
{
// Open the configuration file and retrieve
// the connectionStrings section.
Configuration config = ConfigurationManager.
OpenExeConfiguration(ConfigurationUserLevel.None);
ConnectionStringsSection section =
config.GetSection("connectionStrings")
as ConnectionStringsSection;
if (section.SectionInformation.IsProtected)
{
// Remove encryption.
section.SectionInformation.UnprotectSection();
}
else
{
// Encrypt the section.
section.SectionInformation.ProtectSection(
"DataProtectionConfigurationProvider");
}
// Save the current configuration.
config.Save();
MessageBox.Show(String.Format("Protected={0}",
section.SectionInformation.IsProtected));
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
WebConfig:
// Open the Web.config file.
Configuration config = WebConfigurationManager.
OpenWebConfiguration("~");
// Get the connectionStrings section.
ConnectionStringsSection section =
config.GetSection("connectionStrings")
as ConnectionStringsSection;
// Toggle encryption.
if (section.SectionInformation.IsProtected)
{
section.SectionInformation.UnprotectSection();
}
else
{
section.SectionInformation.ProtectSection(
"DataProtectionConfigurationProvider");
}
// Save changes to the Web.config file.
config.Save(); // Open the Web.config file.
Configuration config = WebConfigurationManager.
OpenWebConfiguration("~");
// Get the connectionStrings section.
ConnectionStringsSection section =
config.GetSection("connectionStrings")
as ConnectionStringsSection;
// Toggle encryption.
if (section.SectionInformation.IsProtected)
{
section.SectionInformation.UnprotectSection();
}
else
{
section.SectionInformation.ProtectSection(
"DataProtectionConfigurationProvider");
}
// Save changes to the Web.config file.
config.Save();
--
※ 發信站: 批踢踢兔(ptt2.cc)
◆ From: 111.248.107.123
2012/04/03
Web.Config vs Bin
要放在同一層才有用 0rz
把web.config 放在wwwroot/web下面 可是bin放在wwwroot下面這樣會讀不到....
搞半天讀不到FCKeditor的問題竟然是這種蠢包
把web.config 放在wwwroot/web下面 可是bin放在wwwroot下面這樣會讀不到....
搞半天讀不到FCKeditor的問題竟然是這種蠢包
--
※ 發信站: 批踢踢兔(ptt2.cc)
◆ From: 61.224.48.4
2012/03/23
C# Regular Expression Examples
───────────────────────────────────────
http://renjin.blogspot.com/2008/08/regular-expression-examples.html
http://219.85.62.1/Canred/showtopic.aspx?topicid=1229
"^\\d+$" //非負整數(正整數 + 0)
"^[0-9]*[1-9][0-9]*$" //正整數
"^((-\\d+)|(0+))$" //非正整數(負整數 + 0)
"^-[0-9]*[1-9][0-9]*$" //負整數
"^-?\\d+$" //整數
"^\\d+(\\.\\d+)?$" //非負浮點數(正浮點數 + 0)
"^(([0-9]+\\.[0-9]*[1-9][0-9]*)|([0-9]*[1-9][0-9]*\\.[0-9]+)|([0-9]*[1-9][0-9]
//正浮點數
"^((-\\d+(\\.\\d+)?)|(0+(\\.0+)?))$" //非正浮點數(負浮點數 + 0)
"^(-(([0-9]+\\.[0-9]*[1-9][0-9]*)|([0-9]*[1-9][0-9]*\\.[0-9]+)|([0-9]*[1-9][0-
9]*)))$"
//負浮點數
"^(-?\\d+)(\\.\\d+)?$" //浮點數
"^[A-Za-z]+$" //由26個英文字母組成的字符串
"^[A-Z]+$" //由26個英文字母的大寫組成的字符串
"^[a-z]+$" //由26個英文字母的小寫組成的字符串
"^[A-Za-z0-9]+$" //由數字和26個英文字母組成的字符串
"^\\w+$" //由數字、26個英文字母或者下劃線組成的字符串
"^[\\w-]+(\\.[\\w-]+)*@[\\w-]+(\\.[\\w-]+)+$" //email地址
"^[a-zA-z]+://(\\w+(-\\w+)*)(\\.(\\w+(-\\w+)*))*(\\?\\S*)?$" //url
--
※ 發信站: 批踢踢兔(ptt2.cc)
◆ From: 61.224.49.164
http://renjin.blogspot.com/2008/08/regular-expression-examples.html
http://219.85.62.1/Canred/showtopic.aspx?topicid=1229
"^\\d+$" //非負整數(正整數 + 0)
"^[0-9]*[1-9][0-9]*$" //正整數
"^((-\\d+)|(0+))$" //非正整數(負整數 + 0)
"^-[0-9]*[1-9][0-9]*$" //負整數
"^-?\\d+$" //整數
"^\\d+(\\.\\d+)?$" //非負浮點數(正浮點數 + 0)
"^(([0-9]+\\.[0-9]*[1-9][0-9]*)|([0-9]*[1-9][0-9]*\\.[0-9]+)|([0-9]*[1-9][0-9]
//正浮點數
"^((-\\d+(\\.\\d+)?)|(0+(\\.0+)?))$" //非正浮點數(負浮點數 + 0)
"^(-(([0-9]+\\.[0-9]*[1-9][0-9]*)|([0-9]*[1-9][0-9]*\\.[0-9]+)|([0-9]*[1-9][0-
9]*)))$"
//負浮點數
"^(-?\\d+)(\\.\\d+)?$" //浮點數
"^[A-Za-z]+$" //由26個英文字母組成的字符串
"^[A-Z]+$" //由26個英文字母的大寫組成的字符串
"^[a-z]+$" //由26個英文字母的小寫組成的字符串
"^[A-Za-z0-9]+$" //由數字和26個英文字母組成的字符串
"^\\w+$" //由數字、26個英文字母或者下劃線組成的字符串
"^[\\w-]+(\\.[\\w-]+)*@[\\w-]+(\\.[\\w-]+)+$" //email地址
"^[a-zA-z]+://(\\w+(-\\w+)*)(\\.(\\w+(-\\w+)*))*(\\?\\S*)?$" //url
--
※ 發信站: 批踢踢兔(ptt2.cc)
◆ From: 61.224.49.164
2012/03/19
Array in C#
知道Array怎麼運作
但是好像不太習慣C#/Java的Array宣告方式 XD (跟平常比較多寫js/as有關係嗎? XD)
一維陣列 (C# 程式設計手冊)
http://msdn.microsoft.com/zh-tw/library/0a7fscd0(VS.80).aspx
宣告:
int[] array = new int[5];
string[] stringArray = new string[6];
初始化:
int[] array1 = new int[5] { 1, 3, 5, 7, 9 };
string[] weekDays = new string[] { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri",
"Sat" };
或是不用new一個陣列直接塞值進去
int[] array2 = { 1, 3, 5, 7, 9 };
string[] weekDays2 = { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" };
BUT 將陣列指派給這個變數時,就必須使用 new 運算子。例如:
int[] array3;
array3 = new int[] { 1, 3, 5, 7, 9 }; // OK
//array3 = {1, 3, 5, 7, 9}; // Error
另外二維以上多維陣列宣告法為 int[維度] ary = new int[長度]
int[,] array = new int[4, 2];
int[, ,] array1 = new int[4, 2, 3];
--
※ 發信站: 批踢踢兔(ptt2.cc)
◆ From: 114.36.63.151
但是好像不太習慣C#/Java的Array宣告方式 XD (跟平常比較多寫js/as有關係嗎? XD)
一維陣列 (C# 程式設計手冊)
http://msdn.microsoft.com/zh-tw/library/0a7fscd0(VS.80).aspx
宣告:
int[] array = new int[5];
string[] stringArray = new string[6];
初始化:
int[] array1 = new int[5] { 1, 3, 5, 7, 9 };
string[] weekDays = new string[] { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri",
"Sat" };
或是不用new一個陣列直接塞值進去
int[] array2 = { 1, 3, 5, 7, 9 };
string[] weekDays2 = { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" };
BUT 將陣列指派給這個變數時,就必須使用 new 運算子。例如:
int[] array3;
array3 = new int[] { 1, 3, 5, 7, 9 }; // OK
//array3 = {1, 3, 5, 7, 9}; // Error
另外二維以上多維陣列宣告法為 int[維度] ary = new int[長度]
int[,] array = new int[4, 2];
int[, ,] array1 = new int[4, 2, 3];
--
※ 發信站: 批踢踢兔(ptt2.cc)
◆ From: 114.36.63.151
2012/03/08
HTML5 & CSS3 懶人包
HTML5 & CSS3 懶人包
1.Ryan的線上講義
http://www.slideshare.net/ryan/html5-basic
http://www.slideshare.net/ryan/some-html5-samples
http://www.slideshare.net/ryan/css3-basic
2.入門看這裡
http://www.w3schools.com/html5/default.asp
http://www.w3schools.com/css3/default.asp
3.延伸閱讀
http://www.html5rocks.com/en/
http://diveintohtml5.info/
4.相容分析
http://caniuse.com/
http://en.wikipedia.org/wiki/Comparison_of_layout_engines_(HTML5)
5.中文參考書
http://www.tenlong.com.tw/items/9574428656?item_id=57719
http://www.tenlong.com.tw/items/9862014504?item_id=244059
6.高級範例
http://www.apple.com/html5/
--
※ 發信站: 批踢踢兔(ptt2.cc)
◆ From: 114.36.53.174
→ pxxxxxxg:W3School 要小心... 另外我自己是都看 MDN 推 03/09 00:50
→ Corsair:MDN是....? 推 03/09 12:38
→ pxxxxxxg:https://developer.mozilla.org/zh-TW/ 推 03/11 01:29
→ Corsair:m(_ _)m 謝謝光大大 推 03/11 02:06
1.Ryan的線上講義
http://www.slideshare.net/ryan/html5-basic
http://www.slideshare.net/ryan/some-html5-samples
http://www.slideshare.net/ryan/css3-basic
2.入門看這裡
http://www.w3schools.com/html5/default.asp
http://www.w3schools.com/css3/default.asp
3.延伸閱讀
http://www.html5rocks.com/en/
http://diveintohtml5.info/
4.相容分析
http://caniuse.com/
http://en.wikipedia.org/wiki/Comparison_of_layout_engines_(HTML5)
5.中文參考書
http://www.tenlong.com.tw/items/9574428656?item_id=57719
http://www.tenlong.com.tw/items/9862014504?item_id=244059
6.高級範例
http://www.apple.com/html5/
--
※ 發信站: 批踢踢兔(ptt2.cc)
◆ From: 114.36.53.174
→ pxxxxxxg:W3School 要小心... 另外我自己是都看 MDN 推 03/09 00:50
→ Corsair:MDN是....? 推 03/09 12:38
→ pxxxxxxg:https://developer.mozilla.org/zh-TW/ 推 03/11 01:29
→ Corsair:m(_ _)m 謝謝光大大 推 03/11 02:06
訂閱:
文章 (Atom)