[wp-hackers] Creating / Inserting into Table named after WP Username

Chris McCoy chris at lod.com
Sat Aug 24 23:25:45 UTC 2013


did you add the global $current_user;
?


On 2013-08-24 7:22 PM, "BenderisGreat" <greglancaster71 at gmail.com> wrote:

>I am playing with something, and need a snippet of code. I am trying to
>have
>a php form submit data into a table, a table with the same name as the
>current user.  Can someone help me out and share the call for this?
>
>This code works to call information from the database;
>
>  <?php $result = mysql_query("SELECT * FROM $current_user->user_login",
>$connection);
>
>
>But in the submit.php, it does not work in the INSERT INTO $current_user
>etc...   
>
>
>
>--
>View this message in context:
>http://wordpress-hackers.1065353.n5.nabble.com/Creating-Inserting-into-Tab
>le-named-after-WP-Username-tp42095.html
>Sent from the Wordpress Hackers mailing list archive at Nabble.com.
>_______________________________________________
>wp-hackers mailing list
>wp-hackers at lists.automattic.com
>http://lists.automattic.com/mailman/listinfo/wp-hackers




More information about the wp-hackers mailing list