我需要通过 IMAPS JavaMail 连接到 Microsoft Exchange Server。首先,我得到了:
A1 NO AUTHENTICATE failed.
javax.mail.AuthenticationFailedException: AUTHENTICATE failed.
Run Code Online (Sandbox Code Playgroud)
我的调试器中的异常。
然后,我禁用了一些身份验证协议:
imapProps.setProperty("mail.imaps.auth.plain.disable", "true");
imapProps.setProperty("mail.imaps.auth.ntlm.disable", "true");
imapProps.setProperty("mail.imaps.auth.gssapi.disable", "true");
Run Code Online (Sandbox Code Playgroud)
这是我得到的新异常(我附上了整个日志):
DEBUG: setDebug: JavaMail version 1.4.4
DEBUG: getProvider() returning javax.mail.Provider[STORE,imaps,com.sun.mail.imap.IMAPSSLStore,Sun Microsystems, Inc]
DEBUG: mail.imap.fetchsize: 16384
DEBUG: mail.imap.statuscachetimeout: 1000
DEBUG: mail.imap.appendbuffersize: -1
DEBUG: mail.imap.minidletime: 10
DEBUG: disable AUTH=PLAIN
DEBUG: disable AUTH=NTLM
DEBUG: enable STARTTLS
DEBUG: trying to connect to host "host.domain.com", port 993, isSSL true
* OK The Microsoft Exchange IMAP4 service is ready.
A0 CAPABILITY
* CAPABILITY IMAP4 …Run Code Online (Sandbox Code Playgroud) 我已经将用户定义的类中的对象添加到HashMap中.当插入Drools代码时,我可以遍历HashMap并获取键和值对.但我无法访问用户类中的属性,这是HashMap的值部分.
这是用于保存数据的POJO文件.此POJO将使用单独的键插入LinkedHashMap.目前,这个密钥只是使用一个简单的for循环生成.
package com.sample.pojos;
import java.util.Date;
public class DateSet {
public DateSet() {
// TODO Auto-generated constructor stub
super();
}
public DateSet(String trainingType, Date completedDate, Date expirationDate) {
super();
this.trainingType = trainingType;
this.completedDate = completedDate;
this.expirationDate = expirationDate;
}
private String trainingType;
private Date completedDate;
private Date expirationDate;
public String getTrainingType() {
return trainingType;
}
public void setTrainingType(String trainingType) {
this.trainingType = trainingType;
}
public Date getCompletedDate() {
return completedDate;
}
public void setCompletedDate(Date completedDate) {
this.completedDate = completedDate;
} …Run Code Online (Sandbox Code Playgroud) 我创建了一个Google图表,并且我添加了从数据库本身获取的数据.虽然通过php循环获取数据,但我遇到了一些困难,因为我的语法无法将数据修改为图表.
这是我已经走了.我需要获取mysql值代替:
1170,460,45,123,456],660,1120,145,785,658]
var data = google.visualization.arrayToDataTable([
['Term', <?php
while ($getchartrows = mysql_fetch_array($getchart))
{
echo " ' " . $getchartrows['std_ID'] . " ' " . ",";
}
?>],
<?php
$one = mysql_query("SELECT * FROM stusitting WHERE std_ID = '0001' AND subjectNo = '$subin' AND grade = '$gradein' AND termNo = '$tcheck' ");
$getone = mysql_fetch_array($one);
?>
['01', <?php echo $getone ['marks']; ?>, 400, 495, 565, 415],
['02', 1170, 460, 45, 123, 456],
['03', 660, 1120, 145, 785, 658]
]);
var …Run Code Online (Sandbox Code Playgroud) 我有一组由javascript生成的文本框.其中一些文本框需要额外的CSS样式.我不能使用id属性,因为只有一些文本框需要这种样式.我也不能使用class属性,因为它在所有文本框中都是相同的.
我目前正在使用这样的CSS:
#txtSys8
{
position: relative;
left: 203px;
}
#txtSys9
{
position: relative;
left: 203px;
}
#txtSys10
{
position: relative;
left: 203px;
}
Run Code Online (Sandbox Code Playgroud)
有没有一种方法可以循环使用这些ID(从#txtSysy8到#txtSys19)而无需单独设置样式?
这是生成html的代码
rssTag ="<TABLE id='rssTable' border=\"0\" width=\"100%\"><TBODY>";
for(var i=8; i<arrGridData.length; i++){
var upToNCharacters = arrGridData[i][0].substring(0, 13);
if(upToNCharacters == "RSS_FEED_LINK"){
rssTag+="<TR><TD><font>" + arrGridData[i][1] + ":</TD><TD> <input type=\"text\" id=\"txtSys"+i+"\" name=\"txtSys"+i+"\" onChange=\"pgEdited()\" tabindex=\" " +(i+1) +"\" class=\"fontDefault\"></TD><TD><input type=\"checkbox\" id=\"check" + arrGridData[i][0].substring(14, arrGridData[i][0].toString().length) + "\" name=\"check\" onChange=\"pgEdited()\" class=\"chk\"/></TD></TR>";
}else{
rssTag+="<TR><TD><font>" + arrGridData[i][1] + ":</TD><TD><input type=\"text\" id=\"txtSys"+i+"\" name=\"txtSys"+i+"\" onChange=\"pgEdited()\" tabindex=\" " +(i+1) …Run Code Online (Sandbox Code Playgroud)