Reply to Re: reducing number...

Your name:

Reply:


Posted by Captain Paralytic on 10/23/06 08:32

plato wrote:
> Not a php or sql wiz but working on a form that is linked to a sql database.
> I want to put a statement at the top of the form that says
> " there are currently '20' places remaining in this workshop".
> Each time a person submits a form I want the page to reduce the number by 1
> until when n=0 it displays in red 'there are no places available in this
> workshop'
>
> thanks
>
> plato
>
> I'm thinking it could work off the ID on the database.

Just did this sort of thing recently with an application to allow
booking of courses.
One table holds details of the course (workshop) including the total
number of places available (in a single row).
A second table has one row per booking with all the details of who has
booked.

Then you join the 2 tables and take the number of bookings away from
the total number available.

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация