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 class WebViewTest extends Activity { | |
@Override | |
public void onCreate(Bundle savedInstanceState) { | |
super.onCreate(savedInstanceState); | |
/* Set the Content View */ | |
setContentView(R.layout.main); | |
/* Get the WebView */ | |
WebView wv1 = (WebView) findViewById(R.id.wv1); |
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
#!/bin/bash | |
NAT_INTERN=tap0 | |
NAT_EXTERN=eth0 | |
iptables -t nat -A POSTROUTING -o $NAT_EXTERN -j MASQUERADE | |
iptables -A FORWARD -i $NAT_INTERN -o $NAT_EXTERN -m state --state RELATED,ESTABLISHED -j ACCEPT | |
iptables -A FORWARD -i $NAT_EXTERN -o $NAT_INTERN -j ACCEPT |
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
WebRequest request = WebRequest.Create(PostUrl); | |
request.Method = "POST"; | |
request.ContentLength = data.Length; | |
request.ContentType = "application/x-www-form-urlencoded"; | |
Stream dataStream = request.GetRequestStream(); | |
dataStream.Write(data, 0, data.Length); | |
dataStream.Close(); |
NewerOlder