Solved

Toogle price, show price on/off

Posted on 2008-06-09
1
154 Views
Last Modified: 2013-12-24
I have a website for a restaurant. There is an admin area in which the client can add menu items, special items and events.

They want to make a change where they have the option of not showing their beverage prices. I would like to set up a toogle where Price is shown or not, based on a check box.

I would like it so after the menu item is added, the admin can view the inserted record and then turn it on/off for the website.

Is there an easy solution?

0
Comment
Question by:meechp123
1 Comment
 
LVL 25

Accepted Solution

by:
dgrafx earned 500 total points
ID: 21751330
yes there is an easy solution
1) just create a new database column and name it for example showPrice - datatype bit with a default of whichever you want 1 (which shows price or 0 which hides price)

2) then in the output query that displays these database items you need to add it to your list of columns (of course)

3) in the output query you may have something like
#itemname# #dollarformat(itemprice)#
just change it to
#itemname# <cfif showPrice>#dollarformat(itemprice)#</cfif>

4) in the admin section just create a checkbox (or selectbox) for the admin to set this item to show price or not

good luck ...
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Intranet Solution - Sharepoint Foundation or up 4 60
how can I backup my incomplete website from hostgator? 3 60
ip / url redirect 13 68
Ways to assess https/ssl websites 3 84
One of the typical problems I have experienced is when you have to move a web server from one hosting site to another. You normally prepare all on the new host, transfer the site, change DNS and cross your fingers hoping all will be ok on new server…
Meet the world's only “Transparent Cloud™” from Superb Internet Corporation. Now, you can experience firsthand a cloud platform that consistently outperforms Amazon Web Services (AWS), IBM’s Softlayer, and Microsoft’s Azure when it comes to CPU and …
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.
A company’s greatest vulnerability is their email. CEO fraud, ransomware and spear phishing attacks are the no1 threat to a company’s security. Cybercrime is responsible for the largest loss of money to companies today with losses projected to r…

914 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now