PHP用switch语句设计网站主页

阅读更多

一 PHP脚本

index.php


switch语句的应用


          返回首页 加入收藏  
     最新商品  热门商品 ">推荐商品 ">特殊商品  
   最新商品
   热门商品
   ">推荐商品
   ">特殊商品
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
index1.php
  1. http-equiv="Content-Type"content="text/html; charset=gb2312">
  2. </span><span class="pln" style="color: #48484c;">无标题文档</span><span class="tag" style="color: #000088;">
  3. src="images/bg6.jpg"width="508"height="543">
index2.php
  1. http-equiv="Content-Type"content="text/html; charset=gb2312">
  2. </span><span class="pln" style="color: #48484c;">无标题文档</span><span class="tag" style="color: #000088;">
  3. href="index.php?lmbs=新品上市">
  4. src="images/bg7.jpg"width="547"height="548">
index3.php
  1. http-equiv="Content-Type"content="text/html; charset=gb2312">
  2. </span><span class="pln" style="color: #48484c;">无标题文档</span><span class="tag" style="color: #000088;">
  3. php echo urlencode("特价区");?>">
  4. src="images/bg8.jpg"width="534"height="410">
index4.php
  1. http-equiv="Content-Type"content="text/html; charset=gb2312">
  2. </span><span class="pln" style="color: #48484c;">无标题文档</span><span class="tag" style="color: #000088;">
  3. src="images/bg7.JPG"width="538"height="520">
二 运行结果
PHP用switch语句设计网站主页_第1张图片
 
三 功能说明
应用switch语句设计网站主页的布局,将网站头、尾文件设置为固定不变的板块、导航条也作为固定板块;而在主显示区中,应用switch语句根据超链接中传递的值不同,显示不同的内容。
  • PHP用switch语句设计网站主页_第2张图片
  • 大小: 315.1 KB
  • 查看图片附件

你可能感兴趣的:(PHP,switch,网站主页)