Good morning,

 

Check out my code below, where I have the <div> tag is where I want it.  I want to replace the partial note displayed at the beginning with the full note when the user clicks on it.

I guess I don’t understand why this doesn’t work.  Can someone explain why?  Thanks in advance. 

-----------------------------------------

 

<script language="_javascript_">

<!--

function showNotes(a,b){

            b.innerHTML = a;

}

-->

</script>

 

<CFQUERY NAME="displayNotes" DATASOURCE="customerNotes"  DBTYPE="ODBC">

SELECT            ID, belongsToID, customerNumber, publishDate, theNotes, salesRep, read, subject

FROM   allNotes

WHERE            customerNumber = #session.customerNumber#

                                    and belongsToID = '#url.noteID#'

</CFQUERY>

 

<cfloop query="displayNotes">

            <cfif read is "no">

                        <cfset unreadNote = "true">

                        <cfbreak>

            <cfelse>

                        <cfset unreadNote = "false">

            </cfif>

</cfloop>

 

<table cellspacing="0" cellpadding="0" border="0" width="98%">

<cfset altBGC = 1>

<cfoutput query="displayNotes">

<cfset divVar = "greeting_"&currentRow>

 

<tr bgcolor="###IIF(altBGC MOD 2, de("ffffff"),de("D9DDBC"))#">

    <td width="25%">

                        <cfif displayNotes.recordcount gte 1>

                                    <cfif unreadNote>

                                                &nbsp;&nbsp;<strong>#subject# </strong>

                                    <cfelse>

                                                &nbsp;&nbsp;<strong>#subject# </strong>

                                    </cfif>

                        <cfelse>

                                    &nbsp;

                        </cfif>  

            </td>

    <td rowspan="2" valign="top">

                        <cfif unreadNote>

                                    <strong><a href="" class="Maroon"><div id="#divVar#">#mid(theNotes, 1, 50)#...</div></a></strong>

                        <cfelse>

                                    #mid(theNotes, 1, 50)#

                        </cfif>  

            </td>

    <td width="12%" align="center">

                        <cfif unreadNote>

                                    <strong>#dateFormat(publishDate, 'mm/dd/yyyy')#</strong>

                        <cfelse>

                                    #dateFormat(publishDate, 'mm/dd/yyyy')#

                        </cfif>  

            </td>

</tr>

<tr bgcolor="###IIF(altBGC MOD 2, de("ffffff"),de("D9DDBC"))#">

    <td>

                        <font size="-2">

                                    <a href="" class="Maroon">Edit</a>&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;

                                    <a href="" class="Maroon">Reply</a>&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;

                                    <a href="" class="Maroon">Delete</a>

                        </font>

            </td>

    <td></td>

</tr>

<cfset altBGC = altBGC + 1>

</cfoutput>

</table>

 

Ron Mast

Webmaster

Truth Hardware

Ph: 507-444-4748

Fx: 507-444-5361

www.truth.com

 

_______________________________

This e-mail and any files transmitted with it are confidential and are intended solely for the use of the individual to whom they are addressed.  If you are not the intended recipient or the individual responsible for delivering the e-mail to the intended recipient, please be advised that you have received this e-mail in error and that any use, dissemination, forwarding, printing, or copying of this e-mail is strictly prohibited.

Reply via email to