We have been working very hard since 2009 to facilitate in your learning Read More. We can't keep up without your support. Donate Now.

www.bit.ly/vucodes

+ Link For Assignments, GDBs & Online Quizzes Solution

www.bit.ly/papersvu

+ Link For Past Papers, Solved MCQs, Short Notes & More

Looking For Something at Site? Search Below

see


+ http://bit.ly/vucodes (Link for Assignments, GDBs & Online Quizzes Solution)

+ http://bit.ly/papersvu (Link for Past Papers, Solved MCQs, Short Notes & More)

+ Click Here to Search (Looking For something at vustudents.ning.com?)

+ Click Here To Join (Our facebook study Group)


Views: 73

Attachments:

Replies to This Discussion

import java.io.*;
import java.util.*;
import javax.servlet.*;
import javax.servlet.http.*;


public class STimerOut extends HttpServlet {
// Handles the HTTP <code>GET</code> method.


  // use rq to read incoming HTTP headers   
  // use rs to specify the HTTP response status
  public void doGet(HttpServletRequest rq, HttpServletResponse rs)
                               throws ServletException, IOException {


   
   // tell the browser that we are sending back html
    rs.setContentType("text/html"); 
   
   // used to modify println() statements to build a legal web page
    PrintWriter out = rs.getWriter();
   
    int t = 60;
   
   /*
   system extracts a user ID from a cookie or attached URL data, then uses
   that as a key into a table of previously created HttpSession objects.
      */
    HttpSession s = rq.getSession();


   /*
   following statements build a legal webpage 
   */
    out.println("<HTML>");
    out.println("<HEAD>");
    out.println("<TITLE >");
    out.println("Session TimeOut ");
    out.println("</TITLE>");
    out.println("</HEAD>");




    out.println("<BODY>");
    out.println("<H1>");
    out.println("Session TimeOut ");
    out.println("</H1>");
    
    out.println("gaining the old time out " +
               s.getMaxInactiveInterval());/* getMaxInactiveInterval() gets the maximum
                              time in seconds for which the session remained
                              inactive.    
    
    out.println("<BR>");
    out.println("<BR>");

    s.setMaxInactiveInterval(2*t*t); /* sets the maximum time in seconds for which the 
                           session can remain inactive. 
    out.println("giving new time to get out " +
               s.getMaxInactiveInterval());


    out.println("</BODY>");
    out.println("</HTML>");

RSS

Latest Activity

umar khan joined +M.Tariq Malik's group
2 hours ago
Khuram Ali Raza Khan joined +M.Tariq Malik's group
2 hours ago
EsT@TiC M@nO posted a status
"anyone have solution file of cs420?"
8 hours ago
Ehtisham Ashfaq posted a status
"salam"
8 hours ago
+!!! ❤️ Shadow Girl❤️!!! replied to Miss. Churhail's discussion LOVE YOUR LIFE!!!!!
9 hours ago
+!!! ❤️ Shadow Girl❤️!!! liked Miss. Churhail's discussion LOVE YOUR LIFE!!!!!
9 hours ago
+!!! ❤️ Shadow Girl❤️!!! liked Miss. Churhail's discussion ہار کی پروا کرتا تو جیتنا چھوڑ دیتا
9 hours ago
Tasmia Ittba joined +M.Tariq Malik's group
9 hours ago
+M.Tariq Malik replied to +M.Tariq Malik's discussion MGT401 Financial Accounting II Online Quiz No 01 Fall 2020 Solution / Discussion in the group MGT401 Financial Accounting II
9 hours ago
+M.Tariq Malik liked +M.Tariq Malik's discussion MGT401 Financial Accounting II Online Quiz No 01 Fall 2020 Solution / Discussion
10 hours ago
+M.Tariq Malik added a discussion to the group MGT401 Financial Accounting II
10 hours ago
Muhammad Azeem replied to +M.Tariq Malik's discussion MGT601 GDB No 01 Fall 2020 Solution / Discussion Last Date: 27-11-2020 in the group MGT601 SME Management
10 hours ago
Muhammad Azeem joined +M.Tariq Malik's group
10 hours ago
+M.Tariq Malik replied to +M.Tariq Malik's discussion CS420 Web Development for Portable Devices Assignment 01 Fall 2020 Solution / Discussion in the group CS420 Web Development for Portable Devices
10 hours ago
+M.Tariq Malik liked +M.Tariq Malik's discussion CS420 Web Development for Portable Devices Assignment 01 Fall 2020 Solution / Discussion
10 hours ago
+M.Tariq Malik added a discussion to the group CS420 Web Development for Portable Devices
10 hours ago

© 2020   Created by +M.Tariq Malik.   Powered by

Promote Us  |  Report an Issue  |  Privacy Policy  |  Terms of Service

.