Hoe kan ik bv. 1.000.000 krijgen

Gestart doorBoude24 reacties34 weergaven

25 berichten · pagina 1 van 2

Boude

Lid · Topicstarter

Berichten
2.837
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
In me databese staat 1000000 maar ik wil op me site 1.000.000 laten zien net al 5.000 zegmaar 3 cijfers dus een punt.. hoe kan ik dat doen?
0
Berichten
18.482
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
number_format
0
Boude

Lid · Topicstarter

Berichten
2.837
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Bedankt luuk biggrin
0
Berichten
18.482
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Graag gedaan biggrin
0
Boude

Lid · Topicstarter

Berichten
2.837
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Ik heb nog een vraagje yummie
ik heb dit:

[COLOR= #0000BB]<?php
            $query[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$mysql_query[/COLOR][COLOR= #007700]([/COLOR][COLOR= #DD0000]"
                        SELECT 
                            name,
                            rang,
                            tanks,
                            exp,
                            betaald,
                            groep,
                            col, 
                            gevangen,
                            bank,
                            geld
                        FROM
                            accounts
                        WHERE
                            id = "[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]id[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]"
                        "[/COLOR][COLOR= #007700]);[/COLOR]
            [COLOR= #0000BB]$fetch[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$mysql_fetch_assoc[/COLOR][COLOR= #007700]([/COLOR][COLOR= #0000BB]$query[/COLOR][COLOR= #007700]);[/COLOR]
            
            [COLOR= #0000BB]$query2[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$mysql_query[/COLOR][COLOR= #007700]([/COLOR][COLOR= #DD0000]"
                        SELECT
                            name
                        FROM
                            clan_groep
                        WHERE 
                            groep = "[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$fetch[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]groep[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]"
                        "[/COLOR][COLOR= #007700]);[/COLOR]
            [COLOR= #0000BB]$fetch2[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$mysql_fetch_assoc[/COLOR][COLOR= #007700]([/COLOR][COLOR= #0000BB]$query2[/COLOR][COLOR= #007700]);[/COLOR]
            ?>


Maar dat moet volgens mij korter kunnen ik wil daarna dit wel gebruiken:

[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #007700]([/COLOR][COLOR= #0000BB]$fetch[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]groep[/COLOR][COLOR= #007700]] ==[/COLOR] [COLOR= #0000BB]0[/COLOR] [COLOR= #007700]?[/COLOR] [COLOR= #DD0000]Geen[/COLOR] [COLOR= #007700]:[/COLOR] [COLOR= #0000BB]$fetch2[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]name[/COLOR][COLOR= #007700]]);[/COLOR] ?>
0
Berichten
1.168
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Je kan ipv. alles neerzetten,(name, tanks enz.) gewoon * neerzetten. Dan wordt alles geselecteerd
0
Erik

Lid

Berichten
7.109
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Dat is nou echt baaad, als je maar één kolom hoeft te selecteren is * echt sirieus onnodig.
0
Boude

Lid · Topicstarter

Berichten
2.837
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Andy dat vind ik ook!

Ik heb niet alle kolomen nodig het zijn er een hoop. En als je dat wel doet krijg je veel meer load.
0
Berichten
1.168
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
@Erik en Boude: Dat weet ik, maar ik dacht dat de eerste query in het script alle cols had, dus dan kan je het verkorten door er een * neer te zetten. Maar als je maar een paar cols nodig hebt, zou ik ze ook per naam neerzetten.
0
Boude

Lid · Topicstarter

Berichten
2.837
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Oke sorry voor het misverstandje wink..

Maar weet iemand daar een oplossing voor? Of niet anders laat ik het zo..

Verder weet iemand een snellere manier als:

[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/header"]header[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"refresh: 0; url=http://one2xs.com"[/COLOR][COLOR= #007700]);[/COLOR] ?>
0
Berichten
1.168
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
van refresh: 0; dit maken: Location:
En url= weglaten.
0
Berichten
93.699
Reputatie
0
Punten
1,27
Lid sinds
Laatst gezien
[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/header"]header[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"location: http://one2xs.com"[/COLOR][COLOR= #007700]);[/COLOR] ?>


dit duswink
0
Berichten
1.168
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Je, had ff geen zin om het zo neer te zetten, want zat op de pc.
0
Berichten
18.482
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
[COLOR= #0000BB]<?php
            $query[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$mysql_query[/COLOR][COLOR= #007700]([/COLOR][COLOR= #DD0000]"
                        SELECT 
                            name,
                            rang,
                            tanks,
                            exp,
                            betaald,
                            groep,
                            col, 
                            gevangen,
                            bank,
                            geld,
                            (
                                SELECT
                                    name
                                FROM
                                    clan_groep
                                WHERE 
                                    groep = a.groep
                            ) clan
                        FROM
                            accounts a
                        WHERE
                            id = "[/COLOR][COLOR= #007700].[/COLOR] [COLOR= #0000BB]$_SESSION[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]id[/COLOR][COLOR= #007700]] .[/COLOR][COLOR= #DD0000]"
                        "[/COLOR][COLOR= #007700]);[/COLOR]
            [COLOR= #0000BB]$fetch[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$mysql_fetch_assoc[/COLOR][COLOR= #007700]([/COLOR][COLOR= #0000BB]$query[/COLOR][COLOR= #007700]);[/COLOR]
            ?>


Dan moet je dit gebruiken

[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] [URL="http://www.php.net/is_null"]is_null[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$fetch[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]clan[/COLOR][COLOR= #007700]]) ?[/COLOR] [COLOR= #DD0000]Geen[/COLOR] [COLOR= #007700]:[/COLOR] [COLOR= #0000BB]$fetch2[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]clan[/COLOR][COLOR= #007700]];[/COLOR] ?>
0
Erik

Lid

Berichten
7.109
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
@ Luuk; Correctie:

[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] [URL="http://www.php.net/is_null"]is_null[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$fetch[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]clan[/COLOR][COLOR= #007700]]) ?[/COLOR] [COLOR= #DD0000]Geen[/COLOR] [COLOR= #007700]:[/COLOR] [COLOR= #0000BB]$fetch[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]clan[/COLOR][COLOR= #007700]];[/COLOR] ?>
0

Jouw reactie

Deel je idee, stel een vraag of help een ander verder.

Editor laden…

Praat mee met de One2xs-community.

Inloggen om te reageren