• Anon (unregistered) in reply to Jay
    Jay:
    pjt33:
    Code Dependent:
    Reaver121:
    Without those I would happily chuck the thing into the toilet.
    Interestingly, that's exactly what I did with my previous phone. Not on purpose, mind you... hint: don't carry your cell phone in your shirt pocket when using the restroom.
    Even better hint: don't do handstands on the toilet.

    DOn't try to flush the toilet either, as that might involve bending over near the toilet.

    Or don't you flush toilets where you live, Pjt33?

    I don't know if I've ever seen a toilet with the flusher placed so low that I've need to bend over so much that I'd be in danger of losing something out my pocket. Maybe you are freakishly tall? Besides, for public restrooms, I usually just use my foot to flush.

  • Yanman (unregistered) in reply to Charles400
    Charles400:
    (Shrugs) I don't know Javascript. Or Regex.

    Lucky, lucky man!

  • Pyroka (unregistered)

    Wow, never thought I'd see so many people hating mobile phones, I take the opposite approach, I don't have a land-line, anyone who wants to contact me can call my mobile (if I decide to answer or not is a different matter)

  • (cs) in reply to Code Dependent
    Code Dependent:
    Reaver121:
    Without those I would happily chuck the thing into the toilet.
    Interestingly, that's exactly what I did with my previous phone. Not on purpose, mind you... hint: don't carry your cell phone in your shirt pocket and then strip down completely naked (and then wildly fling your shirt around) to sit on the pooper when using the restroom.

    FTFY

  • (cs) in reply to Chelloveck
    Chelloveck:
    Whenever I run across anything that "requires" an email address but isn't really going to send me anything I need (like a reg key or something) I use "postmaster@{whatever.com}", where "{whatever.com}" is the site asking for the info. Almost always works, and I hope it annoys anyone trying to add me to their mailing list.

    I have my own domain, so every company I deal with gets a unique email address. I know that Home Depot has had their list comprised as well as NTI (http://www.ntius.com/en/us/home/Default.asp). Broderbund will sell your address to EVERYONE with your other registration details. BJ's wholesale sends personalized emails to the address that I only gave to Broderbund so they must have cross referenced with their own member database.

  • Herby (unregistered) in reply to Chelloveck
    Chelloveck:
    Whenever I run across anything that "requires" an email address but isn't really going to send me anything I need (like a reg key or something) I use "postmaster@{whatever.com}", where "{whatever.com}" is the site asking for the info. Almost always works, and I hope it annoys anyone trying to add me to their mailing list.

    I have my own domain as well. There are TWO problems (to name some). You get emails addressed to every name in the book (and some that aren't) with your domain attached. And you get the joy of finding out just where your email addresses go. I too add a prefix to email addresses requested by web sites. It has a nice character ('-') in it, which fails MANY regex parsers mentioned in the comments. I also get LOTS of "confirmation" emails to new addresses which I can hopefully turn off before they become to nasty.

    One of my email addresses I've forwarded back to the "complaints" address, but I don't think it does anything. It was for a survey I took long ago. Yes, that (worse than useless) "CAN-SPAM" act congress wrote really worked! Why did they even bother?

  • Bob (unregistered) in reply to Kazan

    That's not true. T-Mobile does and AT&T does. Both are GSM that use SIM cards. Both carriers do so for contract as well as pre-paid.

  • PublicLurker (unregistered) in reply to valerion
    valerion:
    I bought a couple of Net10 phones to use whilst on holiday in the States last year - I don't think they had SIM cards.

    Also, it cost $30 for a phone with $30 of airtime. If you don't care about your number it's worth just replacing both every time you run out.

    That's strange, both my wife and myself have tracfone systems, which are by the same company. Both of them have SIM cards.

    I've been told that these companies have different carriers in different parts of the country. That may explain the difference.

  • (cs)

    I don't have a cell phone. Yay!!!

    A few of my co-workers recently got Blackberrys, and in order to let the Blackberrys retrieve e-mail, they need Outlook to leave the e-mail on the server for a few days. Of course, some of them changed their Outlook setup to leave e-mail on the server forever, which of course means everyone sending them e-mail started getting messages saying "the recipient's mailbox is full" (full at the ISP).

    I politely suggested that when people are away from the office, they need to get a life and not worry about their e-mail.

  • slapout (unregistered)

    In the US their are two main systems:

    GSM (Sim cards): AT&T T-Mobile

    CDMA: Verizon Sprint

    There's also Alltel. I'm not sure what system they use, but they just got bought out by Verizon.

    Others like Net10, Boost, Tracfone, etc., sale service that uses the towers owned by the other companies.

    Verizon & AT&T are the two biggest as far as subscribers.

  • neo (unregistered)

    Why didn't he turn javascript off?

  • (cs)
    Josh:
    If you had a G'Zone, you COULD chuck it in the toilet, even WHILE you were talking on it!

    G'Zone Type-S: light on features but super-badass. http://www.casiogzone.com

    Excepting the NexTel MotoPhones, this is the only phone that you can drop-kick over your house and into a mud puddle... and then run through the dishwasher to clean off! You can even have conversations while scuba diving, as it's waterproof to 5 meters.

    The Type-S is light on features - the only BT profile is 'headset' and the camera is 640x480. The new Boulder has a 1.3MP camera and SD Card slot.

    I have a G'Zone Boulder. It's a huge improvement over the Type-S and Type-V. It lacks the silly bumper thing that was on the bottom of the Type-V, and it's a lot smaller and easier to hold. Lots more internal memory than the earlier G'Zones, as well as most of the standard-ish features the others were lacking, e.g. Bluetooth, push-to-talk, microSD card. Even a built-in compass.

  • (cs) in reply to Funny
    Funny:
    Yet another area where you are decades-late yet somehow think to be in advance or something. In the rest of the world, we use SIM-based GSM phones, get them free from the provider *and* get new ones free every two years too. Plus they roam across country borders and operators, so we have service *everywhere*, including in most parts of the US as our phones are multi-bands :-)
    wahhhh wahhh wahhhh I hope you enjoy being so superior that you can't figure out you're just paying for it in your monthly bill instead of up front. Oh, and enjoy that 17% VAT :) In the US we mostly have SIM-based GSM phones too, if you did any research and weren't such an ignorant wanker you would know this (Verizon, Sprint, and one or two other smaller companies which use CDMA are the non-SIM group...)

    In short, do your research and stop being such an arse. GSM, SIM cards, CDMA, and your stupid europe vs america pissing fight aren't even related to the original post anyways.

  • DeepThought (unregistered) in reply to nocturnal
    nocturnal:
    Kazan:
    none of the regular services in the US use SIMs... do the prepaid?

    What??? Most phones in the US use SIMs. AT&T does, and I'm pretty sure it's the biggest cell phone company in the US; and then there's all of the companies that lease AT&T towers, and T-Mobile.

    I use Sprint and there is no SIM card in my phone. Of course, I bought this phone (yes, I rejected their offer to hold me ransom for 3+ years and paid for my phone directly) more than two years ago. I'm not sure if this has changed, but my GF's phone (Verison I think) also doesn't have a SIM card.

    I too specifically requested that my cell phone not have any special bells or whistles. In particular I requested that it NOT come with a camera as I would not have been able to bring it into the secure hosting facilities in which many of my clients had their equipment. The bewildered look on the sales person's face was priceless.

  • (cs)

    "Regexes don't write obfuscated code, people write obfuscated code"

    "You can take my regexes when you pry them from my cold, dead fingers"

  • BruceA (unregistered) in reply to Rhywden
    Rhywden:
    Could someone explain to me why a simple

    /[a-z._-]+@[a-z.-]+.[a-z]{2,3}/i

    does not suffice? Granted, it does not check if the email adress is actually valid - then again, I'd rather do that with a verification email.

    For one thing, it rejects everyone with a TLD of more than 3 letters: .name, .mobi, .info, .aero, .museum, .travel are all valid TLDs.

  • noob (unregistered) in reply to pete
    pete:
    It’s just a plain old phone with plain old service that can only dial and receive plain old calls. And it’s exactly the type of phone that Jack wants.
    Me too! Whenever I am forced to get a new cell phone, I start off by telling the sales weasel the "features" I don't want. They look at me like I'm speaking binary.

    Guess it's time to head over to net10 and see what they have...

    Last time I bought a cell phone, I wanted the (apparently) never asked for feature of "good reception." I don't care if it takes pictures or plays music. I want a phone that works in my house and my office. All the phones that I've owned have either been one or the other, but never both.

    One particular sales guy tried to convince me how all phones ever invented are the same and it wasn't possible for my wife's phone to work in a place where mine didn't if we were on the same network. It's amazing what people will do to avoid saying "I don't know and I don't know how to find out even though I should know because I work here."

  • col (unregistered) in reply to Inhibeo

    You get a free phone every 2 years, even on pay-as-you go?

  • Brush after you flush (unregistered) in reply to Anon

    ...so I guess we've now established that Code Dependent is the only one round here who knows how to use a toilet brush.

    Me on the other hand, my shit just doesn't stick.

  • Floydian (unregistered) in reply to Kazan

    one of the regular services in the US use SIMs? AT&T does, T-Mobile does, Just got a new Verizion Blackberry at work, that came with a SIM. What are you talking about

  • Bob (unregistered) in reply to DOA
    DOA:
    Nice to know I'm not the only one with that attitude towards cell phones.
    There's lots of people out there who want the kids to get off the lawn and take them danged new-fangled contraptions with them. I'm surprised you haven't met more of them since you moved into the retirement home.
  • Rich Lovely (unregistered)

    Doesn't it break with [email protected]?

    Or am I missing something?

  • (cs) in reply to Rich Lovely

    (That last was me... and I missed a greaterthan...)

  • moz (unregistered) in reply to Neil S
    Neil S:
    TRWTF is that half this post is just an ad.

    If this becomes a trend I'll probably delete the feed.

    I don't understand. Do you mean to say that the idea of a 'phone provider having a simple (albeit Javascript-based and non-functional) web interface counts as a selling point wherever you're from? Or that you expect the (unnamed) 'phone Jack chose only to be compatible with one provider?

    I just saw the first two paragraphs as a way to forestall any "WTF are Net 10?" comments.

  • DeepThought (unregistered) in reply to Brush after you flush
    Brush after you flush:
    ...so I guess we've now established that Code Dependent is the only one round here who knows how to use a toilet brush.

    Me on the other hand, my shit just doesn't stick.

    Most public toilets here in the States aren't equipped with brushes. The bowl is full of water so your shit won't normally stick unless you have explosive diarrhea.

    I've been to Europe and can tell you it took me a bit to get used to toilets that pretty much require the use of a brush after each use.

  • Jim (unregistered) in reply to Alyson

    Sprint's Nextel phones also use SIMs.

  • Bob (unregistered) in reply to Kazan
    Kazan:
    Henning Makholm:
    But when his old phone broke and he had to transfer the minutes to a new phone,

    Why does he need to interact with the provider for that?

    (1) Open up old phone.

    (2) Retrieve the SIM.

    (3) Insert SIM into new phone.

    (4) Profit?

    none of the regular services in the US use SIMs... do the prepaid?
    I've investigated the Net10/Tracfone phones. Not sure about the others.

    Apparently whether the Net10/Tracfone phone uses a SIM card depends on the service they contract with in your home area, GSM or CDMA. The GSM phones have the SIM cards.

    But when the Net10/Tracfone has a SIM card, the Net10/Tracfone billing service is tied to the SIM card and phone's serial numbers. You can't take a SIM card from one Net10/Tracfone and stick it in another because the phone serial number doesn't match.

    You might be able to take the SIM card from the original phone, copy the address book to it, swap it into the new phone, and while the phone is unable to connect copy the address book to the new phone's memory before switching back to the new phone's SIM card.

  • SurturZ (unregistered) in reply to pete
    pete:
    It’s just a plain old phone with plain old service that can only dial and receive plain old calls. And it’s exactly the type of phone that Jack wants.
    Me too! Whenever I am forced to get a new cell phone, I start off by telling the sales weasel the "features" I don't want. They look at me like I'm speaking binary.

    Guess it's time to head over to net10 and see what they have...

    01010111 01010100 01000110 00111111

  • Ron Tarmack (unregistered) in reply to TarquinWJ
    TarquinWJ:
    Rhywden:
    Could someone explain to me why a simple

    /[a-z._-]+@[a-z.-]+.[a-z]{2,3}/i

    does not suffice? Granted, it does not check if the email adress is actually valid - then again, I'd rather do that with a verification email.

    I suppose you wanted something more detailed than "it fails to accept a very large number of valid email addresses". Examples would be those that use + signs in the local part, those that use longer TLDs, those that use IDN in the domain names, etc.

    Of course, there isn't much call for it, but to take it to an extreme...

    "this is " @ valid \\"@[123.123.123.123]

    One Perl program I worked on had the following e-mail regex, which accepted the username@[123.123.123.123] notation, and allowed whitespace and other characters to appear in addresses:

    $email !~ /.*?([\w.]+?\s*?[\w.]+?@([-0-9a-zA-Z\056]+\.[0-9a-zA-Z]+|\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\]))\W*?.*/
    

    It was not IPv6 compliant, unfortunately, and didn't accept IP addresses in decimal notation, where 123.123.123.123 becomes 2071690107.

    The expression was designed to pick a valid e-mail address wherever one could be discerned, so you could paste in a typical From: line, such as "Joe User" [email protected], and it would get [email protected] out of it.

  • Lee K-T (unregistered) in reply to DeepThought
    DeepThought:
    Brush after you flush:
    ...so I guess we've now established that Code Dependent is the only one round here who knows how to use a toilet brush.

    Me on the other hand, my shit just doesn't stick.

    Most public toilets here in the States aren't equipped with brushes. The bowl is full of water so your shit won't normally stick unless you have explosive diarrhea.

    I've been to Europe and can tell you it took me a bit to get used to toilets that pretty much require the use of a brush after each use.

    Well not after each use actually, only when you have an American diet.

  • ysth (unregistered)

    function valid_email(email){var tlds = ['AC','AD','AE','AERO','AF','AG','AI','AL','AM','AN','AO','AQ','AR','ARPA','AS','ASIA','AT','AU','AW','AX','AZ','BA','BB','BD','BE','BF','BG','BH','BI','BIZ','BJ','BM','BN','BO','BR','BS','BT','BV','BW','BY','BZ','CA','CAT','CC','CD','CF','CG','CH','CI','CK','CL','CM','CN','CO','COM','COOP','CR','CU','CV','CX','CY','CZ','DE','DJ','DK','DM','DO','DZ','EC','EDU','EE','EG','ER','ES','ET','EU','FI','FJ','FK','FM','FO','FR','GA','GB','GD','GE','GF','GG','GH','GI','GL','GM','GN','GOV','GP','GQ','GR','GS','GT','GU','GW','GY','HK','HM','HN','HR','HT','HU','ID','IE','IL','IM','IN','INFO','INT','IO','IQ','IR','IS','IT','JE','JM','JO','JOBS','JP','KE','KG','KH','KI','KM','KN','KP','KR','KW','KY','KZ','LA','LB','LC','LI','LK','LR','LS','LT','LU','LV','LY','MA','MC','MD','ME','MG','MH','MIL','MK','ML','MM','MN','MO','MOBI','MP','MQ','MR','MS','MT','MU','MUSEUM','MV','MW','MX','MY','MZ','NA','NAME','NC','NE','NET','NF','NG','NI','NL','NO','NP','NR','NU','NZ','OM','ORG','PA','PE','PF','PG','PH','PK','PL','PM','PN','PR','PRO','PS','PT','PW','PY','QA','RE','RO','RS','RU','RW','SA','SB','SC','SD','SE','SG','SH','SI','SJ','SK','SL','SM','SN','SO','SR','ST','SU','SV','SY','SZ','TC','TD','TEL','TF','TG','TH','TJ','TK','TL','TM','TN','TO','TP','TR','TRAVEL','TT','TV','TW','TZ','UA','UG','UK','US','UY','UZ','VA','VC','VE','VG','VI','VN','VU','WF','WS','YE','YT','YU','ZA','ZM','ZW'];if (email!= null&&email!= ""){var emailPattern = /^\w.*@([-a-z0-9]+.)+[a-z]+$/i;if (!emailPattern.test(email)){alert("The email address supplied is not valid or has errors. Make sure the address matches the format [email protected].");return 0;} var isValidTLD=false;var tldIndex = email.lastIndexOf(".")+1;if ( 0 < tldIndex && tldIndex < email.length ){var tld = email.substr(tldIndex).toUpperCase();for (i=0; i<tlds.length; i++){if(tld==tlds[i]){isValidTLD = true;break;}}};if (!isValidTLD){if (!confirm("The email address supplied does not contain a valid top level domain (such as .com or .org). Is this really OK? (click Cancel to fix)")){return 0;}}}else{alert("Please include a valid email address in the "Email" field.");return 0;};return 1;}

  • Peter (unregistered)

    You can also check to see if an email exists without sending mail to it.

    http://www.webdigi.co.uk/blog/2009/how-to-check-if-an-email-address-exists-without-sending-an-email/

    Captcha: sagaciter. How exciting!

  • minini (unregistered) in reply to Ryan

    Wonder why they don't use regexps to validate emails? Here is how you do it with regexps correctly:

    (?:(?:\r\n)?[ \t])(?:(?:(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t] )+|\Z|(?=[["()<>@,;:\".[]]))|"(?:[^"\r\]|\.|(?:(?:\r\n)?[ \t]))"(?:(?: \r\n)?[ \t]))(?:.(?:(?:\r\n)?[ \t])(?:[^()<>@,;:\".[] \000-\031]+(?:(?:( ?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|"(?:[^"\r\]|\.|(?:(?:\r\n)?[ \t]))"(?:(?:\r\n)?[ \t])))@(?:(?:\r\n)?[ \t])(?:[^()<>@,;:\".[] \000-\0 31]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|[([^[]\r\]|\.)
    ](?:(?:\r\n)?[ \t])
    )(?:.(?:(?:\r\n)?[ \t])(?:[^()<>@,;:\".[] \000-\031]+ (?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|[([^[]\r\]|\.)](?: (?:\r\n)?[ \t])))|(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z |(?=[["()<>@,;:\".[]]))|"(?:[^"\r\]|\.|(?:(?:\r\n)?[ \t]))"(?:(?:\r\n) ?[ \t]))<(?:(?:\r\n)?[ \t])(?:@(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:
    r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|[([^[]\r\]|\.)](?:(?:\r\n)?[ \t]))(?:.(?:(?:\r\n)?[ \t])(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n) ?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|[([^[]\r\]|\.)](?:(?:\r\n)?[ \t] )))(?:,@(?:(?:\r\n)?[ \t])(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|[([^[]\r\]|\.)](?:(?:\r\n)?[ \t])* )(?:.(?:(?:\r\n)?[ \t])(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t] )+|\Z|(?=[["()<>@,;:\".[]]))|[([^[]\r\]|\.)](?:(?:\r\n)?[ \t])))) :(?:(?:\r\n)?[ \t]))?(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+ |\Z|(?=[["()<>@,;:\".[]]))|"(?:[^"\r\]|\.|(?:(?:\r\n)?[ \t]))"(?:(?:\r \n)?[ \t]))(?:.(?:(?:\r\n)?[ \t])(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?: \r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|"(?:[^"\r\]|\.|(?:(?:\r\n)?[ \t ]))"(?:(?:\r\n)?[ \t])))@(?:(?:\r\n)?[ \t])(?:[^()<>@,;:\".[] \000-\031 ]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|[([^[]\r\]|\.)]( ?:(?:\r\n)?[ \t]))(?:.(?:(?:\r\n)?[ \t])(?:[^()<>@,;:\".[] \000-\031]+(? :(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|[([^[]\r\]|\.)](?:(? :\r\n)?[ \t])))>(?:(?:\r\n)?[ \t]))|(?:[^()<>@,;:\".[] \000-\031]+(?:(? :(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|"(?:[^"\r\]|\.|(?:(?:\r\n)? [ \t]))"(?:(?:\r\n)?[ \t])):(?:(?:\r\n)?[ \t])(?:(?:(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|"(?:[^"\r\]| \.|(?:(?:\r\n)?[ \t]))"(?:(?:\r\n)?[ \t]))(?:.(?:(?:\r\n)?[ \t])(?:[^()<> @,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|" (?:[^"\r\]|\.|(?:(?:\r\n)?[ \t]))"(?:(?:\r\n)?[ \t])))@(?:(?:\r\n)?[ \t] )(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\ ".[]]))|[([^[]\r\]|\.)](?:(?:\r\n)?[ \t]))(?:.(?:(?:\r\n)?[ \t])(? :[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[ ]]))|[([^[]\r\]|\.)](?:(?:\r\n)?[ \t])))|(?:[^()<>@,;:\".[] \000- \031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|"(?:[^"\r\]|\.|( ?:(?:\r\n)?[ \t]))"(?:(?:\r\n)?[ \t]))<(?:(?:\r\n)?[ \t])(?:@(?:[^()<>@,; :\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|[([ ^[]\r\]|\.)](?:(?:\r\n)?[ \t]))(?:.(?:(?:\r\n)?[ \t])(?:[^()<>@,;:\" .[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|[([^[
    ]\r\]|\.)](?:(?:\r\n)?[ \t])))(?:,@(?:(?:\r\n)?[ \t])(?:[^()<>@,;:\".
    [] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|[([^[]
    r\]|\.)](?:(?:\r\n)?[ \t]))(?:.(?:(?:\r\n)?[ \t])(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|[([^[]\r\] |\.)](?:(?:\r\n)?[ \t])))):(?:(?:\r\n)?[ \t]))?(?:[^()<>@,;:\".[] \0 00-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|"(?:[^"\r\]|\ .|(?:(?:\r\n)?[ \t]))"(?:(?:\r\n)?[ \t]))(?:.(?:(?:\r\n)?[ \t])(?:[^()<>@, ;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[]]))|"(? :[^"\r\]|\.|(?:(?:\r\n)?[ \t]))"(?:(?:\r\n)?[ \t])))@(?:(?:\r\n)?[ \t]) (?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\". []]))|[([^[]\r\]|\.)](?:(?:\r\n)?[ \t]))(?:.(?:(?:\r\n)?[ \t])(?:[ ^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[] ]))|[([^[]\r\]|\.)](?:(?:\r\n)?[ \t])))>(?:(?:\r\n)?[ \t]))(?:,\s( ?:(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\ ".[]]))|"(?:[^"\r\]|\.|(?:(?:\r\n)?[ \t]))"(?:(?:\r\n)?[ \t]))(?:.(?:( ?:\r\n)?[ \t])(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[ ["()<>@,;:\".[]]))|"(?:[^"\r\]|\.|(?:(?:\r\n)?[ \t]))"(?:(?:\r\n)?[ \t ])))@(?:(?:\r\n)?[ \t])(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t ])+|\Z|(?=[["()<>@,;:\".[]]))|[([^[]\r\]|\.)](?:(?:\r\n)?[ \t]))(? :.(?:(?:\r\n)?[ \t])(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+| \Z|(?=[["()<>@,;:\".[]]))|[([^[]\r\]|\.)](?:(?:\r\n)?[ \t])))|(?: [^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\".[
    ]]))|"(?:[^"\r\]|\.|(?:(?:\r\n)?[ \t]))"(?:(?:\r\n)?[ \t]))<(?:(?:\r\n) ?[ \t])(?:@(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[[" ()<>@,;:\".[]]))|[([^[]\r\]|\.)](?:(?:\r\n)?[ \t]))(?:.(?:(?:\r\n) ?[ \t])(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<> @,;:\".[]]))|[([^[]\r\]|\.)](?:(?:\r\n)?[ \t])))(?:,@(?:(?:\r\n)?[ \t])(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@, ;:\".[]]))|[([^[]\r\]|\.)](?:(?:\r\n)?[ \t]))(?:.(?:(?:\r\n)?[ \t] )(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\ ".[]]))|[([^[]\r\]|\.)](?:(?:\r\n)?[ \t])))):(?:(?:\r\n)?[ \t]))? (?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[["()<>@,;:\". []]))|"(?:[^"\r\]|\.|(?:(?:\r\n)?[ \t]))"(?:(?:\r\n)?[ \t]))(?:.(?:(?: \r\n)?[ \t])(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z|(?=[[ "()<>@,;:\".[]]))|"(?:[^"\r\]|\.|(?:(?:\r\n)?[ \t]))"(?:(?:\r\n)?[ \t]) ))@(?:(?:\r\n)?[ \t])(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t]) +|\Z|(?=[["()<>@,;:\".[]]))|[([^[]\r\]|\.)](?:(?:\r\n)?[ \t]))(?:
    .(?:(?:\r\n)?[ \t])(?:[^()<>@,;:\".[] \000-\031]+(?:(?:(?:\r\n)?[ \t])+|\Z |(?=[["()<>@,;:\".[]]))|[([^[]\r\]|\.)](?:(?:\r\n)?[ \t])))>(?:( ?:\r\n)?[ \t]))))?;\s*)

  • (cs)

    Am I the only one wondering why nobody bothers to read all the comments before posting any more?

  • Jurgen (unregistered)

    Ha, In Belgium it's illegal to give you a phone for free. (Couplesale)

  • Lee K-T (unregistered) in reply to Jurgen
    Jurgen:
    Ha, In Belgium it's illegal to give you a phone for free. (Couplesale)

    Funny country, you can't give phones but you can give ammo to children :)

  • (cs) in reply to pete
    pete:
    It’s just a plain old phone with plain old service that can only dial and receive plain old calls. And it’s exactly the type of phone that Jack wants.
    Me too! Whenever I am forced to get a new cell phone, I start off by telling the sales weasel the "features" I don't want. They look at me like I'm speaking binary.

    Guess it's time to head over to net10 and see what they have...

    I have the exact same thing when I'm buying a new calculator. I never use division (and if I really needed to ever, I could just recursively subtract). You wouldn't believe how hard it is to get hold of calculators without all these unnecessary features. It's quite ridiculous.

  • Peter (unregistered) in reply to kastein
    kastein:
    Funny:
    Yet another area where you are decades-late yet somehow think to be in advance or something. In the rest of the world, we use SIM-based GSM phones, get them free from the provider *and* get new ones free every two years too. Plus they roam across country borders and operators, so we have service *everywhere*, including in most parts of the US as our phones are multi-bands :-)
    wahhhh wahhh wahhhh I hope you enjoy being so superior that you can't figure out you're just paying for it in your monthly bill instead of up front. Oh, and enjoy that 17% VAT :) In the US we mostly have SIM-based GSM phones too, if you did any research and weren't such an ignorant wanker you would know this (Verizon, Sprint, and one or two other smaller companies which use CDMA are the non-SIM group...)

    In short, do your research and stop being such an arse. GSM, SIM cards, CDMA, and your stupid europe vs america pissing fight aren't even related to the original post anyways.

    I'll bet we have more sets of antennas on our towers here in the US than anywhere else in the world. Near major highway intersections, towers with 6 or more sets of antennas (each representing a carrier) are not uncommon. Nothing like duplication of equipment and incompatible standards to encourage business!

  • (cs)

    My mobile phone company doesn't offer me online management of my account, so that line in the article is incorrect! My plan is from 2001 (very grandfathered) and the "new" billing system doesn't support it so I'm stuck on the "old" billing system, which does not support the online features. The person on the phone told me I'm on a good plan and can see why I don't want to move away from it. We were planning on joining mine and my wife's plans onto the one account but as they don't provision any new services onto the old system and my plan can't be moved to the new system our two plans appear as two completely separate accounts.

  • Coward (unregistered) in reply to me

    Meh... get over it

    me:
    TRWTF is not checking for plural when displaying the number of comments:

    [image]

  • Mechsoul (unregistered) in reply to Chelloveck
    Chelloveck:
    Whenever I run across anything that "requires" an email address but isn't really going to send me anything I need (like a reg key or something) I use "postmaster@{whatever.com}", where "{whatever.com}" is the site asking for the info. Almost always works, and I hope it annoys anyone trying to add me to their mailing list.

    So now I know who to blame when I get "love letters" for unrequested opt-ins on my sites :P

  • Zach Bora (unregistered) in reply to me
    me:
    TRWTF is not checking for plural when displaying the number of comments:

    [image]

    TRWTF is that my company blocks imageshack... but not youtube.

  • caper (unregistered)

    "You can also check to see if an email exists without sending mail to it."

    No you can't. That method is not accurate at all.

  • (cs) in reply to Chelloveck
    Chelloveck:
    Can someone explain to me why anyone even bothers to "validate" an email address on a web form?
    Because it can trap simple typos and without having to send anything to the server.
    Chelloveck:
    Even well-formed addresses may not be valid, in that they may point to a fake domain or user.
    ...or they may point to a valid address owned by someone who is not the person filling in the form.
    Chelloveck:
    About the only reason I can see for it is to avoid passing absolute crap to a mail bot. Okay, fine, throw out the truly egregious errors. Otherwise, if it's vaguely plausible let it through and assume the mailer will reject anything it can't understand.
    Precisely. So don't send malformed TLDs, illegal domain names, usernames with illegal characters, usernames with illegally placed characters, etc.

    Note that the example in TFA would reject a properly formed email address "[email protected]." -- the final dot is a FQDN terminator, and it prevents the lookup from attempting to descend any further. Evidently it was seen as "absolute crap" by the author. In the light of that, what kind of "absolute crap" would you be rejecting?

  • (cs) in reply to durnurd
    durnurd:
    I personally would not want to try writing a regex to validate any email address. Have you seen some of the more interesting ones?

    Here's my favorite:

    (?:[a-z0-9!#$%&'*+/=?^_`{|}~....

    Precisely. Why write a single regex?

    Personally, I split the string at the "@" sign, and treat LHS and RHS separately. RHS is validated for being a potential domain name (including FQDN with a terminating period), then the TLD is compared against the current latest list of TLDs. The LHS is checked against the rules for usernames. It's pretty simple really, and is far simpler to debug than the black box approach.

    Regexes are useful, but they should also be something you can come back to and update without having to relearn it for a week.

  • (cs) in reply to Pim
    Pim:
    Am I the only one wondering why nobody bothers to read all the comments before posting any more?

    Yes. Everyone else knows patience is a rare commodity these days. Even your mother knows that - but she may not be patient enough to share it with you. ;)

  • (cs) in reply to Rhywden
    Rhywden:
    Could someone explain to me why a simple

    /[a-z._-]+@[a-z.-]+.[a-z]{2,3}/i

    does not suffice? Granted, it does not check if the email adress is actually valid - then again, I'd rather do that with a verification email.

    Doesn't allow some valid emails, and allows some invalid emails. Even without going into the more obscure aspects of it*... The username may, for example, contain other punctuation than you have allowed (the + sign is popular, since it will, for example, automatically apply a label in gmail). You may be surprised to learn that neither the username nor the hostname is allowed to begin or end with a dot or contain two consecutive dots. The top-level-domain may contain more than four letters (.mobi, .museum, etc), and while there are none with only one letter, that possibility cannot be ruled out for the future. You also forbid emails that are simply @com or @org (maybe there are no emails at those addresses, but can you guarantee that for ALL top-level domains?)

    *incidentally, that HUGE regex you sometimes see floating around (and of course someone just HAD to link it in an earlier reply) allows things that aren't necessary to fully specify an email address, including obsolete multiple-mailbox syntax

  • (cs) in reply to rfsmit
    rfsmit:
    Note that the example in TFA would reject a properly formed email address "[email protected]." -- the final dot is a FQDN terminator, and it prevents the lookup from attempting to descend any further. Evidently it was seen as "absolute crap" by the author. In the light of that, what kind of "absolute crap" would you be rejecting?

    NO. Neither RFC 2822 nor RFC 2821 allows either the username or the host portion of an email address to begin or end with a dot. Validating email addresses is hard enough without people giving INVALID examples that "ought to pass" - why not go back to ".@." if you're going to take that approach?

  • Bldvmeom (unregistered) in reply to Rhywden
    Rhywden:
    Could someone explain to me why a simple

    /[a-z._-]+@[a-z.-]+.[a-z]{2,3}/i

    does not suffice? Granted, it does not check if the email adress is actually valid - then again, I'd rather do that with a verification email.

    For one, because it doesn't allow numbers on either side of the @-sign. And also, because it doesn't validate for the newer tld's such as .museum and .travel . Also note that there are a whole lot of special characters in the original regex that yours doesn't take into account.

  • (cs)

    Dear god, that's atrocious LOL!

Leave a comment on “Plain Old Regexs”

Log In or post as a guest

Replying to comment #:

« Return to Article