fixed up a few HTML generation issues in tag classes and JSP templates;

added the authenticatePrivileged method; added SQL date parameter method
to the XML-RPC Request object
This commit is contained in:
Eric J. Bowersox 2004-07-19 08:18:19 +00:00
parent 156511e747
commit 681ec6a8a0
15 changed files with 401 additions and 258 deletions

View File

@ -29,6 +29,10 @@
<!-- The pathname of the services config file, relative to the Web application root directory. -->
<services-config>WEB-INF/services-config.xml</services-config>
<!-- If this property is set, these addresses are considered "privileged" and able to log in
as any user -->
<!-- <privileged-addresses>10.29.99.1,127.0.0.1</privileged-addresses> -->
</engine>
<!-- This section is used to configure the database pool system. -->

View File

@ -130,5 +130,7 @@ public interface UserContext extends SearchMode
public void setDateOfBirth(java.sql.Date date) throws DataException;
public void authenticatePrivileged(String username) throws AccessError, DataException;
} // end interface UserContext

View File

@ -1667,6 +1667,95 @@ class UserContextImpl implements UserContext, ServiceProvider, PropertyProvider
} // end setDateOfBirth
public void authenticatePrivileged(String username) throws AccessError, DataException
{
if (isLoggedIn())
{ // already authenticated, can't authenticate again
logger.error("UserContext already authenticated (with uid " + uid + ")");
throw new InternalStateError("context already authenticated");
} // end if
if (logger.isDebugEnabled())
logger.debug("authenticatePrivileged(): authenticating user \"" + username + "\"...");
if (!(globalsite.isPrivilegedAddress(remote_addr)))
{ // not privileged - f**k off
logger.error("source address " + remote_addr + " is not privileged!");
throw new AccessError("Remote address is not privileged!");
} // end if
Connection conn = null;
PreparedStatement stmt = null;
AuditRecord ar = null;
try
{ // look for a user name matching this user record
conn = globalsite.getConnection(null);
stmt = conn.prepareStatement("SELECT * FROM users WHERE username = ?;");
stmt.setString(1,username);
ResultSet rs = stmt.executeQuery();
if (!(rs.next()))
{ // user not found
logger.error("...user not found");
ar = new AuditRecord(AuditRecord.LOGIN_FAIL,0,remote_addr,"Bad username: " + username);
throw new AccessError("The user account you have specified does not exist. Please try again.");
} // end if
int the_uid = rs.getInt("uid");
if (rs.getBoolean("is_anon"))
{ // can't log in as Anonymous Honyak
logger.error("...user is the Anonymous Honyak, can't explicitly login");
ar = new AuditRecord(AuditRecord.LOGIN_FAIL,the_uid,remote_addr,"Anonymous user");
throw new AccessError("This account cannot be explicitly logged into. Please try again.");
} // end if
if (logger.isDebugEnabled())
logger.debug("...authenticated");
// we're authenticated - load the user data into the context
loadUserData(rs);
rs.close();
// update the "last access" time in the database
stmt.close();
stmt = conn.prepareStatement("UPDATE users SET lastaccess = ? WHERE uid = ?;");
java.util.Date mydate = new java.util.Date();
SQLUtil.setFullDateTime(stmt,1,mydate);
stmt.setInt(2,uid);
stmt.executeUpdate();
// update the "last access" time in this object
last_access = mydate;
// an audit record indicating we logged in OK
ar = new AuditRecord(AuditRecord.LOGIN_OK,the_uid,remote_addr,"[privileged]");
if (logger.isDebugEnabled())
logger.debug("...context loaded, we're ready :-)");
} // end try
catch (SQLException e)
{ // database error - this is a DataException
logger.error("DB error reading user data: " + e.getMessage(),e);
throw new DataException("unable to access user data: " + e.getMessage(),e);
} // end catch
finally
{ // make sure the connection is released before we go
SQLUtil.shutdown(stmt);
AuditRecord.store(conn,ar);
SQLUtil.shutdown(conn);
} // end if
} // end authenticatePrivileged
/*--------------------------------------------------------------------------------
* Implementations from interface ServiceProvider
*--------------------------------------------------------------------------------

View File

@ -9,9 +9,9 @@
*
* The Original Code is the Venice Web Communities System.
*
* The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
* The Initial Developer of the Original Code is Eric J. Bowersox <erbo@ricochet.com>,
* for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
* Copyright (C) 2001-02 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
* Copyright (C) 2001-2004 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
*
* Contributor(s):
*/
@ -118,6 +118,7 @@ public class GlobalSiteImpl implements GlobalSite
*/
private ServiceProvider engine_svc = null; // ServiceProvider for the VeniceEngine
private Set m_privileged_addrs = Collections.EMPTY_SET; // privileged addresses
private DataPool datapool = null; // the database pool
private Properties email_props = null; // email properties
private javax.mail.Session mailsession = null; // email session object
@ -140,9 +141,25 @@ public class GlobalSiteImpl implements GlobalSite
this.engine_svc = engine_svc;
XMLLoader loader = XMLLoader.get();
// Get the <database/> section.
// Get the <engine/> section.
DOMElementHelper config_h = new DOMElementHelper(config);
Element sect = loader.configGetSubSection(config_h,"database");
DOMElementHelper sect_h = new DOMElementHelper(sect);
// Get the <privileged-addresses/> value.
String s = sect_h.getSubElementText("privileged-addresses");
if (!(StringUtil.isStringEmpty(s)))
{ // break it up by commas
String[] addrs = StringUtil.splitArray(s,",");
HashSet tmp = new HashSet();
for (int i=0; i<addrs.length; i++)
tmp.add(addrs[i].trim());
m_privileged_addrs = Collections.unmodifiableSet(tmp);
} // end if
// Get the <database/> section.
sect = loader.configGetSubSection(config_h,"database");
try
{ // allocate the data pool object
@ -158,7 +175,7 @@ public class GlobalSiteImpl implements GlobalSite
// Get the <email/> section.
sect = loader.configGetSubSection(config_h,"email");
DOMElementHelper sect_h = new DOMElementHelper(sect);
sect_h = new DOMElementHelper(sect);
// initialize the email properties and get a mail session object
email_props = new Properties();
@ -580,6 +597,12 @@ public class GlobalSiteImpl implements GlobalSite
*--------------------------------------------------------------------------------
*/
public boolean isPrivilegedAddress(String addr)
{
return m_privileged_addrs.contains(addr);
} // end isPrivilegedAddress
public Connection getConnection(String db_selector) throws SQLException
{
// db_selector is ignored for now

View File

@ -9,9 +9,9 @@
*
* The Original Code is the Venice Web Communities System.
*
* The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
* The Initial Developer of the Original Code is Eric J. Bowersox <erbo@ricochet.com>,
* for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
* Copyright (C) 2002 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
* Copyright (C) 2002-2004 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
*
* Contributor(s):
*/
@ -27,12 +27,14 @@ public interface GlobalSite extends ServiceProvider
public static final int TASK_PRIO_NORMAL = 3;
public static final int TASK_PRIO_MAX = 7;
public abstract Connection getConnection(String db_selector) throws SQLException;
public boolean isPrivilegedAddress(String addr);
public abstract String getStockMessage(String key);
public Connection getConnection(String db_selector) throws SQLException;
public abstract void queueTask(Runnable task, int priority);
public String getStockMessage(String key);
public abstract void queueTask(Runnable task);
public void queueTask(Runnable task, int priority);
public void queueTask(Runnable task);
} // end interface GlobalSite

View File

@ -9,9 +9,9 @@
*
* The Original Code is the Venice Web Communities System.
*
* The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
* The Initial Developer of the Original Code is Eric J. Bowersox <erbo@ricochet.com>,
* for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
* Copyright (C) 2001 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
* Copyright (C) 2001-2004 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
*
* Contributor(s):
*/
@ -31,11 +31,11 @@ class ButtonHolder
*--------------------------------------------------------------------------------
*/
private int width;
private int height;
private Map id_to_caption;
private Map id_to_image;
private String tail_tag;
private int m_width;
private int m_height;
private Map m_id_to_caption;
private Map m_id_to_image;
private String m_tail_tag;
/*--------------------------------------------------------------------------------
* Constructor
@ -47,9 +47,9 @@ class ButtonHolder
// get the initial header information
XMLLoader loader = XMLLoader.get();
loader.configVerifyNodeName(cfg,"buttons");
width = loader.configGetAttributeInt(cfg,"width");
height = loader.configGetAttributeInt(cfg,"height");
tail_tag = "\" WIDTH=" + width + " HEIGHT=" + height + " BORDER=0>";
m_width = loader.configGetAttributeInt(cfg,"width");
m_height = loader.configGetAttributeInt(cfg,"height");
m_tail_tag = "\" width=\"" + m_width + "\" height=\"" + m_height + "\" border=\"0\" />";
// load the individual button descriptors
HashMap tmp_caption = new HashMap();
@ -78,30 +78,30 @@ class ButtonHolder
} // end for
if (tmp_caption.isEmpty())
id_to_caption = Collections.EMPTY_MAP;
m_id_to_caption = Collections.EMPTY_MAP;
else
id_to_caption = Collections.unmodifiableMap(tmp_caption);
m_id_to_caption = Collections.unmodifiableMap(tmp_caption);
if (tmp_image.isEmpty())
id_to_image = Collections.EMPTY_MAP;
m_id_to_image = Collections.EMPTY_MAP;
else
id_to_image = Collections.unmodifiableMap(tmp_image);
m_id_to_image = Collections.unmodifiableMap(tmp_image);
} // end constructor
final String getButtonVisual(String id)
{
// Look up the caption and image.
String img = (String)(id_to_image.get(id));
String img = (String)(m_id_to_image.get(id));
if (img==null)
return "";
String caption = (String)(id_to_caption.get(id));
String caption = (String)(m_id_to_caption.get(id));
// Build the returned tag.
StringBuffer buf = new StringBuffer("<IMG SRC=\"");
buf.append(img).append("\" ALT=\"");
StringBuffer buf = new StringBuffer("<img src=\"");
buf.append(img).append("\" alt=\"");
if (caption!=null) // add square brackets, like Links does around <INPUT TYPE=IMAGE>
buf.append("[ ").append(caption).append(" ]");
buf.append(tail_tag);
buf.append(m_tail_tag);
return buf.toString();
} // end getButtonVisual
@ -109,17 +109,17 @@ class ButtonHolder
final String getButtonInput(String id)
{
// Look up the caption and image.
String img = (String)(id_to_image.get(id));
String img = (String)(m_id_to_image.get(id));
if (img==null)
return "";
String caption = (String)(id_to_caption.get(id));
String caption = (String)(m_id_to_caption.get(id));
// Build the returned tag.
StringBuffer buf = new StringBuffer("<INPUT TYPE=IMAGE SRC=\"");
buf.append(img).append("\" NAME=\"").append(id).append("\" ALT=\"");
StringBuffer buf = new StringBuffer("<input type=\"image\" src=\"");
buf.append(img).append("\" name=\"").append(id).append("\" alt=\"");
if (caption!=null)
buf.append(caption);
buf.append(tail_tag);
buf.append(m_tail_tag);
return buf.toString();
} // end getButtonInput

View File

@ -9,9 +9,9 @@
*
* The Original Code is the Venice Web Communities System.
*
* The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
* The Initial Developer of the Original Code is Eric J. Bowersox <erbo@ricochet.com>,
* for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
* Copyright (C) 2001-02 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
* Copyright (C) 2001-2004 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
*
* Contributor(s):
*/
@ -30,8 +30,8 @@ public class UtilButtonTag extends VeniceTagSupport
*--------------------------------------------------------------------------------
*/
private String type = "img";
private String id = null;
private String m_type = "img";
private String m_id = null;
/*--------------------------------------------------------------------------------
* Overrides from class TagSupport
@ -40,17 +40,17 @@ public class UtilButtonTag extends VeniceTagSupport
public int doStartTag() throws JspException
{
if (id==null)
if (m_id==null)
throw new JspTagException("<util:button/> ID not specified!");
if (!(type.equals("img") || type.equals("input")))
if (!(m_type.equals("img") || m_type.equals("input")))
throw new JspTagException("<util:button/> type not valid!");
String data;
HTMLRendering html = (HTMLRendering)(getRequestOutput().queryService(HTMLRendering.class));
if (type.equals("img"))
data = html.getButtonVisual(id);
if (m_type.equals("img"))
data = html.getButtonVisual(m_id);
else
data = html.getButtonInput(id);
data = html.getButtonInput(m_id);
try
{ // write out what we came here to accomplish
@ -71,8 +71,8 @@ public class UtilButtonTag extends VeniceTagSupport
public void release()
{
super.release();
type = "img";
id = null;
m_type = "img";
m_id = null;
} // end release
@ -83,13 +83,13 @@ public class UtilButtonTag extends VeniceTagSupport
public void setType(String s)
{
type = s.trim().toLowerCase();
m_type = s.trim().toLowerCase();
} // end setType
public void setId(String s)
{
id = s;
m_id = s;
} // end setId

View File

@ -9,7 +9,7 @@
*
* The Original Code is the Venice Web Communities System.
*
* The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
* The Initial Developer of the Original Code is Eric J. Bowersox <erbo@ricochet.com>,
* for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
* Copyright (C) 2001-2004 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
*
@ -39,11 +39,11 @@ public class UtilLinkTag extends VeniceTagSupport
*--------------------------------------------------------------------------------
*/
private String href = null;
private String type = null;
private String cls = null;
private String target = null;
private String title = null;
private String m_href = null;
private String m_type = null;
private String m_class = null;
private String m_target = null;
private String m_title = null;
/*--------------------------------------------------------------------------------
* Overrides from class TagSupport
@ -53,39 +53,39 @@ public class UtilLinkTag extends VeniceTagSupport
public int doStartTag() throws JspException
{
// Check the parameters!
if (href==null)
if (m_href==null)
throw new JspTagException("<util:link/> href not specified!");
if (type==null)
if (m_type==null)
throw new JspTagException("<util:link/> type not specified!");
RequestInput ri = getRequestInput();
HTMLRendering html = (HTMLRendering)(ri.queryService(HTMLRendering.class));
int ityp = html.convertLinkType(type);
int ityp = html.convertLinkType(m_type);
if (ityp==-1)
throw new JspTagException("<util:link/> invalid link type!");
try
{ // Do parameter replacement on the HREF string if necessary.
if (href.indexOf(LOCATION_PARAM)>=0)
href = StringUtil.replaceAllInstances(href,LOCATION_PARAM,URLEncoder.encode(ri.getLocation(),"UTF-8"));
if (m_href.indexOf(LOCATION_PARAM)>=0)
m_href = StringUtil.replaceAllInstances(m_href,LOCATION_PARAM,URLEncoder.encode(ri.getLocation(),"UTF-8"));
// write out what we came here to accomplish
JspWriter out = pageContext.getOut();
out.write("<A ");
if (cls!=null)
out.write("CLASS=\"" + cls + "\" ");
out.write("HREF=\"" + html.formatURL(href,ityp) + "\"");
if (title!=null)
out.write(" TITLE=\"" + title + "\"");
if (target!=null)
out.write(" TARGET=\"" + target + "\"");
out.write("<a ");
if (m_class!=null)
out.write("class=\"" + m_class + "\" ");
out.write("href=\"" + html.formatURL(m_href,ityp) + "\"");
if (m_title!=null)
out.write(" title=\"" + m_title + "\"");
if (m_target!=null)
out.write(" target=\"" + m_target + "\"");
out.write(">");
} // end try
catch (IOException e)
{ // convert the I/O error into something the servlet engine can deal with
throw new JspTagException("error writing <A> tag - " + e.getMessage());
throw new JspTagException("error writing <a> tag - " + e.getMessage());
} // end catch
@ -98,12 +98,12 @@ public class UtilLinkTag extends VeniceTagSupport
try
{ // write out what we came here to accomplish
JspWriter out = pageContext.getOut();
out.write("</A>");
out.write("</a>");
} // end try
catch (IOException e)
{ // convert the I/O error into something the servlet engine can deal with
throw new JspTagException("error writing </A> tag - " + e.getMessage());
throw new JspTagException("error writing </a> tag - " + e.getMessage());
} // end catch
@ -114,11 +114,11 @@ public class UtilLinkTag extends VeniceTagSupport
public void release()
{
super.release();
href = null;
type = null;
cls = null;
target = null;
title = null;
m_href = null;
m_type = null;
m_class = null;
m_target = null;
m_title = null;
} // end release
@ -129,31 +129,31 @@ public class UtilLinkTag extends VeniceTagSupport
public void setHref(String s)
{
href = s;
m_href = s;
} // end setHref
public void setType(String s)
{
type = s;
m_type = s;
} // end setType
public void setAclass(String s)
{
cls = s;
m_class = s;
} // end setAclass
public void setTarget(String s)
{
target = s;
m_target = s;
} // end setTarget
public void setTitle(String s)
{
title = s;
m_title = s;
} // end setTitle

View File

@ -9,9 +9,9 @@
*
* The Original Code is the Venice Web Communities System.
*
* The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
* The Initial Developer of the Original Code is Eric J. Bowersox <erbo@ricochet.com>,
* for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
* Copyright (C) 2001-02 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
* Copyright (C) 2001-2004 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
*
* Contributor(s):
*/
@ -38,13 +38,13 @@ public class UtilStdBulletTag extends VeniceTagSupport
{ // write out what we came here to accomplish
JspWriter out = pageContext.getOut();
// TODO: make this configurable
out.write("<IMG SRC=\"" + html.getImagePath("purple-ball.gif")
+ "\" ALT=\"*\" WIDTH=14 HEIGHT=14 BORDER=0>");
out.write("<img src=\"" + html.getImagePath("purple-ball.gif")
+ "\" alt=\"*\" width=\"14\" height=\"14\" border=\"0\" />");
} // end try
catch (IOException e)
{ // convert the I/O error into something the servlet engine can deal with
throw new JspTagException("error writing button - " + e.getMessage());
throw new JspTagException("error writing standard bullet - " + e.getMessage());
} // end catch

View File

@ -9,7 +9,7 @@
*
* The Original Code is the Venice Web Communities System.
*
* The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
* The Initial Developer of the Original Code is Eric J. Bowersox <erbo@ricochet.com>,
* for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
* Copyright (C) 2001-2004 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
*
@ -39,13 +39,13 @@ public class UtilXLinkTag extends VeniceBodyTagSupport
*--------------------------------------------------------------------------------
*/
private String href = null;
private int type = -1;
private String cls = null;
private String target = null;
private String text = null;
private String title = null;
private boolean target_external = false;
private String m_href = null;
private int m_type = -1;
private String m_class = null;
private String m_target = null;
private String m_text = null;
private String m_title = null;
private boolean m_target_external = false;
/*--------------------------------------------------------------------------------
* Overrides from class BodyTagSupport
@ -67,11 +67,11 @@ public class UtilXLinkTag extends VeniceBodyTagSupport
public int doEndTag() throws JspException
{
// Do some shorts-checking on our stored data.
if (href==null)
if (m_href==null)
throw new JspTagException("<util:xlink/> does not have a <util:href/>!");
if (type<0)
if (m_type<0)
throw new JspTagException("<util:xlink/> does not have a <util:href/>!");
if (text==null)
if (m_text==null)
throw new JspTagException("<util:xlink/> does not have a <util:text/>!");
// Dig out the RequestInput and HTMLRendering service.
@ -80,35 +80,35 @@ public class UtilXLinkTag extends VeniceBodyTagSupport
try
{ // Do parameter replacement on the HREF string if necessary.
if (href.indexOf(LOCATION_PARAM)>=0)
href = StringUtil.replaceAllInstances(href,LOCATION_PARAM,URLEncoder.encode(ri.getLocation(),"UTF-8"));
if (m_href.indexOf(LOCATION_PARAM)>=0)
m_href = StringUtil.replaceAllInstances(m_href,LOCATION_PARAM,URLEncoder.encode(ri.getLocation(),"UTF-8"));
// write out what we came here to accomplish
JspWriter out = pageContext.getOut();
out.write("<A ");
if (cls!=null)
out.write("CLASS=\"" + cls + "\" ");
out.write("HREF=\"" + html.formatURL(href,type) + "\"");
if (title!=null)
out.write(" TITLE=\"" + title + "\"");
if (target!=null)
out.write(" TARGET=\"" + target + "\"");
out.write(">" + text + "</A>");
out.write("<a ");
if (m_class!=null)
out.write("class=\"" + m_class + "\" ");
out.write("href=\"" + html.formatURL(m_href,m_type) + "\"");
if (m_title!=null)
out.write(" title=\"" + m_title + "\"");
if (m_target!=null)
out.write(" target=\"" + m_target + "\"");
out.write(">" + m_text + "</a>");
} // end try
catch (IOException e)
{ // convert the I/O error into something the servlet engine can deal with
throw new JspTagException("error writing <A> tag - " + e.getMessage());
throw new JspTagException("error writing <a/> tag - " + e.getMessage());
} // end catch
href = null;
type = -1;
text = null;
title = null;
if (target_external)
target = null;
target_external = false;
m_href = null;
m_type = -1;
m_text = null;
m_title = null;
if (m_target_external)
m_target = null;
m_target_external = false;
return EVAL_PAGE;
} // end doEndTag
@ -116,8 +116,8 @@ public class UtilXLinkTag extends VeniceBodyTagSupport
public void release()
{
super.release();
cls = null;
target = null;
m_class = null;
m_target = null;
} // end release
@ -128,13 +128,13 @@ public class UtilXLinkTag extends VeniceBodyTagSupport
public void setAclass(String s)
{
cls = s;
m_class = s;
} // end setAclass
public void setTarget(String s)
{
target = s;
m_target = s;
} // end setTarget
@ -145,29 +145,29 @@ public class UtilXLinkTag extends VeniceBodyTagSupport
final void setLink(String href, int type)
{
this.href = href;
this.type = type;
m_href = href;
m_type = type;
} // end setLink
final void setText(String text)
{
this.text = text;
m_text = text;
} // end setText
final void setTitle(String title)
{
this.title = title;
m_title = title;
} // end setTitle
final void setTarget2(String s)
{
if (target==null)
if (m_target==null)
{ // set target via external tag
target = s;
target_external = true;
m_target = s;
m_target_external = true;
} // end if

View File

@ -9,9 +9,9 @@
*
* The Original Code is the Venice Web Communities System.
*
* The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
* The Initial Developer of the Original Code is Eric J. Bowersox <erbo@ricochet.com>,
* for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
* Copyright (C) 2002 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
* Copyright (C) 2002-2004 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
*
* Contributor(s):
*/
@ -36,18 +36,18 @@ public class XmlRpcRequest
*--------------------------------------------------------------------------------
*/
private static Category logger = Category.getInstance(XmlRpcRequest.class);
private static Logger logger = Logger.getLogger(XmlRpcRequest.class);
private static SimpleTimeZone utc = new SimpleTimeZone(0,"UTC");
private static SimpleTimeZone s_utc = new SimpleTimeZone(0,"UTC");
/*--------------------------------------------------------------------------------
* Attributes
*--------------------------------------------------------------------------------
*/
RequestInput req; // request input system
String method_name; // the method name
List method_params; // the method parameters
RequestInput m_req; // request input system
String m_method_name; // the method name
List m_method_params; // the method parameters
/*--------------------------------------------------------------------------------
* Constructors
@ -64,7 +64,7 @@ public class XmlRpcRequest
XMLLoader loader = XMLLoader.get();
Element root = loader.postGetRootElement(req_doc,"methodCall");
DOMElementHelper root_h = new DOMElementHelper(root);
method_name = loader.postGetSubElementText(root_h,"methodName");
m_method_name = loader.postGetSubElementText(root_h,"methodName");
// parse the parameters
Element params = root_h.getSubElement("params");
@ -91,11 +91,11 @@ public class XmlRpcRequest
// save the method parameters
if (tmp_method_params.isEmpty())
method_params = Collections.EMPTY_LIST;
m_method_params = Collections.EMPTY_LIST;
else
{ // make it read-only before
tmp_method_params.trimToSize();
method_params = Collections.unmodifiableList(tmp_method_params);
m_method_params = Collections.unmodifiableList(tmp_method_params);
} // end else
@ -106,15 +106,15 @@ public class XmlRpcRequest
} // end catch
this.req = req; // save reference off
m_req = req; // save reference off
} // end constructor
XmlRpcRequest(RequestInput req, String method_name, List method_params)
{
this.req = req;
this.method_name = method_name;
this.method_params = method_params;
m_req = req;
m_method_name = method_name;
m_method_params = method_params;
} // end constructor
@ -226,7 +226,7 @@ public class XmlRpcRequest
try
{ // use a GregorianCalendar to convert the fields into the appropriate format
GregorianCalendar cal = new GregorianCalendar(utc);
GregorianCalendar cal = new GregorianCalendar(s_utc);
cal.set(Calendar.YEAR,Integer.parseInt(dstr.substring(0,4)));
cal.set(Calendar.MONTH,Integer.parseInt(dstr.substring(4,6)) - 1 + Calendar.JANUARY);
cal.set(Calendar.DAY_OF_MONTH,Integer.parseInt(dstr.substring(6,8)));
@ -396,31 +396,31 @@ public class XmlRpcRequest
public final String getMethod()
{
return method_name;
return m_method_name;
} // end getMethod
public final int getParamCount()
{
return method_params.size();
return m_method_params.size();
} // end getParamCount
public final List getParams()
{
return method_params;
return m_method_params;
} // end getParams
public final Object getParam(int ndx)
{
return method_params.get(ndx);
return m_method_params.get(ndx);
} // end getParam
public final String getParamType(int ndx)
{
Object foo = method_params.get(ndx);
Object foo = m_method_params.get(ndx);
if (foo instanceof Integer)
return "int";
if (foo instanceof Boolean)
@ -429,7 +429,7 @@ public class XmlRpcRequest
return "string";
if (foo instanceof Double)
return "double";
if (foo instanceof Date)
if (foo instanceof java.util.Date)
return "dateTime";
if (foo instanceof byte[])
return "base64";
@ -443,7 +443,7 @@ public class XmlRpcRequest
public final int getParamInt(int ndx) throws XmlRpcFault
{
Object foo = method_params.get(ndx);
Object foo = m_method_params.get(ndx);
if (foo instanceof Integer)
return ((Integer)foo).intValue();
else if (foo instanceof Boolean)
@ -455,11 +455,11 @@ public class XmlRpcRequest
public final double getParamDouble(int ndx) throws XmlRpcFault
{
Object foo = method_params.get(ndx);
Object foo = m_method_params.get(ndx);
if ((foo instanceof Integer) || (foo instanceof Double))
return ((Number)foo).doubleValue();
else if (foo instanceof Boolean)
return ((Boolean)foo).booleanValue() ? 1 : 0;
return ((Boolean)foo).booleanValue() ? 1.0 : 0.0;
else
throw new XmlRpcFault(XmlRpcFault.INVALID_PARAMS,"parameter type mismatch");
@ -467,7 +467,7 @@ public class XmlRpcRequest
public final String getParamString(int ndx) throws XmlRpcFault
{
Object foo = method_params.get(ndx);
Object foo = m_method_params.get(ndx);
if ((foo instanceof byte[]) || (foo instanceof List) || (foo instanceof Map))
throw new XmlRpcFault(XmlRpcFault.INVALID_PARAMS,"parameter type mismatch");
@ -475,22 +475,43 @@ public class XmlRpcRequest
} // end getParamString
public final java.sql.Date getParamSQLDate(int ndx) throws XmlRpcFault
{
Object foo = m_method_params.get(ndx);
if (!(foo instanceof java.util.Date))
throw new XmlRpcFault(XmlRpcFault.INVALID_PARAMS,"parameter type mismatch");
// need to crosswise convert this
Calendar cal_src = new GregorianCalendar(s_utc);
cal_src.setTime((java.util.Date)foo);
Calendar cal_dest = Calendar.getInstance();
cal_dest.set(Calendar.YEAR,cal_src.get(Calendar.YEAR));
cal_dest.set(Calendar.MONTH,cal_src.get(Calendar.MONTH));
cal_dest.set(Calendar.DAY_OF_MONTH,cal_src.get(Calendar.DAY_OF_MONTH));
cal_dest.set(Calendar.HOUR,0);
cal_dest.set(Calendar.MINUTE,0);
cal_dest.set(Calendar.SECOND,0);
cal_dest.set(Calendar.MILLISECOND,0);
return new java.sql.Date(cal_dest.getTimeInMillis());
} // end getParamSQLDate
public final CommunityContext getParamCommunity(int ndx) throws XmlRpcFault, DataException
{
Object foo = method_params.get(ndx);
Object foo = m_method_params.get(ndx);
if ((foo instanceof byte[]) || (foo instanceof List) || (foo instanceof Map) || (foo instanceof Boolean))
throw new XmlRpcFault(XmlRpcFault.INVALID_PARAMS,"parameter type mismatch");
if (foo instanceof Integer)
return req.getUser().getCommunityContext(((Integer)foo).intValue());
return m_req.getUser().getCommunityContext(((Integer)foo).intValue());
else
return req.getUser().getCommunityContext(foo.toString().trim());
return m_req.getUser().getCommunityContext(foo.toString().trim());
} // end getParamCommunity
public final ConferenceContext getParamConference(int ndx, CommunityContext comm)
throws XmlRpcFault, DataException, AccessError
{
Object foo = method_params.get(ndx);
Object foo = m_method_params.get(ndx);
if ((foo instanceof byte[]) || (foo instanceof List) || (foo instanceof Map) || (foo instanceof Boolean))
throw new XmlRpcFault(XmlRpcFault.INVALID_PARAMS,"parameter type mismatch");
if (foo instanceof Integer)
@ -503,7 +524,7 @@ public class XmlRpcRequest
public final TopicContext getParamTopic(int ndx, ConferenceContext conf)
throws XmlRpcFault, DataException, AccessError
{
Object foo = method_params.get(ndx);
Object foo = m_method_params.get(ndx);
if (!(foo instanceof Integer))
throw new XmlRpcFault(XmlRpcFault.INVALID_PARAMS,"parameter type mismatch");
return conf.getTopic(((Integer)foo).shortValue());
@ -513,7 +534,7 @@ public class XmlRpcRequest
public final TopicMessageContext getParamPost(int ndx, TopicContext topic)
throws XmlRpcFault, DataException, AccessError
{
Object foo = method_params.get(ndx);
Object foo = m_method_params.get(ndx);
if (!(foo instanceof Integer))
throw new XmlRpcFault(XmlRpcFault.INVALID_PARAMS,"parameter type mismatch");
return topic.getMessage(((Integer)foo).intValue());

View File

@ -9,9 +9,9 @@
The Original Code is the Venice Web Communities System.
The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
The Initial Developer of the Original Code is Eric J. Bowersox <erbo@ricochet.com>,
for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
Copyright (C) 2001-02 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
Copyright (C) 2001-2004 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
Contributor(s):
--%>
@ -32,24 +32,24 @@
<util:header title="Community Profile:">
<util:subtitle><util:escape><%= comm.getName() %></util:escape></util:subtitle>
</util:header>
<TABLE BORDER=0 CELLPADDING=6 CELLSPACING=0><TR VALIGN=TOP>
<TD ALIGN=LEFT CLASS="c2"><util:font color="content.fg" size="profile-dates">
<%= view.getRequestAttribute("community.logo").toString() %><BR>
<table border="0" cellpadding="6" cellspacing="0"><tr valign="top">
<td align="left" class="c2"><util:font color="content.fg" size="profile-dates">
<%= view.getRequestAttribute("community.logo").toString() %><br />
<% java.util.Date tmpd = comm.getCreationDate(); %>
<% if (tmpd!=null) { %>
Community created:<BR><util:escape><%= view.formatDate(tmpd) %></util:escape><BR>
Community created:<br /><util:escape><%= view.formatDate(tmpd) %></util:escape><br />
<% } // end if %>
<% tmpd = comm.getLastAccessDate(); %>
<% if (tmpd!=null) { %>
Last accessed:<BR><util:escape><%= view.formatDate(tmpd) %></util:escape><BR>
Last accessed:<br /><util:escape><%= view.formatDate(tmpd) %></util:escape><br />
<% } // end if %>
<% tmpd = comm.getLastUpdateDate(); %>
<% if (tmpd!=null) { %>
Profile last updated:<BR><util:escape><%= view.formatDate(tmpd) %></util:escape><BR>
Profile last updated:<br /><util:escape><%= view.formatDate(tmpd) %></util:escape><br />
<% } // end if %>
<user:is_logged_in>
<DIV ALIGN="CENTER">
<div align="center">
<comm:can_join>
<util:xlink>
<util:href type="servlet">comm/join.js.vs?cc=<comm:ID/></util:href>
@ -64,20 +64,20 @@
</util:xlink>
</comm:can_send_invite>
</comm:cannot_join>
</DIV>
</div>
</user:is_logged_in>
</util:font></TD>
</util:font></td>
<TD ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="content">
<comm:is_public><B><U>Public Community</U></B></comm:is_public>
<comm:is_private><B><U>Private Community</U></B></comm:is_private>
<td align="left" class="content"><util:font color="content.fg" size="content">
<comm:is_public><b><u>Public Community</u></b></comm:is_public>
<comm:is_private><b><u>Private Community</u></b></comm:is_private>
<global:categories_enabled>
<BR>
<B>Category:</B>
<br />
<b>Category:</b>
<% CategoryDescriptor cat = (CategoryDescriptor)(view.getRequestAttribute("category")); %>
<% for (int i=0; i<cat.getNumLevels(); i++) { %>
<% if (i>0) { %>: <% } %>
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">
find.js.vs?disp=<%= FindView.FD_COMMUNITIES %>&cat=<%= cat.getIDAtLevel(i) %>
</util:href>
@ -85,39 +85,40 @@
</util:xlink>
<% } // end for %>
</global:categories_enabled>
<P>
<br />
<EM><util:escape><comm:synopsis/></util:escape></EM><P>
<i><util:escape><comm:synopsis/></util:escape></i><p />
<% UserProfile prof = (UserProfile)(view.getRequestAttribute("host.profile")); %>
<B>Host:</B>
<util:xlink>
<b>Host:</b>
<util:xlink aclass="content">
<util:href type="servlet">user/<%= prof.getUserName() %></util:href>
<util:text><%= prof.getUserName() %></util:text>
</util:xlink><BR>
</util:xlink><br />
<% ContactInfo ci = (ContactInfo)(view.getRequestAttribute("contact.info")); %>
<B>Location:</B><BR>
<b>Location:</b><br />
<% tmp = ci.getCompany(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><BR><% } %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><br /><% } %>
<% tmp = ci.getAddressLine1(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><BR><% } %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><br /><% } %>
<% tmp = ci.getAddressLine2(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><BR><% } %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><br /><% } %>
<% tmp = view.getRequestAttribute("address.lastline").toString(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><BR><% } %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><br /><% } %>
<% tmp = view.getRequestAttribute("address.country").toString(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><BR><% } %>
<BR>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><util:escape><%= tmp %></util:escape><br /><% } %>
<br />
<% tmp = comm.getLanguageFullName(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><B>Primary Language:</B>
<util:escape><%= tmp %></util:escape><BR><% } %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><b>Primary Language:</b>
<util:escape><%= tmp %></util:escape><br /><% } %>
<% tmp = comm.getRules(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><B>Standards of Conduct:</B>
<util:escape><%= tmp %></util:escape><BR><% } %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><b>Standards of Conduct:</b>
<util:escape><%= tmp %></util:escape><br /><% } %>
<% tmp = ci.getURL(); %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><B>Homepage:</B>
<A HREF="<%= tmp %>"><util:escape><%= tmp %></util:escape></A><BR><% } %>
<% if (!(StringUtil.isStringEmpty(tmp))) { %><b>Homepage:</b>
<a href="<%= tmp %>" class="content"><util:escape><%= tmp %></util:escape></a><br /><% } %>
</util:font></TD>
</TR></TABLE>
</util:font></td>
</tr></table>
<%-- EOF --%>

View File

@ -9,9 +9,9 @@
The Original Code is the Venice Web Communities System.
The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
The Initial Developer of the Original Code is Eric J. Bowersox <erbo@ricochet.com>,
for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
Copyright (C) 2001-02 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
Copyright (C) 2001-2004 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
Contributor(s):
--%>
@ -31,13 +31,13 @@
<util:subtitle><util:escape><comm:name/></util:escape></util:subtitle>
</util:header>
<% if (confs.size()>0) { %>
<TABLE BORDER=0 ALIGN=LEFT>
<table border="0" align="left">
<% for (int i=0; i<confs.size(); i++) { %>
<TR VALIGN=TOP>
<TD ALIGN=CENTER WIDTH=14><util:stdbullet/></TD>
<TD ALIGN=LEFT CLASS="content"><util:font color="content.fg" size="content">
<tr valign="top">
<td align="center" width="14"><util:stdbullet/></td>
<td align="left" class="content"><util:font color="content.fg" size="content">
<% ConferenceContext conf = (ConferenceContext)(confs.get(i)); %>
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">conf/topics.js.vs?cc=<comm:ID/>&conf=<%= conf.getConfID() %></util:href>
<util:text><util:escape><%= conf.getName() %></util:escape></util:text>
</util:xlink> -
@ -48,32 +48,32 @@
<util:text><util:image src="tag_new.gif" fixup="true" alt="New!" width="40" height="20"/></util:text>
</util:xlink>
<% } // end if %>
<BR>
<br />
<% List hosts1 = (List)(hosts.get(i)); %>
<% if (hosts1.size()>0) { %>
<% if (hosts1.size()>1) { %>Hosts:<% } else { %>Host:<% } %>
<% for (int j=0; j<hosts1.size(); j++) { %>
<% UserFound uf = (UserFound)(hosts1.get(j)); %>
<% if (j>0) { %>, <% } %>
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">user/<%= uf.getName() %></util:href>
<util:text><%= uf.getName() %></util:text>
</util:xlink>
<% } // end for %>
<% } else { %>
Hosts: <EM>(none)</EM>
Hosts: <i>(none)</i>
<% } // end if (hosts present in the conterence) %>
<BR>
<EM><util:escape><%= conf.getDescription() %></util:escape></EM>
</util:font></TD>
</TR>
<br />
<i><util:escape><%= conf.getDescription() %></util:escape></i>
</util:font></td>
</tr>
<% } // end for %>
</TABLE><BR CLEAR=LEFT>
</table><br clear="left" />
<% } else { %>
<util:font color="content.fg" size="content"><EM>No conferences found in this community.</EM></util:font><BR>
<util:font color="content.fg" size="content"><i>No conferences found in this community.</i></util:font><br />
<% } // end if %>
<P>
<DIV ALIGN="LEFT" CLASS="content">
<p />
<div align="left" class="content">
<util:xlink>
<util:href type="servlet">conf/find.js.vs?cc=<comm:ID/></util:href>
<util:text><util:button id="find"/></util:text>
@ -90,4 +90,5 @@
<util:text><util:button id="createnew"/></util:text>
</util:xlink>&nbsp;
</conf:can_create>
</DIV>
</div>
<%-- EOF --%>

View File

@ -147,13 +147,13 @@
<td nowrap="nowrap" align="right" class="content"><util:font color="content.fg" size="content">
<util:comment>Upper navigation linkset</util:comment>
<a name="top">[</a>&nbsp;
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">conf/posts.js.vs?<%= topic_locator %>&p1=0&p2=-1</util:href>
<util:text>View All</util:text>
</util:xlink>
<% if (my_first>0) { %>
&nbsp;|&nbsp;
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">
conf/posts.js.vs?<%= topic_locator %>&p1=<%= Math.max(my_first - my_pagesize,0) %>&p2=<%= my_first - 1 - Math.min(my_first - my_pagesize,0) %>
</util:href>
@ -164,14 +164,14 @@ conf/posts.js.vs?<%= topic_locator %>&p1=<%= Math.max(my_first - my_pagesize,0)
if ((my_total_msg - (my_last + 1))>0) {
%>
&nbsp;|&nbsp;
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">
conf/posts.js.vs?<%= topic_locator %>&p1=<%= my_last + 1 %>&p2=<%= Math.min(my_last + my_pagesize,my_total_msg - 1) %>
</util:href>
<util:text>Scroll Down <%= my_pagesize %></util:text>
</util:xlink>
&nbsp;|&nbsp;
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">
conf/posts.js.vs?<%= topic_locator %>&p1=<%= my_total_msg - my_pagesize %>&p2=<%= my_total_msg - 1 %>
</util:href>
@ -179,18 +179,18 @@ conf/posts.js.vs?<%= topic_locator %>&p1=<%= my_last + 1 %>&p2=<%= Math.min(my_l
</util:xlink>
<% } // end if %>
&nbsp;|&nbsp;
<a href="#bottom">Bottom</a>
<a class="content" href="#bottom">Bottom</a>
&nbsp;]
</util:font></td>
</tr>
<tr valign="middle">
<td align="center" colspan="2"><util:font color="content.fg" size="post-reference">
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet"><%= view.getPageQID() %></util:href>
<util:text>[Permalink to this topic]</util:text>
</util:xlink>
&nbsp;&nbsp;
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet"><%= view.getPageQID() %>.<%= my_first %>-<%= my_last %></util:href>
<util:text>[Permalink to these posts]</util:text>
</util:xlink>
@ -222,20 +222,20 @@ conf/posts.js.vs?<%= topic_locator %>&p1=<%= my_last + 1 %>&p2=<%= Math.min(my_l
out.write(view.getUserPhotoTag(JSPView.getRequestOutput(request),msg.getCreatorUID()));
} // end if
%>
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">
conf/posts.js.vs?<%= topic_locator %>&shac=1&p1=<%= msg.getPostNumber() %>
</util:href>
<util:text><%= msg.getPostNumber() %></util:text>
</util:xlink> of
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">conf/posts.js.vs?<%= topic_locator %>&<%= last_post %></util:href>
<util:text><%= my_total_msg - 1 %></util:text>
</util:xlink>
<util:font color="content.fg" size="post-reference">
&lt;<%= view.getTopicStem() %><%= msg.getPostNumber() %>&gt;
&nbsp;&nbsp;
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet"><%= view.getPageQID() %>.<%= msg.getPostNumber() %></util:href>
<util:text>[Permalink]</util:text>
</util:xlink>
@ -249,7 +249,7 @@ conf/posts.js.vs?<%= topic_locator %>&p1=<%= my_last + 1 %>&p2=<%= Math.min(my_l
if (view.showBozoFilteredIndicator(msg.getCreatorUID())) {
%>
<b><i>(User filtered;
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">
conf/message_bozo.js.vs?<%= topic_locator %>&msg=<%= msg.getPostNumber() %>&flag=0
</util:href>
@ -264,7 +264,7 @@ conf/posts.js.vs?<%= topic_locator %>&p1=<%= my_last + 1 %>&p2=<%= Math.min(my_l
<br />
<b><%= msg.getPseud() %></b>
(<i>
<util:xlink target="_blank">
<util:xlink aclass="content" target="_blank">
<util:href type="servlet">user/<%= poster %></util:href>
<util:text><%= poster %></util:text>
</util:xlink>,
@ -418,12 +418,12 @@ conf/posts.js.vs?<%= topic_locator %>&p1=<%= my_last + 1 %>&p2=<%= Math.min(my_l
<table border="0" width="100%" cellpadding="0" cellspacing="0">
<tr valign="middle">
<td align="center" colspan="2"><util:font color="content.fg" size="post-reference">
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet"><%= view.getPageQID() %></util:href>
<util:text>[Permalink to this topic]</util:text>
</util:xlink>
&nbsp;&nbsp;
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet"><%= view.getPageQID() %>.<%= my_first %>-<%= my_last %></util:href>
<util:text>[Permalink to these posts]</util:text>
</util:xlink>
@ -434,13 +434,13 @@ conf/posts.js.vs?<%= topic_locator %>&p1=<%= my_last + 1 %>&p2=<%= Math.min(my_l
<td nowrap="nowrap" align="right" class="content"><util:font color="content.fg" size="content">
<util:comment>Lower navigation linkset</util:comment>
<a name="bottom">[</a>&nbsp;
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">conf/posts.js.vs?<%= topic_locator %>&p1=0&p2=-1</util:href>
<util:text>View All</util:text>
</util:xlink>
<% if (my_first>0) { %>
&nbsp;|&nbsp;
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">
conf/posts.js.vs?<%= topic_locator %>&p1=<%= Math.max(my_first - my_pagesize,0) %>&p2=<%= my_first - 1 - Math.min(my_first - my_pagesize,0) %>
</util:href>
@ -449,14 +449,14 @@ conf/posts.js.vs?<%= topic_locator %>&p1=<%= Math.max(my_first - my_pagesize,0)
<% } // end if %>
<% if ((my_total_msg - (my_last + 1))>0) { %>
&nbsp;|&nbsp;
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">
conf/posts.js.vs?<%= topic_locator %>&p1=<%= my_last + 1 %>&p2=<%= Math.min(my_last + my_pagesize,my_total_msg - 1) %>
</util:href>
<util:text>Scroll Down <%= my_pagesize %></util:text>
</util:xlink>
&nbsp;|&nbsp;
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">
conf/posts.js.vs?<%= topic_locator %>&p1=<%= my_total_msg - my_pagesize %>&p2=<%= my_total_msg - 1 %>
</util:href>
@ -464,7 +464,7 @@ conf/posts.js.vs?<%= topic_locator %>&p1=<%= my_last + 1 %>&p2=<%= Math.min(my_l
</util:xlink>
<% } // end if %>
&nbsp;|&nbsp;
<a href="#top">Top</a>
<a class="content" href="#top">Top</a>
&nbsp;]
</util:font></td>
</tr>

View File

@ -84,7 +84,7 @@
</util:xlink>&nbsp;
</conf:can_add_to_hotlist>
<br />
<util:font color="content.fg" size="post-reference"><util:xlink>
<util:font color="content.fg" size="post-reference"><util:xlink aclass="content">
<util:href type="servlet"><%= view.getPageQID() %></util:href>
<util:text>[Permalink to this conference]</util:text>
</util:xlink></util:font>
@ -96,31 +96,31 @@
<table width="100%" border="0" cellpadding="0" cellspacing="3">
<tr valign="top">
<td align="left" width="1%" class="content" nowrap="nowrap"><util:font color="content.fg" size="content">
<b><util:xlink>
<b><util:xlink aclass="content">
<util:href type="servlet">conf/topics.js.vs?<%= base_locator %>&sort=<%= ((sort_opt==SORT_NUMBER) ? -SORT_NUMBER : SORT_NUMBER) %></util:href>
<util:text>#</util:text>
</util:xlink></b>&nbsp;&nbsp;
</util:font></td>
<td align="left" class="content"><util:font color="content.fg" size="content">
<b><util:xlink>
<b><util:xlink aclass="content">
<util:href type="servlet">conf/topics.js.vs?<%= base_locator %>&sort=<%= ((sort_opt==SORT_NAME) ? -SORT_NAME : SORT_NAME) %></util:href>
<util:text>Topic Name</util:text>
</util:xlink></b>
</util:font></td>
<td align="right" class="content" nowrap="nowrap"><util:font color="content.fg" size="content">
<b><util:xlink>
<b><util:xlink aclass="content">
<util:href type="servlet">conf/topics.js.vs?<%= base_locator %>&sort=<%= ((sort_opt==SORT_UNREAD) ? -SORT_UNREAD : SORT_UNREAD) %></util:href>
<util:text>New</util:text>
</util:xlink></b>
</util:font></td>
<td align="right" class="content" nowrap="nowrap"><util:font color="content.fg" size="content">
<b><util:xlink>
<b><util:xlink aclass="content">
<util:href type="servlet">conf/topics.js.vs?<%= base_locator %>&sort=<%= ((sort_opt==SORT_TOTAL) ? -SORT_TOTAL : SORT_TOTAL) %></util:href>
<util:text>Total</util:text>
</util:xlink></b>
</util:font></td>
<td align="left" class="content" nowrap="nowrap"><util:font color="content.fg" size="content">
<b><util:xlink>
<b><util:xlink aclass="content">
<util:href type="servlet">conf/topics.js.vs?<%= base_locator %>&sort=<%= ((sort_opt==SORT_DATE) ? -SORT_DATE : SORT_DATE) %></util:href>
<util:text>Last Response</util:text>
</util:xlink></b>
@ -137,13 +137,13 @@
%>
<tr valign="top">
<td align="left" width="1%" class="content" nowrap="nowrap"><util:font color="content.fg" size="content">
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">conf/posts.js.vs?<%= my_locator %>&rnm=1</util:href>
<util:text><%= num %></util:text>
</util:xlink>&nbsp;&nbsp;
</util:font></td>
<td align="left" class="content"><util:font color="content.fg" size="content">
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">conf/posts.js.vs?<%= my_locator %>&rnm=1</util:href>
<util:text><%= topic.getName() %></util:text>
</util:xlink>
@ -157,19 +157,19 @@
<% } // end if %>
</util:font></td>
<td align="right" class="content" nowrap="nowrap"><util:font color="content.fg" size="content">
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">conf/posts.js.vs?<%= my_locator %>&rnm=1</util:href>
<util:text><%= topic.getUnreadMessages() %></util:text>
</util:xlink>
</util:font></td>
<td align="right" class="content" nowrap="nowrap"><util:font color="content.fg" size="content">
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">conf/posts.js.vs?<%= my_locator %>&p1=0&p2=-1</util:href>
<util:text><%= topic.getTotalMessages() %></util:text>
</util:xlink>
</util:font></td>
<td align="left" class="content" nowrap="nowrap"><util:font color="content.fg" size="content">
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">conf/posts.js.vs?<%= my_locator %>&rnm=1</util:href>
<util:text><%= view.formatDate(topic.getLastUpdateDate()) %></util:text>
</util:xlink>
@ -212,7 +212,7 @@
<% if (view_opt==DISPLAY_NEW) { %>
<b>New</b>
<% } else { %>
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">conf/topics.js.vs?<%= base_locator %>&view=<%= DISPLAY_NEW %></util:href>
<util:text>New</util:text>
</util:xlink>
@ -221,7 +221,7 @@
<% if (view_opt==DISPLAY_ACTIVE) { %>
<b>Active</b>
<% } else { %>
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">conf/topics.js.vs?<%= base_locator %>&view=<%= DISPLAY_ACTIVE %></util:href>
<util:text>Active</util:text>
</util:xlink>
@ -230,7 +230,7 @@
<% if (view_opt==DISPLAY_ALL) { %>
<b>All</b>
<% } else { %>
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">conf/topics.js.vs?<%= base_locator %>&view=<%= DISPLAY_ALL %></util:href>
<util:text>All</util:text>
</util:xlink>
@ -239,7 +239,7 @@
<% if (view_opt==DISPLAY_HIDDEN) { %>
<b>Hidden</b>
<% } else { %>
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">conf/topics.js.vs?<%= base_locator %>&view=<%= DISPLAY_HIDDEN %></util:href>
<util:text>Hidden</util:text>
</util:xlink>
@ -248,7 +248,7 @@
<% if (view_opt==DISPLAY_ARCHIVED) { %>
<b>Archived</b>
<% } else { %>
<util:xlink>
<util:xlink aclass="content">
<util:href type="servlet">conf/topics.js.vs?<%= base_locator %>&view=<%= DISPLAY_ARCHIVED %></util:href>
<util:text>Archived</util:text>
</util:xlink>