[CFM] Query in function ?

Pagina: 1
Acties:

  • Defspace
  • Registratie: Mei 2000
  • Laatst online: 27-08 11:17

Defspace

Administrator

Topicstarter
Ik ben php gewend (rot tweakers.net ;) )
maar nu moet ik voor me werk dus in Coldfusion scripten.
en ik vroeg me af of je in een custom function een query kan uitvoeren dus zoiets als dit:
code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
<CFSCRIPT>

function newlinks()
{
WriteOutput('
    <TABLE CLASS="tbl_newlinks">
    <TR><TH>Nieuwe Links</TH></TR>');

<CFQUERY Datasource="links" NAME="links">
select link from newlinks
</CFQUERY>

<CFOUTPUT QUERY="links">
<TR><TD>#links.links#</TD></TR>
</CFOUTPUT>

WriteOutput('</TABLE>');
}

</CFSCRIPT>

Maar dan dus op een manier dat het wel werkt :)

Weet iemand dit ?