[thelist] CF output stretching a c r o s s t h e s cre eee n

Cauley, Megan L megan.l.cauley at lmco.com
Fri Nov 3 11:03:11 CST 2000


thanks seth,

:)

we found that it works fine as long as you put spaces between words.
we were testing it with one long word...
"AAAAAAAAAAA......ect"
that was the main culprit...

we'll use your coding advice too!

megan

np: radiohead national anthem

-----Original Message-----
From: Seth Bienek [mailto:seth at sethbienek.com]
Sent: Friday, November 03, 2000 11:00 AM
To: thelist at lists.evolt.org
Subject: RE: [thelist] CF output stretching a c r o s s t h e s cre eee
n


Hi Megan,

Try using cfoutput around the row you are outputting, rather than around
each variable.  Your code will be more readable, and many problems involving
looping instantly vanish.

If you're outputting query results, this is especially important.

Try rewritting this section of code:
    <tr>
      <td width="27" valign="top" id="datastyle"></td>
      <td width="555" valign="top" id="datastyle"><b>CER:</b>
<cfoutput>#cer_nbr#</cfoutput>&nbsp;&nbsp;&nbsp;&nbsp;<b>Control #:</b>
<cfoutput>#control_nbr# </cfoutput>&nbsp;&nbsp;&nbsp;&nbsp;<b>REV:</b>
<cfoutput>#rev_nbr# </cfoutput><BR><BR></td>
    </tr>

To look like this:
<cfoutput>
    <tr>
      <td width="27" valign="top" id="datastyle"></td>
      <td width="555" valign="top" id="datastyle"><b>CER:</b>
#cer_nbr#&nbsp;&nbsp;&nbsp;&nbsp;<b>Control ##:</b>  #control_nbr#
&nbsp;&nbsp;&nbsp;&nbsp;<b>REV:</b>   #rev_nbr# <BR><BR></td>
    </tr>
</cfoutput>

Notice that I "escaped" the pound signs in "Control #".  This prevents
ColdFusion from trying to interpret that text as a variable..

Also, if you are outputting Query results, it is important to specify the
query name in your output.  It's a good idea to scope the variables in the
output with the query name as well, like this:

<cfoutput query="MyQuery">
    <tr>
      <td width="27" valign="top" id="datastyle"></td>
      <td width="555" valign="top" id="datastyle"><b>CER:</b>
#MyQuery.cer_nbr#&nbsp;&nbsp;&nbsp;&nbsp;<b>Control ##:</b>
#MyQuery.control_nbr# &nbsp;&nbsp;&nbsp;&nbsp;<b>REV:</b>
#MyQuery.rev_nbr# <BR><BR></td>
    </tr>
</cfoutput>

Hope this gets you squared away; if not, shout back.

Best Regards,

Seth

------------------------------
Seth Bienek
Solutions Development Manager
Stonebridge Technologies, Inc.
972.455.7294 tel
972.404.9754 fax
------------------------------

> -----Original Message-----
> From: thelist-admin at lists.evolt.org
> [mailto:thelist-admin at lists.evolt.org]On Behalf Of Cauley, Megan L
> Sent: Thursday, November 02, 2000 1:26 PM
> To: 'thelist at lists.evolt.org'
> Subject: RE: [thelist] CF output stretching a c r o s s t h e s cre eee
> n
>
>
> sorry for the delay....
> the developer who i am working with was out to lunch...
>
> <table border="0" cellpadding="0" cellspacing="1" width="582">
>     <tr>
>       <td width="27" valign="top" id="datastyle"></td>
>       <td width="555" valign="top" id="headerstyle">Capital
> Expenditure<BR>Request Justification<BR><BR><BR></td>
>     </tr>
> 	<tr>
>       <td width="27" valign="top" id="datastyle"></td>
>       <td width="555" valign="top" id="datastyle"><b>CER:</b>
> <cfoutput>#cer_nbr#</cfoutput>&nbsp;&nbsp;&nbsp;&nbsp;<b>Control
> #:</b>  <cfoutput>#control_nbr#
> </cfoutput>&nbsp;&nbsp;&nbsp;&nbsp;<b>REV:</b>
> <cfoutput>#rev_nbr# </cfoutput><BR><BR></td>
>     </tr>
> 	<tr>
>       <td width="27" valign="top" id="datastyle"><b>1.</b></td>
>       <td width="555" valign="top" id="datastyle"><b>Why is this
> capital project needed?  What function or purpose will it serve?
> (Provide sufficient background/explanation to justify the
> expenditure)</b></td>
>     </tr>
> 	 <tr>
>       <td width="27" valign="top" id="datastyle">&nbsp;</td>
>       <td width="555" valign="top" id="datastyle">&nbsp;</td>
>     </tr>
>     <tr>
>       <td width="27" valign="top" id="datastyle">&nbsp;</td>
>       <td width="555" valign="top"
> id="datastyle"><cfoutput>#purpose#</cfoutput></td>
>     </tr>
>
> will this help???
>
> megan
> :)
>
> -----Original Message-----
> From: Howell, Katie [mailto:Kathleen.Howell-1 at ksc.nasa.gov]
> Sent: Thursday, November 02, 2000 1:13 PM
> To: thelist at lists.evolt.org
> Subject: RE: [thelist] CF output stretching a c r o s s t h e s cre eee
> n
>
>
> Code would help, but I think if you nest your tags like this:
> <table>
> 	<tr>
> <cfoutput>
> 		<td>
> 		</td>
> </cfoutput>
> 	</tr>
> </table>
>
> It should work
>
> -----Original Message-----
> From: CDitty [mailto:mail at redhotsweeps.com]
> Sent: Thursday, November 02, 2000 1:00 PM
> To: thelist at lists.evolt.org
> Subject: Re: [thelist] CF output stretching a c r o s s t h e s cre eee
> n
>
>
> If I understand what you are referring to, you can't.  If memory
> serves me
> correct, html pages are drawn from right to left.   If you have
> the opening
> cfoutput tag at the beginning of the table and the closing at the bottom,
> CF is going to parse everything in between.   If you can supply us with
> some code, I am sure that we will be able to answer your question better.
>
> CDitty
>
> At 11:49 AM 11/2/00, you wrote:
> >hi.
> >
> >i looked in the archives & didn't see anything about this....
> >
> >how do we keep  cfoutput from stretching across the page FOREVER.
> >
> >it is in a table with the width set "590",
> >the table cell width "555" is set....
> >
> >i am not all CF savvy, i am the designer here...
> >so excuse my ignorance if it is obvious.
> >
> >thanks,
> >megan
> >
> >
> >np:bjork: hyperballad
> >
> >---------------------------------------
> >For unsubscribe and other options, including
> >the Tip Harvester and archive of TheList go to:
> >http://lists.evolt.org Workers of the Web, evolt !
>
>
> ---------------------------------------
> For unsubscribe and other options, including
> the Tip Harvester and archive of TheList go to:
> http://lists.evolt.org Workers of the Web, evolt !
>
> ---------------------------------------
> For unsubscribe and other options, including
> the Tip Harvester and archive of TheList go to:
> http://lists.evolt.org Workers of the Web, evolt !
>
> ---------------------------------------
> For unsubscribe and other options, including
> the Tip Harvester and archive of TheList go to:
> http://lists.evolt.org Workers of the Web, evolt !
>



---------------------------------------
For unsubscribe and other options, including
the Tip Harvester and archive of TheList go to:
http://lists.evolt.org Workers of the Web, evolt ! 




More information about the thelist mailing list