摘要: 1. 服务器端返回json时,日期对象经常是/Date(1304902921487)/ 这种格式。使用如下代码转换成js正常的Date对象。value = new Date(parseInt(value.replace("/Date(", "").replace(")/",""), 10));2. 另一种方式是使用Epoch格式时间,即1970年1月1日到目前的毫秒数。这种处理方式可以进行更好的转换。 阅读全文
posted @ 2011-05-09 17:44 chenjunbiao 阅读(199) 评论(0) 推荐(0) 编辑
摘要: 参考文章:http://blog.codingmylife.com/?p=85#import <Foundation/Foundation.h>int main (int argc, const char * argv[]){ NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init]; NSString *path = @"/Users/billchen/Desktop/f1.rtf"; NSString *temp = @"Hello Friend"; int i = 100; 阅读全文
posted @ 2011-05-09 13:14 chenjunbiao 阅读(2667) 评论(0) 推荐(0) 编辑