Find Jobs
Hire Freelancers

Another quick fix needed

$10-30 USD

En curso
Publicado hace alrededor de 10 años

$10-30 USD

Pagado a la entrega
The PHP Code below is getting information from the database. The database at this point has 7 rows but the file for some reason only gets the last five and does not start at 1. It should display the first 5 lines from the database and then the next two once I click on "Weiter". As there could be a larger number than 7 rows in the database it needs to adjust to it. So if there are 14 lines it would display the 5 newest, than the next 5 and then the oldest 4 etc. Do not bid more than 10 Dollars as this should be an easy fix for someone who knows what they are doing. If you place a bid I assume you have no questions and you are clear with the demands. <?php $result = mysql_query("SELECT UserID,Datum,Headline,Meldung,IconID FROM tippliga_news ORDER BY Datum DESC;"); $treffer = mysql_num_rows($result); echo "<br><br>\n"; if (!isset($start)) { $start = 0; } $anfang = $start+1; $ende = $start+5; if ($treffer<$ende) { $ende=$treffer; } echo "<strong class='innertxt'>News Archiv ...<br>Nachricht $anfang bis $ende von $treffer</strong><br>\n"; $neu = $start - 5; if ($neu >= 0) { echo "<a href=\"[login to view URL]".$neu."\" target=\"_self\">Zur&uuml;ck</a>\n"; if ($start+6 < $treffer) { echo " - "; } } $neu = $start + 5; if ($neu<$treffer) { echo "<a href=\"[login to view URL]".$neu."\" target=\"_self\">Weiter</a>\n"; } echo "<br><br>\n"; for ($i=$start; $i<$start+5; $i++) { $ii = $i; if ($i>=$treffer) { break; } $e1 = mysql_result($result,$ii,"Headline"); $e2 = mysql_result($result,$ii,"Meldung"); $d = mysql_result($result,$ii,"Datum"); $iconid = mysql_result($result,$ii,"IconID"); $icon = mysql_query("SELECT Datei from tippliga_icons Where IconID='$iconid';"); $iconurl = mysql_result($icon,0,"Datei"); $userid = mysql_result($result,$ii,"UserID"); $u = mysql_query("SELECT user from tippliga_user Where UserID='$userid';"); $user = mysql_result($u,0,"user"); $d_neu = strftime("%H:%M:%S - %d.%m.%Y",strtotime($d)); echo "<span class='innertxt'><img src=\"$iconurl\"><b><i> $e1 </b></i> - von $user ($d_neu)</span><br></i>\n"; echo "<span class='innertxt'>$e2</span>\n\n"; if ($i+1 < $start+5) { echo "<br><br>\n"; } } ?>
ID del proyecto: 5770516

Información sobre el proyecto

2 propuestas
Proyecto remoto
Activo hace 10 años

¿Buscas ganar dinero?

Beneficios de presentar ofertas en Freelancer

Fija tu plazo y presupuesto
Cobra por tu trabajo
Describe tu propuesta
Es gratis registrarse y presentar ofertas en los trabajos

Sobre este cliente

Bandera de UNITED STATES
Seabeck, United States
5,0
420
Forma de pago verificada
Miembro desde nov 14, 2009

Verificación del cliente

¡Gracias! Te hemos enviado un enlace para reclamar tu crédito gratuito.
Algo salió mal al enviar tu correo electrónico. Por favor, intenta de nuevo.
Usuarios registrados Total de empleos publicados
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Cargando visualización previa
Permiso concedido para Geolocalización.
Tu sesión de acceso ha expirado y has sido desconectado. Por favor, inica sesión nuevamente.