[Tutorial] Creating dynamic signatures using PHP and MySQL.
#6

Quote:
Originally Posted by xantowskii
Посмотреть сообщение
PHP код:
$query="SELECT * FROM users WHERE Playername='$player_name'"
Shouldn't it be

PHP код:
$query="SELECT * FROM users WHERE Playername='$player_name' LIMIT 1"
I suggest you to read whats "LIMIT 1" used for since for a while everyone here tends to reply saying it will freeze your server/host if you dont use it, when it doesnt happen and depends on the query you are executing, use a bit of common sense and re read the query again.

Select all from the table 'users' where the field 'Playername' equals to (your user name).

Now try to register the same name two or more times, i dont think so there would be two rows with the same name.

Use limit 1 if, for example, you are selecting the ammount of posts, probably 100 guys with the same post count decide to call that query at the same time, usually happens ; ) or it doesnt?.
Reply


Messages In This Thread
Creating dynamic signatures using PHP and MySQL. - by Nodroz - 04.12.2011, 10:53
Re: Creating dynamic signatures using PHP and MySQL. - by Ash. - 04.12.2011, 10:54
Re: Creating dynamic signatures using PHP and MySQL. - by xantowskii - 04.12.2011, 15:27
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 04.12.2011, 15:42
Re: Creating dynamic signatures using PHP and MySQL. - by Unknown123 - 04.12.2011, 21:27
Respuesta: Re: Creating dynamic signatures using PHP and MySQL. - by kirk - 04.12.2011, 22:08
Re: Respuesta: Re: Creating dynamic signatures using PHP and MySQL. - by xantowskii - 05.12.2011, 06:02
Re: Creating dynamic signatures using PHP and MySQL. - by Hiddos - 05.12.2011, 06:40
Re: Creating dynamic signatures using PHP and MySQL. - by [HiC]TheKiller - 05.12.2011, 06:49
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 05.12.2011, 15:17
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 05.12.2011, 15:39
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 05.12.2011, 16:00
Re: Creating dynamic signatures using PHP and MySQL. - by Speed - 05.12.2011, 16:03
Re: Creating dynamic signatures using PHP and MySQL. - by System64 - 06.12.2011, 11:14
Re: Creating dynamic signatures using PHP and MySQL. - by Biesmen - 06.12.2011, 12:52
Re: Creating dynamic signatures using PHP and MySQL. - by Speed - 06.12.2011, 12:52
Re: Creating dynamic signatures using PHP and MySQL. - by No Fear - 06.12.2011, 12:54
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 06.12.2011, 15:08
Re: Creating dynamic signatures using PHP and MySQL. - by Unknown123 - 06.12.2011, 16:31
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 06.12.2011, 17:05
Re: Creating dynamic signatures using PHP and MySQL. - by Unknown123 - 06.12.2011, 17:50
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 06.12.2011, 19:02
Re: Creating dynamic signatures using PHP and MySQL. - by Unknown123 - 06.12.2011, 21:52
Re: Creating dynamic signatures using PHP and MySQL. - by Djankaa - 06.12.2011, 21:53
Re: Creating dynamic signatures using PHP and MySQL. - by Biesmen - 07.12.2011, 08:22
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 07.12.2011, 11:37
Re: Creating dynamic signatures using PHP and MySQL. - by #marcus. - 07.12.2011, 13:42
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 09.12.2011, 17:55
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 10.12.2011, 09:15
Re: Creating dynamic signatures using PHP and MySQL. - by Zonoya - 10.12.2011, 09:22
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 10.12.2011, 09:23
Re: Creating dynamic signatures using PHP and MySQL. - by Hiddos - 10.12.2011, 09:32
Re: Creating dynamic signatures using PHP and MySQL. - by Zonoya - 10.12.2011, 10:57
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 10.12.2011, 16:49
Re: Creating dynamic signatures using PHP and MySQL. - by Zonoya - 10.12.2011, 18:25
Re: Creating dynamic signatures using PHP and MySQL. - by Zonoya - 11.12.2011, 07:56
Re: Creating dynamic signatures using PHP and MySQL. - by XFlawless - 11.12.2011, 08:17
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 11.12.2011, 08:31
Re: Creating dynamic signatures using PHP and MySQL. - by gamer931215 - 12.12.2011, 09:57
Re: Creating dynamic signatures using PHP and MySQL. - by TheArcher - 12.12.2011, 15:26
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 12.12.2011, 16:10
Re: Creating dynamic signatures using PHP and MySQL. - by royal_king - 17.12.2011, 11:04
Re: Creating dynamic signatures using PHP and MySQL. - by Niko_boy - 19.12.2011, 15:46
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 19.12.2011, 15:48
Re: Creating dynamic signatures using PHP and MySQL. - by Niko_boy - 19.12.2011, 16:03
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 19.12.2011, 16:06
Re: Creating dynamic signatures using PHP and MySQL. - by TheArcher - 19.12.2011, 16:07
Re: Creating dynamic signatures using PHP and MySQL. - by Niko_boy - 19.12.2011, 16:12
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 19.12.2011, 18:09
Re: Creating dynamic signatures using PHP and MySQL. - by Niko_boy - 20.12.2011, 09:04
Re: Creating dynamic signatures using PHP and MySQL. - by GangsTa_ - 20.12.2011, 11:40
Re: Creating dynamic signatures using PHP and MySQL. - by §с†¶e®РµРe - 20.12.2011, 14:05
Re: Creating dynamic signatures using PHP and MySQL. - by System64 - 20.12.2011, 18:12
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 20.12.2011, 18:52
Re: Creating dynamic signatures using PHP and MySQL. - by System64 - 20.12.2011, 19:07
Re: Creating dynamic signatures using PHP and MySQL. - by Niko_boy - 21.12.2011, 08:31
Re: Creating dynamic signatures using PHP and MySQL. - by Nodroz - 21.12.2011, 09:32
Re: Creating dynamic signatures using PHP and MySQL. - by Britas - 21.12.2011, 16:39
Re: Creating dynamic signatures using PHP and MySQL. - by Riddy - 31.12.2011, 16:19
Re: Creating dynamic signatures using PHP and MySQL. - by aleck - 15.09.2012, 11:58
Re: Creating dynamic signatures using PHP and MySQL. - by aleck - 20.09.2012, 04:14
Re: Creating dynamic signatures using PHP and MySQL. - by Jesakos - 01.01.2013, 23:24
Re: Creating dynamic signatures using PHP and MySQL. - by Isolated - 08.04.2013, 15:12
Re: Creating dynamic signatures using PHP and MySQL. - by Isolated - 08.04.2013, 15:57
Re: Creating dynamic signatures using PHP and MySQL. - by FunnyBear - 09.04.2013, 11:08
Re: Creating dynamic signatures using PHP and MySQL. - by ReneG - 10.04.2013, 01:57
Re: Creating dynamic signatures using PHP and MySQL. - by FunnyBear - 10.04.2013, 08:54
Re: Creating dynamic signatures using PHP and MySQL. - by FunnyBear - 10.04.2013, 08:59
Re: Creating dynamic signatures using PHP and MySQL. - by Ash. - 10.04.2013, 09:13
Re: Creating dynamic signatures using PHP and MySQL. - by Ash. - 10.04.2013, 13:31
Re: Creating dynamic signatures using PHP and MySQL. - by DRUNKY - 10.06.2013, 18:22
Re: Creating dynamic signatures using PHP and MySQL. - by AiRaLoKa - 25.12.2013, 05:58
Re: Creating dynamic signatures using PHP and MySQL. - by Vasco2305 - 12.01.2014, 14:14
Re: Creating dynamic signatures using PHP and MySQL. - by TheBosss - 15.01.2014, 15:05
Re: Creating dynamic signatures using PHP and MySQL. - by TheFlyer - 16.03.2014, 16:23
Re: Creating dynamic signatures using PHP and MySQL. - by Niko_boy - 16.03.2014, 19:23
Re: Creating dynamic signatures using PHP and MySQL. - by mrsh - 18.03.2014, 14:10
Re: Creating dynamic signatures using PHP and MySQL. - by TheFlyer - 24.03.2014, 19:02
Re: Creating dynamic signatures using PHP and MySQL. - by khalildz - 18.07.2014, 18:31
Re: Creating dynamic signatures using PHP and MySQL. - by AroseKhanNiazi - 07.01.2015, 12:44

Forum Jump:


Users browsing this thread: 14 Guest(s)