Skip to content

Instantly share code, notes, and snippets.

View wangxian's full-sized avatar
🚩
Focusing

wangxian wangxian

🚩
Focusing
View GitHub Profile
@wangxian
wangxian / test
Created January 24, 2013 10:08
test.html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Div + CSS Example, Wayhome's Blog</title>
<style type="text/css">
<!--
#wrap{overflow:hidden;}
#sidebar_left,#sidebar_right{ padding-bottom:100000px; margin-bottom:-100000px; /*height: 200px;*/ }
#footer { text-align: center; clear: both; }
@wangxian
wangxian / m.css
Created January 24, 2013 10:10
none
* { margin: 0; padding: 0; border: none; }
a, a:link, a:visited, a:hover, a:active { text-decoration: none; }
a img { border: none; }
body { margin:0; -webkit-text-size-adjust:none; font: 11px; line-height: 16px; color: #666; background: #fcfcfc; }
#wrapper { width: 320px; margin: 0 auto; box-sizing: border-box; }
#main { width: 236px; margin: 0 auto; }
h3 { font-size: 13px; color: #363636; margin: 5px 0; font-weight: bold; }
h3 img { vertical-align: middle; margin: 0 8px; }
var app_config = {
"letter" : ['A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I'],
// "api_server": "http://www.ubox.cn",
// "is_log" : true,
// "debug" : true, // true | false | 2
// "alias" : {
"jquery" : 'jquery-1.8.0.js'
}
};
@wangxian
wangxian / Test.java
Created March 21, 2014 09:54 — forked from skrb/Test.java
import java.io.IOException;
import javafx.application.Application;
import javafx.scene.Scene;
import javafx.scene.layout.StackPane;
import javafx.scene.web.WebEngine;
import javafx.scene.web.WebView;
import javafx.stage.Stage;
public class Test extends Application {
@wangxian
wangxian / .gitignore_global
Created February 14, 2020 16:01 — forked from jacobtomlinson/.gitignore_global
An example global gitignore file
# An example global gitignore file
#
# Place a copy if this at ~/.gitignore_global
# Run `git config --global core.excludesfile ~/.gitignore_global`
# Compiled source #
###################
*.com
*.class
*.dll
@wangxian
wangxian / a-clash-tproxy-gateway.md
Created September 22, 2024 14:22 — forked from phlinhng/a-clash-tproxy-gateway.md
Clash as transparent proxy gateway via TPROXY

Notes

  1. If your local network use public IP ranges instead of private ones, make sure to add respecive RETURN rules to iptables to prevent looping issue
  2. Set clash as DHCP's only DNS server to allow domain-based filter (shunting) rules work
  3. Use lsof -i udp:53 to check if clash's DNS module work fine, otherwise you may have to kill systemd-resolved and any other processes occupying the UDP 53 port
  4. The given scripts will NOT hangle the traffic of gateway itself since it is not recommend to do so. If you want to redirect the egress traffic of the gateway, the following material may be useful

Reference