954,561 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

HTML To Excel

Day
Time
Unit
Lecturer
Monday
8.00am To 1.00 Pm
BCT 2406 Project Research and definition
 
 
 
 
 
Tuesday
8.00am To 10.00am
BCT 2405 Client Server Systems & Computing
JB Kariuki

 
12.00noon To 2.00PM
BCT 2405 Computer Graphics System
Kihongo

 
2.00PM To 5.00 PM
BCT 2405 Computer Graphics System
Kihongo

 
 
 
 
Wednesday
7.00am To 10.00am
BCT 2405 Client Server Systems & Computing
JB Kariuki

 
11.00noon To 1.00PM
BCT 2403 Knowledge Based Systems
George Okeyo
 
 
 
 
Thursday
7.00am To 10.00am
BCT 2403 Knowledge Based Systems
George Okeyo

 
11.00am To 12.00 PM
BCT 2401 Operations Research
P Kihara

 
12.00am To 2.00 PM
BCT 2404 Decision Support System
L Mburu

 
3.00am To 6.00 PM
BCT 2404 Decision Support System
L Mburu

 
 
 
 
Friday
9.00am To 10.00am
BCT 2401 Operations Research
P Kihara

 
11.00am To 2.00 PM
Research Methodology
L Mengo

 
2.00PM To 4.00 PM
Research Methodology
L Mengo

 
 
 
 

njagi
Newbie Poster
15 posts since Jun 2007
Reputation Points: 39
Solved Threads: 1
 

easiest way I know is to view it in a web browser and then highlight the information and copy it to excel.

piers
Junior Poster in Training
68 posts since Jul 2007
Reputation Points: 10
Solved Threads: 3
 

use the following code:

i have just included the first row and hope you will not have problems with the rest:

<?php


echo "<table cellspacing='4' cellpadding='4' border=1 align=center>";
echo"<tr>";
echo"<td>Day</td>";
echo"<td>Time</td>";
echo"<td>Unit</td>";
echo"<td>Lecturer</td>";
echo"</tr>";

echo"</table>";















header("Content-type: application/octet-stream");

# replace excelfile.xls with whatever you want the filename to default to
header("Content-Disposition: attachment; filename=excelfile.xls");
header("Pragma: no-cache");
header("Expires: 0");


?> 
  
  
</p>
</body>
</html>


please if found this code helpful, can you add my reputation

tirivamwe
Light Poster
36 posts since Oct 2005
Reputation Points: 11
Solved Threads: 2
 

This works for me !!! Thank you very much !!!

jwf3148
Newbie Poster
1 post since Feb 2009
Reputation Points: 10
Solved Threads: 0
 

can i format the table columns? like tell the column to act as a number?
i getting 1231 instead 1.23443E+14 of 123443211234000

rui.penso
Newbie Poster
1 post since Aug 2009
Reputation Points: 10
Solved Threads: 0
 

thanx

sainiweb
Newbie Poster
15 posts since Apr 2010
Reputation Points: 10
Solved Threads: 0
 

Hi! A little late, but.... I found the following 'library' easy to use.

http://innovationsdesign.net/wb_2.7/pages/tech-resources/downloads/desktop_write.php

Using php, could you pass what you want to pass into excel via a variable and your set.

Hope it helps.

ddellostritto
Newbie Poster
21 posts since Oct 2010
Reputation Points: 10
Solved Threads: 0
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You