Hello folks…

 

I have strange issue that I am trying to figure out and was hoping someone may know where I might be missing something. I am running the queries below to pull some template settings for me out of a sql database table and one of the fields I use returns a simple single digit number that I use to specify the directory that the main image files will come from.

 

When I run the page it runs fine with no errors but for some reason the number that I pull gets appended to itself for every item that is displayed. Let’s see if I can explain this better.

 

If I have 10 items that are returned from my <cfoutput query="rsFinancialBenefitList">

 

What I get is ….

 

http://mysite.com/D2//layout.cfm?page=Shelton&pg=5&item=1

http://mysite.com/D22//layout.cfm?page=Shelton&pg=5&item=2

http://mysite.com/D222//layout.cfm?page=Shelton&pg=5&item=3

http://mysite.com/D2222//layout.cfm?page=Shelton&pg=5&item=4

http://mysite.com/D22222//layout.cfm?page=Shelton&pg=5&item=5

http://mysite.com/D222222//layout.cfm?page=Shelton&pg=5&item=6

http://mysite.com/D2222222//layout.cfm?page=Shelton&pg=5&item=7

http://mysite.com/D22222222//layout.cfm?page=Shelton&pg=5&item=8

http://mysite.com/D222222222//layout.cfm?page=Shelton&pg=5&item=9

http://mysite.com/D2222222222//layout.cfm?page=Shelton&pg=5&item=10

 

…and so on.

 

Any ideas on why it’s doing this?  …it seems to works with other sections of my site just fine.

 

--------------here are my Querys----------------

<cfquery name="GetTemplateData" datasource="agenttemplate">

SELECT * FROM dbo.Templates WHERE EntityID = '#LookUpPin.ENTITYID#'

</cfquery>

 

<cfquery name="rsFinancialBenefitList" datasource="SASBenefits">

SELECT * FROM dbo.Benefits WHERE ((dbo.Benefits.BenefitCategory = 'F') AND (dbo.Benefits.Active = 1)) ORDER BY dbo.Benefits.Name ASC

</cfquery>

 

--------- “Template” variable returns a number a value of 2--------

---------------Page---------------

<cfoutput query="rsFinancialBenefitList">

<table width="100%"  border="0" cellspacing="0" cellpadding="2">

<tr>

<td><strong class="12ptTextBlack"><a href="../D#GetTemplateData.Template#/layout.cfm?page=#trim(GetTemplateData.TMP_Page)#&pg=12&benefit=#rsFinancialBenefitList.BenefitCode#&ben=5"><font color="##003366">#rsFinancialBenefitList.Name#</font></a></strong><br>

<span class="12ptTextBlack">#rsFinancialBenefitList.Teaser#</span></td>

</tr>

<tr>

<td height="1"><img src="../images/spacer.gif" width="1" height="2"></td>

</tr>

</table>

</cfoutput>

--------------Page End-------------

 

Thanks,

 

Neal

 

Reply via email to