1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

HELP!Parse error: parse error, unexpected T_UNSET error

Discussion in 'PHP' started by jigen7, Oct 4, 2007.

  1. #1
    can anyone help me fix this?? code it gives me an unset error which i dont know how to debug.. it reads every url stored in $all_url then removes the url that has address starting from 0-9 and if it see the word google it is also remove... or can anyone give me an alternative code?

    $x = $counter;
    while (++$x < 200) {
    if (preg_match('~http://(www\.)?([0-9]|(.+\.)?google\.com)~', $all_url[$x])
    unset($all_url[$x]);
    }
     
    jigen7, Oct 4, 2007 IP
  2. nico_swd

    nico_swd Prominent Member

    Messages:
    4,153
    Likes Received:
    344
    Best Answers:
    18
    Trophy Points:
    375
    #2
    You're missing a closing parenthesis at the end of the preg_match line.
     
    nico_swd, Oct 4, 2007 IP
  3. jigen7

    jigen7 Peon

    Messages:
    42
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    oh man is that all??well it works lol thanks but it does not return the urls that i want... can any1 revise it?i want to get only the urls with full domain for example www.digitalpoint.com... i want to exclude the urls that is starting with a number , /search, and site that does not include google word
     
    jigen7, Oct 4, 2007 IP