Two ways to display horizontal repeating areas in php_PHP tutorial
WBOYOriginal
2016-07-21 15:49:31949browse
Method 1. Note that there is a predefined picture record set rsmpic. The pictures to be repeated horizontally are pictures. Please change the name of your record set according to your situation. Neatly put the horizontally repeated content in a table < table width="100" border="0" align="center" cellpadding="5" cellspacing="5"> $numberColumns = '3'; $numrows = '3'; while(($numrows <> 0) AND (! $rsmpic->EOF)) { $startrw = $endrw + 1; $endrw = $endrw + $numberColumns;?>
< ?PHP While (($startrw <= $endrw) AND (!$rsmpic->EOF)) { //Start repeating content?>
Wend; } Method 2. Drag the repeat mark outside the
(vertical repetition is outside the
), and add a variable, Add 1 for each repetition, if %3 is equal to 0 echo a "
" . Please look carefully
.
"; ?>
http://www.bkjia.com/PHPjc/319540.htmlwww.bkjia.comtruehttp: //www.bkjia.com/PHPjc/319540.htmlTechArticleMethod 1. Note that there is a predefined picture record set rsmpic. The pictures you want to repeat horizontally are the pictures. Please follow your Change the situation to your recordset name. Neatly place the horizontal repeating content...
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn