COCOS2D
http://www.cocos2d-x.org/MoonWarriors/index.html
http://www.cocos2d-x.org/js-tests/
appgyver
semantic-ui
http://semantic-ui.com/
http://stackoverflow.com/questions/18886813/semantic-ui-vs-bootstrap
http://stackshare.io/stackups/bootstrap-vs-foundation-vs-semantic-ui
http://stackoverflow.com/questions/18886813/semantic-ui-vs-bootstrap
http://stackshare.io/stackups/bootstrap-vs-foundation-vs-semantic-ui
[轉]7 Material Design Web UI Frameworks
http://superdevresources.com/material-design-web-ui-frameworks/
[轉]Creating a fast and mobile-friendly website with Jekyll
http://nicolashery.com/fast-mobile-friendly-website-with-jekyll/
clean coder
http://onenode.blogspot.tw/2015/05/clean-coder.html
clean code 可以看
過早 需求過早精緻化 這我就不懂了
應該說和我的做法不同,也略懂他的意思,但不理解為何
應該是指prototype
番茄工作法可以參考
要等真的確定投入開發時~ 才把完整的需求實作出來
感覺這個跟agile的工作模式有關係
agile 是以interation..為單位一直不斷的循環開發
mm,不行aglie,就要事先確認
agile 本來就是認定需求不確定
然後一直寫一直趕
XD 文件也是作完才產生
pert也可以參考,和約耳不同
我個人覺得......避免需求過早精緻化的部份可能要了解agile的核心概念
agile是用最有效率的工作方式
約耳約的方式是用經驗累積,達到接近值,他是用科學方式預估
clean code 可以看
過早 需求過早精緻化 這我就不懂了
應該說和我的做法不同,也略懂他的意思,但不理解為何
應該是指prototype
番茄工作法可以參考
要等真的確定投入開發時~ 才把完整的需求實作出來
感覺這個跟agile的工作模式有關係
agile 是以interation..為單位一直不斷的循環開發
mm,不行aglie,就要事先確認
agile 本來就是認定需求不確定
然後一直寫一直趕
XD 文件也是作完才產生
pert也可以參考,和約耳不同
我個人覺得......避免需求過早精緻化的部份可能要了解agile的核心概念
agile是用最有效率的工作方式
約耳約的方式是用經驗累積,達到接近值,他是用科學方式預估
[轉]TVS-671-PT-4G: upgraded to i7-4765T
http://forum.qnap.com/viewtopic.php?f=12&t=102210&start=30
symbiosis
Hi,
I've decided to go with i7-4765T (quad-core, 35W) CPU for my TVS-671-PT-4G, got it from ebay for $250.
Got 16GB memory as well: G.SKILL Ripjaws 2x8G DDR3L 1600 (PC3L 12800) F3-1600C9D-16GRSL
Upgrade was easy, even since this is first QNAP unit I open (I have multiple Synology boxes but recently switched to QNAP, got TS-870 Pro filled with 500GB 840 Pro SSDs and 10GB Ethernet), took about 30 minutes with no rush. After upgrade powered on the unit, it started, then rebooted itself and then booted just fine, CPU and 16GB memory recognized, no worries.
Happy with power consumption, new CPU is more powerful than Pentium but consumes less power:
QNAP TVS-671 4x HGST He8, Pentium G3250 - 59.6W idle, 68W file operations, 32.8W sleep
QNAP TVS-671 4x HGST He8, i7-4765T - 52.3W idle, 58.4W file operations
Now awaiting for Intel X540-T2 10GB NIC to complete my setup
P.S. This upgrade will definitely void the warranty as they put a red substance on almost every screw you have to remove...like 30 of them
http://24h.pchome.com.tw/prod/DRAG10-A9005XQZT?q=/S/DRAG10
36500
[轉]迪士尼太強勢?德國百間戲院抵制《復仇者聯盟2》
http://yahootwmovie.tumblr.com/post/117557196243/2
根據THR報導,德國內193座小鎮上的戲院聯合聲稱,因為迪士尼影業提高了電影播放費用,因此拒絕放映《復仇者聯盟2:奧創紀元》,總計686廳。戲院業者透露,迪士尼影業將每張票的拆帳分潤從47.7%大幅提升到53%,並刪減廣告宣傳費用,甚至不再預先支付3D眼鏡的費用。
這個功能太棒了!! [轉]5個新 Google Search 搜尋命令遙控Android手機實測
http://www.playpcesor.com/2015/04/5-google-search-android.html#more
find phone
set reminder 」命令,就能新增任務內容、提醒時間、提醒地點到手機上 設定手機提醒卡片
set an alarm 設定手機鬧鐘 App
note to self 新增各種筆記 App 內容
send directions 打開手機 Google 地圖導航
[轉]Stack Overflow 2015 報告:Javascript 連三年蟬聯最火爆程序語言
http://buzzorange.com/techorange/2015/04/13/stack-overflow-2015/
I 職位
第25.首楞嚴經.卷2.續十番顯見九:約二妄合明顯見性非見之别業妄見。
https://www.youtube.com/watch?v=ZT1ZGxPa7Ac&list=PLA16E144975D1AFCD&index=27
28:37 ~ 34:19 世尊解釋的太棒了!
48:36 ~ 結束 淨界法師 解釋的非常的清楚
28:37 ~ 34:19 世尊解釋的太棒了!
48:36 ~ 結束 淨界法師 解釋的非常的清楚
[轉]turn-a-windows-8-1-pc-into-a-wi-fi-hotspot
這個最清楚 use this
http://blog.xuite.net/yh96301/blog/69378815-Windows+8%E7%AD%86%E8%A8%98%E5%9E%8B%E9%9B%BB%E8%85%A6%E8%A8%AD%E5%AE%9A%E7%82%BA%E7%84%A1%E7%B7%9A%E5%9F%BA%E5%9C%B0%E5%8F%B0
http://win.dyu.edu.tw/winap.htm
http://lifehacker.com/turn-a-windows-8-1-pc-into-a-wi-fi-hotspot-with-the-com-1593327340
command:
netsh wlan set hostednetwork mode=allow ssid=MarkWilson key=Lifehacker
netsh wlan start hostednetwork
Allow other network users to connect
hostednetwork is virtual lan card name
ssid and key..... wifi
can not use
http://blog.xuite.net/yh96301/blog/69378815-Windows+8%E7%AD%86%E8%A8%98%E5%9E%8B%E9%9B%BB%E8%85%A6%E8%A8%AD%E5%AE%9A%E7%82%BA%E7%84%A1%E7%B7%9A%E5%9F%BA%E5%9C%B0%E5%8F%B0
http://win.dyu.edu.tw/winap.htm
http://lifehacker.com/turn-a-windows-8-1-pc-into-a-wi-fi-hotspot-with-the-com-1593327340
command:
netsh wlan set hostednetwork mode=allow ssid=MarkWilson key=Lifehacker
netsh wlan start hostednetwork
hostednetwork is virtual lan card name
ssid and key..... wifi
can not use
[轉]免重灌對齊SSD 4K: AOMEI Partition Assistant
https://duke8888.wordpress.com/2015/02/06/%e5%b0%8f%e7%b1%b3%e8%b7%af%e7%94%b1%e5%99%a8mini-%e7%b0%a1%e5%96%ae%e4%bd%bf%e7%94%a8%e5%bf%83%e5%be%97/
AS SSD Benchmark 去檢視4KB對齊,確認是完成對齊的,但用了一段時間後,4KB突然變成了未對齊… 如下圖中出現紅色的BAD:
我們還是用傲梅分區助手(英文版為 AOMEI Partition Assistant)來完成4KB對齊吧
AS SSD Benchmark 去檢視4KB對齊,確認是完成對齊的,但用了一段時間後,4KB突然變成了未對齊… 如下圖中出現紅色的BAD:
[轉]備份、還原驅動程式
https://duke8888.wordpress.com/2015/02/27/%e5%82%99%e4%bb%bd%e3%80%81%e9%82%84%e5%8e%9f%e9%a9%85%e5%8b%95%e7%a8%8b%e5%bc%8f/
果我們可以直接用批次檔配合 Windows Driver Kit (WDK) 中的 Devcon.exe 去備份客戶
果我們可以直接用批次檔配合 Windows Driver Kit (WDK) 中的 Devcon.exe 去備份客戶
[轉]預付卡
http://www.mobile01.com/topicdetail.php?f=18&t=4340363&p=1
fedora
若手機是雙卡雙待的,最省錢的方式:
插兩張卡:
台哥大 3G(50元-250MB-1個月)
+
台灣之星不分網內外一分鐘2元
台哥大那張,只接電話+3G,不打電話,每個月流量不要用超過,6個月 300元
打電話,一律由台灣之星那張播出,只打電話/接電話 不做其它事,儘量少打,半年內不要打超過75分鐘, 6個月150元
節約使用,總共 6個月 450元,相當於1個月 75元,有微量3G+可以打電話
當然可能的話,要聯絡朋友一律 LINE 語音(免費,吃網路流量,250MB 夠講幾個小時)。
但現實沒那麼完美的
有時候打電話給人是無法用 LINE 的,比如:叫便當、預約、問事情、問商品...什麼的。打給陌生人的,根本無法用 LINE。
即便打給朋友的,有些人也不是手機 3G/4G 一直開著的。這種時候也要播傳統電話過去,叫對方上網開 LINE 有事情要講,然後就趕緊掛掉,換用 LINE 講話,要打幾秒鐘。
所以傳統電話還是有必要的,要選 1分鐘 2元的,一分鐘7元那種太坑了。
sapphirine
想法很好 可惜做不到
雙卡機一卡3G/4G 另一卡一定是2G
台星只能放3G才會通...
所以要同時3G上網+台星卡 是做不到的
要等以後看不會出同時3G雙待 或 4G+3G雙待的
LightWorks完全教程 影片編輯 剪輯
http://wiki.ubuntu.org.cn/index.php?title=LightWorks%E5%AE%8C%E5%85%A8%E6%95%99%E7%A8%8B&variant=zh-hant
微型定位器最小跟踪器汽车老人小孩防窃听防远程监听设备超长待机 ........................
http://item.taobao.com/item.htm?spm=a230r.1.14.78.fkcJGk&id=42956384327&ns=1&abbucket=11#detail
3g 坐機
盈信Ⅱ型 无线插卡座机 固定插卡电话机 移动联通手机SIM卡防辐射http://detail.tmall.com/item.htm?id=43646565511
還真的有這種東西.....哈
還真的有這種東西.....哈
[轉]超便宜的 Asterisk Appliance ,只要 美金$30
超便宜的 Asterisk Appliance ,只要 美金$30。
- 使用 Asterisk-GUI
- 整合了 Google Voice
- FXS x2
- WiFi, Router, Firewall
- 網頁回撥 ClickToCall
Ward Mundy originally shared:
Introducing the Ultimate Asterisk Appliance for Under $30
Today on Nerd Vittles: http://nerdvittles.com/?p=12550
JS200-fx
使用 ssd 注意事項 win8.1 ssdready eMMC
如果平板之類的 eMMC能讀寫的次數就有限了,又不能換
第一:把one drive同步關了
http://www.7sooo.com/?a=url&k=21606e44&u=aHR0cDovL3d3dy5nZXppbGEuY29tL3R1dG9yaWFscy83ODA3Lmh0bWw=&t=V2luOC4xIFVwZGF0ZeWFs!mXreWBnOeUqC@npoHnlKhPbmVEcml2ZeWQjOatpeacjeWKoeaVmeeoiyAtIOi9r!S7ti4uLl@moLzlrZDllaY=&s=5aaC5L2V5Y246L29b25lZHJpdmU=
第二:把windows update取消: 進控制台,把它關了!
為什麼要做這?
因為不做的話,windows會在後台一直寫有的沒的,log,update等等,一直寫,有的檔案很小,一直寫根本在減少eMMC的壽命!
第一:把one drive同步關了
http://www.7sooo.com/?a=url&k=21606e44&u=aHR0cDovL3d3dy5nZXppbGEuY29tL3R1dG9yaWFscy83ODA3Lmh0bWw=&t=V2luOC4xIFVwZGF0ZeWFs!mXreWBnOeUqC@npoHnlKhPbmVEcml2ZeWQjOatpeacjeWKoeaVmeeoiyAtIOi9r!S7ti4uLl@moLzlrZDllaY=&s=5aaC5L2V5Y246L29b25lZHJpdmU=
- 進到設定,找one drive或skydrive,關閉同步
- Win8.1平台:依次定位到计算机配置》管理模板》Windows组件》SkyDrive目录; Win8.1 Update平台:依次定位到计算机配置》管理模板》Windows组件》OneDrive目录。
第二:把windows update取消: 進控制台,把它關了!
為什麼要做這?
因為不做的話,windows會在後台一直寫有的沒的,log,update等等,一直寫,有的檔案很小,一直寫根本在減少eMMC的壽命!
[轉]用 Excle 反推你保單 "解約後" 拿到錢的實值利率, 這才是這張保單的真實利率
http://www.mobile01.com/topicdetail.php?f=291&t=4315910
kkebbc
你先去研究一下利率的算法 單利 跟 複利 有什麼差別
然後研究一下, IRR 怎麼算, excel "Rate" 公式怎麼用
然後用 Excle 反推你保單 "解約後" 拿到錢的實值利率, 這才是這張保單的真實利率.
這個保險員不會跟你講, 因為有些保險公司算出來會低到吐血.
最後再比較其他家保單 , 再決定要不要保
我只能說, 利率好一點保險公司的有 3.6%,
[轉]用特製會議記錄格式開一次有效會議
http://www.playpcesor.com/2015/03/amazing-meeting.html#more
有興趣的朋友,可以到「 amazemeet 」這個網站,去下載他的「 Meeting Facilitator Canvas 」,這是該位站長特別設計的會議格式。
如果你對我改良後的 Evernote 專用會議記錄範本有興趣,也可以到這裡下載我的「 Evernote 會議筆記範本」。
有興趣的朋友,可以到「 amazemeet 」這個網站,去下載他的「 Meeting Facilitator Canvas 」,這是該位站長特別設計的會議格式。
drupal 7 change password
best easy
table user: admin passwd change to
$S$DZC1YWO0ZgrI3JY1NAj6bHzv7yiG7GkskhtTVAu3FLgOtVONdjWD
=> mynewpassword
ps: if try more than 5 times, delete table flood data. then can login agin.
多人同時wifi
ubiquiti
https://www.ubnt.com/unifi/unifi-ap/
http://www.osslab.org.tw/Hardware/Router/UniFi_AP_solution
http://goods.ruten.com.tw/item/qa?21408161381410#qna
-----
ruckus wireless
http://www.informationsecurity.com.tw/article/article_detail.aspx?aid=7532
https://www.ubnt.com/unifi/unifi-ap/
http://www.osslab.org.tw/Hardware/Router/UniFi_AP_solution
http://goods.ruten.com.tw/item/qa?21408161381410#qna
-----
ruckus wireless
http://www.informationsecurity.com.tw/article/article_detail.aspx?aid=7532
[轉]react
颠覆式前端UI开发框架:React
http://www.infoq.com/cn/articles/subversion-front-end-ui-development-framework-react?utm_source=infoq&utm_medium=related_content_link&utm_campaign=relatedContent_articles_clk
创新高性能移动 UI 框架-Canvas UI 框架
http://www.infoq.com/cn/articles/innovative-high-performance-mobile-ui-framework-canvas
http://facebook.github.io/flux/docs/overview.html
=====
I think, if good, many framework use. Don't need fast learn.
http://jsperf.com/react-vs-raw-dom-manipulation/16
http://davidchang.github.io/ngReact/#examples
[轉]版主狂想曲:-「團購券」的全新服務模式-
http://gn00116743.pixnet.net/blog/post/59873545-%E7%89%88%E4%B8%BB%E7%8B%82%E6%83%B3%E6%9B%B2%EF%BC%9A-%E3%80%8C%E5%9C%98%E8%B3%BC%E5%88%B8%E3%80%8D%E7%9A%84%E5%85%A8%E6%96%B0%E6%9C%8D%E5%8B%99%E6%A8%A1%E5%BC%8F-
其實這一點都不奇怪,只要親自當消費者去跟流行、買幾張當紅餐卷使用後就能明白,不只吃個飯被迫排隊定位、食材也明顯被「調整過成本」最重要的是,連通的過路客在期間內都很難享受到好的服務,吃過之後幾乎都沒有任何理由讓我自行去消費第二次,也就成為「一次性餐廳」,根本不可能累積到有持續消費意義的正面口碑。
確實,從追女的角度來看,跟對方說:「我剛好拿到兩張OO的餐卷、一起去吃吧!」既可以避免式低價、又能有效排除對方的不安,最重要的是跳過付錢動作不會尷尬、又能一開始就精準控制預算,更直白的說,可以精準的協助我們規劃整場約會的全套計畫,何樂不為?
既然如此,那這類餐券解套、突圍的方式可以從這邊著手,不妨改販賣另外一種型態的餐卷:「VIP貴賓券」
如果有人想合作發展這個新的消費型態,歡迎跟我聯繫。 -->指該網頁
其實這一點都不奇怪,只要親自當消費者去跟流行、買幾張當紅餐卷使用後就能明白,不只吃個飯被迫排隊定位、食材也明顯被「調整過成本」最重要的是,連通的過路客在期間內都很難享受到好的服務,吃過之後幾乎都沒有任何理由讓我自行去消費第二次,也就成為「一次性餐廳」,根本不可能累積到有持續消費意義的正面口碑。
確實,從追女的角度來看,跟對方說:「我剛好拿到兩張OO的餐卷、一起去吃吧!」既可以避免式低價、又能有效排除對方的不安,最重要的是跳過付錢動作不會尷尬、又能一開始就精準控制預算,更直白的說,可以精準的協助我們規劃整場約會的全套計畫,何樂不為?
既然如此,那這類餐券解套、突圍的方式可以從這邊著手,不妨改販賣另外一種型態的餐卷:「VIP貴賓券」
[轉]關於 RDBMS 的 Schema Migration...
https://blog.gslin.org/
以目前 open source 的兩個專案,MySQL 與 PostgreSQL 來看,裡面提到的 lock 應該都不是問題...
首先是 MySQL 的部份,真的量大的網站都應該是往 InnoDB 投靠,而 pt-online-schema-change 在這個領域則是處理的很好。
Facebook 的 Mark Callaghan 曾經在 2010 年寫過一篇關於 InnoDB 的 online schema change 的原理:「Online Schema Change for MySQL」,主要是利用 Trigger 的機制,用七個步驟架構出沒有 downtime 的 online schame change。
就算不考慮 pt-online-schema-change 這種工具,在 MySQL 5.6 開始,就有愈來愈多 ALTER TABLE 的行為是不會影響到 read/write 了:「Avoiding MySQL ALTER table downtime」。
而 PostgreSQL 的情況也差不多,常見的 ALTER TABLE (新增與刪除 column 與 index) 也都不會影響 read/write。
這些在 Stack Overflow 上有不少討論:「ALTER TABLE without locking the table?」。
MySQL 在 RDBMS 領域裡比起來的確是不怎樣,不過沒有這麼糟糕啊...
以目前 open source 的兩個專案,MySQL 與 PostgreSQL 來看,裡面提到的 lock 應該都不是問題...
首先是 MySQL 的部份,真的量大的網站都應該是往 InnoDB 投靠,而 pt-online-schema-change 在這個領域則是處理的很好。
Facebook 的 Mark Callaghan 曾經在 2010 年寫過一篇關於 InnoDB 的 online schema change 的原理:「Online Schema Change for MySQL」,主要是利用 Trigger 的機制,用七個步驟架構出沒有 downtime 的 online schame change。
就算不考慮 pt-online-schema-change 這種工具,在 MySQL 5.6 開始,就有愈來愈多 ALTER TABLE 的行為是不會影響到 read/write 了:「Avoiding MySQL ALTER table downtime」。
而 PostgreSQL 的情況也差不多,常見的 ALTER TABLE (新增與刪除 column 與 index) 也都不會影響 read/write。
這些在 Stack Overflow 上有不少討論:「ALTER TABLE without locking the table?」。
MySQL 在 RDBMS 領域裡比起來的確是不怎樣,不過沒有這麼糟糕啊...
[轉]前淘宝工程师谈12306:做它比做淘宝难
http://www.yixieshi.com/it/19765.html
前淘宝工程师谈12306:做它比做淘宝难
时间:2014-12-04 15:55 来源:产品中国 作者:佚名
如果把12306外包给IBM或者阿里巴巴来做,能否比现在做得好?
如果是以前,我肯定会回答:是。因为我们始终认为,一个年投入超3亿元的卖火车票网站,没有什么理由做不好吧?其实不光是小编这样认为,包括众多媒体,甚至专业人士都曾喷过12306,但近日一名前淘宝工程师通过科普的方式给了我们一记响亮的耳光:做12306网站难度远高于淘宝。
我曾在淘宝写过一段时间代码,2012年在一家百强民企做电商副总,当时在极为艰苦的条件下带队开发了一个B2C网站,走支付宝和银联支付通道,年营业额千万级。
在平时,12306也就是个正常的电商网站。但一到黄金周,12306就是一个全站所有商品都秒杀,所有SKU(库存量单位,物流管理术语,编者注)都是动态库存的变态。
媒体人喷12306,是他们不懂技术,没有能力和耐心来分析背后的难度。技术人员喷,则是因为大部分的技术人员在短时间思考时,容易陷入过于乐观的误区。
至于12306一期工程3个亿(含硬件)贵不贵我不评价,我只提供一个数字供参考,百度一年的研发费用(不含硬件)是10亿,这个数字来自百度财报。网上能查到。3亿看起来好大一个数字,真用到超大型的电商系统、搜索引擎系统里面,其实也不算什么天文数字了。
再解释一下,为什么秒杀压力大,以及为什么12306的动态库存很复杂。
先说秒杀:
2013年12月25日前后,天猫搞了一个圣诞季积分兑换活动,持续几天。25号上午10点12分,放出了15000个天猫魔盒,从成交记录上看,是19秒内全部抢完。
实际上,我也参加秒杀了,我应该是5秒内答题完成并提交订单,结果告诉我排队的人太多,14秒以后重试。
我想,14秒以后哪还有我的事情呀,于是重新答题秒杀,结果出现了服务器错误的页面。反复刷新几次,就告诉秒杀结束了。
淘宝是什么技术水平呢,淘宝有至少4000技术人员,至少4万台服务器。以淘宝这样的技术水平,也不能做到秒杀时让每个用户都没有拥挤感,为什么呢?
一是要尊重物理原理。一台服务器一秒钟能承受的计算量是有极限的,任你怎么优化,采用多高效的算法和编程语言,都突破不了某个极限。
二是要考虑经济效益。十一黄金周的时候,北京主城区到八达岭长城的路堵得严严实实,但不能因为黄金周的高峰,就把这段路修成长安街那样10车道的高速公路。
再说动态库存:
淘宝秒杀天猫魔盒的时候,只有一个商品(行话叫做SKU),它的库存是15000个。有一个人秒杀到了,库存就减1,19秒卖完的,一秒要成功产生789个订单。想象一下,你在广场上卖火车票,一秒钟有8万人举着钱对你喊:卖给我!
好了,讲了这半天淘宝,可以说12306了吧?
我以北京西到深圳北的G71次高铁为例,它有17个站,3种座位。表面看起来,这不就是3个商品吗?G71商务座、G71一等座、G71二等座。大部分轻易喷12306的技术人员就是在这里栽第一个跟头的。
实际上,G71有136*3 =408种商品(408个SKU),怎么算来的?请看:
如果卖北京西始发的,有16种卖法(因为后面有16个站),北京西到:保定、石家庄、郑州、武汉、长沙、广州、虎门、深圳……都是一个个独立的商品,
同理,石家庄上车的,有15种下车的可能,以此类推,单以上下车的站来计算,有136种票:16+15+14…+2+1=136。每种票都有3种座位,一共是408个商品。
旅客A买了一张北京西(01号站)到保定东(02号站)的,那【北京西到保定东】这个商品的库存就要减一,同时,北京西到石家庄、郑州、武汉、长沙、广州、虎门、深圳等15个站台的商品库存也要减一,也就是说,出一张北京到保定东的票,实际上要减16个商品的库存!
这还不是最复杂的,如果旅客B买了一张北京西(01号站)到深圳北(17号站)的票,除了【北京西到深圳北】这个商品的库存要减一,北京西到保定东、石家庄、郑州、武汉、长沙、广州、虎门等15个站台的商品库存也要减1,保定东到石家庄、郑州、武汉、长沙、广州、虎门、深圳北等15个站台的商品库存要减1……总计要减库存的商品数是16+15+14+…+1=120个。
想象一下,8万人举着钱对你高喊:卖给我。你好不容易在钱堆里找到一只手,拿了他的钱,转身找120个同事,告诉他们减库存,而这120个同事也和你一样被8万人围着;也和你一样,每卖出一个商品要找几十个人减库存……这就是12306动态库存的变态之处。比你平时买东西的任何网站的库存机制都复杂几十上百倍。
再说一下抢票插件,防机器人抢票,也不是加个图片验证码那么简单。验证码设置得复杂一点吧,人们要喷:这只是便宜大学生和办公室白领,农民工连26个字母都认不齐,怎么搞?搞动画验证码吧,也有人喷:视力不好的人怎么办?最后验证码搞得太简单了,皆大欢喜了,其实最高兴的是开发抢票插件的公司。
以上讨论只是把12306当成和淘宝一样没有历史包袱从零起步的交易系统,实际上,它不是,它后面的票池,还有电话售票、火车站售票、代售点售票等多个传统渠道要服务。除了客运服务,12306还有全国最大(很可能也是全球最大)的大宗物资货运系统。
架空政策(包括定价政策、警方打击黄牛政策、身份验证政策)谈技术,是不可能解决春运抢票困局的,要想让春运的时候每个人在12306抢票都毫无拥挤感(但不一定能抢到票,铁路运力摆在那),那就是逼着12306买一大堆服务器对付春运,春运过去后,成为跟amazon一样牛逼的云计算服务商。和逼北京修一条10车道的高速公路去八达岭长城一个道理。
目前的12306技术上是还有问题,比如,抢票高峰,输入个身份证号和图片验证码都卡得要死(本人亲测),服务器端繁忙,你浏览器端卡什么呀?
但人家在进步。相信2015年春运的时候,技术已经不再是一票难求的主要问题。在铁路运力不可能神速增加的情况下,要做到春运更公平地买票,需要靠政策调整。
jekyll & jekyll theme
http://jekyllrb.com/
jekyll theme
https://mademistakes.com/work/ 裡面幾個範例,真是非常的好用,弄個簡單的網站,不用幾分鐘,而且又能產生對應的新增頁面,早發現就不用找網路的樣版了!
和drupal比,如果新增資料不多的,基本上用這個就夠了。
其中的jekyll plugs裡面有i18n或是本地化,如果能用的話,多語言的簡單站台也沒問題。
=========
jekyll theme 中有兩個要特別地方:
一、搜尋:用json.....也不用mysql (簡單看一下,也許有誤)
二、留言:用別人留言系統
這樣的話,基本上就夠用了。
PS:有簡單的購物後,送email的模組的話,那真的用jekyll太棒了,因為主機非常好租,而且又便宜,好維護,好備份。
jekyll theme
https://mademistakes.com/work/ 裡面幾個範例,真是非常的好用,弄個簡單的網站,不用幾分鐘,而且又能產生對應的新增頁面,早發現就不用找網路的樣版了!
和drupal比,如果新增資料不多的,基本上用這個就夠了。
其中的jekyll plugs裡面有i18n或是本地化,如果能用的話,多語言的簡單站台也沒問題。
=========
jekyll theme 中有兩個要特別地方:
一、搜尋:用json.....也不用mysql (簡單看一下,也許有誤)
二、留言:用別人留言系統
這樣的話,基本上就夠用了。
PS:有簡單的購物後,送email的模組的話,那真的用jekyll太棒了,因為主機非常好租,而且又便宜,好維護,好備份。
[轉]國外專業媒體集體評比整理分享,買205 55 R16輪胎可參考看看
http://www.mobile01.com/topicdetail.php?f=276&t=4224117
不過米其林也是六大品牌之一
在國外的專業媒體集評中
表現比較好的只有高階胎PSS和sport cup
但至少也都有中上的水準
假如開車本來就慢慢開,對抓地力和煞停沒有強烈需求
省油導向的消費者,其實連國外媒體都推薦saver+
CPC5相較耐磨度最好的saver+ 耐磨度當然相對較差,但要說不佳,可能也不至於
就像saver+ 和PS3濕地抓地力和煞停比CPC5差
但PS3只有小輸CPC5,saver+跟CPC5就輸比較多
但也都是相對不好,不到不佳
要說不佳
那些倒數名次的輪胎才是真的不佳
3g 分享器
HUAWEI華為 (E5730)喵王 隨身行動熱點機
http://shopping.pchome.com.tw/prod/AGAC3Z-A9005IE9T
重點:E5730可將3G轉為有線網路,讓有線設備也能暢遊3G
==================
無言了,真是便宜
http://taiwan.tmall.com/item/42483777028.htm?spm=a220m.1000858.1000725.7.4SnSGB&id=42483777028&skuId=88461992234&cat_id=50024406&rn=9652f03c6e674fac8283e08619a8a74e&user_id=2097119406&is_b=1
http://detail.1688.com/offer/35816045763.html
==================
無言了,真是便宜
http://taiwan.tmall.com/item/42483777028.htm?spm=a220m.1000858.1000725.7.4SnSGB&id=42483777028&skuId=88461992234&cat_id=50024406&rn=9652f03c6e674fac8283e08619a8a74e&user_id=2097119406&is_b=1
http://detail.1688.com/offer/35816045763.html
[轉]將圖片壓縮與最佳化的免費工具整理,讓圖檔變得更小又不影響品質
http://www.gtwang.org/2014/11/online-image-optimization-tools.html
名稱:Kraken.io
網址:https://kraken.io/
名稱:TinyPNG
網址:https://tinypng.com/
名稱:JPEGmini
網址:http://www.jpegmini.com/
名稱:RIOT
網址:http://luci.criosweb.ro/riot/
名稱:PNG Gauntlet
網址:http://pnggauntlet.com/
名稱:CompressNow
網址:http://compressnow.com/
名稱:Trimage
網址:http://trimage.org/
名稱:ImageOptim
網址:https://imageoptim.com/
http://mashable.com/2013/10/29/image-compressors/
vps
http://zhaofuli.org/10675.html
http://amh.sh/
Hostsailor 再加上折扣碼,一年才$22.87 USD........真是
OpenVZ
512 MB RAM
512 MB VSwap
50 GB HDD
1 Core
1 Gbit Port
512 GB Bandwidth
1 IPV4 address
Unlimited IPV6
Hosted in Netherlands
CPU:2 cores
内存:256MB
vSWAP:512MB
硬盘:25G/RAID10
月流量:500GB/1000Mbps
虚拟架构:OPENVZ
IP/面板:1个/SolusVM
--------------------
HostUS 年付10美元
https://my.hostus.us/cart.php?a=add&pid=103
1 CPU Core
768MB RAM
Swap 768MB
20GB HDD
2048 GB
http://amh.sh/
Hostsailor 再加上折扣碼,一年才$22.87 USD........真是
OpenVZ
512 MB RAM
512 MB VSwap
50 GB HDD
1 Core
1 Gbit Port
512 GB Bandwidth
1 IPV4 address
Unlimited IPV6
Hosted in Netherlands
--------------------
AlphaRacks,13年开办的一家国外VPS主机商,母机应该是洛杉矶PR机房的。现在有一款套餐年付价格10美元,CPU:2 cores
内存:256MB
vSWAP:512MB
硬盘:25G/RAID10
月流量:500GB/1000Mbps
虚拟架构:OPENVZ
IP/面板:1个/SolusVM
--------------------
HostUS 年付10美元
https://my.hostus.us/cart.php?a=add&pid=103
1 CPU Core
768MB RAM
Swap 768MB
20GB HDD
2048 GB
drupal bootstrap i ckeditor removing
use this
<i class="icon glyphicon glyphicon-search" aria-hidden="true"></i>
in drupal bootstrap theme ckeditor 4, usually remove
check follow
https://www.drupal.org/node/2369415
https://www.drupal.org/node/1908696
this way is ok, on
site/all/modules/ckeditor/ckeditor.config.js
put
config.protectedSource.push( /<i[^>]*><\/i>/g );
in CKEDITOR.editorConfig = function(config) { OOXXOO }
then ckeditor can put <i> on source mode, but can not show on edit, change source again, code not remove.
so save, then show on page...... I think it ...ok
just try
<i class="icon glyphicon glyphicon-search" aria-hidden="true"></i>
in drupal bootstrap theme ckeditor 4, usually remove
check follow
https://www.drupal.org/node/2369415
https://www.drupal.org/node/1908696
this way is ok, on
site/all/modules/ckeditor/ckeditor.config.js
put
config.protectedSource.push( /<i[^>]*><\/i>/g );
in CKEDITOR.editorConfig = function(config) { OOXXOO }
then ckeditor can put <i> on source mode, but can not show on edit, change source again, code not remove.
so save, then show on page...... I think it ...ok
just try
druapl 有興趣的model
http://www.drupalla.com/project/
http://www.drupalla.com/project/transliteration
上傳時的檔名非英數問題
http://www.drupalla.com/project/menu_block它可以很轻松的实现菜单分离,通过配置,就完全可以实现学员把Drupal主菜单的子菜单项下面的菜单项,显示到左边栏
http://www.drupalla.com/project/l10n_update这个模块可以自动下载并更新你安装的模块的翻译文件,省的你一个一个去下载导入了
http://www.drupalla.com/project/lightbox2
图片或相片时会跳出一个对话框
http://www.drupalla.com/project/webform
除了会寄送一封Email到指定信箱外
========
https://www.drupal.org/project/ajaxblocks
可以用ajax 載入 block
可以用ajax 載入 block
[轉][Javascript] 自定義Google地圖標誌及參數
http://hsw00.com/x2/forum.php?mod=viewthread&tid=5478
<div id="vat_canvas" style="width:100%;height:100%;"></div>
<script type="text/javascript">
<!--//
var script = document.createElement('script') ;
script.type = 'text/javascript' ;
script.src = 'https://maps.googleapis.com/maps/api/js?v=3.exp&sensor=false&'
+ 'callback=initialize&'
+ 'language=zh-TW' ;
document.body.appendChild(script) ;
var map = null ;
var geoCoder = null ;
var hide_address = '0' ;
function initialize() {
var latlng = new google.maps.LatLng(25.033663, 121.564644) ;
var mapOptions = {
zoom : 16 ,
panControl : false ,
zoomControl : true ,
mapTypeControl : true ,
scaleControl : true ,
streetViewControl : true ,
overviewMapControl : true ,
rotateControl : true ,
center : latlng
};
map = new google.maps.Map(document.getElementById('vat_canvas'), mapOptions) ;
var html = '<div style="width:212px;height:55px;">'
+ '<font color="red">性感小野貓股份有限公司</font><BR>'
+ '<font color="green">統編:12345678</font><BR>'
+ '<font color="blue">地址:台北101性感路野貓巷520號</font></div>' ;
var infowindow = new google.maps.InfoWindow({
content : html
});
var marker = new google.maps.Marker({
map : map ,
position : latlng ,
title : '性感小野貓股份有限公司'
});
infowindow.open(map,marker) ;
}
//-->
</script>
1. var latlng = new google.maps.LatLng(25.033663, 121.564644) ;
須調整裡面的經緯度,可利用Google地圖直接查你要標誌位置的經緯度然後填入.
2. zoom : 16 ,
這數值為地圖的縮放程度,依照需求自己做調整吧.
3. var html = '<div style="width:212px;height:55px;">'
+ '<font color="red">性感小野貓股份有限公司</font><BR>'
+ '<font color="green">統編:12345678</font><BR>'
+ '<font color="blue">地址:台北101性感路野貓巷520號</font></div>' ;
調整自定義標誌的框架寬及高,內容文字跟文字顏色等,視需求自行調整.
4. title : '性感小野貓股份有限公司'
這是滑鼠移到標誌時會顯示的名稱,視需求自行調整吧.
<div id="vat_canvas" style="width:100%;height:100%;"></div>
<script type="text/javascript">
<!--//
var script = document.createElement('script') ;
script.type = 'text/javascript' ;
script.src = 'https://maps.googleapis.com/maps/api/js?v=3.exp&sensor=false&'
+ 'callback=initialize&'
+ 'language=zh-TW' ;
document.body.appendChild(script) ;
var map = null ;
var geoCoder = null ;
var hide_address = '0' ;
function initialize() {
var latlng = new google.maps.LatLng(25.033663, 121.564644) ;
var mapOptions = {
zoom : 16 ,
panControl : false ,
zoomControl : true ,
mapTypeControl : true ,
scaleControl : true ,
streetViewControl : true ,
overviewMapControl : true ,
rotateControl : true ,
center : latlng
};
map = new google.maps.Map(document.getElementById('vat_canvas'), mapOptions) ;
var html = '<div style="width:212px;height:55px;">'
+ '<font color="red">性感小野貓股份有限公司</font><BR>'
+ '<font color="green">統編:12345678</font><BR>'
+ '<font color="blue">地址:台北101性感路野貓巷520號</font></div>' ;
var infowindow = new google.maps.InfoWindow({
content : html
});
var marker = new google.maps.Marker({
map : map ,
position : latlng ,
title : '性感小野貓股份有限公司'
});
infowindow.open(map,marker) ;
}
//-->
</script>
1. var latlng = new google.maps.LatLng(25.033663, 121.564644) ;
須調整裡面的經緯度,可利用Google地圖直接查你要標誌位置的經緯度然後填入.
2. zoom : 16 ,
這數值為地圖的縮放程度,依照需求自己做調整吧.
3. var html = '<div style="width:212px;height:55px;">'
+ '<font color="red">性感小野貓股份有限公司</font><BR>'
+ '<font color="green">統編:12345678</font><BR>'
+ '<font color="blue">地址:台北101性感路野貓巷520號</font></div>' ;
調整自定義標誌的框架寬及高,內容文字跟文字顏色等,視需求自行調整.
4. title : '性感小野貓股份有限公司'
這是滑鼠移到標誌時會顯示的名稱,視需求自行調整吧.
難得不錯的火鍋文 [轉]毒物吃到飽?無毒專家教你6原則健康吃鍋
毒物吃到飽?無毒專家教你6原則健康吃鍋
https://tw.news.yahoo.com/%E6%AF%92%E7%89%A9%E5%90%83%E5%88%B0%E9%A3%BD-%E7%84%A1%E6%AF%92%E5%B0%88%E5%AE%B6%E6%95%99%E4%BD%A06%E5%8E%9F%E5%89%87%E5%81%A5%E5%BA%B7%E5%90%83%E9%8D%8B-050000596.html
吃到飽 從不是我的選擇
天氣冷的時候,孩子有時會想吃火鍋,我們偶爾也會去解解饞,但從不光顧吃到飽的火鍋店,因為這和我的飲食原則有許多地方相違背。火鍋店會附贈飲料、冰淇淋或甜點,這些東西我們幾乎不吃外面的。例如飲料,絕大多數是用果汁粉、紅茶粉泡的,至於冰淇淋有乳化劑、香料和色素,孩子也知道不該吃。
至於可無限取用的火鍋料,儘管冰櫃裡琳瑯滿目,我卻無從下手,找不出新鮮安心的食材,那些丸子、魚餃、熱狗,姑且不論原料的好壞,光是製作過程就摻入很多食品添加物。相比之下,我寧可帶孩子去單點的火鍋店,想吃什麼、想吃多少自己點。
湯底 我習慣這樣子點
火鍋店的花樣越來越多,尤其是涮涮鍋,番茄、香茅、咖哩、起士、甘蔗、昆布、麻辣……多不勝數,光看完就要不少時間。我尊重孩子的口味,但教他們如何吃得健康一點,所以我們會各自選擇喜歡的湯底,請服務人員上鍋時將湯底減半,另外給我們一壺白水,自己加水稀釋。
肉類 我會做這些觀察
因為我不吃餃類和丸子,吃火鍋時一定會吃肉片。服務人員上菜時,我會立刻檢查肉片是否冷凍著,如果已是半退冰狀態,我會要求更換。此外,肉的顏色太紅或太白,我就不吃了。我還會觀察肉的紋理走向,如果很奇怪,就會放一片進鍋子涮涮看,若一涮就分解,那就是組合肉。
這些東西 我絕對不吃
吃火鍋很容易吃入太多調味料,所以基本上我和家人都不沾沙茶醬,只沾少量的和風醬,吃得清爽些。考量到雞蛋的問題很多,我幾乎不在外頭吃,更遑論雞蛋很容易受沙門氏桿菌污染,絕不會拿生蛋黃沾肉吃。
煮鍋 我按照這個順序
就像在家烹調一樣,燙過蔬菜的水不宜拿來喝,而且我習慣先吃肉再吃菜,最後吃飯,在外吃火鍋時,同樣遵循這些原則,衍生出一套煮鍋的順序──先煮白色青菜→加入可久煮的玉米、番茄、豆腐→喝湯,撈出豆腐吃→涮肉吃,再吃鍋裡的青菜,並喝湯→煮綠色青菜吃,吃點白飯。在綠色青菜下鍋之後,我就絕不喝湯。
火鍋久煮 不營養也不科學
我知道很多朋友嫌煮鍋麻煩,就用大鍋煮的方式,一口氣把菜盤全倒入火鍋,把火開至最大,久煮、慢吃。我覺得這並不理想,所有的食物混在一起,很難吃出原味,而不斷煮沸也將營養素破壞;更何況像酸菜白肉鍋、泡菜鍋、海鮮鍋再久煮之後,亞硝酸鹽會大量增加,建議不要這麼做。
(本文摘自/真食物這樣選!這樣吃!/蘋果屋出版)
multiple language druapl site model 多語言
基本上使用下列的model就夠了,之後抓一個版型來用。
1、有個問題在版型上,有的版型會用自做的Main Menu,所以這點要注意,最好是版面有留Main Menu的區塊,這樣就可以放上superfish for Main Menu,但用這個又有一個問題,是css套上去的顏色不太合的情況,所以要先試這塊,先看合不合。
2、之後才進行多語言的測試,基本上,多語言切換完全沒有問題,有介面沒翻譯到的,也可以自行翻譯。
3、另外建議把 使用者登入區塊 關了,因為好看多了,那怎麼登入,直接在根路徑打/user就可以登入。
4、版型後面有版權宣告,記得去template.php改一下。
5、footer區塊,建議自己建一個新的區塊,連接到一個page,這樣就行放很多資訊,不要用原本的footer區塊。
=======設定==========
對應模組功能要打開,記得
架構-內容類型-裡面要多語的類型,在“發佈選項“,要選“已啟用翻譯功能“。
架構-選單-編輯選單 要選 Translate and Localize. Menu items with language will allow translations. Menu items without language will be localized.
====備份/還原======== 不要用那個什麼備份軟體....太浪費時間了!
備份:
1、請直接進phpmyadmin,選 資料庫->匯出->自訂->輸出zip,然後注意一下,blob要HEX輸出。
2、直接把整個drupal目錄copy下來。
還原:
1、先把整個drupal目錄還原到主機上;最後是zip上去,server上解壓最快。
2、直接進 資料庫,用phpmyadmin還 (!!sql檔太大)。
所以請記得,任何安裝後的model,不要用,請砍了,libary也是。別留一堆垃圾,另外將來後續備份,如果只變更site目錄下的檔案,就只備份site目錄。
如果有更新drupal版本,或任何版本,請直接再備份整個drupal目錄。
相信這是最完整的方式.....
============
https://www.drupal.org/project/module_filter
** language tw **
https://localize.drupal.org/translate/languages/zh-hant
drupal-7.33.zh-hant.po
** language **
https://www.drupal.org/project/i18n
i18n-7.x-1.11.zip
https://www.drupal.org/project/variable
variable-7.x-2.5.zip
languageicons-7.x-1.1.zip
** imce & upload & multiple insert **
imce-7.x-1.9.zip
imce_filefield-7.x-1.0.zip
imce_uploader-7.x-1.3.zip
plupload-1.5.8.zip
plupload-7.x-1.7.zip
insert-7.x-1.3.zip
** Menu **
superfish-7.x-1.9.zip
Superfish-for-Drupal-master.zip
gdsmith-jquery.easing-1.3.1-0-g82496a9.zip
** other **
ckeditor-7.x-1.16.zip
filefield_sources-7.x-1.9.zip
jquery_update-7.x-2.4.zip
libraries-7.x-2.2.zip
Flex Slider
1、有個問題在版型上,有的版型會用自做的Main Menu,所以這點要注意,最好是版面有留Main Menu的區塊,這樣就可以放上superfish for Main Menu,但用這個又有一個問題,是css套上去的顏色不太合的情況,所以要先試這塊,先看合不合。
2、之後才進行多語言的測試,基本上,多語言切換完全沒有問題,有介面沒翻譯到的,也可以自行翻譯。
3、另外建議把 使用者登入區塊 關了,因為好看多了,那怎麼登入,直接在根路徑打/user就可以登入。
4、版型後面有版權宣告,記得去template.php改一下。
5、footer區塊,建議自己建一個新的區塊,連接到一個page,這樣就行放很多資訊,不要用原本的footer區塊。
=======設定==========
對應模組功能要打開,記得
架構-內容類型-裡面要多語的類型,在“發佈選項“,要選“已啟用翻譯功能“。
架構-選單-編輯選單 要選 Translate and Localize. Menu items with language will allow translations. Menu items without language will be localized.
====備份/還原======== 不要用那個什麼備份軟體....太浪費時間了!
備份:
1、請直接進phpmyadmin,選 資料庫->匯出->自訂->輸出zip,然後注意一下,blob要HEX輸出。
2、直接把整個drupal目錄copy下來。
還原:
1、先把整個drupal目錄還原到主機上;最後是zip上去,server上解壓最快。
2、直接進 資料庫,用phpmyadmin還 (!!sql檔太大)。
所以請記得,任何安裝後的model,不要用,請砍了,libary也是。別留一堆垃圾,另外將來後續備份,如果只變更site目錄下的檔案,就只備份site目錄。
如果有更新drupal版本,或任何版本,請直接再備份整個drupal目錄。
相信這是最完整的方式.....
============
https://www.drupal.org/project/module_filter
** language tw **
https://localize.drupal.org/translate/languages/zh-hant
drupal-7.33.zh-hant.po
** language **
https://www.drupal.org/project/i18n
i18n-7.x-1.11.zip
https://www.drupal.org/project/variable
variable-7.x-2.5.zip
languageicons-7.x-1.1.zip
** imce & upload & multiple insert **
imce-7.x-1.9.zip
imce_filefield-7.x-1.0.zip
imce_uploader-7.x-1.3.zip
plupload-1.5.8.zip
plupload-7.x-1.7.zip
insert-7.x-1.3.zip
** Menu **
superfish-7.x-1.9.zip
Superfish-for-Drupal-master.zip
gdsmith-jquery.easing-1.3.1-0-g82496a9.zip
** other **
ckeditor-7.x-1.16.zip
filefield_sources-7.x-1.9.zip
jquery_update-7.x-2.4.zip
libraries-7.x-2.2.zip
Flex Slider
FlexSlider Views Slideshow
http://www.devsaran.com/drupal-module
http://www.devsaran.com/drupal-module
durpal menu 多語言
http://blog.csdn.net/ejc2001/article/details/26246723
Structure -> Menu s -> Main menu :
1. click edit menu 2. MULTILINGUAL OPTIONS: Translate and Localize. Menu
items with language will allow translations. Menu items without language will be localized.
Structure -> Menu s -> Main menu :
1. click list links 2. add link or edit menu
***** "path" set <front> or node is different.
<front>:every page show menu
node: only language show language menu
Structure -> Menu s -> Main menu :
1. click edit menu 2. MULTILINGUAL OPTIONS: Translate and Localize. Menu
items with language will allow translations. Menu items without language will be localized.
Structure -> Menu s -> Main menu :
1. click list links 2. add link or edit menu
***** "path" set <front> or node is different.
<front>:every page show menu
node: only language show language menu
joomla T3 framework multiple language
http://www.t3-framework.org/documentation/bs3-customization#multiple-language
but new t3, have some step have different
Step 4: Assign menu for Megamenu
but new t3, have some step have different
Step 4: Assign menu for Megamenu
--> just change MENU , change to your wnat language, then can use.
設定多語言(Multi-Language)站台
http://www.kenming.idv.tw/web-building_config_multi-lang_site_with_joomla25
http://help.joomla.org/files/EN-GB_multilang_tutorial.pdf
http://help.joomla.org/files/EN-GB_multilang_tutorial.pdf
joomla T3 use Extension manager update faild ?!
Use
Components -> JA Extension manager
check update ~ ~
check update ~ ~
[轉]網站設計師必須知道的15個工具網站
http://des13.pixnet.net/blog/post/57498609
ColorCombos
配色是Web 設計的首要大事,Color Combos 幫你預備了數千種配色方案,可以根據色調瀏覽選取。
LIpsum
Lipsum.com是 Lorem Ipsum Text 縮寫的自創詞,字典中不存在的單詞,是在演示頁面結構的時候,需要加文字的地方使用Lorem Ipsum Text 填充可以避免用戶因關注文字的意思而分神。Lipsum.com 可以幫你生成製定數目的Lorem Ipsum 單詞。
What the font?
有時候你對某個Logo 感興趣,想知道是圖片的LOGO是什麼字體做的,可以將Logo 圖片上傳到這個網站,結果之準確會讓你難以置信。
ConvertIcon
Favicon 越來越受歡迎,尤其隨著Firefox 的流行,Firefox 會將你站點的Favicon 標誌顯示在標籤上,也會顯示於書籤,Favicon 支持多種圖形格式,比如png,但IE 並不支持png,該站點可以幫助你將png 等圖片格式的Favicon 轉換成IE 支持的ico 格式。
BgPatterns
背景線上產生器。現代Web設計的趨勢之一包括使用背景圖案,BgPatterns.com可以幫你設計背景圖案,他們有大量可選的圖案,可以按不同方式接合,還可以設置透明度。
HTML Encoder
如果你要在網站中顯示Web代碼,那將是非常煩人的事,你必須將諸如<一類的符號用編碼表示,這個網站可以幫你做這些事情,只需將你的代碼複製進去,他們會幫你生成可以直接使用的代碼。還有HTML Decoder 幫你做相反的事。
Xenocode Browsers
該網站非常有用,可以直接模擬預覽你的網站在IE6, IE7, IE8,Firefox 2, Firefox 3, Google Chrome 以及Opera 中的樣子。唯一的不足是,不支持Mac 和Linux 環境下的瀏覽器。
Test Everything
測試任何你想得到的東西。
這個網站包含了超過100 中工具幫你測試幾乎所有東西,如跨瀏覽器兼容,查PR 值,甚至幫你驗證代碼。
Sprite Generator
CSS Sprites在顯著降低HTTP請求方面功不可沒,但CSS sprite可不是個簡單的技術,Sprite generator 可以幫你做這些繁複的工作,將你的圖片打包成zip上傳上去,他們會把你的圖片組合成sprite,還幫你生成CSS代碼。
Buttonator
線上按鈕產生站,這個網站可以幫你設計漂亮的按鈕。
Load Impact
網站壓力測試站,讓你測試同時上線人數流量等等。
這個壓力測試站點可以幫你測試你的站點的抗壓能力,如果你的某篇文章曾經上過Digg 或StumbleUpon 等網站的首頁,你就會知道抗壓測試多麼重要。
IconFinder
這個網站收藏了大量來自網絡的免費圖標。
TypeTester
可以幫你測試不同字體的顯示效果。
CSS Tidy
這個站點可以幫你檢查CSS 代碼,並修正其中的錯誤,比如,它可以發現你的CSS 代碼中最常見到重複設置問題。
Contact Forms Generators
表單產生站,可以幫助你實現和瀏覽者的互動,無需編程,就能快速生成訪客反饋表單,甚至幫你生成郵件發送PHP, ASP, Perl代碼。
ColorCombos
配色是Web 設計的首要大事,Color Combos 幫你預備了數千種配色方案,可以根據色調瀏覽選取。
LIpsum
Lipsum.com是 Lorem Ipsum Text 縮寫的自創詞,字典中不存在的單詞,是在演示頁面結構的時候,需要加文字的地方使用Lorem Ipsum Text 填充可以避免用戶因關注文字的意思而分神。Lipsum.com 可以幫你生成製定數目的Lorem Ipsum 單詞。
What the font?
有時候你對某個Logo 感興趣,想知道是圖片的LOGO是什麼字體做的,可以將Logo 圖片上傳到這個網站,結果之準確會讓你難以置信。
ConvertIcon
Favicon 越來越受歡迎,尤其隨著Firefox 的流行,Firefox 會將你站點的Favicon 標誌顯示在標籤上,也會顯示於書籤,Favicon 支持多種圖形格式,比如png,但IE 並不支持png,該站點可以幫助你將png 等圖片格式的Favicon 轉換成IE 支持的ico 格式。
BgPatterns
背景線上產生器。現代Web設計的趨勢之一包括使用背景圖案,BgPatterns.com可以幫你設計背景圖案,他們有大量可選的圖案,可以按不同方式接合,還可以設置透明度。
HTML Encoder
如果你要在網站中顯示Web代碼,那將是非常煩人的事,你必須將諸如<一類的符號用編碼表示,這個網站可以幫你做這些事情,只需將你的代碼複製進去,他們會幫你生成可以直接使用的代碼。還有HTML Decoder 幫你做相反的事。
Xenocode Browsers
該網站非常有用,可以直接模擬預覽你的網站在IE6, IE7, IE8,Firefox 2, Firefox 3, Google Chrome 以及Opera 中的樣子。唯一的不足是,不支持Mac 和Linux 環境下的瀏覽器。
Test Everything
測試任何你想得到的東西。
這個網站包含了超過100 中工具幫你測試幾乎所有東西,如跨瀏覽器兼容,查PR 值,甚至幫你驗證代碼。
Sprite Generator
CSS Sprites在顯著降低HTTP請求方面功不可沒,但CSS sprite可不是個簡單的技術,Sprite generator 可以幫你做這些繁複的工作,將你的圖片打包成zip上傳上去,他們會把你的圖片組合成sprite,還幫你生成CSS代碼。
Buttonator
線上按鈕產生站,這個網站可以幫你設計漂亮的按鈕。
Load Impact
網站壓力測試站,讓你測試同時上線人數流量等等。
這個壓力測試站點可以幫你測試你的站點的抗壓能力,如果你的某篇文章曾經上過Digg 或StumbleUpon 等網站的首頁,你就會知道抗壓測試多麼重要。
IconFinder
這個網站收藏了大量來自網絡的免費圖標。
TypeTester
可以幫你測試不同字體的顯示效果。
CSS Tidy
這個站點可以幫你檢查CSS 代碼,並修正其中的錯誤,比如,它可以發現你的CSS 代碼中最常見到重複設置問題。
Contact Forms Generators
表單產生站,可以幫助你實現和瀏覽者的互動,無需編程,就能快速生成訪客反饋表單,甚至幫你生成郵件發送PHP, ASP, Perl代碼。
couchbase youtube demo
http://www.couchbase.com/connect/
http://www.couchbase.com/connect/agenda/keynote-demo-couchbase-server-3-0/
http://www.couchbase.com/connect/agenda/building-always-available-mobile-applications/
http://www.couchbase.com/connect/agenda/general-session-welcome-keynote/
http://www.couchbase.com/connect/agenda/integrating-with-hadoop/
http://www.couchbase.com/connect/agenda/keynote-demo-couchbase-server-3-0/
http://www.couchbase.com/connect/agenda/building-always-available-mobile-applications/
http://www.couchbase.com/connect/agenda/general-session-welcome-keynote/
http://www.couchbase.com/connect/agenda/integrating-with-hadoop/
[轉]ubuntu gimp save to web
http://tutorialforlinux.com/2014/06/26/how-to-save-images-for-the-web-on-ubuntu-linux-by-the-gimp-easy-visual-guide/
sudo su -c "apt-get install gimp-plugin-registry"
sudo su -c "apt-get install gimp-plugin-registry"
[轉]Finding Great Images for your Website -- free pictures
https://computing.artsci.wustl.edu/finding-great-images-your-website
Unsplash truly beautiful photos that are completely free to do anything you want with. 10 new photos every 10 days.
LittleVisuals is similar to Unsplash, but they aim to publish new photos every 7 days. These guys also allow you to download their photos in handy .zip packs!
Function. 100% free to do whatever you want with.
GratisPhotography is a project run by Ryan McGuire, which features new photos added each week. All pictures are completely free of any copyright!
PicJumo recently launched and provides one quality free photo every day! Totally free photos for your commercial & personal work. Make sure you subscribe to get the new ones sent to you daily!
Unsplash truly beautiful photos that are completely free to do anything you want with. 10 new photos every 10 days.
LittleVisuals is similar to Unsplash, but they aim to publish new photos every 7 days. These guys also allow you to download their photos in handy .zip packs!
Function. 100% free to do whatever you want with.
GratisPhotography is a project run by Ryan McGuire, which features new photos added each week. All pictures are completely free of any copyright!
PicJumo recently launched and provides one quality free photo every day! Totally free photos for your commercial & personal work. Make sure you subscribe to get the new ones sent to you daily!
firebase offline-online somethings
Now try to use firebase for design app. But get somethings about :
1. At offline, you can read, but add, delete, edit can not, this "can not" is snapshot that need to online sync, then get data.
2. So firebase example is use models or objects to keep data, but you change activeity or clearn app, then objects data loss. maybe can use Serialization, but not good idea.
3. Can't control local database. This is fun, maybe firebase no local database or other methods for offline. Some app need offline, for counting data, CURD data, keep then sync, counting age.
mm, I think my java, android app and firebase knowledge, I don't real understand or think error. So just writer this message for keep.
1. At offline, you can read, but add, delete, edit can not, this "can not" is snapshot that need to online sync, then get data.
2. So firebase example is use models or objects to keep data, but you change activeity or clearn app, then objects data loss. maybe can use Serialization, but not good idea.
3. Can't control local database. This is fun, maybe firebase no local database or other methods for offline. Some app need offline, for counting data, CURD data, keep then sync, counting age.
mm, I think my java, android app and firebase knowledge, I don't real understand or think error. So just writer this message for keep.
couchbase change domain
http://docs.couchbase.com/couchbase-manual-2.5/cb-install/#couchbase-getting-started-hostnames
1、sudo /etc/init.d/couchbase-server stop
or Linux 2.0 this is /opt/couchbase/var/lib/couchbase/ip. This file contains the identified IP address of the node once it is part of a cluster. Open the file, and add a single line containing the hostname, as configured in the previous step.
For Linux 2.0.1. You update the ip_start file with the hostname. The file is at this location: /opt/couchbase/var/lib/couchbase/ip_start.
Delete the files under:
/opt/couchbase/var/lib/couchbase/data/*
/opt/couchbase/var/lib/couchbase/mnesia/*
/opt/couchbase/var/lib/couchbase/config/config.dat
Execute:
sudo /etc/init.d/couchbase-server start
1、sudo /etc/init.d/couchbase-server stop
or Linux 2.0 this is /opt/couchbase/var/lib/couchbase/ip. This file contains the identified IP address of the node once it is part of a cluster. Open the file, and add a single line containing the hostname, as configured in the previous step.
For Linux 2.0.1. You update the ip_start file with the hostname. The file is at this location: /opt/couchbase/var/lib/couchbase/ip_start.
Delete the files under:
/opt/couchbase/var/lib/couchbase/data/*
/opt/couchbase/var/lib/couchbase/mnesia/*
/opt/couchbase/var/lib/couchbase/config/config.dat
Execute:
sudo /etc/init.d/couchbase-server start
=======================
If can't not, maybe reinstall. just delete
/opt/couchbase/var/lib/couchbase/config/config.dat
then server stop, restart. then can resetup.
[轉]本月精選:怎樣成為一個見錢眼開的真正有錢
http://gn00116743.pixnet.net/blog/post/59054284-%E6%9C%AC%E6%9C%88%E7%B2%BE%E9%81%B8%EF%BC%9A%E6%80%8E%E6%A8%A3%E6%88%90%E7%82%BA%E4%B8%80%E5%80%8B%E8%A6%8B%E9%8C%A2%E7%9C%BC%E9%96%8B%E7%9A%84%E7%9C%9F%E6%AD%A3%E6%9C%89%E9%8C%A2
open source erp
http://bbs.erp100.com/thread-266848-1-1.html
http://www.douban.com/review/5816038/
上述开源ERP软件,曾经势头最劲的是Compiere,两年前是OpenBravo,从今年的InforWorld最佳开源ERP评奖来看,OpenERP似乎开始引领风骚了。从中文化及中文资料翻译的程度来说,Compiere最为完全,其次是OpenERP。但Compiere已经基本淡出了开源ERP的世界。从Google趋势看,2010年前后,OpenBravo排名第一。不过,最近两年,OpenERP的关注度上升很快,已经超过了OpenBravo,排名第一。
pc control android
webkey
http://webkey.cc/
How to Control an Android Device From Your PC
http://blog.laptopmag.com/control-android-from-pc
How to control your Android via PC
http://www.cnet.com/how-to/how-to-control-your-android-via-pc/
aten tap CS533http://www.aten.com/Mobility-&-USB/Tap--USB-to-Bluetooth-KM-Switch/Tap-(USB-to-Bluetooth-KM-Switch)-Tap-your-desktop-keyboard-into-an-iPhone%C2%AE-or-iPad%C2%AE!~CS533.html
http://webkey.cc/
How to Control an Android Device From Your PC
http://blog.laptopmag.com/control-android-from-pc
How to control your Android via PC
http://www.cnet.com/how-to/how-to-control-your-android-via-pc/
aten tap CS533http://www.aten.com/Mobility-&-USB/Tap--USB-to-Bluetooth-KM-Switch/Tap-(USB-to-Bluetooth-KM-Switch)-Tap-your-desktop-keyboard-into-an-iPhone%C2%AE-or-iPad%C2%AE!~CS533.html
安裝應用程式的過程中產生不明的錯誤代碼: "-24"
整個無言...google play store 問題...
網路上最多的是root,砍 對應錯誤程式的資料夾....手機現在不見得會root了
所以建議,把android的同步開到最大,先同步備份一次,然後把手機還原吧!
記得一個小問題,本人碰到的,因為一開始有插sd卡,結果還原時,android把程式還原到sd卡上,所以先把sd拔了,還原完,再插sd卡.............我覺得可能是我搞錯,.....但懶得查了...反正就這樣做
網路上最多的是root,砍 對應錯誤程式的資料夾....手機現在不見得會root了
所以建議,把android的同步開到最大,先同步備份一次,然後把手機還原吧!
記得一個小問題,本人碰到的,因為一開始有插sd卡,結果還原時,android把程式還原到sd卡上,所以先把sd拔了,還原完,再插sd卡.............我覺得可能是我搞錯,.....但懶得查了...反正就這樣做
firebase auth SimpleLogin when offline auth check
>> firebase response
Great question. We are actually putting the finishing touches on login v2 and I think you will be happy with the offline improvements it brings. Ultimately, you are running into issues with what you are trying to do because it cannot be done with the current API. However, with our upcoming login refresh, we will persist session tokens on the client, allowing you to authenticate via custom or simple login without any internet connection. We are still a couple weeks out from finishing this project and making it production-ready, but keep an eye out on this group for announcements.
=================
https://www.firebase.com/docs/web/guide/user-auth.html
Storing User Data
Great question. We are actually putting the finishing touches on login v2 and I think you will be happy with the offline improvements it brings. Ultimately, you are running into issues with what you are trying to do because it cannot be done with the current API. However, with our upcoming login refresh, we will persist session tokens on the client, allowing you to authenticate via custom or simple login without any internet connection. We are still a couple weeks out from finishing this project and making it production-ready, but keep an eye out on this group for announcements.
=================
https://www.firebase.com/docs/web/guide/user-auth.html
Internally, Simple Login generates JWT auth tokens after authenticating against the appropriate provider. It then calls Firebase.auth() with those tokens. It does not store profile or state information in Firebase. In order to persist user data we'll have to save it to our Firebase.
=================
Firebase.auth() in firebase-client-jvm-1.0.18.jar/com/firebase/client/Firebase.class
can not decomplier, for understand how to save data. ....
Firebase.auth() in firebase-client-jvm-1.0.18.jar/com/firebase/client/Firebase.class
can not decomplier, for understand how to save data. ....
mikrotik qos connection timeout (Established)and limit connection
Now P2P is too good, so use QOS can't stop. So
1、 setup limit connection:in Firewall, Filter Rule add
Action: drop Protocol: TCP UDP Extra-Connection Limit: xx
2、set connection timeout: in Firewall, Connections, Tracking-TCP Established Timeout: 00:05:00 (5mins by your want)
then......p2p......can use, but.....you know
1、 setup limit connection:in Firewall, Filter Rule add
Action: drop Protocol: TCP UDP Extra-Connection Limit: xx
2、set connection timeout: in Firewall, Connections, Tracking-TCP Established Timeout: 00:05:00 (5mins by your want)
then......p2p......can use, but.....you know
github 刪除
http://www.douban.com/group/topic/32935166/
>>芽衣
git rm --cached filename
git commit -m "hehe"
git push origin branch
>>cloudaice
上面的一些解法只是保持以后不会跟踪了,要想彻底删除的方法如下:
git filter-branch --index-filter 'git rm -r --cached --ignore-unmatch path/to/your/file' HEAD
git push origin master --force
rm -rf .git/refs/original/
git reflog expire --expire=now --all
git gc --prune=now
git gc --aggressive --prune=now
>>芽衣
git rm --cached filename
git commit -m "hehe"
git push origin branch
>>cloudaice
上面的一些解法只是保持以后不会跟踪了,要想彻底删除的方法如下:
git filter-branch --index-filter 'git rm -r --cached --ignore-unmatch path/to/your/file' HEAD
git push origin master --force
rm -rf .git/refs/original/
git reflog expire --expire=now --all
git gc --prune=now
git gc --aggressive --prune=now
android crosswalk intel XDK codova
剛用intel XDK 做crosswalk,用codova,做純網頁 app,非常慢.....慢到極點了
crosswalk是把最新的chorme的核心,包在apk中,只有4.4才是內建chorme新的核心,所以crosswalk就是把apk包了chorme,讓apk走html5架構暴快
如果單純crosswalk比cocoonjs還快,目前看有人測試,所以是慢在codova.....
codova太慢了,如果用android studio 做原生的webview,連網頁超快,但我現在手機,雖然是4.2,但底層已換chorme,所以我測很快,所以現在兩種情況:
一、以後走4.4後,chorme為底層broswer時,html5暴快,
二、等android studio可以包crosswalk時,就算4.x的都暴快,4.0以下不能用crosswalk,但包了crosswalk會胖20 MB
但,很妙的是,如果走codova crosswalk XDK,放到手機中,吃的記憶體不多,5x~8x MB,但會自動掛掉 .......
crosswalk是把最新的chorme的核心,包在apk中,只有4.4才是內建chorme新的核心,所以crosswalk就是把apk包了chorme,讓apk走html5架構暴快
如果單純crosswalk比cocoonjs還快,目前看有人測試,所以是慢在codova.....
codova太慢了,如果用android studio 做原生的webview,連網頁超快,但我現在手機,雖然是4.2,但底層已換chorme,所以我測很快,所以現在兩種情況:
一、以後走4.4後,chorme為底層broswer時,html5暴快,
二、等android studio可以包crosswalk時,就算4.x的都暴快,4.0以下不能用crosswalk,但包了crosswalk會胖20 MB
但,很妙的是,如果走codova crosswalk XDK,放到手機中,吃的記憶體不多,5x~8x MB,但會自動掛掉 .......
android webview performance crosswalk
Now HAHA!!
https://diego.org/2015/01/07/embedding-crosswalk-in-android-studio/
https://crosswalk-project.org/documentation/embedding_crosswalk/crosswalk_aar.html
=====================================
https://www.timroes.de/2013/11/23/old-webview-vs-chromium-webview/
Have you looked at crosswalk? https://crosswalk-project.org/ It’s a chromium web runtime that can be packaged with the app, so you get a benefit on 4.x devices, not just kitkat. It has more features (like webrtc) and sometimes outperforms chromium webview.
https://crosswalk-project.org/
==============
https://gist.github.com/butelo/9365587
1:R.layout.activity_xwalk_embed_lib -> R.layout.xxxxx
2: R.menu.xwalk_embed_lib -> R.menu.xxxx
3: AndroidManifest.xml
<uses-permission android:name="android.permission.INTERNET">
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE">
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE">
==============
use this
https://groups.google.com/forum/#!msg/adt-dev/nQobKd2Gl_8/Z5yWAvCh4h4J
problem:libxwalkcore.so can be soft.
just do armeabi-v7a.jar is have lib/armeabi-v7a/libxwalkcore.so and jar put in libs
==============
test for this, use android studio, have big problem:libxwalkcore.so
can't load libxwalkcore.so
http://comments.gmane.org/gmane.comp.web.crosswalk.help/250
find this and follow, then can understand....: There are different between android studio and ADT in so library. We must edit build.gradle file to copy libs into build/native-libs dir. for example,
use ver 7.xxxxx
libs already put xwalk_core_library_java.jar and armeabi-v7a/libxwalkcore.so
and
AndroidManifest.xml need to put
<uses-permission android:name="android.permission.INTERNET">
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE">
this is for load libxwalkcore.so success, need to put
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE">
=====================================
Finialy, I can't use this.
If really want to use , please use verion for Cordova + Crosswalk backend. it's easy success.
or use Intel XDK
https://diego.org/2015/01/07/embedding-crosswalk-in-android-studio/
https://crosswalk-project.org/documentation/embedding_crosswalk/crosswalk_aar.html
=====================================
https://www.timroes.de/2013/11/23/old-webview-vs-chromium-webview/
Have you looked at crosswalk? https://crosswalk-project.org/ It’s a chromium web runtime that can be packaged with the app, so you get a benefit on 4.x devices, not just kitkat. It has more features (like webrtc) and sometimes outperforms chromium webview.
https://crosswalk-project.org/
==============
https://gist.github.com/butelo/9365587
1:R.layout.activity_xwalk_embed_lib -> R.layout.xxxxx
2: R.menu.xwalk_embed_lib -> R.menu.xxxx
3: AndroidManifest.xml
<uses-permission android:name="android.permission.INTERNET">
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE">
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE">
==============
use this
https://groups.google.com/forum/#!msg/adt-dev/nQobKd2Gl_8/Z5yWAvCh4h4J
problem:libxwalkcore.so can be soft.
just do armeabi-v7a.jar is have lib/armeabi-v7a/libxwalkcore.so and jar put in libs
==============
test for this, use android studio, have big problem:libxwalkcore.so
can't load libxwalkcore.so
http://comments.gmane.org/gmane.comp.web.crosswalk.help/250
find this and follow, then can understand....: There are different between android studio and ADT in so library. We must edit build.gradle file to copy libs into build/native-libs dir. for example,
use ver 7.xxxxx
libs already put xwalk_core_library_java.jar and armeabi-v7a/libxwalkcore.so
and
AndroidManifest.xml need to put
<uses-permission android:name="android.permission.INTERNET">
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE">
this is for load libxwalkcore.so success, need to put
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE">
=====================================
Finialy, I can't use this.
If really want to use , please use verion for Cordova + Crosswalk backend. it's easy success.
or use Intel XDK
android 自動版本更新
http://blog.csdn.net/xjanker2/article/details/6303937
有非常重要的重點:
*****請先下載Config.java和NetworkTool.java兩個程式,放到對應的java目錄下。
https://code.google.com/p/androidex/source/browse/trunk/jtapp-12-updateapksamples/#jtapp-12-updateapksamples%2Fsrc%2Fjtapp%2Fupdateapksamples
*****UpdateActivity.java 是主程式,把對應的程式碼改到你的程式,其中要注意的是,程式碼中的UpdateActivity請記得要換成你自己的名稱....我也是被搞了一下~~哈
*****為什麼在模擬器中,更新會不能安裝,找到的文章解釋
http://stackoverflow.com/questions/19959890/android-app-not-install-an-existing-package-by-the-same-name-with-a-conflicting
the APK installed in the Emulator is signed with your debug-key(usually installed in ~/.android/debug.keystore)
因為key不同,但實際上,如果建置完畢的話,更新是不會有這問題。目前確實成功。
===========================
發生錯誤:
NetworkTool.java 中
HttpResponse response = client.execute(new HttpGet(url));
會發生
ERROR : android.os.NetworkOnMainThreadException
解決方式:
方法一:/*設定可以讓Thread運行在Android主要Thread*/
http://stackoverflow.com/questions/16439587/android-os-networkonmainthreadexception-with-android-4-2
在 HttpResponse response = client.execute(new HttpGet(url)); 之前放上
if (android.os.Build.VERSION.SDK_INT > 9) {
StrictMode.ThreadPolicy policy = new StrictMode.ThreadPolicy.Builder().permitAll().build();
StrictMode.setThreadPolicy(policy);
}
並
import android.os.StrictMode;
方法二:
etwork problem的問題我試了,是HTTPClient的部份不能在UI Thread做,寫一個extend AsyncTask的class讓HTTPClient的部份在background做就可以了
http://givemepass.blogspot.com/2011/12/http-server.html
===========================
第二個問題:寫檔在sd上
1. 在AVD建的時候要加上SD卡的容量
2. 在 AndroidManifest.xml 補上
有非常重要的重點:
*****請先下載Config.java和NetworkTool.java兩個程式,放到對應的java目錄下。
https://code.google.com/p/androidex/source/browse/trunk/jtapp-12-updateapksamples/#jtapp-12-updateapksamples%2Fsrc%2Fjtapp%2Fupdateapksamples
*****UpdateActivity.java 是主程式,把對應的程式碼改到你的程式,其中要注意的是,程式碼中的UpdateActivity請記得要換成你自己的名稱....我也是被搞了一下~~哈
*****為什麼在模擬器中,更新會不能安裝,找到的文章解釋
http://stackoverflow.com/questions/19959890/android-app-not-install-an-existing-package-by-the-same-name-with-a-conflicting
the APK installed in the Emulator is signed with your debug-key(usually installed in ~/.android/debug.keystore)
因為key不同,但實際上,如果建置完畢的話,更新是不會有這問題。目前確實成功。
===========================
發生錯誤:
NetworkTool.java 中
HttpResponse response = client.execute(new HttpGet(url));
會發生
ERROR : android.os.NetworkOnMainThreadException
解決方式:
方法一:/*設定可以讓Thread運行在Android主要Thread*/
http://stackoverflow.com/questions/16439587/android-os-networkonmainthreadexception-with-android-4-2
在 HttpResponse response = client.execute(new HttpGet(url)); 之前放上
if (android.os.Build.VERSION.SDK_INT > 9) {
StrictMode.ThreadPolicy policy = new StrictMode.ThreadPolicy.Builder().permitAll().build();
StrictMode.setThreadPolicy(policy);
}
並
import android.os.StrictMode;
方法二:
etwork problem的問題我試了,是HTTPClient的部份不能在UI Thread做,寫一個extend AsyncTask的class讓HTTPClient的部份在background做就可以了
http://givemepass.blogspot.com/2011/12/http-server.html
===========================
第二個問題:寫檔在sd上
1. 在AVD建的時候要加上SD卡的容量
2. 在 AndroidManifest.xml 補上
android studio
http://save-coco.blogspot.com/2014/07/maven-eclipseandroid-app.html
Maven 據說很難用...功能強大,很難用
http://blog.csdn.net/wangwei_cq/article/details/17070307
Gradle 現在用這個
http://www.codedata.com.tw/java/understanding-gradle-3-getting-started/
http://ithelp.ithome.com.tw/question/10129873
---------------
http://jdev.tw/blog/3513/learning-android-studio
=====================
setup 1: onclick
http://www.youtube.com/watch?v=RCyuqMVGl4g
TextView mytv = (TextView)findViewById(R.id.textView);
mytv.setText("change textView!");
=====================
setup 2: export apk
builder-> apk
Maven 據說很難用...功能強大,很難用
http://blog.csdn.net/wangwei_cq/article/details/17070307
Gradle 現在用這個
http://www.codedata.com.tw/java/understanding-gradle-3-getting-started/
http://ithelp.ithome.com.tw/question/10129873
---------------
http://jdev.tw/blog/3513/learning-android-studio
=====================
setup 1: onclick
http://www.youtube.com/watch?v=RCyuqMVGl4g
TextView mytv = (TextView)findViewById(R.id.textView);
mytv.setText("change textView!");
=====================
setup 2: export apk
builder-> apk
ruby sinatra admin login rack--two way
1.
http://www.sinatrarb.com/faq.html
2.
http://www.sinatrarb.com/faq.html
require 'sinatra'
helpers do
def protected!
return if authorized?
headers['WWW-Authenticate'] = 'Basic realm="Restricted Area"'
halt 401, "Not authorized\n"
end
def authorized?
@auth ||= Rack::Auth::Basic::Request.new(request.env)
@auth.provided? and @auth.basic? and @auth.credentials and @auth.credentials == ['admin', 'admin']
end
end
get '/' do
"Everybody can see this page"
end
get '/protected' do
protected!
"Welcome, authenticated client"
end
2.
http://www.highdots.com/forums/ruby-rails-talk/logging-out-rake-auth-basic-284054.html
LOGIN FORM (GET LOGIN METHOD)
<form method="post" action="/login">
<p><label>Username</label><input name="post[username]" /></p>
<p><label>Password</label><input name="post[password]"
type="password"/></p>
<p><button type="submit">Login</button></p>
</form>
POST LOGIN METHOD
post '/login' do
if authenticate(params["post"]["username"], Digest::MD5.hexdigest(params["post"]["password"]))
session[:user] = params["post"]["username"]
flash[:notice] = "Login succeeded!"
redirect '/admin'
else
flash[:error] = "Login failed!"
redirect '/login'
end
end
HELPER METHODS
# Authentication is hard-coded as there will only 1-3 users
def authenticate(username, password)
if username == 'admin' and password == '[admin_password_in_MD5]'
return true
else
return false
end
end
# Protect pages
def login_required
if session[:user]
return true
else
redirect '/login'
return false
end
end
# Get the username of the logged in user
def current_user
if session[:user]
session[:user]
end
end
# Verify if a user is logged in
def logged_in?
!!session[:user]
end
jQuery Mobile and AngularJS Working Together
1. http://simonguest.com/2013/04/08/jquery-mobile-and-angularjs-working-together/
2. http://0not.net/index.php/using-angularjs-and-jquery-mobile/
2. http://0not.net/index.php/using-angularjs-and-jquery-mobile/
- At the bottom of body, load AngularJS and then jQM
- Use jQM for routing (which is the default, as long as you don’t include ngRoute)
StrongLoop begin
1. http://docs.strongloop.com/display/LB/LoopBack+2.0+release+notes
2. http://docs.strongloop.com/display/LB/Project+layout+reference
3. http://docs.strongloop.com/pages/viewpage.action?pageId=3836281
4. https://github.com/strongloop/loopback-example-app this is new loopback example, need to look at this example, can understand how to work loopback.
if see "slc lb", the mean is old loopback 1.0, so don't need to see.
5. https://github.com/strongloop/loopback-example-passport
http://passportjs.org/guide/oauth/
I try many, so now I think loopback 2.0....is too new, many docs is not correct. Maybe furture is good or ok, but now for develpoer is no good....
2. http://docs.strongloop.com/display/LB/Project+layout+reference
3. http://docs.strongloop.com/pages/viewpage.action?pageId=3836281
4. https://github.com/strongloop/loopback-example-app this is new loopback example, need to look at this example, can understand how to work loopback.
if see "slc lb", the mean is old loopback 1.0, so don't need to see.
5. https://github.com/strongloop/loopback-example-passport
http://passportjs.org/guide/oauth/
I try many, so now I think loopback 2.0....is too new, many docs is not correct. Maybe furture is good or ok, but now for develpoer is no good....
StrongLoop Access Control
x http://docs.strongloop.com/display/LB/Controlling+data+access
x can't use old...https://github.com/strongloop/loopback-example-access-contro
.................l
Ok http://docs.strongloop.com/display/LB/Creating+and+authenticating+users
1. http://xxx-xxx.rhcloud.com/explorer/#!/Users
2. New User
2.1. Click POST /Users
2.2. Click to set as parameter value
2.3. Change value: username 'tt', email 'tt@tt.com' . Add new "password": "xxx",
2.4. Try it out! if Response Code = 200 then success.
3. Login User
3.1. before login, try to Click Get /Users/{id} , put id = 1, Try it out! get error msg: 401 Authorization Required..... now can sure, not login.
x can't use old...https://github.com/strongloop/loopback-example-access-contro
.................l
Ok http://docs.strongloop.com/display/LB/Creating+and+authenticating+users
1. http://xxx-xxx.rhcloud.com/explorer/#!/Users
2. New User
2.1. Click POST /Users
2.2. Click to set as parameter value
2.3. Change value: username 'tt', email 'tt@tt.com' . Add new "password": "xxx",
2.4. Try it out! if Response Code = 200 then success.
3. Login User
3.1. before login, try to Click Get /Users/{id} , put id = 1, Try it out! get error msg: 401 Authorization Required..... now can sure, not login.
3.2. Click POST /Users/login
3.3. credentials value input {"username":"tt", "password":"xxx"}
3.4. if see id , ttl, created, userid then success. id = access token
3.5. copy id value, put access token on page top. click Set Access Token.
3.6. now go back 3.1, try again. now success. login user only can use by self fun.
StrongLoop OpenShift offine-sync TEST
1. https://developers.openshift.com/en/getting-started-client-tools.html#ubuntu
2. http://docs.strongloop.com/display/SL/OpenShift
3.http://xxxx-xxxxx.rhcloud.com/
http://xxxx-xxxxx.rhcloud.com/explorer/
http://strongloop.com/strongblog/node-js-rest-api-openshift-redhat/?utm_source=tuicool
old : loopback :http://loopback.io/
new : http://strongloop.com/
===========
rhc create-app sl https://raw.github.com/strongloop/openshift-cartridge-strongloop/master/metadata/manifest.yml
rhc show-app xxxxx 查相關資訊
rhc show-app xxxxx --gears quota 查空間
*ubuntu *
1. curl -sL https://deb.nodesource.com/setup | sudo bash -
if local no file, use rhc git-clone to get file in local. *ps.1
use mongodb : sudo npm install loopback-connector-mongodb --save
** mongodb://$OPENSHIFT_MONGODB_DB_HOST:$OPENSHIFT_MONGODB_DB_PORT/ ......this can't use, please login openshit, then command line:
>echo $OPENSHIFT_MONGODB_DB_HOST
>echo $OPENSHIFT_MONGODB_DB_PORT
>git init
>git add -A
>git commit -a -m "Initial Commit"
>git commit -a -m "msg about commit"
>git remote add openshift <remote_git_url>
>git push --force openshift master
ps:
1. if local file failed, use command: rhc git-clone xxx :: xxx -> app name
2. http://www.codeproject.com/Articles/746155/Deploying-MongoDB-and-Node-js-application-on-OpenS
3. http://docs.mongodb.org/ecosystem/platforms/red-hat-openshift/
-------------
http://strongloop.com/node-js/studio-beta/
2. http://docs.strongloop.com/display/SL/OpenShift
3.http://xxxx-xxxxx.rhcloud.com/
http://xxxx-xxxxx.rhcloud.com/explorer/
http://strongloop.com/strongblog/node-js-rest-api-openshift-redhat/?utm_source=tuicool
old : loopback :http://loopback.io/
new : http://strongloop.com/
===========
rhc create-app sl https://raw.github.com/strongloop/openshift-cartridge-strongloop/master/metadata/manifest.yml
rhc show-app xxxxx 查相關資訊
rhc show-app xxxxx --gears quota 查空間
===========
update to openshift, need to install local npm and strongloop*ubuntu *
1. curl -sL https://deb.nodesource.com/setup | sudo bash -
2. sudo apt-get install nodejs https://github.com/joyent/node/wiki/Installing-Node.js-via-package-manager
3. npm install -g strongloop
===========
ALL in LOCAL:
slc loopback:datasource myMongoDB this is local, not on openshift
3. npm install -g strongloop
===========
ALL in LOCAL:
slc loopback:datasource myMongoDB this is local, not on openshift
if local no file, use rhc git-clone to get file in local. *ps.1
use mongodb : sudo npm install loopback-connector-mongodb --save
>echo $OPENSHIFT_MONGODB_DB_HOST
>echo $OPENSHIFT_MONGODB_DB_PORT
- git mothod : in local app directory
>git init
>git add -A
>git commit -a -m "Initial Commit"
>git commit -a -m "msg about commit"
>git remote add openshift <remote_git_url>
>git push --force openshift master
ps:
1. if local file failed, use command: rhc git-clone xxx :: xxx -> app name
2. http://www.codeproject.com/Articles/746155/Deploying-MongoDB-and-Node-js-application-on-OpenS
3. http://docs.mongodb.org/ecosystem/platforms/red-hat-openshift/
-------------
http://strongloop.com/node-js/studio-beta/
ssh logini openshift
use puttygen to product .ppk , need product openssh key (menu conversions)
command line:ssh -i "openssh key" xxxxx@xx-xxxx.rhcloud.com
then can login, use linux ssh ~~~
command line:ssh -i "openssh key" xxxxx@xx-xxxx.rhcloud.com
then can login, use linux ssh ~~~
dreamfactory realtime
http://community.dreamfactory.com/t/realtime-integration-firebase-socket-io/178
http://blog.dreamfactory.com/blog/bid/300138/Mobile-App-Development-with-CORs-and-Pub-Sub3
*vm https://bitnami.com/stack/dreamfactory/virtual-machine
http://faye.jcoglan.com/
http://blog.dreamfactory.com/blog/bid/300138/Mobile-App-Development-with-CORs-and-Pub-Sub3
*vm https://bitnami.com/stack/dreamfactory/virtual-machine
http://faye.jcoglan.com/
[轉]程式開發者談Facebook上的授權以及帳號被盜的觀念
http://www.cool3c.com/article/65408
https://www.facebook.com/settings?tab=applications
https://www.facebook.com/settings?tab=applications
3 4 way couchbase couchbase lite sync_gateway :: online - offline - sync
This is OK! Sure!
1、use aws install ubuntu 14 (8GB),install
http://www.couchbase.com/download
**Couchbase Server "3.0 b2"
**Sync Gateway lates..
sudo dpkg -i
install finish!
this json use databases: todos , so sync_gateway need setup this.
***ps:setup 2, if create bucket todos, use passwoard. need add in config file.
port: 4985 for admin, 4984 for user
***ps: 2014/10/28 SYNC_URL = "http://xxx.xxx.amazonaws.com:4984/todos/";
if use this way is ok, can use.
1、use aws install ubuntu 14 (8GB),install
http://www.couchbase.com/download
**Couchbase Server "3.0 b2"
**Sync Gateway lates..
sudo dpkg -i
install finish!
--------------
2、Setup Couchbase Server http://127.0.0.1:8091 (http://xxx.xxx.compute.amazonaws.com:8091)
** default bucket, ram set 100MB (now just for test), why, because aws ram less.
** create bucket : todos (for mobile app use)
--------------
3、Set Sync Gateway
** edit .bashrc, add => export PATH="$PATH:/opt/couchbase-sync-gateway/bin/"
** create config file, name: xxxxx
xxxx :https://github.com/couchbaselabs/ToDoLite-Android/ use this sync-gateway-config.json
but add line : "adminInterface":":4985",
change line or add : "server": "http://127.0.0.1:8091/",
***ps:setup 2, if create bucket todos, use passwoard. need add in config file.
"username": "todos",
"password": "xxxxxxxxxx",
--------------
4、Then > sync_gateway xxxxx
connect to http://127.0.0.1:4985/_admin/ (http://xxx.xxx.compute.amazonaws.com:4985/_admin/)
if see Welcome to Couchbase Sync Gateway. , success. and check it about have a link : todos,if have, all ok!
--------------
5、Try to download https://github.com/couchbaselabs/ToDoLite-Android
Cahnge:app/src/main/java/com/couchbase/todolite/Application.java
Application.java SYNC_URL = "127.0.0.1:4984"
Application.java SYNC_URL = "127.0.0.1:4984"
"xxx.xxx.compute.amazonaws.com:4984"
***ps: 2014/10/28 SYNC_URL = "http://xxx.xxx.amazonaws.com:4984/todos/";
if use this way is ok, can use.
--------------
after all, follow step for
https://github.com/couchbaselabs/ToDoLite-Android/
--------------
then play app with your server~~~~
4 way, 3 way data binding offline data synchronization in angularjs
http://fitc.ca/presentation/4-way-data-binding-offline-data-synchronization-in-angularjs/
http://fitc.ca/presentation/mobile-offline-data-synchronization-in-angularjs/
watch ppt firest,
http://www.youtube.com/watch?v=6ecuA-pOev0&feature=youtu.be&t=14m9s
then see this youtube, begin time:14:45 start demo
v6 time:29:17 CouchDB online synchronization to CouchDB
time: 31:26 have ios emu
-----
Sync multiple AngularJS apps without server via PouchDB
http://www.mircozeiss.com/sync-multiple-angularjs-apps-without-server-via-pouchdb/
http://www.youtube.com/watch?v=QSC1fnfUlU0
this easy simple to try sync
-----
Building offline applications with AngularJS and PouchDB 13 Jun 2013
http://www.mircozeiss.com/building-offline-applications-with-angularjs-and-pouchdb/
-----
A standalone REST interface server for PouchDB.
https://github.com/pouchdb/pouchdb-server
-----Couchbase Lite
Couchbase Sync Gateway
http://www.couchbase.com/mobile#sync-gateway
Install on premise
http://www.couchbase.com/download#cb-mobile
Install on Amazon Web Services
https://aws.amazon.com/marketplace/seller-profile/ref=dtl_pcp_sold_by?ie=UTF8&id=1a064a14-5ac2-4980-9167-15746aabde72
Couchbase vs. Apache CouchDB :: A comparison of two open source NoSQL database technologies
http://www.couchbase.com/couchbase-vs-couchdb
Couchbase Server for ubuntu free download V2.5.1 Released March 31, 2014
http://www.couchbase.com/couchbase-server/overview
如果是自建,還真的這個比較適當。
中文相關 http://hhtucode.blogspot.com/search/label/Couchbase
**********
Build always-available apps that work both online & offline.
http://developer.couchbase.com/mobile/
1. Couchbase Server:JSON database 放資料(db)server
2. Sync Gateway:synchronize on-device Couchbase Lite - Couchbase Sever,and Authentication, Access Control, Validation
3. Couchbase lite: on-device JSON database, full function (sync), all platom
Downloads for both community and enterprise editions are free. Support and updates are different between them, and not necessarily free.
所以是全部免費,除了支援...要付錢,那基本上採用這架構是沒問題的了!!
*********
-----
***couchbase-sync-gateway 深入簡報
http://www.slideshare.net/Couchbase/webinar-couchbase-mobile-sync-gateway-configuration-and-management-webinar-mobile-advanced-couchbase-sync-gateway1
記得裝完後,用config檔啟動,補上這個設定:
"adminInterface":":4985",
然後在 http://xxx.xxx.xx/_admin/ 可以簡單的做db管理........官方沒這個,好佳在有人摸出來...
-----
Setting up couchbase-sync-gateway (1.0.2-9) ...
You have successfully installed Couchbase Sync Gateway.
You can start Couchbase Sync Gateway by using the following command:
/opt/couchbase-sync-gateway/bin/sync_gateway
That's it! This command starts Sync Gateway on port 4984, connects to a limited in-memory database
that lives on Sync Gateway called "walrus", and starts the admin server on port 4985.
The command-line options are:
-adminInterface=":4985": Address to bind admin interface to
-bucket="sync_gateway": Name of bucket
-dbname="": Name of CouchDB database (defaults to name of bucket)
-interface=":4984": Address to bind to
-log="": Log keywords, comma separated
-personaOrigin="": Base URL that clients use to connect to the server
-pool="default": Name of pool
-pretty=false: Pretty-print JSON responses
-url="walrus:": Address of Couchbase server
-verbose=false: Log more info about requests
By using this software you agree to the End User License Agreement.
See /opt/couchbase-sync-gateway/LICENSE.txt.
http://fitc.ca/presentation/mobile-offline-data-synchronization-in-angularjs/
watch ppt firest,
http://www.youtube.com/watch?v=6ecuA-pOev0&feature=youtu.be&t=14m9s
then see this youtube, begin time:14:45 start demo
v6 time:29:17 CouchDB online synchronization to CouchDB
time: 31:26 have ios emu
-----
Sync multiple AngularJS apps without server via PouchDB
http://www.mircozeiss.com/sync-multiple-angularjs-apps-without-server-via-pouchdb/
http://www.youtube.com/watch?v=QSC1fnfUlU0
this easy simple to try sync
-----
Building offline applications with AngularJS and PouchDB 13 Jun 2013
http://www.mircozeiss.com/building-offline-applications-with-angularjs-and-pouchdb/
-----
A standalone REST interface server for PouchDB.
https://github.com/pouchdb/pouchdb-server
-----Couchbase Lite
Couchbase Sync Gateway
http://www.couchbase.com/mobile#sync-gateway
Install on premise
http://www.couchbase.com/download#cb-mobile
Install on Amazon Web Services
https://aws.amazon.com/marketplace/seller-profile/ref=dtl_pcp_sold_by?ie=UTF8&id=1a064a14-5ac2-4980-9167-15746aabde72
Couchbase vs. Apache CouchDB :: A comparison of two open source NoSQL database technologies
http://www.couchbase.com/couchbase-vs-couchdb
Couchbase Server for ubuntu free download V2.5.1 Released March 31, 2014
http://www.couchbase.com/couchbase-server/overview
如果是自建,還真的這個比較適當。
中文相關 http://hhtucode.blogspot.com/search/label/Couchbase
**********
Build always-available apps that work both online & offline.
http://developer.couchbase.com/mobile/
1. Couchbase Server:JSON database 放資料(db)server
2. Sync Gateway:synchronize on-device Couchbase Lite - Couchbase Sever,and Authentication, Access Control, Validation
3. Couchbase lite: on-device JSON database, full function (sync), all platom
Downloads for both community and enterprise editions are free. Support and updates are different between them, and not necessarily free.
所以是全部免費,除了支援...要付錢,那基本上採用這架構是沒問題的了!!
*********
-----
***couchbase-sync-gateway 深入簡報
http://www.slideshare.net/Couchbase/webinar-couchbase-mobile-sync-gateway-configuration-and-management-webinar-mobile-advanced-couchbase-sync-gateway1
記得裝完後,用config檔啟動,補上這個設定:
"adminInterface":":4985",
-----
Setting up couchbase-sync-gateway (1.0.2-9) ...
You have successfully installed Couchbase Sync Gateway.
You can start Couchbase Sync Gateway by using the following command:
/opt/couchbase-sync-gateway/bin/sync_gateway
That's it! This command starts Sync Gateway on port 4984, connects to a limited in-memory database
that lives on Sync Gateway called "walrus", and starts the admin server on port 4985.
The command-line options are:
-adminInterface=":4985": Address to bind admin interface to
-bucket="sync_gateway": Name of bucket
-dbname="": Name of CouchDB database (defaults to name of bucket)
-interface=":4984": Address to bind to
-log="": Log keywords, comma separated
-personaOrigin="": Base URL that clients use to connect to the server
-pool="default": Name of pool
-pretty=false: Pretty-print JSON responses
-url="walrus:": Address of Couchbase server
-verbose=false: Log more info about requests
By using this software you agree to the End User License Agreement.
See /opt/couchbase-sync-gateway/LICENSE.txt.
delphi xe6 andorid ios
Android使用分享
http://delphi.ktop.com.tw/board.php?cid=30&fid=1501&tid=105719
delphi XE5/XE6 小型成品展示,小型的 CRM
http://delphi.ktop.com.tw/board.php?cid=31&fid=79&tid=106351
http://jamesjuantw.pixnet.net/blog/post/185758317
http://delphi.ktop.com.tw/board.php?cid=30&fid=1501&tid=105719
delphi XE5/XE6 小型成品展示,小型的 CRM
http://delphi.ktop.com.tw/board.php?cid=31&fid=79&tid=106351
http://jamesjuantw.pixnet.net/blog/post/185758317
使用activerecord注意
** tableize
rails console下,執行"Post".tableize 得到posts,table名稱
----------------------
sinatra 在tux下執行
** singularize 複數變單數
執行上方式同上
** pluralize 單數變複數
執行上方式同上
http://api.rubyonrails.org/classes/ActiveSupport/Inflector.html
rails console下,執行"Post".tableize 得到posts,table名稱
----------------------
sinatra 在tux下執行
** singularize 複數變單數
執行上方式同上
** pluralize 單數變複數
執行上方式同上
http://api.rubyonrails.org/classes/ActiveSupport/Inflector.html
ruby on sinatra 正式開發上線 發現問題
基本上,很多人用 rank db:migrate, 看日本的範例是直接開mysql資料庫,那時候不懂,他的做法出乎意外,因為大部份的範例不是這樣,現在才知道為什麼。
rank db:create_migration NAME=xxx 建立後,再改xxx.rb檔,設完後,rank db:migrate就產生大問題了!
在開發環境,用sqlite3, 是的,可以用,但到正式mysql資料庫,能用,但編碼是litaxxxx ....不是UTF8;那在xxx.rb 文件內強制設定option
create_table :tops, options: 'DEFAULT CHARSET=utf8'
當然就不發生錯誤,但回到sqllite3就錯了!因為sqlite3沒支援這語法......那這樣怎麼處理? 寫程式,因為xxx.rb,是ruby語法。
但這樣有比較快嗎?
還是直接把 cretae table schema和insert sql直接另外做文件,進mysql和sqlite3執行sql比較快....
mysql 當然更快是直接把table名稱改掉,新增 新的table;
sqlite3 直接copy一個新的sqlite3,進去刪掉table更快...
也許是我不了解rank db,但目前的了解就是這樣子....
另外有試著把mysql的db,需設成utf8,但租的主機有時候是不能亂改的.....哈,無解
rank db:create_migration NAME=xxx 建立後,再改xxx.rb檔,設完後,rank db:migrate就產生大問題了!
在開發環境,用sqlite3, 是的,可以用,但到正式mysql資料庫,能用,但編碼是litaxxxx ....不是UTF8;那在xxx.rb 文件內強制設定option
create_table :tops, options: 'DEFAULT CHARSET=utf8'
當然就不發生錯誤,但回到sqllite3就錯了!因為sqlite3沒支援這語法......那這樣怎麼處理? 寫程式,因為xxx.rb,是ruby語法。
但這樣有比較快嗎?
還是直接把 cretae table schema和insert sql直接另外做文件,進mysql和sqlite3執行sql比較快....
mysql 當然更快是直接把table名稱改掉,新增 新的table;
sqlite3 直接copy一個新的sqlite3,進去刪掉table更快...
也許是我不了解rank db,但目前的了解就是這樣子....
另外有試著把mysql的db,需設成utf8,但租的主機有時候是不能亂改的.....哈,無解
[轉]database.yml &, <<, *
http://stackoverflow.com/questions/6651275/what-do-the-mean-in-this-database-yml-file
The & marks an alias for the node (in your example &defaultaliases the development node as "default")
* references the aliased node with the name "default".
<<: inserts the content of that node.
test: &test <<: *default
default_env:
<<: *production
The & marks an alias for the node (in your example &defaultaliases the development node as "default")
default_env:
<<: *production
sinatra mobile app cordova -- just for note
https://gauntface.com/blog/2014/02/05/cordova-web-best-practices-v2-0
http://spiritmachineblog.tumblr.com/post/41432461669/a-simple-openlayers-app-with-yeoman-sinatra-mongodb
HTML5 Boilerplate
Sass with Compass
Modernizr
http://thibaultdenizet.com/tutorial/cors-with-angular-js-and-sinatra/
=====
簡單說:發現現在要走moble app,要有yoeman的產生的網頁檔,或是 走Angular.js, jquerymobile, bootstrap三個來做。
新增、修改、刪除 走Restful,看上面範例。這樣產出來的網頁能適用 手機和平板。
但要把 程式轉成可以用cordova,要用Compass之類的,把所有的js, css, html5 三個檔。
http://vimeo.com/35998909
https://www.youtube.com/watch?v=e4yUTkva_FM
https://www.youtube.com/watch?v=wVntVkRLR3M
bit.ly/zen-ng-phonegap
Angular UI部份
這看起來有點像官方Angular原生
http://angular-ui.github.io/bootstrap/
這是另一個整合好Bootstrap and Angular JS
http://mobileangularui.com/
這是angular+ionic
http://ionicframework.com/
http://ionicframework.com/docs/overview/#download
http://ionicframework.com/docs/components/
==================
**SASS (Sass)
**require jquery.mobile 21:13
http://demos.jquerymobile.com/1.2.0/
http://demos.jquerymobile.com/1.2.0/docs/pages/page-anatomy.html
css style => data-role
http://mobileangularui.com/demo/#/
http://ionicframework.com/
============
https://www.youtube.com/watch?v=sCnGSOaaZFo
http://jaydata.org/blog/angularjs-with-jaydata%E2%80%93-the-todo-example-with-the-itemstore-api
http://jaydata.org/
=======
Three-way data-binding sync 同步
--
http://fitc.ca/presentation/4-way-data-binding-offline-data-synchronization-in-angularjs/
http://fitc.ca/presentation/mobile-offline-data-synchronization-in-angularjs/
--
CouchDB comes with a suite of features, such as on-the-fly document transformation and real-time change notifications, that makes web app development a breeze. It even comes with an easy to use web administration console. You guessed it, served up directly out of CouchDB!
--
The Database that Syncs!
PouchDB is an open-source JavaScript database inspired by Apache CouchDB that is designed to run well within the browser.
===============
http://deployd.com/
http://remotestorage.io/ https://unhosted.org/
--https://togetherjs.com/
--http://socket.io/
--http://pusher.com/
--https://parse.com/plans ,but free good
$$ https://backendless.com/
$$ http://www.kinvey.com/pricing
Examples of open source backend systems are usergrid_, BaasBox, DreamFactory, deployd,Meteor, sockethub, and Hoodie.
Examples which have not yet shut down are Kinvey, Apigee,Backendless, Kii, built.io, Firebase, Encore.io, AppearIQ, AnyPresence,FeedHenry, Syncano, Apstrata, FanIgnite, CloudMine, iKnode, FatFractal,Kumulos, Netmera, Buddy, apiOmat, Applicasa (especially for in-app purchases), AppGlu (especially for product catalogs), Flurry (especially for advertising and analytics), Facebook's Parse, Appcelerator (includingsingly), Amazon's AWS Mobile Services (including Cognito, analytics, storage, and push notifications), and Apple's CloudKit.
http://spiritmachineblog.tumblr.com/post/41432461669/a-simple-openlayers-app-with-yeoman-sinatra-mongodb
HTML5 Boilerplate
Sass with Compass
Modernizr
http://thibaultdenizet.com/tutorial/cors-with-angular-js-and-sinatra/
=====
簡單說:發現現在要走moble app,要有yoeman的產生的網頁檔,或是 走Angular.js, jquerymobile, bootstrap三個來做。
新增、修改、刪除 走Restful,看上面範例。這樣產出來的網頁能適用 手機和平板。
但要把 程式轉成可以用cordova,要用Compass之類的,把所有的js, css, html5 三個檔。
http://vimeo.com/35998909
https://www.youtube.com/watch?v=e4yUTkva_FM
https://www.youtube.com/watch?v=wVntVkRLR3M
bit.ly/zen-ng-phonegap
Angular UI部份
這看起來有點像官方Angular原生
http://angular-ui.github.io/bootstrap/
這是另一個整合好Bootstrap and Angular JS
http://mobileangularui.com/
這是angular+ionic
http://ionicframework.com/
http://ionicframework.com/docs/overview/#download
http://ionicframework.com/docs/components/
==================
**SASS (Sass)
**require jquery.mobile 21:13
http://demos.jquerymobile.com/1.2.0/
http://demos.jquerymobile.com/1.2.0/docs/pages/page-anatomy.html
css style => data-role
%meta{name: 'viewport', content: 'width=device-width, initial-scal-1')
http://demos.jquerymobile.com/1.2.0/docs/lists/lists-collapsible.html
**haml
http://html2haml.heroku.com/
**haml
http://html2haml.heroku.com/
=====
phonegap 41:01
開一個android專案,但只是把網頁load進來.....真是簡單
開一個android專案,但只是把網頁load進來.....真是簡單
www/index.html
1. script include: phonegap-1.3.0.js
2. onBodyLoad(){
document.addEventListener("dviceready", onDeviceready, false);
windows.location.href = 'http://localhost:3000'
}
http://mobileangularui.com/demo/#/
http://ionicframework.com/
============
https://www.youtube.com/watch?v=sCnGSOaaZFo
http://jaydata.org/blog/angularjs-with-jaydata%E2%80%93-the-todo-example-with-the-itemstore-api
http://jaydata.org/
=======
Three-way data-binding sync 同步
AngularJS model change and view change together
現在只有firebase,要看有沒有別的專案
簡單說,ng會定時去檢查,如果有任何動動作,就會主動去更新
model一改變,view就改變,所以model要綁定remote Restful
大概是這意思,綁定就行了
綁定後,如果model有改變,對應的view就會變
另外就正websocket, WebHooks, PubSubHubbub
$evalAsync()
Wrap code that depends on ng-init in $scope.$evalAsync(), which forces it to run on the next $digest() phase:
簡單說,ng會定時去檢查,如果有任何動動作,就會主動去更新
model一改變,view就改變,所以model要綁定remote Restful
大概是這意思,綁定就行了
綁定後,如果model有改變,對應的view就會變
另外就正websocket, WebHooks, PubSubHubbub
http://www.troikatech.com/blog/2014/02/26/websocket-webmachine/
https://github.com/simulacre/sinatra-websocket
http://xh-css.cn/2013/11/watch-how-the-apply-runs-a-digest/https://github.com/simulacre/sinatra-websocket
$evalAsync()
Wrap code that depends on ng-init in $scope.$evalAsync(), which forces it to run on the next $digest() phase:
--
http://fitc.ca/presentation/4-way-data-binding-offline-data-synchronization-in-angularjs/
http://fitc.ca/presentation/mobile-offline-data-synchronization-in-angularjs/
--
CouchDB comes with a suite of features, such as on-the-fly document transformation and real-time change notifications, that makes web app development a breeze. It even comes with an easy to use web administration console. You guessed it, served up directly out of CouchDB!
--
The Database that Syncs!
PouchDB is an open-source JavaScript database inspired by Apache CouchDB that is designed to run well within the browser.
===============
http://deployd.com/
http://remotestorage.io/ https://unhosted.org/
--https://togetherjs.com/
--http://socket.io/
--http://pusher.com/
--https://parse.com/plans ,but free good
$$ https://backendless.com/
$$ http://www.kinvey.com/pricing
Examples of open source backend systems are usergrid_, BaasBox, DreamFactory, deployd,Meteor, sockethub, and Hoodie.
Examples which have not yet shut down are Kinvey, Apigee,Backendless, Kii, built.io, Firebase, Encore.io, AppearIQ, AnyPresence,FeedHenry, Syncano, Apstrata, FanIgnite, CloudMine, iKnode, FatFractal,Kumulos, Netmera, Buddy, apiOmat, Applicasa (especially for in-app purchases), AppGlu (especially for product catalogs), Flurry (especially for advertising and analytics), Facebook's Parse, Appcelerator (includingsingly), Amazon's AWS Mobile Services (including Cognito, analytics, storage, and push notifications), and Apple's CloudKit.
訂閱:
文章 (Atom)
