lulu50
asked on
Alternate Div background color
Hi,
Something is wrong that I am not sure what I'm doing wrong.
I'm trying to alternate my div to display a different color
this is what I have:
Something is wrong that I am not sure what I'm doing wrong.
I'm trying to alternate my div to display a different color
this is what I have:
<script language="JavaScript">
$(document).ready(function(){
$(".RuleDiv div:odd").css("background-color", "#F4F4F8");
$(".RuleDiv div:even").css("background-color", "#EFF1F1");
});
</script>
<table style="width:100%;">
<cfoutput query="SearchResult">
<div class="RuleDiv">
<tr>
<td colspan="9" class="ListGridHdrRow">
<span style="font-weight:bold;">Version:</span>
#SearchResult.Version# <span style="font-weight:bold;">CQ Ticket:</span> #SearchResult.CQticketNumber# <span style="font-weight:bold;">Rule Identifier: </span>#SearchResult.RuleIdentifier#</td>
</tr>
<tr>
<td style="padding-left:5px;font-weight:bold;">Case ID</td>
<td style="padding-left:5px;font-weight:bold;">Px</td>
<td style="padding-left:5px;font-weight:bold;">Dx</td>
<td style="padding-left:5px;font-weight:bold;">PassFail</td>
<td style="padding-left:5px;font-weight:bold;" colspan="2">Result</td>
<td style="padding-left:5px;font-weight:bold;">Created by</td>
<td style="padding-left:5px;font-weight:bold;">Created Date</td>
</tr>
<cfquery name="SearchSubResult" datasource="#strDSN#" username="#strUID#" password="#strPWD#" result= "DataSubResult">
select TS.ICDID, TS.CaseID, TS.RuleID, TS.Px, TS.Dx, TS.PassFail,
TS.Result, TS.CreatedDate, TS.ModifiedBy
from TestingICD TS
where TS.RuleID in (#SearchResult.RuleID#)
</cfquery>
<!--- <cfdump var="#SearchSubResult#">
<cfoutput>SQL: #DataSubResult.SQL#</cfoutput> --->
<cfif (isDefined("SearchSubResult") and #SearchSubResult.RecordCount# gt 0) >
<cfloop query="SearchSubResult">
<tr>
<td style="font-weight:normal;padding-left:10px;">#SearchSubResult.CaseID#</td>
<td style="font-weight:normal;padding-left:10px;">#SearchSubResult.Px#</td>
<td style="font-weight:normal;padding-left:10px;">#SearchSubResult.Dx#</td>
<td style="font-weight:normal;padding-left:10px;">#SearchSubResult.PassFail#</td>
<td style="font-weight:normal;padding-left:10px;" colspan="2">#SearchSubResult.Result#</th>
<td style="font-weight:normal;padding-left:10px;">#SearchSubResult.ModifiedBy#</td>
<td style="font-weight:normal;padding-left:10px;">#Trim(DateFormat(SearchSubResult.CreatedDate, "mm/dd/yyyy"))#</td>
</tr>
</cfloop>
</cfif>
<tr>
<td colspan="9"> </td>
</tr>
<tr>
<td colspan="11">
</td>
</tr>
</div>
</cfoutput>
</table>
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thank you
You are most welcome.
ASKER