Jump to content


Photo

Seat map.


  • Please log in to reply
1 reply to this topic

#1 RodneyCaisip

RodneyCaisip

    Newbie

  • New Members
  • Pip
  • 1 posts

Posted 02 January 2014 - 12:29 PM

Hello I'm Rodney, i would like to ask for advice and guides on how could i make a simple seat map which every seat has to be updated by colors if it its reserved, paid etc. any idea to connect it to database to determine the seat status.

And one thing, im currently using the old php 4xxx and i will use php5, i want to know if what should i change in my database connection. like mysql as mysqli? is there anything more about it?  Sorry for my bad english.  thank you.  ::)



#2 Barand

Barand

    Sen . ( ile || sei )

  • Gurus
  • 14,130 posts
  • LocationCheshire, UK

Posted 10 January 2014 - 06:31 PM

You don't say what type of seat but it would probably be time-based as well as location-based so you would need a data structure along these lines.

+------------+                                   +-------------+
|  seat      |                                   | session     |
+------------+                                   +-------------+
| seatId     |---+                         +-----| sessionId   |
| seat_row   |   |                         |     | sessionDate |
| seat_no    |   |                         |     | sessionTime |
| location   |   |                         |     +-------------+
+------------+   |                         |
                 |     +---------------+   |
                 |     | booking       |   |
                 |     +---------------+   |
                 |     | bookingId     |   |
                 |     | sessionId     | >-+
                 +---< | seatId        |
                       | status        |
                       +---------------+

"Location" in the seat table would, in the case of a theatre, be something like front stalls, balcony etc. You would need to store enough for you calculate the seat position on a map. Say from row and seat number in a simple layout.

 

Example http://forums.phpfre...p/#entry1461646


|baaGrid| easy data tables - and more
|baaChart| easy line, column and pie charts
|baaSelect| generate js and php code for dynamic linked dropdowns

 





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

Cheap Linux VPS from $5
SSD Storage, 30 day Guarantee
1 TB of BW, 100% Network Uptime

AlphaBit.com