[opencms-dev] Solved https images but jsp no longer working

Arian Abrahantes Quintana Arian.Abrahantes.Quintana at cern.ch
Tue Jul 12 13:40:34 CEST 2005


Hi:
 
The problem with figures an css was solved. I had to include the export property to "true" in the module I was using and later each of the resources or elements within declaring also the same properties. Now I am able to view my site nicely formatted through https.
 
So here comes another small problem:
 
Why does jsp code is no longer working under https protocol?

All jsp have export set to true. A small example is read something from a database and display it. Just like this:

+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

try
    {
        //Loading Drivers
        Class.forName("org.gjt.mm.mysql.Driver");
        try{
  
            //making the connection
            String url = "jdbc:mysql://myserver.ch:3306/";
            Connection con = DriverManager.getConnection(url,"root","password");
  
           
           //Creating JDBC Statement
           Statement stmt = con.createStatement();
  
           // Getting Data from Table
           
           String query = "SELECT * FROM MyTable WHERE myField='whatever'";

           out.println("<table><tr><td><b>Field</b></td><td><b>Value</b></td></tr>");
              
           ResultSet rs = stmt.executeQuery(query);
           while (rs.next()) {
             // get all data and print it
           }
           out.println("</table><br>");
  
           if(rs != null) rs.close();
           if(stmt != null) stmt.close();
           if(con != null) con.close();
         }
         catch (SQLException o)
         {
  	 out.println("SQL Error<br>");
         }
    }
    catch (ClassNotFoundException err)
    {
      out.println("Class loading error");
    }
////////////////////////////////////////////////////////////////

Under http everything works fine but through https I just get in the body oh the response 

<table><tr><td><b>Field</b></td><td><b>Value</b></td></tr>
</table><br>

choices:
1- Result set of the query in the database is empty when the communication is through https. Parameters are not "well-passed" to mysql (Missconfiguration)

2- Reply from database is not catched in https protocol. unlikely since otherwise it'll cry due to the exception on the communication with the database.

I also think might be something of both but I am a rookie on opencms.

Can any one help me on this issue?.

best regards and thx in advance;

arian
-------------- next part --------------
A non-text attachment was scrubbed...
Name: winmail.dat
Type: application/ms-tnef
Size: 3838 bytes
Desc: not available
URL: <https://webmail.opencms.org/pipermail/opencms-dev/attachments/20050712/e26a97a4/attachment.bin>


More information about the opencms-dev mailing list