Note that there are some explanatory texts on larger screens.

plurals
  1. POimport class success but when try to use it it gives error
    primarykey
    data
    text
    <p>in my jsp page i imported class and it works file in my pc on tomcat 7 but when i upload it to my server it give compilation error for jsp file my code for </p> <pre><code>!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt; &lt;%@ page import="com.*" %&gt; &lt;%@ page import="DIO.*" %&gt; &lt;html xmlns="http://www.w3.org/1999/xhtml"&gt; &lt;head&gt; </code></pre> <p>and place where i am getting error is</p> <pre><code>&lt;td class="value"&gt;&lt;%= com.PageCounter.getIntTodaysCount() %&gt;&lt;/td&gt; </code></pre> <p>my class PageCounter is inside com package and it works file on my local host pc errror when uploading to server</p> <p>and error is </p> <pre><code>An error occurred at line: 32 in the jsp file: /index.jsp PageCounter cannot be resolved 29: &lt;table cellspacing="0" class="info_table" style="height: 175px" &gt; 30: &lt;tbody&gt; 31: &lt;tr&gt; 32: &lt;td class="value"&gt;&lt;%= PageCounter.getIntTodaysCount() %&gt;&lt;/td&gt; 33: &lt;td class="full"&gt;Visits Today&lt;/td&gt; 34: &lt;/tr&gt; </code></pre> <p>doe it will due to change in version of tomcat</p> <p>any suggetion will be great help</p> <p>error is </p> <pre><code>An error occurred at line: 51 in the jsp file: /index.jsp DIO cannot be resolved to a type 48: &lt;div class="portlet-header"&gt; 49: &lt;h4&gt;Upcoming Events&lt;/h4&gt; 50: &lt;/div&gt; &lt;!-- .portlet-header --&gt; 51: &lt;% DIO sharedDataBase = (DIO)application.getAttribute("sharedDataBase"); 52: String[][] eventData=sharedDataBase.getData("select eventName,eventDescription,eventDate from listOfEvents order by eventDate desc", 10);%&gt; 53: &lt;div class="portlet-content"&gt; 54: &lt;marquee direction="up" onmouseover="stop()" style="height: 200px" onmouseout="start()" scrollamount="2" Stacktrace: org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:103) org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:331) org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:468) org.apache.jasper.compiler.Compiler.compile(Compiler.java:378) org.apache.jasper.compiler.Compiler.compile(Compiler.java:353) org.apache.jasper.compiler.Compiler.compile(Compiler.java:340) org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:646) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:357) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334) javax.servlet.http.HttpServlet.service(HttpServlet.java:728) </code></pre> <p>page counter class</p> <pre><code>package com; import java.util.Date; import java.sql.SQLException; import DIO.DIO; public class PageCounter { private static int count; private static int todaysCount; private static Date previousDate=new Date(); public static int getIntTodaysCount(){ Date date = new Date(); if (previousDate.before(date)) { ++todaysCount; }else{ previousDate=date; todaysCount=1; } return todaysCount; } public static int getIntCount(DIO sharedDataBase){ count++; try { sharedDataBase.updateData("update pageCount set pageCount="+count+" where pageCountId=1"); } catch (SQLException e) { e.printStackTrace(); } return count; } } </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload