Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <html>
- <head>
- <title>test menu</title>
- </head>
- <body>
- <style type="text/css">
- body {
- font-family:verdana;
- font-size:10px;
- color:#000;
- }
- div {
- padding:0px;
- }
- a{
- padding:3px;
- margin:0px;
- background-color:#99c;
- text-decoration:none;
- }
- a:hover {
- background-color:#ccc;
- text-decoration:none;
- }
- .active {
- background-color:#ffc;
- }
- </style>
- <div>
- <?php
- $menu=isset($_GET['m'])?$_GET['m']:'home';
- $menus=array('home','product','support','about');
- for($i=0;$i<count($menus);$i++){
- echo "<a href=\"?m=".$menus[$i]."\"".($menu==$menus[$i]?" class=\"active\"":"").">".$menus[$i]."</a>\n";
- }
- ?>
- </div>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement