當前位置: 首頁>>代碼示例>>PHP>>正文


PHP toggleRowClass函數代碼示例

本文整理匯總了PHP中toggleRowClass函數的典型用法代碼示例。如果您正苦於以下問題:PHP toggleRowClass函數的具體用法?PHP toggleRowClass怎麽用?PHP toggleRowClass使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。


在下文中一共展示了toggleRowClass函數的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: toggleRowClass

        echo $rcol;
        ?>
">
					<input type="checkbox" name="del[<?php 
        echo $a['awardId'];
        ?>
]" value="1" />
				</td>
			</tr>
		<?php 
    }
}
?>
			<tr>
				<td class="<?php 
echo toggleRowClass($rcol);
?>
">
					<?php 
echo l('new');
?>
 <input type="text" name="newcode" value="" />
				</td>
				<td class="<?php 
echo $rcol;
?>
">
					<input type="text" name="newname" value="" />
				</td>
				<td colspan="2" class="<?php 
echo $rcol;
開發者ID:beporter,項目名稱:hlstats,代碼行數:31,代碼來源:awardsActions.inc.php

示例2: toggleRowClass

     }
     echo '&nbsp;<a href="index.php?mode=playerinfo&amp;player=', $entry['playerId'], '">', $entry['lastName'], '</a></td>', "\n";
     echo '<td class="', toggleRowClass($rcol), '">';
     echo '<img width="16" height="16" ';
     if ($entry['skill'] > $entry['oldSkill']) {
         echo 'src="hlstatsimg/skill_up.gif" alt="Up" title="Up"';
     } elseif ($entry['skill'] < $entry['oldSkill']) {
         echo 'src="hlstatsimg/skill_down.gif" alt="Down" title="Down"';
     } else {
         echo 'src="hlstatsimg/skill_stay.gif" alt="Stay" title="Stay"';
     }
     echo ' />';
     echo $entry['skill'], '</td>', "\n";
     echo '<td class="', toggleRowClass($rcol), '">', $entry['kills'], '</td>', "\n";
     echo '<td class="', toggleRowClass($rcol), '">', $entry['deaths'], '</td>', "\n";
     echo '<td class="', toggleRowClass($rcol), '">', $entry['kpd'], '</td>', "\n";
     echo '</tr>', "\n";
     $x++;
 }
 echo '<tr><td colspan="6" align="right">';
 if ($pData['pages'] > 1) {
     for ($i = 1; $i <= $pData['pages']; $i++) {
         if ($playersObj->getOption('page') == $i) {
             echo "[", $i, "]";
         } else {
             echo "<a href='index.php?", makeQueryString(array('page' => $i)), "'>[", $i, "]</a> ";
         }
     }
 } else {
     echo "[1]";
 }
開發者ID:beporter,項目名稱:hlstats,代碼行數:31,代碼來源:players.inc.php

示例3: l

			<th><?php 
    echo l('Times Killed');
    ?>
</th>
			<th><?php 
    echo l('Deaths by');
    ?>
</th>
			<th><?php 
    echo l('Kills per Death');
    ?>
</th>
		</tr>
		<?php 
    foreach ($playerKillStats as $entry) {
        echo '<tr class="', toggleRowClass($rcol), '">';
        echo '<td>';
        if ($entry['active'] == "1") {
            echo '<img src="hlstatsimg/player.gif" width="16" height="16" alt="', l('Player'), '" alt="', l('Player'), '" />';
        } else {
            echo '<img src="hlstatsimg/player_inactive.gif" width="16" height="16" alt="', l('Player'), '" alt="', l('Player'), '" />';
        }
        echo '<a href="index.php?mode=playerinfo&player=', $entry['playerId'], '">', makeSavePlayerName($entry['name']), '</a>';
        echo '</td>';
        echo '<td>', $entry['kills'], '</td>';
        echo '<td>', $entry['deaths'], '</td>';
        echo '<td>', number_format((int) $entry['kpd'], 1), '</td>';
        echo '</tr>';
    }
    ?>
	</table>
開發者ID:BlackMajic,項目名稱:HLStats,代碼行數:31,代碼來源:playerinfo.inc.php

示例4: foreach

        echo $playerObj->getOption('sortorder');
        ?>
.gif" alt="Sorting" width="7" height="7" />
				<?php 
    }
    ?>
			</th>
		</tr>
<?php 
    foreach ($history['data'] as $entry) {
        $rcol = "row-dark";
        echo '<tr>';
        echo '<td class="', toggleRowClass($rcol), '">', $entry['eventTime'], '</td>';
        echo '<td class="', toggleRowClass($rcol), '">', $entry['message'], '</td>';
        echo '<td class="', toggleRowClass($rcol), '">', $entry['serverName'], '</td>';
        echo '<td class="', toggleRowClass($rcol), '">', $entry['map'], '</td>';
        echo '</tr>';
    }
    echo '<tr><td colspan="5" align="right">';
    if ($history['pages'] > 1) {
        for ($i = 1; $i <= $history['pages']; $i++) {
            if ($playerObj->getOption('page') == $i) {
                echo "[", $i, "]";
            } else {
                echo "<a href='index.php?", makeQueryString(array('page' => $i)), "'>[", $i, "]</a> ";
            }
        }
    } else {
        echo "[1]";
    }
    echo '</td></tr></table>', "\n";
開發者ID:beporter,項目名稱:hlstats,代碼行數:31,代碼來源:playerchathistory.inc.php


注:本文中的toggleRowClass函數示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。