why wont this register a user?
BTW i know this method isnt safe, this is just a test program
https://pastebin.com/tZxQJpVK
BTW i know this method isnt safe, this is just a test program
https://pastebin.com/tZxQJpVK
|
C#
why wont my program register users? MYSQL |
|
why wont this register a user?
BTW i know this method isnt safe, this is just a test program https://pastebin.com/tZxQJpVK
Sep 26, 2017 03:45 AM
(This post was last modified: Sep 26, 2017 03:46 AM by Ninja.)
Are you getting any errors? Did you try debugging to see if the code you want gets executed (correctly)? Did you catching and displaying the exception that got thrown?
(Sep 26, 2017 03:45 AM)Ninja Wrote: Are you getting any errors? Did you try debugging to see if the code you want gets executed (correctly)? Did you catching and displaying the exception that got thrown? No, he's just putting this "Exception ex" without using it. Op, try to debug it and edit the post with errors.
Sep 27, 2017 02:21 PM
(This post was last modified: Sep 27, 2017 02:22 PM by Siy.)
First of all it is 'INSERT' and not 'INSTERT'.
If you're using XAMPP/WAMP i think the server should be 'localhost' instead of '127.0.0.1' (dont quote me on this one) and since you're not inserting anything into 'id' anways you can just skip that in your query and use: Code $"INSERT INTO `users` (`naam`, `password`) VALUES ('{user}', '{pass}');"if you think there is a problem with your query do the following: Go to PHPMYADMIN -> select your database -> select your table -> click the [SQL] button -> click the [INSERT] button. A query will be generated. Copy and use that. |
|
|
| Possibly Related Threads... | |||
| Thread / Author | Replies | Views | Last Post |
| [.NET] by FooterAug 17, 2019 12:02 PM | 5 | 232 |
Aug 17, 2019 12:02 PM Last Post: Fhack |
| [Python] by SilentDec 11, 2016 12:51 PM | 3 | 178 |
Dec 11, 2016 12:51 PM Last Post: Silent |
| [Shell] by Mr KakeFeb 4, 2016 10:33 AM | 8 | 243 |
Feb 4, 2016 10:33 AM Last Post: jahwi |