Hi all. I need some help creating a link that goes to a page depending upon a variable in a database. Here is sample code I am trying to make work:
<cfquery ""
<cfquery name="rsgetAvailable"
datasource="name" username="name" password="pw">
SELECT variable
FROM table
</cfquery>
<cfset variable eq "">
<cfif variable eq "on">
<a href="http://360buyers.com/threesixty/studentrentals_Search.cfm" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('SearchbyListing','','../Artwork/By Listing_Over.png',1)"><img src="../Artwork/By Listing_Live.png" alt="Search by Listing" name="SearchbyListing" width="250" height="150" border="0" id="SearchbyListing" /></a>
<cfelse>
<a href="http://360buyers.com/threesixty/studentrentals_Search sa.cfm" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('SearchbyListing','','../Artwork/By Listing_Over.png',1)"><img src="../Artwork/By Listing_Live.png" alt="Search by Listing" name="SearchbyListing" width="250" height="150" border="0" id="SearchbyListing" /></a>
<cfif>
Seems like this should work but is does not.
Can anyone help by identifying the problem(s)
Thank you much