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.

Problem explode

Discussion in 'PHP' started by radbelerwerazf, Jun 18, 2009.

  1. #1
    Welcome

    Over the last 2 days I did not extracts data from the left before the Traffic rapidshare.com rapidshare modification to work properly


    Rapidshare.com
     
    radbelerwerazf, Jun 18, 2009 IP
  2. Vooler

    Vooler Well-Known Member

    Messages:
    1,146
    Likes Received:
    64
    Best Answers:
    4
    Trophy Points:
    150
    #2
    If you are trying ot take this 1000 out then I can help. I dont know regular expression, so am gona do using some explodes:

    $data = "<td>Traffic left:</td><td align=right><b><script>document.write(setzeTT(\"\"+Math.ceil(0/1000)));</script> MB</b></td>";
    list($crap,$num) = explode("Math.ceil(",$data);
    list($crap,$num) = explode("/",$num);
    $num = intval($num);

    print $num;
     
    Vooler, Jun 18, 2009 IP
  3. radbelerwerazf

    radbelerwerazf Peon

    Messages:
    21
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Still not working please help

     
    radbelerwerazf, Jun 19, 2009 IP
  4. Vooler

    Vooler Well-Known Member

    Messages:
    1,146
    Likes Received:
    64
    Best Answers:
    4
    Trophy Points:
    150
    #4
    What my code is getting you is the valu bold in there:
    <td>Traffic left:</td><td align=right><b><script>document.write(setzeTT(""+Math.ceil(0/1000)));</script> MB</b></td>


    Do you need to get result of expression in ceil function "0/1000" ?

    regards
     
    Vooler, Jun 19, 2009 IP
  5. radbelerwerazf

    radbelerwerazf Peon

    Messages:
    21
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    I am to be in a similar construction as that which gave
     
    radbelerwerazf, Jun 19, 2009 IP
  6. Vooler

    Vooler Well-Known Member

    Messages:
    1,146
    Likes Received:
    64
    Best Answers:
    4
    Trophy Points:
    150
    #6
    Sorry cant understand what exactly you are willing to express by
    "I am to be in a similar construction as that which gave"

    regards
     
    Vooler, Jun 19, 2009 IP