[Help] Updating Bot Items

JayC

Always Learning
Aug 8, 2013
5,504
1,401
UberCMS Code:

Code:
<select name="which_one">
                                                        <?php
                                                        $getBotName = mysql_query('SELECT id FROM bots WHERE owner = "'.USER_NAME.'"');
                                                        $getResponse = mysql_query('SELECT id,keyword,serve_id FROM bots_responses WHERE bot_id = ".$getBotName."');
                                                     
                                                        while($botRes = mysql_fetch_array($getResponse)){
                                                            echo '<option value="';
                                                            echo $botRes['id'];
                                                            echo '">';
                                                            echo $botRes['keyword'];
                                                            echo ' - ';
                                                            echo $botRes['serve_id'];
                                                            echo '<br /></option>';
                                                        }
                                                        ?>
                                                        </select><br /><br />
What I want it to do is to run the get bot name to get the ID of the bot and then any bots with that ID it will display all the responses for id, keyword + serve_id but its not working xD this is what it looks like:
dnDxexd.png
 

Users who are viewing this thread

Top