<%@page import="java.io.PrintWriter, java.util.*,ar.framework.utilities.StringUtilities, ar.framework.db.DBConnection, ar.reddog.*, java.text.DateFormat"%> <% DBConnection con = null; try{ con = new DBConnection( "mysql127.secureserver.net", "reddogent", "reddogent", "Reddog007" ); %> <%@ page language="java" contentType="text/html; charset=iso-8859-1" %> RedDogEntertainment.com | About
<% String sql = "SELECT * FROM about WHERE title='thecompany';"; con.executeQuery( sql ); con.next(); String body = con.getString( "body" ); //body = body.replaceAll( "/images", "/images" ); %> <% sql = "SELECT * FROM about WHERE title='theman';"; con.executeQuery( sql ); con.next(); body = con.getString( "body" ); //body = body.replaceAll( "/images", "/jsp/images" ); %>
THE COMPANY

<%=body%>

THE MAN BEHIND THE COMPANY
launch compilation reel

<%=body%>

<% sql = "SELECT * FROM whats_new LIMIT 0, 3;"; con.executeQuery( sql ); while( con.next() ){ String whatsnewid = con.getString( "whatsnewid" ); String headline = con.getString( "headline" ); if( headline.equals( "na" ) || headline == null ) headline = ""; else headline += "  "; headline = headline.replaceAll( "\\\\", "" ); headline = headline.replaceAll( "'", "\\'" ); body = con.getString( "body" ); body.replaceAll( "\\w'", "\\'" ); body.replaceAll( ";|\\s'", ";\\'" ); body = body.replaceAll( "\\n", "" ); body = body.replaceAll( "\\r", "" ); java.sql.Date dateposted = con.getDate( "dateposted" ); DateFormat formatter = DateFormat.getDateInstance( DateFormat.SHORT ); String datestr = formatter.format( dateposted ); %> <% }/*END WHILE*/ %>
What's New
<%=datestr%> <%=headline%>

<% String root = this.getServletContext().getRealPath( "/images/shows" ); Hashtable catagories = new Hashtable(); sql = "SELECT * FROM shows WHERE showstatus='inthecan';"; con.executeQuery( sql ); while( con.next() ){ Show show = new Show(); show.setShowid( con.getString( "showid" ) ); show.setTitle( con.getString( "title" ) ); show.setDistributor( con.getString( "distributor" ) ); show.setDesc( con.getString( "description" ) ); Catagory catagory = new Catagory( con.getString( "catagoryid" ) ); show.setCatagory( catagory ); Vector shows = (Vector)catagories.get( catagory.getCatagoryid() ); if( shows == null ) shows = new Vector(); shows.add( show ); catagories.put( catagory.getCatagoryid(), shows ); } Enumeration keys = catagories.keys(); while( keys.hasMoreElements() ){ String catagoryid = (String)keys.nextElement(); Catagory catagory = new Catagory( catagoryid ); Vector entries = (Vector)catagories.get( catagoryid ); %> <% for( int i=0; i <% } %> <% } %>
In the Can
<%=catagory.getCatagory()%>
<% if( new java.io.File( root + "/" + show.getShowid() + ".jpg" ).exists() ){ %> <% } %>
<%=show.getTitle()%>

<% }catch( Exception e ){ PrintWriter o = new PrintWriter( out ); e.printStackTrace( o ); }finally{ con.close(); } %>