anchor.diff:          
           propertyfile += "\n"+key+" = "+value+"\n";
   		
  -		return propertyfile;
  -	}
  -	
  +        return propertyfile;
  +    }
  +    
  +    public static String safeGetParameter( ServletRequest request, String name )
  +    {
  +        try
  +        {
  +            String res = request.getParameter( name );
  +            if( res != null ) 
  +            {
  +                res = new String(res.getBytes("ISO-8859-1"),
  +                                 "UTF-8" );
  +            }
  +
  +            return res;
  +        }
  +        catch( UnsupportedEncodingException e )
  +        {
  +            // Should never happen
  +            return "";
  +        }
  +
  +    }
       public void writeProperties( File propertyFile, String contents )
           throws IOException
       {
  -        byte[] bytes = contents.getBytes("ISO-8859-1");
  +        byte[] bytes = contents.getBytes();
           OutputStream out = null;
           
           try
  
positive.code:         return s.trim();
      }
      
  	public String setProperty( String propertyfile, String key, String value )
  	{
          int idx = 0;
          
  		while( (idx < propertyfile.length()) && ((idx = propertyfile.indexOf(key,idx)) != -1) )
  		{
              int prevret = propertyfile.lastIndexOf("\n",idx);
              if( prevret != -1 )
              {
  
negative.code:                     continue;
                  }
              }
              int eqsign = propertyfile.indexOf("=",idx);
  			
              if( eqsign != -1 )
              {
                  int ret = propertyfile.indexOf("\n",eqsign);
  				
                  if( ret == -1 ) ret = propertyfile.length();
  				
                  propertyfile = TextUtil.replaceString( propertyfile, eqsign+1, ret, value );
                  
                  return propertyfile;
              }
              // idx += key.length();
          }
  
          //
          //  If it was not found, we'll add it here.
  