is it possible to execute multiple commands with exec(), passthru() or system() ? I wish to open a mysql connections and return the output of 'show databases;' etc. In my mind you need at least 2 commands to do this. using passthru() to connect and another passthru to query fails.

anyone have a solution to this?

thanks in advance.

    you can use whatever you can do directly at the console prompt
    like "ls -l; df -k" so divide with semi-colons
    but I don't understand why you don't use the PHP-internal functions for that? (mysql_list_dbs())

      Write a Reply...