Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

¹ØÓÚjspµÄһЩСÎÊÌâ - Web ¿ª·¢ / JavaScript

ÎÒÏëÓÃjavabeanʵÏÖ¼ÆÊý
´úÂëÈçÏ£º
ComputerCount.java
package tom.jiafei;
import java.io.*;
public class ComputerCount{
  int number=0;
  boolean iscome=false;
  File file=new File("Count.dat");
  private void countpeople(){
  if(!file.exists())
  {
  number++;
  try{
  file.createNewFile();
  FileOutputStream out=new FileOutputStream(file);
  DataOutputStream dataOut=new DataOutputStream(out);
  dataOut.writeInt(number);
  out.close();
  dataOut.close();
  }
  catch(IOException ee){}
  }
  else
  { try{ FileInputStream in=new FileInputStream(file);
  DataInputStream dataIn=new DataInputStream(in);
  number=dataIn.readInt();
  number++;
  in.close();
  dataIn.close();
  FileOutputStream out=new FileOutputStream(file);
  DataOutputStream dataOut=new DataOutputStream(out);
  dataOut.writeInt(number);
  out.close();
  dataOut.close();
  }
  catch(IOException ee){}
  }
  iscome=true;
  }
&nbs


Ïà¹ØÎÊ´ð£º

jspÖÐ <c:if test> Ïà¹ØÎÊÌâ

ÔÚ²éѯºó½«²éѯ³öÀ´µÄÖµ¸³¸ø¸÷ÊäÈë¿ò
<c:if test="${not empty dataValue}">
      fm.SAMPLING_DATE.value=" <c:out value='${dataValue.SAMPLING_DATE}'/ ......

jspÒ³Ãæ»ñÈ¡sessionµÄÎÊÌâ - Java / Java EE

ÎÒÔÚjspÒ³Ãæ´æÉÏÒ»¸ösession,±¾Ò³Ã滹¿ÉÒÔÈ¡³öÖµÀ´.
µ«ÊÇһˢÐÂ,»òÕß´ò¿ªÐµÄÒ³Ãæ¾ÍÈ¡²»³öÖµÀ´ÁË.
Ææ¹ÖµÄÊÇ,ÎÒ²âÊÔÁíÒ»¸ö³ÌÐòʱºò
ÔÚjspÒ³Ãæ´æÉÏÒ»¸ösession,±¾Ò³Ãæ¿ÉÒÔÈ¡³öÖµÀ´,ˢлò´ò¿ªÐÂÒ³ÃæÖµÄÜÈ¡³öÀ´ÁË.
......

htmlתjspºó²¼¾ÖΪʲô±äÁË

Ò»¸ö¾²Ì¬µÄhtmlÒ³Ã棬ÃÀ»¯£¬½çÃæ²¼¾ÖÒѾ­´¦ÀíºÃÁË £¬ÔÚ±àд³ÌÐòµÄʱºòÐèÒªÔÚת»¯³ÉJSPÒ³Ã棬

ËùÒÔн¨Ò»¸öJSPÒ³Ã棬½²Ô­À´µÄ´úÂ뿽±´µ½ÀïÃæÈ¥£¬½á¹û²¼¾Ö±äÁË£¿

²»´æÔÚ·¾¶ÎÊÌâ!

ûÈË? Õæʧ°Ü!
......

jspÌøת

ÎÒµãºóÍËʱÊÇ¿Õ°×Ò³Ãæ
ÐèˢвÅÄÜÏÔʾ
Õâ¸öÔõô´¦Àí°¡
Çë´ó¼Ò°ï°ïæ
°ÑÎÊÌâ˵µÄÏêϸһЩ£¬ÕâÑùÓÐÖúÓÚÎÊÌâµÄ»Ø¸´£¬¼°´ð°¸µÄ׼ȷÐÔ£¡

ÎÒ¾õµÃÊÇÄãµÄä¯ÀÀÆ÷Æ÷µÄÎÊÌâ°É£¬ÎÒÒÔÇ°Óöµ½¹ýÕâÑùµÄÎÊÌ⣬°ÑIEµÄËùÓÐÊôÐÔÖ ......

jspÏà¹ØÎÊÌâ - Web ¿ª·¢ / JavaScript

ÎÒÏëµÇ¼ºó£¬Èç¹ûµÇ¼³É¹¦¾ÍÈ¥Ö´ÐÐij¸öÒ³Ãæ
ÎÒÏÖÔڵĴúÂëÊÇÕâÑùµÄ£º
if(rs.next()){
 session.setAttribute( "username" , user);
  <jsp:include page="login.jsp" />// ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ