Fork me on GitHub
上一页 1 ··· 11 12 13 14 15 16 17 18 19 ··· 125 下一页

2013年4月11日

摘要: public void Init() { FDJson(); } void FDJson() { using(WWW _load = new WWW("file://"+ FileFunc.GetStreamPath("FontP... 阅读全文
posted @ 2013-04-11 15:02 pengyingh 阅读(354) 评论(0) 推荐(0)

2013年3月23日

摘要: public 变量 一经修改会保存值,相当于static 变量,在editor 模式下每次run之后变量会记住editor下设置的值private 每次run 变量都会初始化,如果是float类型,默认初始值为0 阅读全文
posted @ 2013-03-23 17:34 pengyingh 阅读(899) 评论(0) 推荐(0)

2012年10月11日

摘要: 点击按钮触发面板弹出动画:void MainPanelBtnClick(string btnName) { switch (btnName) { case "0": if(currentBtn != MainPanelBtn.BE... 阅读全文
posted @ 2012-10-11 22:29 pengyingh 阅读(571) 评论(0) 推荐(1)

2012年6月26日

摘要: apple 提供了详细的代码文档为iphone推送通知服务做示范,但提示不是很具体;倒是如何实现和处理alert在设备app上讲述比较详细. 作为service,需要和apple的服务器交互,device只要维护和apns的一个连接,节省电池前提条件:使用SSL证书,这个就涉及不同的服务器不同的配置了,例如windows/linux的SSL连接socket的如何实现?逻辑条件判断需要发送的消息,简单一点就是每10min发送一条组合每条message的payload/ 按照一定的格式,其实格式也不是很多种断开与apns的链接Device token定位符号,APNS首先为每一个程序分配了一tok 阅读全文
posted @ 2012-06-26 11:50 pengyingh 阅读(409) 评论(0) 推荐(0)
摘要: sample_push.php<?php/** * @file * sample_push.php * * Push demo * * LICENSE * * This source file is subject to the new BSD license that is bundled * with this package in the file LICENSE.txt. * It is also available through the world-wide-web at this URL: * http://code.google.com/p/apns-php/wiki/L 阅读全文
posted @ 2012-06-26 11:45 pengyingh 阅读(2341) 评论(0) 推荐(0)
摘要: http://blog.csdn.net/gnicky/article/details/75442021. URL是不一样的,端口是21962. 使用同样的Certificate,建立安全连接,接受数据,直到数据不存在,类似table select操作3.每条纪录是一个token,server然后要删除这些device token纪录Access to the feedback service takes place through a binary interface similar to that used for sending push notifications. You acces 阅读全文
posted @ 2012-06-26 10:33 pengyingh 阅读(708) 评论(0) 推荐(0)

2012年6月25日

摘要: <span><span><?php class Crypt{ protected $key = ""; //公钥 private function keyED($txt,$encrypt_key) { $encrypt_key = md5($encrypt_key); $ctr=0; $tmp = ""; for ($i=0;$i<strlen($txt);$i++) { if ($ctr==strlen($encrypt_key)){ $ctr=0; } $tmp.= substr($txt,$i,1) ^ subs 阅读全文
posted @ 2012-06-25 19:17 pengyingh 阅读(993) 评论(0) 推荐(0)
摘要: 假如你也是一个java程序员,而你又不是很懂Socket。下面我的这篇文章也许能帮助你一些。http://xiva.iteye.com/blog/993336首先我们写好上面文章中的server端。下面我们可以访问一下下面的地址:http://code.google.com/p/cocoaasyncsocket/这是一个开源框架。呵,不知道拿到自己程序中使用是否涉及侵权。但是这句话“The CocoaAsyncSocket project is in the public domain.”是我有信心使用它们的源码,否则只能自己用c来写了,或者使用CFSocket、CFNetwork等类自己来写 阅读全文
posted @ 2012-06-25 14:12 pengyingh 阅读(277) 评论(0) 推荐(0)
摘要: openssl可以直接使用命令对文件件进行base64的编码与解码,利用openssl提供的API同样可以做到这一点。废话不多说,直接上代码了。需要注意的是通过base64编码后的字符每64个字节都会有一个换行符的存在。static int base64_encode(char *str,int str_len,char *encode,int encode_len){ BIO *bmem,*b64; BUF_MEM *bptr; b64=BIO_new(BIO_f_base64()); bmem=BIO_new(BIO_s_mem()); b64=BI... 阅读全文
posted @ 2012-06-25 13:19 pengyingh 阅读(1269) 评论(0) 推荐(0)
摘要: http://www.cnblogs.com/aLittleBitCool/archive/2011/09/22/2185418.htmlopenssl是一个功能强大的工具包,它集成了众多密码算法及实用工具。我们即可以利用它提供的命令台工具生成密钥、证书来加密解密文件,也可以在利用其提供的API接口在代码中对传输信息进行加密。RSA是一个非对称加密算法。简单说来,非对称加密算法就是说加密解密一个文件需要有两个密钥,一个用来加密,为公钥,一个用来解密,为私钥。证书可以用来授权公钥的使用。今天小研究了下openssl的rsa加密,其中主要涉及利用公钥和密钥加解密文件,没有涉及对证书的操作。想要集体 阅读全文
posted @ 2012-06-25 13:17 pengyingh 阅读(678) 评论(0) 推荐(0)
上一页 1 ··· 11 12 13 14 15 16 17 18 19 ··· 125 下一页

导航