Solo usuarios registrados pueden comentar y agradecer, Logueate o Registrate

Autor Topic: modulo de ranking de renas en html  (Visto 2013 veces)

0 Miembros and 1 Guest are viewing this topic.

Offline punkjaja Posteado: July 13, 2019, 06:43:40 PM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 282
  • Gracias recibida: 303
  • cl
buenas tengo una web de mu en html y nose como ponerlo todo aqui es basado a mucore

          <td><table align="center" bgcolor="#333333" border="1" cellpadding="1" cellspacing="0" width="590">
              <tbody>
                <td colspan="4" align="right" height="19"><span class="style11"><strong>Salon de la Fama  - Mu Xtreme</strong></span></td>
           
              <tr class="style12" align="center">
                <td align="center" class="rounded"><font color="black">#</font></td>
                <td width="74" align="center" bgcolor="#395142" ><span class="style11">Personajes</span></td>
                <td align="center" height="5" bgcolor="#395142" width="74"><span class="style11">Renas registradas</span></td>
              </tr>
<?

$query=mssql_query("select TOP 50 AccountID,EventChips from MuOnline.dbo.T_MU2003_EVENT where EventChips>0  order by EventChips desc");

aqui me quedo y no funciona alguna ayuda porfavro


Offline Yalc #1 Posteado: July 13, 2019, 08:03:07 PM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 230
  • Gracias recibida: 6001
  • ve
@punkjaja guíate con esto


aclaro que todavía faltan cosas, por eso guíate para que lo termines

No puedo afirmar si esta mala o no la consulta porque no se como es tu base de datos, pero viéndola me parece que esta mal formulada

"select TOP 5 AccountID,EventChips from MuOnline.dbo.T_MU2003_EVENT where EventChips>0  order by EventChips desc"

Code: [Select]

<?php

$Top_renas = $core_db->("select TOP 5 AccountID,EventChips from MuOnline.dbo.T_MU2003_EVENT where EventChips>0  order by EventChips desc");

$Count=0;
while (!$Top_renas->EOF) {
$Count++;

          <td><table align="center" bgcolor="#333333" border="1" cellpadding="1" cellspacing="0" width="590">
              <tbody>
                <td colspan="4" align="right" height="19"><span class="style11"><strong>Salon de la Fama  - Mu Xtreme</strong></span></td>
           
              <tr class="style12" align="center">
                <td align="center" class="rounded"><font color="black">#</font></td>
                <td width="74" align="center" bgcolor="#395142" ><span class="style11">Personajes</span></td>
                <td align="center" height="5" bgcolor="#395142" width="74"><span class="style11">Renas registradas</span></td>
              </tr>

$Top_renas->MoveNext();
}
?>


Offline punkjaja #2 Posteado: July 13, 2019, 08:38:00 PM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 282
  • Gracias recibida: 303
  • cl
@punkjaja guíate con esto


aclaro que todavía faltan cosas, por eso guíate para que lo termines

No puedo afirmar si esta mala o no la consulta porque no se como es tu base de datos, pero viéndola me parece que esta mal formulada

"select TOP 5 AccountID,EventChips from MuOnline.dbo.T_MU2003_EVENT where EventChips>0  order by EventChips desc"

Code: [Select]

<?php

$Top_renas = $core_db->("select TOP 5 AccountID,EventChips from MuOnline.dbo.T_MU2003_EVENT where EventChips>0  order by EventChips desc");

$Count=0;
while (!$Top_renas->EOF) {
$Count++;

          <td><table align="center" bgcolor="#333333" border="1" cellpadding="1" cellspacing="0" width="590">
              <tbody>
                <td colspan="4" align="right" height="19"><span class="style11"><strong>Salon de la Fama  - Mu Xtreme</strong></span></td>
           
              <tr class="style12" align="center">
                <td align="center" class="rounded"><font color="black">#</font></td>
                <td width="74" align="center" bgcolor="#395142" ><span class="style11">Personajes</span></td>
                <td align="center" height="5" bgcolor="#395142" width="74"><span class="style11">Renas registradas</span></td>
              </tr>

$Top_renas->MoveNext();
}
?>

sin exito :(  algo mas le falta uso files darksteam 1.0 con su db original de los files


Offline Yalc #3 Posteado: July 13, 2019, 08:45:55 PM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 230
  • Gracias recibida: 6001
  • ve
@punkjaja pasarme la DB para ver que puedo hacer, una que no tenga datos privados de tu server


Offline thejonyx #4 Posteado: July 13, 2019, 09:39:40 PM

  • Php Coder
  • 0 puntos por ventas
  • *
  • Rank: Experto
  • Posts: 155
  • Gracias recibida: 1999
  • ve
es bueno q tengas claro como separar el codigo html del codigo de php, ademas veo q en la query en el FROM estas colocando la base de datos y tiene q ser la tabla q tiene los datos. como dice el comentario anterior si aportas la base de datos q usas se puede hacer la query correcta para el ranking de renas.
Code: [Select]
<table align="center" bgcolor="#333333" border="1" cellpadding="1" cellspacing="0" width="590">
    <tbody>
        <td colspan="4" align="right" height="19"><span class="style11"><strong>Salon de la Fama  - Mu Xtreme</strong></span></td>
           
        <tr class="style12" align="center">
            <td align="center" class="rounded"><font color="black">#</font></td>
            <td width="74" align="center" bgcolor="#395142" ><span class="style11">Personajes</span></td>
            <td align="center" height="5" bgcolor="#395142" width="74"><span class="style11">Renas registradas</span></td>
        </tr>

<?php
$Top_renas = $core_db->Execute("select TOP 5 AccountID,EventChips from MuOnline.dbo.T_MU2003_EVENT where EventChips>0  order by EventChips desc");
$Count=0;
while (!$Top_renas->EOF) {
$Count++;
echo'
    <tr class="style12" align="center">
            <td align="center" class="rounded"><font color="black">'.$Count.'</font></td>
            <td width="74" align="center" bgcolor="#395142" ><span class="style11">'.$Top_renas->fields[0].'</span></td>
            <td align="center" height="5" bgcolor="#395142" width="74"><span class="style11">'.$Top_renas->fields[1].'</span></td>
            </tr>';

$Top_renas->MoveNext();
}
?>

La vida seria mucho mas facil si pudieramos ver el codigo fuente.

Offline punkjaja #5 Posteado: July 13, 2019, 10:44:25 PM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 282
  • Gracias recibida: 303
  • cl
@punkjaja pasarme la DB para ver que puedo hacer, una que no tenga datos privados de tu server

alli lo tienes amigo

DB que uso


Offline punkjaja #6 Posteado: July 14, 2019, 07:37:02 PM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 282
  • Gracias recibida: 303
  • cl

Offline punkjaja #7 Posteado: July 15, 2019, 04:43:15 PM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 282
  • Gracias recibida: 303
  • cl

Offline Yalc #8 Posteado: July 15, 2019, 04:50:48 PM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 230
  • Gracias recibida: 6001
  • ve
@punkjaja a ver que puedo hacer, cualquier cosa te aviso


Offline Yalc #9 Posteado: July 15, 2019, 05:57:24 PM | Modificado: July 15, 2019, 10:47:33 PM by Yalc

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 230
  • Gracias recibida: 6001
  • ve
@punkjaja prueba con esto

Code: [Select]
<div>
<table align="center" bgcolor="#333333" border="1" cellpadding="1" cellspacing="0" width="590">
    <thead>
    <td colspan="4" align="right" height="19"><span class="style11"><strong>Salon de la Fama  - Mu Xtreme</strong></span></td>-->
    <tr>
      <th>#</th>
      <th>Nombre</th>
      <th>Renas</th>
    </tr>
    </thead>
    <tbody>
<?
$consulta = $core_db->Execute("select top 10 AccountID,EventChips from T_MU2003_EVENT where EventChips>0 order by EventChips desc");
$Count=0;
while (!$consulta->EOF) {
    $Count++;
    echo'
        <tr class="style12" align="center">
                <td align="center" class="rounded"><font color="black">'.$Count.'</font></td>
                <td width="74" align="center" bgcolor="#395142" ><span class="style11">'.$consulta->fields[0].'</span></td>
                <td align="center" height="5" bgcolor="#395142" width="74"><span class="style11">'.$consulta->fields[1].'</span></td>
            </tr>';

    $consulta->MoveNext();
}
?>
  </tbody>
  </table>
</div>


Offline punkjaja #10 Posteado: July 15, 2019, 10:13:02 PM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 282
  • Gracias recibida: 303
  • cl
@punkjaja prueba con esto

Spoiler for Hiden:
Code: [Select]
<div>
<table align="center" bgcolor="#333333" border="1" cellpadding="1" cellspacing="0" width="590">
    <thead>
    <td colspan="4" align="right" height="19"><span class="style11"><strong>Salon de la Fama  - Mu Xtreme</strong></span></td>-->
    <tr>
      <th>#</th>
      <th>Nombre</th>
      <th>Renas</th>
    </tr>
    </thead>
    <tbody>
<?
$consulta = $core_db->Execute("select top 10 AccountID,EventChips from T_MU2003_EVENT where EventChips>0 order by EventChips desc");
$Count=0;
while (!$consulta->EOF) {
    $Count++;
    echo'
        <tr class="style12" align="center">
                <td align="center" class="rounded"><font color="black">'.$Count.'</font></td>
                <td width="74" align="center" bgcolor="#395142" ><span class="style11">'.$consulta->fields[0].'</span></td>
                <td align="center" height="5" bgcolor="#395142" width="74"><span class="style11">'.$consulta->fields[1].'</span></td>
            </tr>';

    $consulta->MoveNext();
}
?>
  </tbody>
  </table>
</div>

http://mu-xtreme.ml/ranking-sum.asp miras esto me sale


Offline Yalc #11 Posteado: July 15, 2019, 11:09:24 PM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 230
  • Gracias recibida: 6001
  • ve
@punkjaja prueba con esto

Spoiler for Hiden:
Code: [Select]
<div>
<table align="center" bgcolor="#333333" border="1" cellpadding="1" cellspacing="0" width="590">
    <thead>
    <td colspan="4" align="right" height="19"><span class="style11"><strong>Salon de la Fama  - Mu Xtreme</strong></span></td>-->
    <tr>
      <th>#</th>
      <th>Nombre</th>
      <th>Renas</th>
    </tr>
    </thead>
    <tbody>
<?
$consulta = $core_db->Execute("select top 10 AccountID,EventChips from T_MU2003_EVENT where EventChips>0 order by EventChips desc");
$Count=0;
while (!$consulta->EOF) {
    $Count++;
    echo'
        <tr class="style12" align="center">
                <td align="center" class="rounded"><font color="black">'.$Count.'</font></td>
                <td width="74" align="center" bgcolor="#395142" ><span class="style11">'.$consulta->fields[0].'</span></td>
                <td align="center" height="5" bgcolor="#395142" width="74"><span class="style11">'.$consulta->fields[1].'</span></td>
            </tr>';

    $consulta->MoveNext();
}
?>
  </tbody>
  </table>
</div>

http://mu-xtreme.ml/ranking-sum.asp miras esto me sale

Prueba este sino sirve el otro. No me parece que estés usando mucore pero prueba
Code: [Select]
<div>
<table align="center" bgcolor="#333333" border="1" cellpadding="1" cellspacing="0" width="590">
    <thead>
    <td colspan="4" align="center" height="19"><span class="style11"><strong>Salon de la Fama  - Mu Xtreme</strong></span></td>
    <tr>
      <th>#</th>
      <th>Nombre</th>
      <th>Renas</th>
    </tr>
    </thead>
    <tbody>
<?
$renas = "select top 10 AccountID,EventChips from T_MU2003_EVENT where EventChips>0 order by EventChips desc";
$consulta = $core_db->Execute($renas);
$Count=0;
while (!$consulta->EOF) {
    $Count++;
    echo'
        <tr class="style12" align="center">
                <td align="center" class="rounded"><font color="black">'.$Count.'</font></td>
                <td width="74" align="center" bgcolor="#395142" ><span class="style11">'.$consulta->fields[0].'</span></td>
                <td align="center" height="5" bgcolor="#395142" width="74"><span class="style11">'.$consulta->fields[1].'</span></td>
            </tr>';

    $consulta->MoveNext();
}
?>
  </tbody>
  </table>
</div>

Code: [Select]
<div>
<table align="center" bgcolor="#333333" border="1" cellpadding="1" cellspacing="0" width="590">
    <thead>
    <td colspan="4" align="center" height="19"><span class="style11"><strong>Salon de la Fama  - Mu Xtreme</strong></span></td>
    <tr>
      <th>#</th>
      <th>Nombre</th>
      <th>Renas</th>
    </tr>
    </thead>
    <tbody>
<?
$renas = "select top 10 AccountID,EventChips from T_MU2003_EVENT where EventChips>0 order by EventChips desc";
$consulta = mssql_query($renas);
$Count=0;
while ($top_renas = mssql_fetch_assoc($consulta)) {
    $Count++;
    echo'
        <tr class="style12" align="center">
                <td align="center" class="rounded"><font color="black">'.$Count.'</font></td>
                <td width="74" align="center" bgcolor="#395142" ><span class="style11">'.$top_renas['AccountID'].'</span></td>
                <td align="center" height="5" bgcolor="#395142" width="74"><span class="style11">'.$top_renas['EventChips'].'</span></td>
            </tr>';
}
?>
  </tbody>
  </table>
</div>


Offline punkjaja #12 Posteado: July 15, 2019, 11:27:42 PM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 282
  • Gracias recibida: 303
  • cl
@punkjaja prueba con esto

Spoiler for Hiden:
Code: [Select]
<div>
<table align="center" bgcolor="#333333" border="1" cellpadding="1" cellspacing="0" width="590">
    <thead>
    <td colspan="4" align="right" height="19"><span class="style11"><strong>Salon de la Fama  - Mu Xtreme</strong></span></td>-->
    <tr>
      <th>#</th>
      <th>Nombre</th>
      <th>Renas</th>
    </tr>
    </thead>
    <tbody>
<?
$consulta = $core_db->Execute("select top 10 AccountID,EventChips from T_MU2003_EVENT where EventChips>0 order by EventChips desc");
$Count=0;
while (!$consulta->EOF) {
    $Count++;
    echo'
        <tr class="style12" align="center">
                <td align="center" class="rounded"><font color="black">'.$Count.'</font></td>
                <td width="74" align="center" bgcolor="#395142" ><span class="style11">'.$consulta->fields[0].'</span></td>
                <td align="center" height="5" bgcolor="#395142" width="74"><span class="style11">'.$consulta->fields[1].'</span></td>
            </tr>';

    $consulta->MoveNext();
}
?>
  </tbody>
  </table>
</div>

http://mu-xtreme.ml/ranking-sum.asp miras esto me sale

Prueba este sino sirve el otro. No me parece que estés usando mucore pero prueba
Code: [Select]
<div>
<table align="center" bgcolor="#333333" border="1" cellpadding="1" cellspacing="0" width="590">
    <thead>
    <td colspan="4" align="center" height="19"><span class="style11"><strong>Salon de la Fama  - Mu Xtreme</strong></span></td>
    <tr>
      <th>#</th>
      <th>Nombre</th>
      <th>Renas</th>
    </tr>
    </thead>
    <tbody>
<?
$renas = "select top 10 AccountID,EventChips from T_MU2003_EVENT where EventChips>0 order by EventChips desc";
$consulta = $core_db->Execute($renas);
$Count=0;
while (!$consulta->EOF) {
    $Count++;
    echo'
        <tr class="style12" align="center">
                <td align="center" class="rounded"><font color="black">'.$Count.'</font></td>
                <td width="74" align="center" bgcolor="#395142" ><span class="style11">'.$consulta->fields[0].'</span></td>
                <td align="center" height="5" bgcolor="#395142" width="74"><span class="style11">'.$consulta->fields[1].'</span></td>
            </tr>';

    $consulta->MoveNext();
}
?>
  </tbody>
  </table>
</div>

Code: [Select]
<div>
<table align="center" bgcolor="#333333" border="1" cellpadding="1" cellspacing="0" width="590">
    <thead>
    <td colspan="4" align="center" height="19"><span class="style11"><strong>Salon de la Fama  - Mu Xtreme</strong></span></td>
    <tr>
      <th>#</th>
      <th>Nombre</th>
      <th>Renas</th>
    </tr>
    </thead>
    <tbody>
<?
$renas = "select top 10 AccountID,EventChips from T_MU2003_EVENT where EventChips>0 order by EventChips desc";
$consulta = mssql_query($renas);
$Count=0;
while ($top_renas = mssql_fetch_assoc($consulta)) {
    $Count++;
    echo'
        <tr class="style12" align="center">
                <td align="center" class="rounded"><font color="black">'.$Count.'</font></td>
                <td width="74" align="center" bgcolor="#395142" ><span class="style11">'.$top_renas['AccountID'].'</span></td>
                <td align="center" height="5" bgcolor="#395142" width="74"><span class="style11">'.$top_renas['EventChips'].'</span></td>
            </tr>';
}
?>
  </tbody>
  </table>
</div>

juro que te amo funciono muchisimas gracias capo te pasaste


Offline Yalc #13 Posteado: July 15, 2019, 11:32:08 PM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 230
  • Gracias recibida: 6001
  • ve
@punkjaja una cosa te digo que veas, el nombre creo que aparece es de la cuenta creo y por seguridad debería ser el nombre del pj


Offline punkjaja #14 Posteado: July 15, 2019, 11:33:06 PM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 282
  • Gracias recibida: 303
  • cl
@punkjaja una cosa te digo que veas, el nombre creo que aparece es de la cuenta creo y por seguridad debería ser el nombre del pj

y como cambio eso


Offline Yalc #15 Posteado: July 15, 2019, 11:34:37 PM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 230
  • Gracias recibida: 6001
  • ve
@punkjaja una cosa te digo que veas, el nombre creo que aparece es de la cuenta creo y por seguridad debería ser el nombre del pj

y como cambio eso

cual de los dos códigos que te pase te funciono?


Offline punkjaja #16 Posteado: July 15, 2019, 11:36:51 PM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 282
  • Gracias recibida: 303
  • cl
@punkjaja una cosa te digo que veas, el nombre creo que aparece es de la cuenta creo y por seguridad debería ser el nombre del pj

y como cambio eso

cual de los dos códigos que te pase te funciono?
el segundo amigazo


Offline Yalc #17 Posteado: July 16, 2019, 12:52:20 AM

  • 0 puntos por ventas
  • *
  • Rank: Puto amo
  • Posts: 230
  • Gracias recibida: 6001
  • ve
@punkjaja una cosa te digo que veas, el nombre creo que aparece es de la cuenta creo y por seguridad debería ser el nombre del pj

y como cambio eso

cual de los dos códigos que te pase te funciono?
el segundo amigazo

Prueba a ver, sino sirve usa el anterior después con un poco de tiempo te ayudo

Code: [Select]
<div>
<table align="center" bgcolor="#333333" border="1" cellpadding="1" cellspacing="0" width="590">
    <thead>
    <td colspan="4" align="center" height="19"><span class="style11"><strong>Salon de la Fama  - Mu Xtreme</strong></span></td>
    <tr>
      <th>#</th>
      <th>Nombre</th>
      <th>Renas</th>
    </tr>
    </thead>
    <tbody>
<?
$renas = "select top 10 AccountID,EventChips from T_MU2003_EVENT where EventChips>0 order by EventChips desc";
$consulta = mssql_query($renas);
$top_renas = mssql_fetch_assoc($consulta);
$name = 'select top 10 Name from Character where AccountID = '.$top_renas['AccountID'].'';
$consulta2 = mssql_query($name);
$Count=0;
while ($top_renas && $names = mssql_fetch_assoc($consulta2)) {
    $Count++;
    echo'
        <tr class="style12" align="center">
                <td align="center" class="rounded"><font color="black">'.$Count.'</font></td>
                <td width="74" align="center" bgcolor="#395142" ><span class="style11">'.$names['Name'].'</span></td>
                <td align="center" height="5" bgcolor="#395142" width="74"><span class="style11">'.$top_renas['EventChips'].'</span></td>
            </tr>';
}
?>
  </tbody>
  </table>
</div>


Solo usuarios registrados pueden comentar y agradecer, Logueate o Registrate


 

Related Topics

  Subject / Started by Replies Last post
10 Replies
3415 Views
Last post August 05, 2020, 12:32:35 PM
by cepo
5 Replies
1117 Views
Last post September 20, 2018, 06:25:21 AM
by mardelmu
4 Replies
2256 Views
Last post June 26, 2020, 05:38:21 PM
by sentinel20
4 Replies
467 Views
Last post June 08, 2022, 01:02:08 PM
by 102pe
4 Replies
414 Views
Last post April 09, 2023, 03:29:33 PM
by ZabiinoOo