Need to capture actual session time - help!

I am trying to capture the time a user is on the actual site.
I tried using onSessionEnd in my application.cfc but that just
drops in the time of the actual last click variable I set and when
the session times out. I don't capture the actual time the person
left the site. I don't want to use short timeout values because the
site has some very long pages to read and someone could spend 30
minutes on the page. Is there a way to have a hidden layer or
graphic that keeps an open connection with the browser and the
server so I can use short timeout values and not worry about the
person just sitting there on one page reading? I also need to make
sure whatever method is the most browser friendly and as
unnoticeable by the user as possible. Thanks!

You could use AJAX to ping a back-end page to keep your
session alive. You would need to have a javascript run every x
seconds firing the AJAX call. Something like (not full script just
an example):
<script type="text/javascript">
// Every 10 seconds call the keepAlive function
window.setInterval("keepAlive('<cfoutput>#session.CFID#</cfoutput>')",10000);
function keepAlive(sessionid){
//do ajax keep alive call here (i.e. call to keepalive.cfm)
</script>

Similar Messages

  • 4G online gaming doesnt work why? i need someone who actually cares to help me plse!!!

    my modem is Pantech UML290     .i  notice cannot play any online games...my old 3g modem works perfectly with the same games but this new service as far as online games or this modem apparently has issues...i have had nothing but problems, high ping rates and packet loss as well as jitter and no one with the exception of 1 service tech apparently cares...they only care that you can connect and brows web to a degree....i have spoke to 8 techs only one cares and states their is a problem....i have tested this on speedtest.com upload and download speed is fast remarkably fast but inconsistant, the ping is terible and jitter and packet loss is even worse...i am going to try to replace the modem as last form of troubleshoooting, if that doesnt work then 4g can go in the trash until they resolve the problem....they advertise online gameing and video streaming for 4g...i cannot do online gaming will not even connect to game host due to high pings and data loss...and yet the new service wich is supposed to be much better and support online gaming doesnt work and my 3g device works without a problem, can play games all day long without i hitch and no one from tech can explain why....sounds like a problem..i have spoke with several people on forums they have all said the same thing....release tech and dontr know how to fix the problems....the response you will get is all we care about is that you can connect and view the web!!! wow so when i buy a car i guess all they care about is the car moves, they dont care if the ac worrks or anything else does to...thats the way its been explained to me time and time again...except for 1 tech...   the games that i have tried to play is BATTLEFIELD BAD COMPANY 2,     CALL OF DUTY MODERN WARFARE 2 ,  STARCRAFT 2,  noNE will work,  note been playing with old 3g device and service for over a yr with no problems!!  SOMEONE PLSE HELP!!!

    I live out in the country and have no high speed internet so i bought the pantech UML290 and I have been able to play on the 4g network right out of the box. Plugin, install, and go. I Play Bad Company2 and my ping is usually 142. I connect to a chicago server from okc and my gameplay has improved so much more. I get 2 to 3 bars in my house and it flys on web pages.  I had the at@t lightning 3g and my pings on the same server were 185 but spiked up to 999 and back down to 180's . I love this UML290 and do not have Idea why you are having problems. I would return the uml and get another one. You might make sure the other communication software is uninstalled and worst case scenario, reformat the hard drive and start with a fresh install.  Can you give a description of your computer specs ?  Is this going through a cradlepoint router ? I would be happy to try to help, I know how much it sucks have a laggy gaming experience.  

  • Need to render all the time - help!

    Hi everyone,
    I just received a lot of footage from a director to edit. They're all quicktime files, but the format is "Apple Photo - JPEG, 320 x 240)". Everytime I drag a clip to the timeline, it goes red on me and I need to render it. I can't do this for a whole movie...anyone know how I can get around this?
    Thanks,
    Sarah

    Thanks for the quick reply...someone posted earlier about sneaking around this by creating a multiclip sequence, which for some reason you can drag clips to without then having to render them. I'm prepared to use this method...unless it's going to come back to bite me later for some weird reason? Any thoughts?
    Thanks!

  • Session Time Out capturing for legacy application running in portal

    Hi Forums,
    I am using portal URL  iView to connect to legacy application. How to capture the session time of of that legacy application and show it in the portal. In portal I have already handled session time out which shows a javascript popup message. I want to call the same piece of code once session time out happens in the legacy application which is been accessed by portal through URL iview.
    Many Thanks and Best Regards
    Sudhir

    Hi Sudhir,
    The handling of the session timeout should be done by the application itself not the portal. From the portal you have no way of working out what the application is doing. My suggestion to you is that you need to modify the application to handle the scenario you describe not the portal.
    BRgds,
    Simon

  • Session time out in Websphere Application Server

    Hi ,
    I am using Websphere Application server 5.1 . I need to set the session time out for my web application. Actually, i edited the web.xml and set the value
    <session-config>
              <session-timeout>10</session-timeout>
         </session-config>But when I am refreshing my jsp page, after 10-15 mts, i am able to get a valid page without any problem. Actually since the session time out is 10 mts , I should not get a valid page after 10 mts . I tried one more option for setting the session time out . I opened the admin console of my App server and set the session time out there too. But session not seems to be timing out after 10-15 mts. I am still able to get a valid jsp page. I have many session attributes in that page. So after 10 mts, i should not get a valid page.. I dont know, what's wrong in my configuration. If some body knows the answer please help me.
    thanks in advance.
    Aneesh K

    So what you're trying to achieve is that the ui closes or becomes invalid if no action has been performed for a certain time? That should be easy enough, install a javax.swing.Timer somewhere in your application and set it to the time you desire. Whenever the user performs an action, invoke reset() on the timer (it's a fairly cheap operation). If the timer fires, you know the timeout occured.
    You have to decide for yourself what you consider a 'user action' in this context. If you want the session to stay alive as long as the user is still doing something, just install an AWTEventListener, which can react to pretty much anything, mouse movement, keyboard input etc.

  • How to capture transaction response time in SQL

    I need to capture  Transaction response time (i.e. ping test) to calculated the peak hours and averaged
    on a daily basis.
    and
    Page refresh time that is calculated no less than every 2 hours for peak hours and averaged on a daily basis. 
    Please assist
    k

    My best guess as to what you are looking for is something like the following (C#):
    private int? Ping()
    System.Data.SqlClient.SqlConnection objConnection;
    System.Data.SqlClient.SqlCommand objCommand;
    System.Data.SqlClient.SqlParameter objParameter;
    System.Diagnostics.Stopwatch objStopWatch = new System.Diagnostics.Stopwatch();
    DateTime objStartTime, objEndTime, objServerTime;
    int intToServer, intFromServer;
    int? intResult = null;
    objConnection = new System.Data.SqlClient.SqlConnection("Data Source=myserver;Initial Catalog=master;Integrated Security=True;Connect Timeout=3;Network Library=dbmssocn;");
    using (objConnection)
    objConnection.Open();
    using (objCommand = new System.Data.SqlClient.SqlCommand())
    objCommand.Connection = objConnection;
    objCommand.CommandType = CommandType.Text;
    objCommand.CommandText = @"select @ServerTime = sysdatetime()";
    objParameter = new System.Data.SqlClient.SqlParameter("@ServerTime", SqlDbType.DateTime2, 7);
    objParameter.Direction = ParameterDirection.Output;
    objCommand.Parameters.Add(objParameter);
    objStopWatch.Start();
    objStartTime = DateTime.Now;
    objCommand.ExecuteNonQuery();
    objEndTime = DateTime.Now;
    objStopWatch.Stop();
    objServerTime = DateTime.Parse(objCommand.Parameters["@ServerTime"].Value.ToString());
    intToServer = objServerTime.Subtract(objStartTime).Milliseconds;
    intFromServer = objEndTime.Subtract(objServerTime).Milliseconds;
    intResult = (int?)objStopWatch.ElapsedMilliseconds;
    System.Diagnostics.Debug.Print(string.Format("Milliseconds from client to server {0}, milliseconds from server back to client {1}, and milliseconds round trip {2}.", intToServer, intFromServer, intResult));
    return intResult;
    Now, while the round trip measurement is fairly accurate give or take 100ms, any measurement of latency to and from SQL Server is going to be subject to the accuracy of the time synchronization of the client and server.  If the server's and client's
    time isn't synchronized precisely then you will get odd results in the variables intToServer and intFromServer.
    Since the round trip result of the test is measured entirely on the client that value isn't subject to the whims of client/server time synchronization.

  • To capture the passed time in a TimedTrigger UI Element

    Hi, I want to capture the passed time in a TimedTrigger UI Element. I need to capture the passed time from init the application to the execution of an action of a button.
    ¿How can i do it?
    Regards.

    Marcel,
    You do not TimedTrigger for this at all.
    1. Create private variable startTime of type long in custom coding section of view controller (bottom of view controller source between //@begin other .. //@end):
    private long startTime;
    2. In wdDoInit of view controller assign current time:
    startTime = System.currentTimeMillis();
    3. In action handler you may get time passed as following:
    timePassed = System.currentTimeMillis() - startTime;
    The result is in milliseconds, to get seconds divide it by 1000.
    Valery Silaev
    SaM Solutions
    http://www.sam-solutions.net

  • My tabs will not restore after starting Firefox -- even with the option to restore my tabs and windows is checked in the "options" window. I'm losing tabs from previous sessions that I need to keep open every time I need to restart. Thanks for any advice!

    Is there something else I need to tweak to get rid of this annoyance instead of simply clicking the check box? I'm losing tabs from previous sessions that I need to keep open every time I need to restart. Thanks for any advice!

    Make sure that you do not use Clear Recent History to clear the <i>Browsing History</i> when you close Firefox.
    *https://support.mozilla.com/kb/Clear+Recent+History
    It is possible that there is a problem with the files sessionstore.js and sessionstore.bak in the Firefox Profile Folder.
    Delete the sessionstore.js [2] file and possible sessionstore-##.js [3] files with a number and sessionstore.bak in the Firefox Profile Folder.
    * Help > Troubleshooting Information > Profile Directory: Open Containing Folder
    * http://kb.mozillazine.org/Profile_folder_-_Firefox
    Deleting sessionstore.js will cause App Tabs and Tab Groups and open and closed (undo) tabs to get lost, so you will have to create them again (make a note or bookmark them).
    See also:
    * [1] http://kb.mozillazine.org/Session_Restore
    * [2] http://kb.mozillazine.org/sessionstore.js
    * [3] http://kb.mozillazine.org/Multiple_profile_files_created

  • HT3702 I am unable to add my bank/card details in my apple account, every time i am getting a message that it has been declined. kindly help me in authorise my bank card in my apple account i need to purchase few apps, pls help me

    Hi,
    I am unable to add my bank/card details in my apple account, every time i am getting a message that it has been declined. kindly help me in authorise my bank card in my apple account i need to purchase few apps, pls help me

    What sort of card are you trying to use ? If it's a debit card then I don't think that they are still accepted as a valid payment method - they are not listed on this page and there have been a number of posts recently about them being declined
    If it's a credit card then is it registered to exactly the same name and address (including format and spacing etc) that you have on your iTunes account, it was issued by a bank in your country and you are currently in that country ? If it is then you could check with the card issuer to see if it's them that are declining it, and if not then try contacting iTunes support and see if they know why it's being declined : http://www.apple.com/support/itunes/contact/ - click on Contact iTunes Store Support on the right-hand side of the page, then Account Management

  • A previous and unrelated text always appears when I need to send a new text. This prevents forwarding texts also, which I need to do all the time for my business. How can I fix? Please help!

    A previous and unrelated text always appears when I need to send a new text. This prevens forwarding texts also, which I need to do all the time for my businss. How can I fix? Please help?

    Hi,
    This sounds like it is about Window positions.
    iChat has Default places for Incoming Invites.
    Video is always top Center of your Screen
    Audio and Text chats are Upper right with the Audio slightly lower than Text Chats.
    Secondary invites are sort of Stacked like when you open multiple files from the same App.
    Your outgoing Windows are "Remembered" as to where the last one was when you used it.
    This can be an issue if you use your Mac with a second display and turn Off Mirroring.
    You windows can get "left" on the other screen.
    Go to System Preferences > Displays and turn On Mirroring and the windows should come back to one Screen/display.
    If this does not help go to your Home Folder/Library/Preferences and delete (Drag to Trash) com.apple.ichat.plist and restart iChat.
    Unfortunately you will need to reset any iChat Preferences you have changed from defaults.
    10:42 PM      Tuesday; April 26, 2011
    Please, if posting Logs, do not post any Log info after the line "Binary Images for iChat"
     G4/1GhzDual MDD (Leopard 10.5.8)
     MacBookPro 2Gb( 10.6.7)
    , Mac OS X (10.6.7),
    "Limit the Logs to the Bits above Binary Images."  No, Seriously

  • Need to capture multiple image paths for responsive design when only one will be displayed at a time

    I'm new to CQ and am having enough trouble following the documentation on image components as it is (why is there no master reference for all this?). I have a requirement where we need to capture three versions of an image and put the URLs into three attributes of a tag. The appropriately sized image will be selected via JavaScript based on the browser/device capabilities. I need to know how to capture those images when seemingly only one at a time can be dropped onto the page. Or perhaps there is a more CQ solution to this.

    Hi,
    You need to customize image component. I mean selected image is a asset in the repository and each asset by default has 3 rendtion generated when the image is uploaded in the dam.
    For example when you upload image.jpg file into the DAM, standard workflow is launched and after a while inside the repository (see paths) are created following renditions:
    /content/dam/project/image/image.jpg/jcr:content/renditions/cq5dam.thumbnail.140.100.png
    /content/dam/project/image/image.jpg/jcr:content/renditions/cq5dam.thumbnail.319.319.png
    /content/dam/project/image/image.jpg/jcr:content/renditions/cq5dam.thumbnail.48.48.png
    This process can be customized by changing /etc/workflow/models/dam/update_asset.html workflow and modifing "Thumbnail creation" step by adding in the Process tab -> Arguments field new values for new rendition. So for example if you add there [400,400] new rendition will be created in the path
    /content/dam/project/image/image.jpg/jcr:content/renditions/cq5dam.thumbnail.400.400.png
    Next step is to customize jsp for image component. Using path to the drag and dropped image from a component attributes you can easily take all renditions iterating on the /content/dam/project/image/yourimage.jpg/jcr:content/renditions node and then set paths to all renditions in the tag attributes. Then like you wrote using js you can select proper rendition.
    I hope that it hepls you.
    Regards,
    Adam

  • Need to confirm actual time for 2 persons on one operation  in work order( PM)

    Need to confirm actual time for 2 persons on one operation  in work order( PM)

    Hi Abdullatif Siam,
    If you can move your discussion to the relevant space, possibility of people responding to you would be more..
    May be you move your post here -- Enterprise Asset Management --> http://scn.sap.com/community/eam
    BR
    Prabhith

  • Dreamweaver need to create a session variable or Cookie or something Help

    I have been working for weeks I am very close but can't get over one last hurdle. I am trying to call a session variable much like dreamweaver calls mm_username. It is in the same user table as username - password - access level - Customer_id. I need to pull the session variable or cookie or however I can do it to access the customer id number so I can have customer specific information and pricing. There will be mulitple users for each customer so I need another variable besides mm_username. Help I use dreamweaver cs4 aspvbscript and sqlserver ...help

    I soon as I put the red line of code in it is custoemr _id instead of user id in my table. Dreamweaver removes the user id function. is it in the wrong place ...what am i doning wrong ....it is fine with the first part you did but the second part it doesnt like in red.
    <%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%>
    <!--#include virtual="/Connections/p21.asp" -->
    <%
    ' *** Validate request to log in to this site.
    MM_LoginAction = Request.ServerVariables("URL")
    If Request.QueryString <> "" Then MM_LoginAction = MM_LoginAction + "?" + Server.HTMLEncode(Request.QueryString)
    MM_valUsername = CStr(Request.Form("username"))
    If MM_valUsername <> "" Then
      Dim MM_fldUserAuthorization
      Dim MM_redirectLoginSuccess
      Dim MM_redirectLoginFailed
      Dim MM_loginSQL
      Dim MM_rsUser
      Dim MM_rsUser_cmd
      MM_fldUserAuthorization = "Access_Level" 
      MM_redirectLoginSuccess = "/mainmenu.asp" 
      MM_redirectLoginFailed = "/loginfailed.asp" 
      MM_loginSQL = "SELECT customer_id, Login_Name, password"
      If MM_fldUserAuthorization <> "" Then MM_loginSQL = MM_loginSQL & "," & MM_fldUserAuthorization
      MM_loginSQL = MM_loginSQL & " FROM dbo.btb_web_login WHERE Login_Name = ? AND password = ?"
      Set MM_rsUser_cmd = Server.CreateObject ("ADODB.Command")
      MM_rsUser_cmd.ActiveConnection = MM_p21_STRING
      MM_rsUser_cmd.CommandText = MM_loginSQL
      MM_rsUser_cmd.Parameters.Append MM_rsUser_cmd.CreateParameter("param1", 200, 1, 20, MM_valUsername) ' adVarChar
      MM_rsUser_cmd.Parameters.Append MM_rsUser_cmd.CreateParameter("param2", 200, 1, 10, Request.Form("password")) ' adVarChar
      MM_rsUser_cmd.Prepared = true
      Set MM_rsUser = MM_rsUser_cmd.Execute 
      If Not MM_rsUser.EOF Or Not MM_rsUser.BOF Then
        ' username and password match - this is a valid user
        Session("MM_Username") = MM_valUsername
        Session ("MM_USERID") = MM_rsUser.Fields.Item("customer_id").value
        If (MM_fldUserAuthorization <> "") Then
          Session("MM_UserAuthorization") = CStr(MM_rsUser.Fields.Item(MM_fldUserAuthorization).Value)
        Else
          Session("MM_UserAuthorization") = ""
        End If
        if CStr(Request.QueryString("accessdenied")) <> "" And false Then
          MM_redirectLoginSuccess = Request.QueryString("accessdenied")
        End If
        MM_rsUser.Close
        Response.Redirect(MM_redirectLoginSuccess)
      End If
      MM_rsUser.Close
      Response.Redirect(MM_redirectLoginFailed)
    End If
    %><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Brown Live Online Login</title>
    <style type="text/css">
    <!--
    body {
        background-image: url(/images/gradientblacktowhite.jpg);
        background-repeat: repeat-x;
    .style1 {
        color: #FFFFFF;
        font-weight: bold;
    .style3 {color: #000000; font-weight: bold; }
    .style5 {
        font-size: xx-large;
        color: #0000FF;
    .style6 {color: #000000}
    -->
    </style></head> 
    <body>
    <p class="style5"><img src="/images/BTBlogosmall.jpg" width="322" height="53" /></p>
    <p class="style5">Brown Live Online 2.0 </p>
    <form ACTION="<%=MM_LoginAction%>" id="form1" name="form1" method="POST">
      <p>
        <label><span class="style3">    User Name</span>
        <input name="username" type="text" id="username" size="20" />
        </label>
      </p>
      <p>
        <label><span class="style1"><span class="style6">Password</span></span>
        <input name="password" type="password" id="password" size="20" />
        </label>
      </p>
      <p>
        <label>
        <input type="submit" name="button" id="button" value="Login" />
        </label>
      </p>
    </form>
    <p><a href="/index.html"><img src="/images/brown2.0.jpg" width="100" height="100" /></a> Click Image to return to <a href="http://www.browntransmission.com">www.browntransmission.com</a></p>
    </body>
    </html>

  • My MacBook Pro keyboard is giving trouble. 0,p,;,/ and the enter key needs to be pressed several times before registering. Help me please??

    My MacBook Pro keyboard is giving trouble. The 0,p,;,/ and the enter key, needs to be pressed several times before registering. Help me please??

    If you are still under warranty and/or have AppleCare, call them.  Let them deal w/it.  Out of warranty, your keyboard may need cleaning.  Use a vacuum hose or a can of compressed air to get the dirt out from under the keys.  For instructions to remove the keys if it comes to that check out the following websites:
    iFixit
    TakeItApart
    Search YouTube for Macbook Pro “How To” tutorials.
    If you do not want to DIY, take your MBP to your local AS or an AASP.

  • Session Time Out For UNLOGGED IN USER During Search -pls help SIR!

    Hi,
    The problem lies in searchresultscontroller.java/searchcontroller.java file under search/web/handler of an application that supports educational note sharing.
    The problem is that -
    When I search with query strings in different fields(as you will find in the above mentioned java files)..the keywords in resourcedto and get some files as search results.
    Then I click on one of the file from within the search result and visit the file.
    Here if I m logged in as an user, and the session time out is set to 1 minute in the web.xml file of the web folder not the admin folder then when I hit the BACK TO SEARCH button it easily goes back to the previous search result page along with the queries string that I had input previously.
    The problem is that when I m NOT LOGGED in as an user, and I've performed a search with queries and other dropdowns in the search panel, I get the search result page, I visit the file by clicking on one of them but when I hit the BACK TO SEARCH button I don't see the previous search result page from where I had navigated to view the file.
    Please suggest on what changes shall I make in the code so that even if I m not logged in as an user, I get back to the search result page on hitting the BACK TO SEARCH button from the file view page.Sir I m herein pasting the code of the searchresultscontroller.java file, but please feel free to ask for anyother file whose code you might want to see.SEARCHRESULTSCONTROLLER.JAVA FILE CONTENT-
    package com.mgh.sps.search.web.handler;
    import java.util.Map;
    import java.util.regex.Pattern;
    import javax.servlet.http.HttpServletRequest;
    import javax.servlet.http.HttpServletResponse;
    import org.apache.log4j.Logger;
    import org.springframework.validation.BindException;
    import org.springframework.validation.Errors;
    import org.springframework.web.servlet.ModelAndView;
    import org.springframework.web.servlet.mvc.SimpleFormController;
    import com.mgh.sps.search.business.facade.Search;
    import com.mgh.sps.common.dto.ResourceDTO;
    import com.mgh.sps.common.util.SessionAttributeKey;
    import com.mgh.sps.common.util.SessionManager;
    import com.mgh.sps.fileusage.web.constants.FileUsageWebConstants;
    public class SearchResultsController extends SimpleFormController {
    * SearchResults Controller
    * @author Muralikrishna.s
    * @Codedondate DD-MM-YY=26-07-07
    * @Usecase/s associated =UC504
    private static final Logger logger = Logger
    .getLogger(SearchResultsController.class.getName());
    private final static String REG_EXP = "^[A-Za-z0-9]*$";
    private final static Pattern EMAIL_PATTERN_REG = Pattern.compile(REG_EXP);
    * Spring framework method used to hold reference data
    * @param request
    * HttpServletRequest
    * @param command
    * Object
    * @param arg2
    * Errors
    * @return Map
    * @throws Exception
    @Override
    protected Map referenceData(HttpServletRequest request, Object command,
    Errors errors) throws Exception {
    logger.debug("SearchResultsController.referenceData() method entered:"
    + request + "," + command + "," + errors);
    SessionManager.setSessionAttribute(SessionAttributeKey.tabIndex,
    FileUsageWebConstants.TAB_SEARCH, request);
    Search search = (Search) super.getWebApplicationContext().getBean(
    "searchfacade");
    ResourceDTO resourceDto = (ResourceDTO) command;
    String[] allValues = new String[7];
    if (null != (String[]) SessionManager.getSessionAttribute(
    SessionAttributeKey.allValues, request)) {
    allValues = (String[]) SessionManager.getSessionAttribute(
    SessionAttributeKey.allValues, request);
    resourceDto.setKeywords(allValues[0]);
    resourceDto.setCountry(allValues[1]);
    resourceDto.setUniversityName(allValues[2]);
    resourceDto.setSubjectArea(allValues[3]);
    resourceDto.setQualification(allValues[4]);
    resourceDto.setYearLevel(allValues[5]);
    resourceDto.setSpecificType(allValues[6]);
    logger.debug("%%%%%%%%%%%%%%%%%qualification%%%%%%%%%%%%%%%"
    + resourceDto.getQualification());
    String flag = (String) request.getParameter("id");
    resourceDto.setFlag(flag);
    logger.debug("SearchResultsController.referenceData() method exited:");
    return search.retrieveReferenceData(resourceDto);
    * Spring framework method used to hold OnSubmit
    * @param request
    * HttpServletRequest
    * @param response
    * HttpServletResponse
    * @param command
    * Object
    * @param arg3
    * BindException
    * @return ModelAndView
    * @throws Exception
    @Override
    protected ModelAndView onSubmit(HttpServletRequest request,
    HttpServletResponse response, Object command, BindException errors)
    throws Exception {
    SessionManager.cleanup(request);
    logger.debug("SearchResultsController.onSubmit() method entered:"
    + request + "," + command + "," + response + "," + errors);
    Search search = (Search) super.getWebApplicationContext().getBean(
    "searchfacade");
    Map dynamic = (Map) getServletContext().getAttribute("config");
    ResourceDTO resourceDto = (ResourceDTO) command;
    SessionManager.removeSessionAttribute(SessionAttributeKey.allValues,
    request);
    //changed by sreelatha on sep21
    //resourceDto.setKeywords(request.getParameter("keywords"));
    //String key = request.getParameter("keywords");
    //logger.debug("&&&&&&&&&&&&& key &&&&&&&&&&&&" + key);
    String keywords = (request.getParameter("keywords"));
    if(null!=keywords) {
    keywords = keywords.trim();
    resourceDto.setKeywords(keywords);
    // changes end
    resourceDto.setUniversityName(request.getParameter("universityName"));
    resourceDto.setSubjectArea(request.getParameter("subjectArea"));
    resourceDto.setCountry(request.getParameter("country"));
    resourceDto.setQualification(request.getParameter("qualification"));
    resourceDto.setYearLevel(request.getParameter("yearLevel"));
    resourceDto.setSpecificType(request.getParameter("specificType"));
    String[] allValues = new String[7];
    //changed by sreelatha on sep21
    //allValues[0] = request.getParameter("keywords");
    allValues[0] = resourceDto.getKeywords();
    //changes end
    allValues[1] = request.getParameter("country");
    allValues[2] = request.getParameter("universityName");
    allValues[3] = request.getParameter("subjectArea");
    allValues[4] = request.getParameter("qualification");
    allValues[5] = request.getParameter("yearLevel");
    allValues[6] = request.getParameter("specificType");
    SessionManager.setSessionAttribute(SessionAttributeKey.allValues,
    allValues, request);
    if(null!=keywords) {
    keywords = keywords.trim();
    String words="";
    for(int i=0;i<keywords.length();i++) {
    String key=String.valueOf(keywords.charAt(i));
    if(key.contains("*")) {
    key = key.replace("*"," ");
    } else if(key.contains("?")) {
    key = key.replace("?"," ");
    } else if(key.contains("[")) {
    key = key.replace("["," ");
    } else if(key.contains("{")) {
    key = key.replace("{"," ");
    } else if(key.contains("(")) {
    key = key.replace("("," ");
    } else if(key.contains(")")) {
    key = key.replace(")"," ");
    } else if(key.contains("+")) {
    key = key.replace("+"," ");
    } else if(key.contains("
    key = key.replace("
    } else if(key.contains(" ")) {
    key = key.replace(" "," ");
    } else if(key.contains("_")) {
    key = key.replace("","");
    } else if(!EMAIL_PATTERN_REG.matcher(key).matches()) {
    key = key.replaceAll(key," ");
    words = words + key;
    keywords = words;
    resourceDto.setKeywords(keywords);
    SessionManager.setSessionAttribute(SessionAttributeKey.test, search.setInputValues(resourceDto, dynamic), request);
    String name = (String) SessionManager.getSessionAttribute(SessionAttributeKey.tempName, request);
    String flag1 = request.getParameter("id");
    String status="";
    if (flag1 !=null && flag1.equals("loggedInUser"))
    if(name==null)
    return new ModelAndView();
    if (flag1 !=null && flag1.equals("loggedInUser")){
    status = "redirect:SearchResults.htm?id=loggedInUser";
    }else if(flag1 !=null && flag1.equals("nonLoggedInUser"))
    status = "redirect:SearchResultsnlu.htm?id=nonLoggedInUser";
    super.setSuccessView(status);
    ModelAndView mav = new ModelAndView(super.getSuccessView());
    logger.debug("SearchResultsController.onSubmit() method exited:");
    return mav;
    }

    Cross-posted in many forums. Don't answer this one.

Maybe you are looking for