Hey everyone this is my first post and im very stuck. I am new to web development and am currently undertaking a College course although i cannot get much help off of my lecturer.
My website is a travel agency that allows online bookings. On my home page there is a list of special offers that the user can click on to order. The offers on display are read from a DB however i need the code to verify the user is logged in once they click on the offers link. If they are logged in they will be directed to my offers.cfm page. If the user is not logged in i need an error message to appear alerting them that they are not logged in and need to be to order these offers.
I know that sounds pretty confusing, and i am sorry but this is hard to explain for a newbie lol. I have pasted the code that i have done to display the offers, hopefully this will help.
<cfquery name="tours" datasource="webtoursmj">
SELECT tours.departdate, packages.tourname, packages.packageid, packages.tourlocation, packages.adultprice
FROM packages INNER JOIN tours
ON packages.packageid = tours.packageid;
#DateFormat (departdate, "d/m/yy")# -
<a href="offers.cfm?id=#packageid#">BOOK NOW</a><br><br>