Deleting from a Database via PHP

5 posts Page 1 of 1
Contributors
User avatar
Gameboy
New Member
New Member
Posts: 12
Joined: Sat Apr 18, 2015 10:42 pm

Deleting from a Database via PHP
Gameboy
Hello everyone,

I am currently developing a YouTube Partner Dashboard system and I am revamping my old network manager/admin page and am trying to make a new user level in MySQL. To do this, I need to be able to delete a user from the admin level on my dashboard. I was wondering what code I'd be needing to delete a row in MYSQL via PHP on a secure Hypertext Protocool connection.

Thanks!
User avatar
CodenStuff
Site Admin
Site Admin
Posts: 4389
Joined: Tue Aug 04, 2009 1:47 am

Not sure about this one.

Typically to delete an entry you would use a command such as:
Code: Select all
"DELETE FROM Users WHERE theusersid=78"
Welcome to CodenStuff.com Learn Code, Love Code. Thank you for being a member of the community.
User avatar
Gameboy
New Member
New Member
Posts: 12
Joined: Sat Apr 18, 2015 10:42 pm

CodenStuff wrote:
Not sure about this one.

Typically to delete an entry you would use a command such as:
Code: Select all
"DELETE FROM Users WHERE theusersid=78"
This may work, I have a complex database with over 30 columns :)
User avatar
visualtech
VIP - Donator
VIP - Donator
Posts: 265
Joined: Sat Nov 19, 2011 2:19 pm

For starters, HTTP/S shouldn't really matter. It's just a security protocol for transferring data from the browser to the server. Now, if you're using secure MySQL instances using ECC or TLS (yeah, they have that for MySQL as well), then you might want to tell us a little bit more about it.

Secondly, consider Database Normalisation. If you have 30 columns, there is a high chance that you aren't doing something the way you were supposed to.

And yeah, Cody's reply is perfect. That's the way to go! :)
Image
User avatar
Gameboy
New Member
New Member
Posts: 12
Joined: Sat Apr 18, 2015 10:42 pm

visualtech wrote:
For starters, HTTP/S shouldn't really matter. It's just a security protocol for transferring data from the browser to the server. Now, if you're using secure MySQL instances using ECC or TLS (yeah, they have that for MySQL as well), then you might want to tell us a little bit more about it.

Secondly, consider Database Normalisation. If you have 30 columns, there is a high chance that you aren't doing something the way you were supposed to.

And yeah, Cody's reply is perfect. That's the way to go! :)
Alright, thank you very much @visualtech, highly appreciated. I have my databases setup correctly, it is just that I have so many added on additions for the YouTube API that it becomes almost confusing!
5 posts Page 1 of 1
Return to “Help & Support”