Jump to content

Recommended Posts

look:

 

$result = mysql_query("SELECT donorlevel, id, name, desktop FROM ibf_members  ORDER BY donorlevel DESC LIMIT 5;")

 

 

and my html code is:

 

 

$id = "<a href='forums/index.php?showuser={$row['id']}'>{$row['name']}$lol</a>";

 

 

ok so i need a php code that does 1) 2) 3) 4) for each LIMIT XX I DO, and put's it next to the $id,

 

thx

 

Link to comment
https://forums.phpfreaks.com/topic/148718-how-do-i-order-numbers-on-result/
Share on other sites

Show your new knowledge as a proper example, nice to here it mate!

 

$counter = $counter + 1; << increment by 1 it means.

 

++$counter; <<< same result i guess.

 

look at this to brain kill ya.

 

<?php

$redarrow=1;

$redarrow=$redarrow+1;

echo $redarrow;

?>

 

<?php

$redarrow=1;

++$redarrow;

echo $redarrow;

?>

look at this it crazy but it works in the correct way.

<?php

$array=array("a","b","c","d");

$num=0;

echo $array[$num];

echo $array[++$num];

echo $array[++$num];

echo $array[++$num];

?>

 

result.

abcd

 

understandable way.

<?php

$array=array("a","b","c","d");

echo $array[0];

echo $array[+1];

echo $array[+2];

echo $array[+3];

?>

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.