[Zope] HELP! - DTML Variables
Mohan Baro
mcbaro@uwimona.edu.jm
Fri, 8 Dec 2000 08:53:51 -0500
This is a multi-part message in MIME format.
------=_NextPart_000_000A_01C060F4.630A9AE0
Content-Type: text/plain;
charset="us-ascii"
Content-Transfer-Encoding: 7bit
In the code segment :
<dtml-in expr="find_employee(employee_id='XXXXXXX')" size=50
start=query_start>
<dtml-if sequence-start>
How do I declare a variable such as
intEmployee='123456'
so that I can use it as:
<dtml-in expr="find_employee(employee_id=<dtml-var intEmployee>)" size=50
start=query_start>
<dtml-if sequence-start>
What I am really tring to do is:
<dtml-in expr="find_employee(employee_id='<dtml-var
"AUTHETICATED_USER.getUserName()">')" size=50 start=query_start>
<dtml-if sequence-start>
But I keep on getting syntax errors.
Mohan.
------=_NextPart_000_000A_01C060F4.630A9AE0
Content-Type: text/html;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Dus-ascii">
<META content=3D"MSHTML 5.50.4134.600" name=3DGENERATOR></HEAD>
<BODY>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2><SPAN =
class=3D389284713-08122000>In the=20
code segment :</SPAN></FONT></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2><dtml-in=20
expr=3D"find_employee(employee_id=3D<SPAN=20
class=3D389284713-08122000>'XXXXXXX</SPAN>')" size=3D50=20
start=3Dquery_start><BR> <dtml-if=20
sequence-start><BR></FONT></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2></FONT> </DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2>How do=20
I declare a variable such as</FONT></SPAN></DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2>intEmployee=3D'123456'</FONT></SPAN></DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2>so=20
that I can use it as:</FONT></SPAN></DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2><dtml-in expr=3D"find_employee(employee_id=3D<dtml-var=20
intEmployee>)" size=3D50 start=3Dquery_start><BR> =
<dtml-if=20
sequence-start></FONT></SPAN></DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2>What I=20
am really tring to do is:</FONT></SPAN></DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2><dtml-in expr=3D"find_employee(employee_id=3D<SPAN=20
class=3D389284713-08122000>'<dtml-var=20
"AUTHETICATED_USER.getUserName()"></SPAN>')" size=3D50=20
start=3Dquery_start><BR> <dtml-if=20
sequence-start><BR></FONT></SPAN></DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2>But I=20
keep on getting syntax errors.</FONT></SPAN></DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2></FONT></SPAN> </DIV>
<DIV><SPAN class=3D389284713-08122000><FONT face=3DArial color=3D#0000ff =
size=3D2>Mohan.</DIV>
<DIV><BR></DIV></FONT></SPAN>
<BLOCKQUOTE dir=3Dltr style=3D"MARGIN-RIGHT: 0px">
<DIV class=3DOutlookMessageHeader dir=3Dltr align=3Dleft><FONT =
face=3DArial=20
color=3D#0000ff =
size=3D2></FONT> </DIV></BLOCKQUOTE></BODY></HTML>
------=_NextPart_000_000A_01C060F4.630A9AE0--