iOS一些常用的判断

1、文字中是否包含表情

+ (BOOL)stringContainsEmoji:(NSString *)string {
    __block BOOL returnValue = NO;
    [string enumerateSubstringsInRange:NSMakeRange(0, [string length]) options:NSStringEnumerationByComposedCharacterSequences usingBlock:
     ^(NSString *substring, NSRange substringRange, NSRange enclosingRange, BOOL *stop) {
         const unichar hs = [substring characterAtIndex:0];
         if (0xd800 <= hs && hs <= 0xdbff) {
             if (substring.length > 1) {
                 const unichar ls = [substring characterAtIndex:1];
                 const int uc = ((hs - 0xd800) * 0x400) + (ls - 0xdc00) + 0x10000;
                 if (0x1d000 <= uc && uc <= 0x1f77f) {
                     returnValue = YES;
                 }else{
                     returnValue = NO;
                 }
             }
         } else if (substring.length > 1) {
             const unichar ls = [substring characterAtIndex:1];
             if (ls == 0x20e3) {
                 returnValue = YES;
             }else{
                 returnValue = NO;
             }
             
         } else {
             // non surrogate
             if (0x2100 <= hs && hs <= 0x27ff) {
                 returnValue = YES;
             } else if (0x2B05 <= hs && hs <= 0x2b07) {
                 returnValue = YES;
             } else if (0x2934 <= hs && hs <= 0x2935) {
                 returnValue = YES;
             } else if (0x3297 <= hs && hs <= 0x3299) {
                 returnValue = YES;
             } else if (hs == 0xa9 || hs == 0xae || hs == 0x303d || hs == 0x3030 || hs == 0x2b55 || hs == 0x2b1c || hs == 0x2b1b || hs == 0x2b50) {
                 returnValue = YES;
             }else{
                 returnValue = NO;
             }
         }
     }];
    return returnValue;
}

2、邮箱

+ (BOOL) validateEmail:(NSString *)email
{
    NSString *emailRegex = @"[A-Z0-9a-z._%+-]+@[A-Za-z0-9.-]+\\.[A-Za-z]{2,4}";
    NSPredicate *emailTest = [NSPredicate predicateWithFormat:@"SELF MATCHES %@", emailRegex];
    return [emailTest evaluateWithObject:email];
}

3、身份证号

+ (BOOL)validateIdentityCard: (NSString *)identityCard
{
    BOOL flag;
    if (identityCard.length <= 0) {
        flag = NO;
        return flag;
    }
    NSString *regex2 = @"^[1-9]\\d{7}((0\\d)|(1[0-2]))(([0|1|2]\\d)|3[0-1])\\d{3}$";
    NSString *regex3 = @"^[1-9]\\d{5}[1-9]\\d{3}((0\\d)|(1[0-2]))(([0|1|2]\\d)|3[0-1])\\d{3}([0-9]|X)$";
    NSPredicate *identityCardPredicate = [NSPredicate predicateWithFormat:@"SELF MATCHES %@",regex2];
    NSPredicate *identityCardPredicate2 = [NSPredicate predicateWithFormat:@"SELF MATCHES %@",regex3];
    if ([identityCardPredicate evaluateWithObject:identityCard]==YES ||[identityCardPredicate2 evaluateWithObject:identityCard]==YES) {
        return YES;
    }else{
        return NO;
    }
    
}

4、中文名称

+ (BOOL)isChineseName:(NSString *)name{
    BOOL isname = false;
    for (int i=0; i<name.length; i++) {
        NSRange range=NSMakeRange(i,1);
        NSString *subString=[name substringWithRange:range];
        const char *cString=[subString UTF8String];
        if (strlen(cString)==3)
        {
            isname = YES;
        }else{
            isname = NO;
            break;
        }
    }
    return isname;
}

5、将视图添加在全屏

+ (void)addWindow:(UIView *)view {
    
    UIWindow *window = [UIApplication sharedApplication].keyWindow;

    [window addSubview:view];
}

6、将当前时间转换为时间戳

+ (NSString *)timeToTurnTheTimestamp {
    
    NSDate* dat = [NSDate dateWithTimeIntervalSinceNow:0];
    NSTimeInterval a=[dat timeIntervalSince1970];
    
    return [NSString stringWithFormat:@"%0.f", a];
}

7、将某个时间转换为时间戳

+ (NSString *)timeToTurnTheTimestamp:(NSString *) time{
      NSDateFormatter *dateFormatter = [[NSDateFormatter alloc] init];
      [dateFormatter setDateFormat:@"yyyy-MM-dd HH:mm:ss"];
      NSDate * needFormatDate = [dateFormatter dateFromString:time];
      NSTimeInterval a=[needFormatDate timeIntervalSince1970];
      return [NSString stringWithFormat:@"%0.f", a];
}

8、获取设备的ip地址

+ (NSString *)deviceIPAdress {
    
    NSString *address = @"an error occurred when obtaining ip address";
    struct ifaddrs *interfaces = NULL;
    struct ifaddrs *temp_addr = NULL;
    int success = 0;
    success = getifaddrs(&interfaces);
    if (success == 0) { // 0 表示获取成功
        temp_addr = interfaces;
        while (temp_addr != NULL) {
            if( temp_addr->ifa_addr->sa_family == AF_INET) {
                // Check if interface is en0 which is the wifi connection on the iPhone
                if ([[NSString stringWithUTF8String:temp_addr->ifa_name] isEqualToString:@"en0"]) {
                    // Get NSString from C String
                    address = [NSString stringWithUTF8String:inet_ntoa(((struct sockaddr_in *)temp_addr->ifa_addr)->sin_addr)];
                }
            }
            temp_addr = temp_addr->ifa_next;
        }
    }
    freeifaddrs(interfaces);
    return address;
}

9、判断手机号

+(BOOL)isPhoneNumber:(NSString *)mobileNum{
    
    if ([mobileNum length] == 0) {
        return NO;
    }  
    mobileNum = [mobileNum stringByReplacingOccurrencesOfString:@" " withString:@""];
    if (mobileNum.length != 11)
    {
        return NO;
    }else{
        /**
         * 移动号段正则表达式
         */
        NSString *CM_NUM = @"^((13[4-9])|(147)|(15[0-2,7-9])|(17[0,1,3,6,7,8])|(18[2-4,7-8]))\\d{8}|(1705)\\d{7}$";
        /**
         * 联通号段正则表达式
         */
        NSString *CU_NUM = @"^((13[0-2])|(145)|(15[5-6])|(17[0,1,3,5,6,7,8])|(18[5,6]))\\d{8}|(1709)\\d{7}$";
        /**
         * 电信号段正则表达式
         */
        NSString *CT_NUM = @"^((133)|(153)|(17[0,1,3,6,7,8])|(18[0,1,9]))\\d{8}$";
        NSPredicate *pred1 = [NSPredicate predicateWithFormat:@"SELF MATCHES %@", CM_NUM];
        BOOL isMatch1 = [pred1 evaluateWithObject:mobileNum];
        NSPredicate *pred2 = [NSPredicate predicateWithFormat:@"SELF MATCHES %@", CU_NUM];
        BOOL isMatch2 = [pred2 evaluateWithObject:mobileNum];
        NSPredicate *pred3 = [NSPredicate predicateWithFormat:@"SELF MATCHES %@", CT_NUM];
        BOOL isMatch3 = [pred3 evaluateWithObject:mobileNum];
        
        if (isMatch1 || isMatch2 || isMatch3) {
            return YES;
        }else{
            return NO;
        }
    }
}

10、计算字符串Size

+ (CGSize)boundingRectWithSize:(CGSize)size
                    withString:(NSString *)string
                      withFont:(UIFont *)font {
    
    return [string boundingRectWithSize:size options: NSStringDrawingTruncatesLastVisibleLine |
                   NSStringDrawingUsesLineFragmentOrigin |
                   NSStringDrawingUsesFontLeading  attributes:@{NSFontAttributeName:font} context:nil].size;
}

11、判断是否是同一天

+ (BOOL)isSameDay:(NSDate *)date1 date2:(NSDate *)date2
{
    NSCalendar *calendar = [NSCalendar currentCalendar];
    unsigned unitFlag = NSCalendarUnitYear | NSCalendarUnitMonth | NSCalendarUnitDay;
    NSDateComponents *comp1 = [calendar components:unitFlag fromDate:date1];
    NSDateComponents *comp2 = [calendar components:unitFlag fromDate:date2];
    return ( ([comp1 day] == [comp2 day]) && ([comp1 month] == [comp2 month]) && ([comp1 year] == [comp2 year]));
}

12、时间比较大小

+ (int)compareOneDay:(NSDate *)oneDay withAnotherDay:(NSDate *)anotherDay
{
    NSDateFormatter *dateFormatter = [[NSDateFormatter alloc] init];
    [dateFormatter setDateFormat:@"yyyy-MM-dd HH:mm"];
    NSString *oneDayStr = [dateFormatter stringFromDate:oneDay];
    NSString *anotherDayStr = [dateFormatter stringFromDate:anotherDay];
    NSDate *dateA = [dateFormatter dateFromString:oneDayStr];
    NSDate *dateB = [dateFormatter dateFromString:anotherDayStr];
    NSComparisonResult result = [dateA compare:dateB];
    DLog(@"oneDay : %@, anotherDay : %@", oneDay, anotherDay);
    if (result == NSOrderedDescending) {
        //oneDay > anotherDay
        return 1;
    }
    else if (result == NSOrderedAscending){
        //oneDay < anotherDay
        return -1;
    }
    //oneDay = anotherDay
    return 0;
}

13、是不是整数

+ (BOOL)isPureInt:(NSString*)string{
    NSScanner* scan = [NSScanner scannerWithString:string];
    int val;
    return[scan scanInt:&val] && [scan isAtEnd];
}

14、是不是浮点型

+ (BOOL)isPureFloat:(NSString*)string{
    NSScanner* scan = [NSScanner scannerWithString:string];
    float val;
    return[scan scanFloat:&val] && [scan isAtEnd];
}

15、是不是数字

+ (BOOL)isPureIntOrisPureFloat:(NSString *)numberStr{
    if( ![self isPureInt:numberStr] && ![self isPureFloat:numberStr])
    {
        return NO;
    }else{
        return YES;
    }
}

16、是不是周末

+ (BOOL)iscalculateWeek:(NSString *)string{
    NSDateFormatter *date = [[NSDateFormatter alloc]init];
    [date setDateFormat:@"yyyy.MM.dd"];
    NSDate *startD =[date dateFromString:string];
    NSString *str = [self calculateWeek:startD];
    if ([str isEqualToString:@"周日"] || [str isEqualToString:@"周六"] ) {
        return YES;
    }else{
        return NO;
    }
}

17、某一天是周几

+ (NSString *)calculateWeek:(NSDate *)date{
    //计算week数
    NSCalendar * myCalendar = [NSCalendar currentCalendar];
    myCalendar.timeZone = [NSTimeZone systemTimeZone];
    NSInteger week = [[myCalendar components:NSCalendarUnitWeekday fromDate:date] weekday];
//    NSLog(@"week : %zd",week);
    switch (week) {
        case 1:
        {
            return @"周日";
        }
        case 2:
        {
            return @"周一";
        }
        case 3:
        {
            return @"周二";
        }
        case 4:
        {
            return @"周三";
        }
        case 5:
        {
            return @"周四";
        }
        case 6:
        {
            return @"周五";
        }
        case 7:
        {
            return @"周六";
        }
    }
    
    return @"";
}

18、两个时间段相差时分秒

+ (NSString *)dateTimeDifferenceWithStartTime2:(NSString *)startTime endTime:(NSString *)endTime{
    NSDateFormatter *date = [[NSDateFormatter alloc]init];
    [date setDateFormat:@"yyyy-MM-dd HH:mm:ss"];
    NSDate *startD =[date dateFromString:startTime];
    NSDate *endD = [date dateFromString:endTime];
    NSTimeInterval start = [startD timeIntervalSince1970]*1;
    NSTimeInterval end = [endD timeIntervalSince1970]*1;
    NSTimeInterval value = end - start;
    int second = (int)value %60;//秒
    int minute = (int)value /60%60;
    int house = (int)value / (24 * 3600)%3600;
    int day = (int)value / (24 * 3600);
    NSString *str = @"";
    if (day != 0) {
        str = [NSString stringWithFormat:@"%d天%d小时%d分%d秒",day,house,minute,second];
    }else if (day==0 && house != 0) {
        str = [NSString stringWithFormat:@"%d小时%d分%d秒",house,minute,second];
    }else if (day== 0 && house== 0 && minute!=0) {
     
       str = [NSString stringWithFormat:@"%d分%d秒",minute,second];
    }else{
        str = [NSString stringWithFormat:@"%d秒",second];
    }
    return str;
}

19、计算多少秒为几天几时几分

+ (NSString *)timeFormatted:(int)totalSeconds
{
    
    int seconds = totalSeconds % 60;
    int minutes = (totalSeconds / 60) % 60;
    int hours = totalSeconds / 3600;
    int day = totalSeconds / (24 * 3600);
    
    NSString *str = @"";
    if (day != 0) {
        str = [NSString stringWithFormat:@"%d天%d小时%d分%d秒",day,hours,minutes,seconds];
    }else if (day==0 && hours != 0) {
        str = [NSString stringWithFormat:@"%d小时%d分%d秒",hours,minutes,seconds];
    }else if (day== 0 && hours== 0 && minutes!=0) {
        
        str = [NSString stringWithFormat:@"%d分%d秒",minutes,seconds];
    }else{
        str = [NSString stringWithFormat:@"%d秒",seconds];
    }
    return str;

}

+ (NSString *)timeFormattedSingle:(int)totalSeconds{

    int seconds = totalSeconds % 60;
    int minutes = (totalSeconds / 60) % 60;
    int hours = totalSeconds / 3600;
    int day = totalSeconds / (24 * 3600);
    
    NSString *str = @"";
    if (day != 0) {
        str = [NSString stringWithFormat:@"%d天 %d:%d:%d",day,hours,minutes,seconds];
    }else if (day==0 && hours != 0) {
        str = [NSString stringWithFormat:@"%d:%d:%d",hours,minutes,seconds];
    }else if (day== 0 && hours== 0 && minutes!=0) {
        
        str = [NSString stringWithFormat:@"%d:%d",minutes,seconds];
    }else{
        str = [NSString stringWithFormat:@"%d",seconds];
    }
    return str;

}

19、属性字符串

1、同字体不同色
+ (NSMutableAttributedString *) compareString:(NSString *)firstStr andLast:(NSString *)nextStr withFont:(UIFont *)font withFirstColor:(UIColor *)firstColor withLastColor:(UIColor *)lastcolor{

    NSMutableAttributedString * firstPart = [[NSMutableAttributedString alloc] initWithString:firstStr];
    NSDictionary * firstAttributes = @{ NSFontAttributeName:font,NSForegroundColorAttributeName:firstColor,};
    [firstPart setAttributes:firstAttributes range:NSMakeRange(0,firstPart.length)];
    NSMutableAttributedString * secondPart = [[NSMutableAttributedString alloc] initWithString:nextStr];
    NSDictionary * secondAttributes = @{NSFontAttributeName:font,NSForegroundColorAttributeName:lastcolor,};
    [secondPart setAttributes:secondAttributes range:NSMakeRange(0,secondPart.length)];
    [firstPart appendAttributedString:secondPart];
    return  firstPart;
}
2、同色不同字体
+ (NSMutableAttributedString *) compareString:(NSString *)firstStr andLast:(NSString *)nextStr withColor:(UIColor *)color withFirstFont:(UIFont *)firstFont withLastFont:(UIFont *)lastFont{

    NSMutableAttributedString * firstPart = [[NSMutableAttributedString alloc] initWithString:firstStr];
    NSDictionary * firstAttributes = @{ NSFontAttributeName:firstFont,NSForegroundColorAttributeName:color,};
    [firstPart setAttributes:firstAttributes range:NSMakeRange(0,firstPart.length)];
    NSMutableAttributedString * secondPart = [[NSMutableAttributedString alloc] initWithString:nextStr];
    NSDictionary * secondAttributes = @{NSFontAttributeName:lastFont,NSForegroundColorAttributeName:color,};
    [secondPart setAttributes:secondAttributes range:NSMakeRange(0,secondPart.length)];
    [firstPart appendAttributedString:secondPart];
    return  firstPart;
}
3、不同色不同字体
+ (NSMutableAttributedString *) compareString:(NSString *)firstStr andLast:(NSString *)nextStr withFirstFont:(UIFont *)firstfont withLastFont:(UIFont *)lastfont withFirstColor:(UIColor *)firstColor withLastColor:(UIColor *)lastcolor{
    
    NSMutableAttributedString * firstPart = [[NSMutableAttributedString alloc] initWithString:firstStr];
    NSDictionary * firstAttributes = @{ NSFontAttributeName:firstfont,NSForegroundColorAttributeName:firstColor,};
    [firstPart setAttributes:firstAttributes range:NSMakeRange(0,firstPart.length)];
    
    NSMutableAttributedString * secondPart = [[NSMutableAttributedString alloc] initWithString:nextStr];
    NSDictionary * secondAttributes = @{NSFontAttributeName:lastfont,NSForegroundColorAttributeName:lastcolor,};
    [secondPart setAttributes:secondAttributes range:NSMakeRange(0,secondPart.length)];
    
    [firstPart appendAttributedString:secondPart];
    return  firstPart;
}

20、两个时间段之间的月份

- (NSMutableArray *)createArraywithStart:(NSString *)startString withEnd:(NSString *)endString
{
    NSMutableArray * resultArray=[NSMutableArray array];
    NSArray * startArray=[startString componentsSeparatedByString:@"-"];
    NSArray * endArray=[endString componentsSeparatedByString:@"-"];
    if ([[startArray objectAtIndex:0]isEqualToString:[endArray objectAtIndex:0]]) {
        for (int i=[[startArray objectAtIndex:1]intValue]; i<=[[endArray objectAtIndex:1]intValue]; i++) {
            NSString * yearString=[NSString stringWithFormat:@"%@-%d月",[startArray objectAtIndex:0],i];
            [resultArray addObject:yearString];
        }
    }else if([[startArray objectAtIndex:0] compare:[endArray objectAtIndex:0] options:NSNumericSearch] == NSOrderedAscending){//升
        for (int i=[[startArray objectAtIndex:1]intValue]; i<=12; i++) {
            NSString * yearString=[NSString stringWithFormat:@"%@-%d月",[startArray objectAtIndex:0],i];
            [resultArray addObject:yearString];
        }
        for (int i=[[startArray objectAtIndex:0]intValue]+1; i<=[[endArray objectAtIndex:0]intValue]-1; i++) {
            for (int j=1; j<=12; j++) {
                NSString * yearString=[NSString stringWithFormat:@"%d-%d月",i,j];
                [resultArray addObject:yearString];
            }
        }
        for (int i=1; i<=[[endArray objectAtIndex:1]intValue]; i++) {
            NSString * yearString=[NSString stringWithFormat:@"%@-%d月",[endArray objectAtIndex:0],i];
            [resultArray addObject:yearString];
        }
    }else{
        DLog(@"您的结束时间晚于开始时间");
    }
    return resultArray;
}
- (NSArray *)dateFromeTime:(NSString *)startTime ToTime:(NSString *)lastTime{
    
    NSArray *startArr = [startTime componentsSeparatedByString:@"."];
    NSArray *lastArr = [lastTime componentsSeparatedByString:@"."];

    NSMutableArray *dates = [[NSMutableArray alloc] init];
 
    NSInteger indexMonth = [startArr[1] integerValue];
    NSInteger indexYear = [startArr[0] integerValue];
    NSString *first = [NSString stringWithFormat:@"%@.%ld",startArr[0],(long)indexMonth];
    [dates addObject:first];
    while (([lastArr[0] integerValue] > indexYear) || ([lastArr[0] integerValue] == indexYear && [lastArr[1] integerValue] >= indexMonth))
    {
        indexMonth++;
        if (indexMonth > 12){ // 判断是否大于12月
            indexMonth = 1;
            indexYear ++;
        }
        NSString *monthTime = [NSString stringWithFormat:@"%ld.%ld",(long)indexYear,(long)indexMonth];
        [dates addObject:monthTime];
    }
    [dates removeLastObject];
    
    return dates;
}

21、两个时间段之间的天数

- (NSArray *)dateFromeTime:(NSString *)startTime ToTime:(NSString *)lastTime{

    NSDateFormatter *date = [NSDateFormatter sharedDateFormatter];
    [date setDateFormat:@"yyyy.MM.dd"];
    NSDate *startD =[date dateFromString:startTime];
    NSDate *endD = [date dateFromString:lastTime];
    NSTimeInterval nowTime = [startD timeIntervalSince1970]*1;
    NSTimeInterval endTime = [endD timeIntervalSince1970]*1;
    
    NSMutableArray *dates = [[NSMutableArray alloc] init];
    NSTimeInterval  dayTime = 24*60*60;
    double mm = (long long)nowTime % (int)dayTime;
   NSTimeInterval time = nowTime - mm;
    
    while (time <= endTime) {
        NSString *showOldDate = [date stringFromDate:[NSDate dateWithTimeIntervalSince1970:time]];
        [dates addObject:showOldDate];
        time += dayTime;
    }
    [dates removeObjectAtIndex:0];
    [dates addObject:lastTime];
    
    return dates;
}

22、获取网络北京时间,[NSDate date]获取的是设备当前时间

#pragma mark --请求网络时间戳

+ (void)getInternetDateWithSuccess:(void(^)(NSTimeInterval timeInterval))success

failure:(void(^)(NSError *error))failure{

//1.创建URL

NSString *urlString = @"http://m.baidu.com";

urlString = [urlString stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLQueryAllowedCharacterSet]];

//2.创建request请求对象

NSMutableURLRequest *request = [[NSMutableURLRequest alloc] init];

[request setURL:[NSURL URLWithString: urlString]];

[request setCachePolicy:NSURLRequestReloadIgnoringCacheData];

[request setTimeoutInterval:5];

[request setHTTPShouldHandleCookies:FALSE];

[request setHTTPMethod:@"GET"];

//3.创建URLSession对象

NSURLSession *session = [NSURLSession sharedSession]; //4.设置数据返回回调的block

NSURLSessionDataTask *task = [session dataTaskWithRequest:request completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {

if (error == nil && response != nil) {

//这么做的原因是简体中文下的手机不能识别“MMM”,只能识别“MM”

NSArray *monthEnglishArray = @[@"Jan",@"Feb",@"Mar",@"Apr",@"May",@"Jun",@"Jul",@"Aug",@"Sept",@"Sep",@"Oct",@"Nov",@"Dec"];

NSArray *monthNumArray = @[@"01",@"02",@"03",@"04",@"05",@"06",@"07",@"08",@"09",@"09",@"10",@"11",@"12"];

NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *)response;

NSDictionary *allHeaderFields = [httpResponse allHeaderFields];

NSString *dateStr = [allHeaderFields objectForKey:@"Date"];

dateStr = [dateStr substringFromIndex:5];

dateStr = [dateStr substringToIndex:[dateStr length]-4];

dateStr = [dateStr stringByAppendingString:@" +0000"];

//当前语言是中文的话,识别不了英文缩写

for (NSInteger i = 0 ; i < monthEnglishArray.count ; i++) {

NSString *monthEngStr = monthEnglishArray[i];

NSString *monthNumStr = monthNumArray[i];

dateStr = [dateStr stringByReplacingOccurrencesOfString:monthEngStr withString:monthNumStr];

}

NSDateFormatter *dMatter = [[NSDateFormatter alloc] init];

[dMatter setDateFormat:@"dd MM yyyy HH:mm:ss Z"];

NSDate *netDate = [dMatter dateFromString:dateStr];

NSTimeInterval timeInterval = [netDate timeIntervalSince1970];

dispatch_async(dispatch_get_main_queue(), ^{

success(timeInterval);

});

}else{

dispatch_async(dispatch_get_main_queue(), ^{

failure(error);

});

}

}];

//4、执行网络请求

[task resume];

}
最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
  • 序言:七十年代末,一起剥皮案震惊了整个滨河市,随后出现的几起案子,更是在滨河造成了极大的恐慌,老刑警刘岩,带你破解...
    沈念sama阅读 220,002评论 6 509
  • 序言:滨河连续发生了三起死亡事件,死亡现场离奇诡异,居然都是意外死亡,警方通过查阅死者的电脑和手机,发现死者居然都...
    沈念sama阅读 93,777评论 3 396
  • 文/潘晓璐 我一进店门,熙熙楼的掌柜王于贵愁眉苦脸地迎上来,“玉大人,你说我怎么就摊上这事。” “怎么了?”我有些...
    开封第一讲书人阅读 166,341评论 0 357
  • 文/不坏的土叔 我叫张陵,是天一观的道长。 经常有香客问我,道长,这世上最难降的妖魔是什么? 我笑而不...
    开封第一讲书人阅读 59,085评论 1 295
  • 正文 为了忘掉前任,我火速办了婚礼,结果婚礼上,老公的妹妹穿的比我还像新娘。我一直安慰自己,他们只是感情好,可当我...
    茶点故事阅读 68,110评论 6 395
  • 文/花漫 我一把揭开白布。 她就那样静静地躺着,像睡着了一般。 火红的嫁衣衬着肌肤如雪。 梳的纹丝不乱的头发上,一...
    开封第一讲书人阅读 51,868评论 1 308
  • 那天,我揣着相机与录音,去河边找鬼。 笑死,一个胖子当着我的面吹牛,可吹牛的内容都是我干的。 我是一名探鬼主播,决...
    沈念sama阅读 40,528评论 3 420
  • 文/苍兰香墨 我猛地睁开眼,长吁一口气:“原来是场噩梦啊……” “哼!你这毒妇竟也来了?” 一声冷哼从身侧响起,我...
    开封第一讲书人阅读 39,422评论 0 276
  • 序言:老挝万荣一对情侣失踪,失踪者是张志新(化名)和其女友刘颖,没想到半个月后,有当地人在树林里发现了一具尸体,经...
    沈念sama阅读 45,938评论 1 319
  • 正文 独居荒郊野岭守林人离奇死亡,尸身上长有42处带血的脓包…… 初始之章·张勋 以下内容为张勋视角 年9月15日...
    茶点故事阅读 38,067评论 3 340
  • 正文 我和宋清朗相恋三年,在试婚纱的时候发现自己被绿了。 大学时的朋友给我发了我未婚夫和他白月光在一起吃饭的照片。...
    茶点故事阅读 40,199评论 1 352
  • 序言:一个原本活蹦乱跳的男人离奇死亡,死状恐怖,灵堂内的尸体忽然破棺而出,到底是诈尸还是另有隐情,我是刑警宁泽,带...
    沈念sama阅读 35,877评论 5 347
  • 正文 年R本政府宣布,位于F岛的核电站,受9级特大地震影响,放射性物质发生泄漏。R本人自食恶果不足惜,却给世界环境...
    茶点故事阅读 41,540评论 3 331
  • 文/蒙蒙 一、第九天 我趴在偏房一处隐蔽的房顶上张望。 院中可真热闹,春花似锦、人声如沸。这庄子的主人今日做“春日...
    开封第一讲书人阅读 32,079评论 0 23
  • 文/苍兰香墨 我抬头看了看天上的太阳。三九已至,却和暖如春,着一层夹袄步出监牢的瞬间,已是汗流浃背。 一阵脚步声响...
    开封第一讲书人阅读 33,192评论 1 272
  • 我被黑心中介骗来泰国打工, 没想到刚下飞机就差点儿被人妖公主榨干…… 1. 我叫王不留,地道东北人。 一个月前我还...
    沈念sama阅读 48,514评论 3 375
  • 正文 我出身青楼,却偏偏与公主长得像,于是被迫代替她去往敌国和亲。 传闻我的和亲对象是个残疾皇子,可洞房花烛夜当晚...
    茶点故事阅读 45,190评论 2 357

推荐阅读更多精彩内容

  • 图片转化 倒计时 倒计时 富文本部分字体飘灰 富文本部分字体飘灰 手动设置tabar 底部阴影 获取当前控件所在的...
    _Jock羁阅读 180评论 0 0
  • 第5章 引用类型(返回首页) 本章内容 使用对象 创建并操作数组 理解基本的JavaScript类型 使用基本类型...
    大学一百阅读 3,237评论 0 4
  • PHP常用函数大全 usleep() 函数延迟代码执行若干微秒。 unpack() 函数从二进制字符串对数据进行解...
    上街买菜丶迷倒老太阅读 1,370评论 0 20
  • php usleep() 函数延迟代码执行若干微秒。 unpack() 函数从二进制字符串对数据进行解包。 uni...
    思梦PHP阅读 1,984评论 1 24
  • 有一次约朋友小麦烤肉,在等待肉熟的过程中,他抓着他的那部iphone4埋着头发着消息。我好奇地问他,这么多年,为什...
    简言375阅读 174评论 0 0