Home > database >  The MySQL database tables
The MySQL database tables

Time:10-25

How to design the data table? A scenic details page, this page is roughly divided into three boxes,
A: there are at least five image shuffling figure;
2: below as the TAB label, attractions, scenic spots information, tickets booking;
3: is the user comment,
How does a great god, the data table design? Attractions information and message information for a table or open a few table? (PHP + MySQL + HTML + CSS, etc.)

CodePudding user response:

Suggested three tables:
Attractions a table;
Message information one table, one table's primary key field is the attractions, said the comments in this scenic spot;
Pictures can put a file system, and then create a scenic picture list, including attractions table's primary key, the file name of the picture,

CodePudding user response:

If the hotel details page with spots details about the layout of the page, also can be divided into three tables? Hotel information table, message table, the table picture?

CodePudding user response:

The
1/f, reference Dong Xuyang TonyDong response:
suggested three tables:
Attractions a table;
Message information one table, one table's primary key field is the attractions, said the comments in this scenic spot;
Pictures can put a file system, and then create a scenic picture list, including attractions table's primary key, the file name of the picture,

If the hotel details page with spots details about the layout of the page, also can be divided into three tables? Hotel information table, message table, the table picture?

CodePudding user response:

The
reference 3 floor won't... Response:
Quote: refer to 1st floor Dong Xuyang TonyDong response:
suggested three tables:
Attractions a table;
Message information one table, one table's primary key field is the attractions, said the comments in this scenic spot;
Pictures can put a file system, and then create a scenic picture list, including attractions table's primary key, the file name of the picture,

If the hotel details page with spots details about the layout of the page, also can be divided into three tables? Hotel information table, message table, the table picture?

You can; Or put the hotels and attractions in a table, add a field to distinguish, so in the future there will be other information (such as hotel) can be in this way,

CodePudding user response:

The
reference 4 floor Dong Xuyang TonyDong response:
Quote: reference 3 floor won't... Response:

The
Quote: 1/f, reference Dong Xuyang TonyDong response:
suggested three tables:
Attractions a table;
Message information one table, one table's primary key field is the attractions, said the comments in this scenic spot;
Pictures can put a file system, and then create a scenic picture list, including attractions table's primary key, the file name of the picture,

If the hotel details page with spots details about the layout of the page, also can be divided into three tables? Hotel information table, message table, the table picture?

You can; Or put the hotels and attractions in a table, add a field to distinguish, so in the future there will be other information (such as hotel) can be in this way,

Good thank you (gather together ten words)
  • Related