I would like the alphabet across the top of the page with a list of names below so the user can click the letter, and it drops down to the corresponding letter in the names list below. However, since the list is dynamically created I don't know how to generate the <a name="letter">letter</a> part into the list. I imagine it would take some type of a script to test if the first character of the name changed, but that is over my head. Any ideas?
Normal HTML:
<a href="#A">A</a>
<a href="#B">B</a>
<a name="A">A</a>
A names
<a name="B">B</a>
B names
What I have is:
<cfoutput query="Getnames">
<tr>
<td>#name#</td>
<td>#phone#</td>
</tr>
</cfoutput>
Normal HTML:
<a href="#A">A</a>
<a href="#B">B</a>
<a name="A">A</a>
A names
<a name="B">B</a>
B names
What I have is:
<cfoutput query="Getnames">
<tr>
<td>#name#</td>
<td>#phone#</td>
</tr>
</cfoutput>