Click here to Skip to main content
15,914,111 members
Home / Discussions / Linux, Apache, MySQL, PHP
   

Linux, Apache, MySQL, PHP

 
GeneralRe: infinite loop while using php's dir object..? Pin
chevu29-Mar-10 19:04
chevu29-Mar-10 19:04 
Questionquery help with table that has no primary keys Pin
scorpio2219-Mar-10 10:26
scorpio2219-Mar-10 10:26 
AnswerRe: query help with table that has no primary keys Pin
PHP_Guy22-Mar-10 11:01
PHP_Guy22-Mar-10 11:01 
QuestionCreating project setup Pin
sarang_k17-Mar-10 18:36
sarang_k17-Mar-10 18:36 
AnswerRe: Creating project setup Pin
PHP_Guy19-Mar-10 7:24
PHP_Guy19-Mar-10 7:24 
QuestionExporting HTML file to PDF format Pin
sarang_k11-Mar-10 22:47
sarang_k11-Mar-10 22:47 
AnswerRe: Exporting HTML file to PDF format Pin
Niall Barr11-Mar-10 23:07
professionalNiall Barr11-Mar-10 23:07 
QuestionUse PEAR's datagrid export to an excel sheet, but getting all unrecognized characters [modified] Pin
alexyxj11-Mar-10 8:44
alexyxj11-Mar-10 8:44 
QuestionStored Procedure with Php and MySQL Pin
scorpio2211-Mar-10 5:19
scorpio2211-Mar-10 5:19 
AnswerRe: Stored Procedure with Php and MySQL Pin
PHP_Guy19-Mar-10 7:46
PHP_Guy19-Mar-10 7:46 
GeneralRe: Stored Procedure with Php and MySQL Pin
scorpio2222-Mar-10 4:25
scorpio2222-Mar-10 4:25 
GeneralRe: Stored Procedure with Php and MySQL Pin
PHP_Guy22-Mar-10 10:44
PHP_Guy22-Mar-10 10:44 
GeneralRe: Stored Procedure with Php and MySQL Pin
scorpio2222-Mar-10 10:56
scorpio2222-Mar-10 10:56 
GeneralRe: Stored Procedure with Php and MySQL Pin
PHP_Guy22-Mar-10 11:21
PHP_Guy22-Mar-10 11:21 
GeneralRe: Stored Procedure with Php and MySQL Pin
scorpio2223-Mar-10 3:44
scorpio2223-Mar-10 3:44 
Questionphp - include_once Pin
thes3cr3t16-Mar-10 22:39
thes3cr3t16-Mar-10 22:39 
AnswerRe: php - include_once Pin
chevu7-Mar-10 22:37
chevu7-Mar-10 22:37 
AnswerRe: php - include_once Pin
PHP_Guy19-Mar-10 7:51
PHP_Guy19-Mar-10 7:51 
QuestionOrganize mysql results in html table with PHP Pin
pelikan20026-Mar-10 14:15
pelikan20026-Mar-10 14:15 
AnswerRe: Organize mysql results in html table with PHP Pin
Luc Pattyn6-Mar-10 14:38
sitebuilderLuc Pattyn6-Mar-10 14:38 
The trick is to get the cells of the table in the right order. There are many ways to do so.

1.
use a two-dimensional array; fetch the database results (order does not matter); loop over them filling the array; when filled, start creating the table from the array.

2.
use a one-dimensional array representing one day; for each day, fetch the database results for that day only; fill the array; now generate HTML for one row.

3.
fetch all the database results in chronological order (use an ORDER BY clause). Now start reading the results and create your array; start a new row when day does not equal previous day; insert one or more empty cells when time chunks aren't consecutive; etc.

Smile | :)
Luc Pattyn [Forum Guidelines] [Why QA sucks] [My Articles]

I only read code that is properly formatted, adding PRE tags is the easiest way to obtain that.

GeneralRe: Organize mysql results in html table with PHP Pin
pelikan20027-Mar-10 0:53
pelikan20027-Mar-10 0:53 
GeneralRe: Organize mysql results in html table with PHP Pin
pelikan20027-Mar-10 5:22
pelikan20027-Mar-10 5:22 
GeneralRe: Organize mysql results in html table with PHP Pin
Luc Pattyn7-Mar-10 8:45
sitebuilderLuc Pattyn7-Mar-10 8:45 
GeneralRe: Organize mysql results in html table with PHP Pin
pelikan200211-Mar-10 5:05
pelikan200211-Mar-10 5:05 
GeneralRe: Organize mysql results in html table with PHP Pin
Luc Pattyn11-Mar-10 5:13
sitebuilderLuc Pattyn11-Mar-10 5:13 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.