tag"s name is 0th Attribute of attributes;
I lowercase tag"s name and want to check every attribute"s quote is """;
by code 2:
but in no use.
Any suggestion is welcome.Did I miss something important?.....@@.
thank you
May goodness be with you all
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
tag"s name is 0th Attribute of attributes;
I lowercase tag"s name and want to check every attribute"s quote is """;
but in no use.
Any suggestion is welcome.Did I miss something important?.....@@.
thank you
May goodness be with you all
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
regards:
----------------------------------------------------------------------------------------------------
code 1:
----------------------------------------------------------------------------------------------------
Vector attributes;
attributes = tag.getAttributesEx();
----------------------------------------------------------------------------------------------------
code 2:
----------------------------------------------------------------------------------------------------
for(attributesCount=0;attributesCount<attributes.size();attributesCount++){
if(attributesCount==0){
attribute = (Attribute)attributes.elementAt(0);
attribute.setName(attribute.getName().toLowerCase());
}
else{
char TobecheckQuote=((Attribute)attributes.elementAt(attributesCount)).getQuote();
(TobecheckQuote=="""){
}
else{
((Attribute)attributes.elementAt(attributesCount)).setQuote(""");
}
}
}
----------------------------------------------------------------------------------------------------
tag"s name is 0th Attribute of attributes;
I lowercase tag"s name and want to check every attribute"s quote is """;
by code 2:
but in no use.
Any suggestion is welcome.Did I miss something important?.....@@.
thank you
May goodness be with you all
regards:
----------------------------------------------------------------------------------------------------
code
----------------------------------------------------------------------------------------------------
Vector attributes;
Attribute attribute;
attributes = tag.getAttributesEx();
int attributesCount;
for(attributesCount=0;attributesCount<attributes.size();attributesCount++){
if(attributesCount==0){
attribute = (Attribute)attributes.elementAt(0);
attribute.setName(attribute.getName().toLowerCase());
}
else{
char TobecheckQuote=((Attribute)attributes.elementAt(attributesCount)).getQuote();
if(TobecheckQuote=='"'){
}
else{
((Attribute)attributes.elementAt(attributesCount)).setQuote('"');
}
}
}
---------------------------------------------------------------------------------------------------
unexpected output:
----------------------------------------------------------------------------------------------------
omited------------------------------------------------------------------
<body" "leftmargin="0"" "topmargin="0"" "bgcolor="#8C9163"" "text="#000000"><table" "height="100%"border="0"" "align="center"" "cellpadding="0"" "cellspacing="0"><tr><td" "colspan="3"><table" "border="0"" "cellspacing="0"" "cellpadding="0"><tr>
<td" "align="right"" "class="eng_line"><img" "src="http://www.yzu.edu.tw/images/main/eng-title.gif"" "width="260"" "height="18" alt="*"></td>
</tr><tr>
<td" "class="top_img"><img" "src="http://www.yzu.edu.tw/images/main/top-main-01.jpg"" "width="800"" "height="90"" "border="0"" "usemap="#Map" alt="*"><map" "name="Map"><area" "shape="circle"" "coords="66,45,44"" "href="/?PHPSESSID=c849a291f40ea22447a392d4b419b468"" "alt="元智大學首頁"></map></td>
</tr></table></td></tr><tr><td" "align="center"" "valign="top"" "class="left_bar"><table" "border="0"" "cellpadding="0"" "cellspacing="0">
<tr>
<td" "width="132"></td>
</tr>
<tr><td" "align="center"> </td></tr>
omited------------------------------------------------------------------
seems that "" added before Attribute name =.=
tag"s name is 0th Attribute of attributes;
I lowercase tag"s name and want to check every attribute"s quote is """;
but in no use.
Any suggestion is welcome.Did I miss something important?.....@@.
thank you
May goodness be with you all