--- In [email protected], "Muthukumar Selvarasu"
<[EMAIL PROTECTED]> wrote:
>
> Please remember to write your response BELOW the previous text. 
>  
> From: [email protected] [mailto:[EMAIL PROTECTED] On
Behalf
> Of Joseph
> Sent: Wednesday, April 02, 2008 5:47 AM
> To: [email protected]
> Subject: [php-list] How Do You Increment Numbers in Steps
>  
> Hi all
> 
> I am trying create a table on the fly, to display unicode characters
> and I want that every thirty table cells to insert a table header cell
> so that when a user scrolls down the page they can always see a header
> every so often.
> 
> Can anyone point me to a good mathematics tutorial for PHP please?
> 
> Joseph 
> 
> ------------------------------------
> 
> Hi
>  
> I hope you using while / for loop to show the list of records.
>  
> Add condition inside the loop
>  
> While ....
> {
> $inc ++;
> If($inc % 30 ==0) echo "Your header row code";
> }
>  
>  
> Thanks,
> Muthukumar Selvarasu,
> Project Manager (Web Development),
> Webmasters Ltd.
>
------------------------------------
Hi All

Thank you all for your suggestions, was very helpful advice.

I finally managed to do this, thanks Muthukumar & James.

In case anyone needs a list of unicode numbers close at hand, here is
my new working script (with the headers in the appropriate places).

====================
<?php
        $ystr1 = "\n<tr>\n<td width=\"35\" class=\"ybig\">&nbsp;\n</td>\n<td
width=\"15\"><strong>";
        $ystr2 = ";</strong>\n</td>\n";
        $ystr3 = "<td width=\"15\">\n<strong>&amp;#";
        $ystr4 = "</td>\n<td width=\"35\">&nbsp;\n</td>\n</tr>\n";

        //      set variables for our maths
        
//-----------------------------------------------------------------------------
        //      max limit for our unicode characters
        $ystart = 1;
        While ($ystart <= 3000)
        {
                        echo $ystr1.'&#'.$ystart.$ystr2;
                        echo $ystr3.$ystart.$ystr4;
        If($ystart % 20 ==0)
                        echo "<tr><th colspan=\"2\">Character</th><th
colspan=\"2\">Unicode</th></tr>";
                        $ystart++;
        }
        echo "</table></center>";
?>
=========================

Once again, many thanks folks.

Joseph

Reply via email to