Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. Linux, Apache, MySQL, PHP
  4. array?

array?

Scheduled Pinned Locked Moved Linux, Apache, MySQL, PHP
questionwcfdata-structures
3 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B Offline
    B Offline
    benjamin yap
    wrote on last edited by
    #1

    stdClass Object ( [return] => Array ( [0] => test [1] => test23 ) )

    Hi, how do i get the value of each array slots and print it nicely into a table form? I did a print_r and get the above. Below is my code

    $wsdl="http://localhost:8084/WebService/SMSWebService?wsdl";
    $client=new soapclient('http://localhost:8084/WebService/SMSWebService?wsdl');
    
    
    $response =$client->RetrieveSMS(								array('username'=>'usa',
    'password'=>'canada',
    'keyword'=>'Temp'
    )); 
    print\_r($response);
    
    M A 2 Replies Last reply
    0
    • B benjamin yap

      stdClass Object ( [return] => Array ( [0] => test [1] => test23 ) )

      Hi, how do i get the value of each array slots and print it nicely into a table form? I did a print_r and get the above. Below is my code

      $wsdl="http://localhost:8084/WebService/SMSWebService?wsdl";
      $client=new soapclient('http://localhost:8084/WebService/SMSWebService?wsdl');
      
      
      $response =$client->RetrieveSMS(								array('username'=>'usa',
      'password'=>'canada',
      'keyword'=>'Temp'
      )); 
      print\_r($response);
      
      M Offline
      M Offline
      Marc Firth
      wrote on last edited by
      #2

      These links will help: http://uk.php.net/manual/en/language.types.array.php[^] http://www.w3schools.com/PHP/php_arrays.asp[^] http://www.tizag.com/phpT/arrays.php[^]

      Neonlight

      1 Reply Last reply
      0
      • B benjamin yap

        stdClass Object ( [return] => Array ( [0] => test [1] => test23 ) )

        Hi, how do i get the value of each array slots and print it nicely into a table form? I did a print_r and get the above. Below is my code

        $wsdl="http://localhost:8084/WebService/SMSWebService?wsdl";
        $client=new soapclient('http://localhost:8084/WebService/SMSWebService?wsdl');
        
        
        $response =$client->RetrieveSMS(								array('username'=>'usa',
        'password'=>'canada',
        'keyword'=>'Temp'
        )); 
        print\_r($response);
        
        A Offline
        A Offline
        AndreasJ8
        wrote on last edited by
        #3

        echo " <TABLE>";
        forEach ( $response as $ind=$val ) {
        #
        # vers.1
        echo "<tr>...." .$ind."....." .$val ;
        # ver.2
        sprintf ( .... ) ;
        }

        about SPRINTF() you will find here http://ru2.php.net/manual/en/function.sprintf.php[^]

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups