ColdFusion, why do I keep getting an error because there is a undefined...
...URL parameter? <cfif url.adminID EQ 1>
<div align="center">Select a table from above to Update.</div>
<cfelse>
<cfswitch expression="#url.adminID#">
<cfcase value="1">
<cfquery name="GetData" datasource="bmxDB">
SELECT
updates
FROM
updatesTbl
</cfquery><hr />
<div align="center"><span class="mediaName">Updates</span><br />
<textarea name="updates" cols="40" rows="10"><cfoutput>#GetData.updates#</cfoutput></textarea></div>
</cfcase>
<cfdefaultcase>
<div align="center">Select a table from above to Update.</div>
</cfdefaultcase>
</cfswitch>
</cfif>
In my URL link I have a page called admin.cfm
to get the CFSWITCH to work, it needs to say admin.cfm?adminID=1(2,3, or 4)
What if someone were to change the URL too admin.cfm?
I want a spot in my page to say "Select a table from above to Update."
It throws an error when I get rid of the ?adminID=1(2,3, or 4)
|