Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    HG3
    HG3 is offline
    New Coder
    Join Date
    Sep 2011
    Location
    BRAZIL
    Posts
    23
    Thanks
    7
    Thanked 0 Times in 0 Posts

    Exclamation Orientation of objects

    Hello everybody, I need help to search all that is between "()" as in the example below, more my script not ta working .
    Can anyone help me?

    PHP Code:
    <?php

    $txt 
    "
    <?php
    //bla bla bla
    forum(hello condingforums...
    bla...bla...bla...bla..bla
    bla...bla...bla...bla..bla);
    ?>
    "
    ;

    preg_match_all('#\(\w+\)#'$txt$matches);
    print_r($matches);

    ?>

  • #2
    Regular Coder
    Join Date
    Jul 2010
    Location
    Oregon City
    Posts
    280
    Thanks
    5
    Thanked 50 Times in 49 Posts
    PHP Code:
    <?php

    $txt 
    "
    <?php
    //bla bla bla
    forum(hello condingforums...
    bla...bla...bla...bla..bla
    bla...bla...bla...bla..bla);
    ?>
    "
    ;

    preg_match_all("/\\(.*\\)/si"$txt$matches);
    print_r($matches);

    ?>

  • #3
    HG3
    HG3 is offline
    New Coder
    Join Date
    Sep 2011
    Location
    BRAZIL
    Posts
    23
    Thanks
    7
    Thanked 0 Times in 0 Posts
    thank you Adee =)


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •