Dynamic Method

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • smartic
    New Member
    • May 2007
    • 150

    Dynamic Method

    I need to replace the var $method with the GET how can id that ?

    Code:
    <?php
    $method = 'GET';
    echo $_GET['q'];
    ?>
  • Markus
    Recognized Expert Expert
    • Jun 2007
    • 6092

    #2
    Originally posted by smartic
    I need to replace the var $method with the GET how can id that ?

    Code:
    <?php
    $method = 'GET';
    echo $_GET['q'];
    ?>
    You could use REQUEST.

    Comment

    • smartic
      New Member
      • May 2007
      • 150

      #3
      thank you put i have found solution for it:
      <?php
      $str = '_GET';
      $method = $$str;
      echo $method['q'];
      ?>

      Comment

      Working...