This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// 해당 소스는 curl을 사용하기 때문에, 서버에서 PHP Curl extension을 사용할 수 있어야 합니다. | |
$ch = curl_init(); | |
curl_setopt ($ch, CURLOPT_URL, $LinkView['link_url']); | |
// $LinkView['link_url']에 원하는 대상 페이지 주소를 넣어주세요. | |
curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1); | |
$contents = curl_exec($ch); | |
curl_close($ch); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* { transform: translateZ(0); -webkit- transform: translateZ(0); } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void setBnetByte(String strData, bool isVariable = false) | |
{ | |
String hexData = bnetHelper.Acsii2Hex(strData); | |
if (isVariable) | |
{ | |
byte[] bData = bnetHelper.Hex2Byte(hexData); | |
this.setBnetByte(bData); | |
} | |
else { | |
UInt32 intData = UInt32.Parse(hexData, System.Globalization.NumberStyles.AllowHexSpecifier); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
IPAddress bnetServerIP = Dns.GetHostAddresses(bnetConInfo["ip"])[0]; | |
IPEndPoint bnetServerEP = new IPEndPoint(bnetServerIP, Int32.Parse(bnetConInfo["port"])); | |
this.bnetSock = new Socket(AddressFamily.InterNetwork, SocketType.Dgram, ProtocolType.Udp); | |
byte[] receiveBuffer = new byte[255]; | |
try | |
{ | |
this.bnetSock.ReceiveBufferSize = Int32.MaxValue; | |
this.bnetSock.ReceiveTimeout = 3000; | |
this.getHandleMsg(BnetCode.ConnectionWithServer); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private List<byte> bnetData = new List<byte>(); | |
private BnetHelper bnetHelper = BnetHelper.getInstance(); | |
public byte bnetCommand; | |
public int serverToken = 0; | |
public int clientToken = 0; | |
public BnetProtocol() | |
{ | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ListBoxItem lb = new ListBoxItem(); | |
TextBlock tb = new TextBlock(); | |
/* ListView TextWrapping using TextBlock. */ | |
tb.TextWrapping = TextWrapping.Wrap; | |
tb.Text = data; | |
lb.Content = tb; | |
MainChatList.Items.Add(lb); | |
MainChatList.SelectedIndex = MainChatList.Items.Count - 1; | |
MainChatList.ScrollIntoView(MainChatList.Items[MainChatList.Items.Count - 1]); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ListBoxItem lb = new ListBoxItem(); | |
DockPanel dp = new DockPanel(); | |
TextBlock user = new TextBlock(); | |
user.Text = data.name; | |
if(data.color != null) | |
{ | |
user.Foreground = (SolidColorBrush)(new BrushConverter().ConvertFrom("#" + data.color)); | |
} | |
TextBlock tb = new TextBlock(); | |
tb.TextWrapping = TextWrapping.Wrap; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ListView mList = (ListView) findViewById(R.id.mainList); | |
String[] items = new String[] { | |
"Hello World!", | |
"Foo Bar", | |
"404 Not Found", | |
"Dev Students" | |
}; | |
ArrayAdapter<String> adapter = new ArrayAdapter<String>(this, android.R.layout.simple_expandable_list_item_1, items); | |
mList.setAdapter(adapter); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private void MainTabChanged(object sender, SelectionChangedEventArgs e) | |
{ | |
int tabItem = ((sender as TabControl)).SelectedIndex; | |
if (e.Source is TabControl) // This is a soultion of those problem. | |
{ | |
switch (tabItem) | |
{ | |
case 0: // Chatting | |
Debug.WriteLine("Tab: Chatting"); | |
if (MainChatList.Items.Count > 0) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#.bash_profile | |
if [ -f ~/.bashrc ]; then | |
. ~/.bashrc | |
fi | |
#============================================================ | |
# | |
# ALIASES AND FUNCTIONS | |
# Arguably, some functions defined here are quite big. | |
# If you want to make this file smaller, these functions can |
OlderNewer