function get_url_params($url, $arg_name) { $regx = '/.*[&|\?]'. $arg_name .'=([^&]*)(.*)/'; preg_match($regx, $url, $match); retu...
分类:
Web程序 时间:
2015-07-07 12:48:17
阅读次数:
522
打开 preferences -> Setting-User,加入以下代码{
"font_size": 14,
"ignored_packages": [],
"auto_complete": true,
"auto_match_enabled": true
}“auto_complete”: true,
“auto_match_enabled”: true
这两...
分类:
其他好文 时间:
2015-07-07 11:06:15
阅读次数:
135
### Rails 异常处理 的多种处理方法
1. routes match '*path', via: :all, to: 'controller#action'
2. application.rb 的 exception_app
```ruby
# application.rb
config.exceptions_app = ->(env) ...
分类:
其他好文 时间:
2015-07-06 19:53:39
阅读次数:
93
<?xml?version="1.0"?encoding="utf-8"?>
<RelativeLayout?xmlns:android="http://schemas.android.com/apk/res/android"
????android:layout_width="match_parent"
????android:layout_height="wrap...
分类:
其他好文 时间:
2015-07-06 18:16:48
阅读次数:
209
fill_parent&match_parent:在Android2.2及以上版本中,fill_parent与match_parent意思相同(其中fill_parent兼容低版本)。都是尽可能多的占用框架内的空间。wrap_content:在保证框内容不丢失的情况下,尽可能少的占用空间。示例1上面...
分类:
其他好文 时间:
2015-07-05 10:54:38
阅读次数:
100
写UI布局:
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"...
分类:
移动开发 时间:
2015-07-05 01:00:23
阅读次数:
329
Game Center 的内容很多,这里主要总结Authentication,match,LeaderBoard1. 关于ui,game center 提供了很多标准ui ,如matchmakervc,friendrequestvc,gamecentervc, leaderboardvc简单易用。我...
分类:
移动开发 时间:
2015-07-05 00:55:15
阅读次数:
212
1. layout xml
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_...
分类:
其他好文 时间:
2015-07-04 19:49:02
阅读次数:
292
1. main layout:
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layou...
分类:
其他好文 时间:
2015-07-04 16:45:14
阅读次数:
150
模式匹配表达式:[]let main argv = let eval x = match x with |5 -> "优" |4 -> "良" |3 -> "中" |_ -> "差" let y = eval 4 ...
分类:
其他好文 时间:
2015-07-03 20:28:17
阅读次数:
115