PDA

View Full Version : HTML table code



sconly
07-08-2011, 06:21 AM
I've got an excel sheet with data that i need to convert to html (table) code including formatting, i.e. tabs, alignment, etc., as when i put it in my db it treats it as a text string without any formatting.

Can anyone supply me with some sample code or suggest a website that could help me with me quest?

Example:

From this text string:

Product Description HP ProLiant DL4x170h G6 - Xeon E5504 2 GHz
Type Cluster ( 4 nodes )
Form Factor Rack-mountable - 2U
Dimensions (WxDxH) 44.8 cm x 73.4 cm x 8.7 cm
Localisation Europe
Server Scalability 2-way
Processor 1 x Intel Xeon E5504 / 2 GHz ( Quad-Core )
Cache Memory 4 MB L3 Cache
Cache Per Processor 4 MB
RAM 6 GB (installed) / 24 GB (max) - DDR3 SDRAM - Advanced ECC - 1333 MHz - PC3-10600
Storage Controller RAID ( Serial ATA-300 )
Hard Drive None.
Monitor None.
Graphics Controller Matrox MGA G200e
Video Memory 32 MB
Networking Network adapter - Ethernet, Fast Ethernet, Gigabit Ethernet - Ethernet Ports : 2 x Gigabit Ethernet
Cluster Configuration 4 x HP ProLiant DL170h G6 Server - computing node
Cluster Interconnect Gigabit Ethernet
Power AC 230V ( 50 Hz )
Power Redundancy Optional
Manufacturer Warranty 1 year warranty - on-site

To this:

<table>
<tr><td>Product Description </td><td>Samsung NB30 Plus Atom N450 1.66 GHz - 10.1" TFT</td></tr>
<tr><td>Dimensions (WxDxH) </td><td>26.4 cm x 18.9 cm x 3.9 cm</td></tr>
<tr><td>Weight </td><td>1.26 kg</td></tr>
<tr><td>System Type </td><td>Netbook</td></tr>
<tr><td>Built-in Devices </td><td>Stereo speakers, wireless LAN aerial, Bluetooth aerial</td></tr>
<tr><td>Processor </td><td>Intel Atom N450 / 1.66 GHz</td></tr>
<tr><td>Cache Memory </td><td>512 KB - L2 Cache</td></tr>
<tr><td>RAM </td><td>1 GB DDR2 SDRAM - 800 MHz ( 1 x 1 GB )</td></tr>
<tr><td>Card Reader </td><td>3 in 1</td></tr>
<tr><td>Hard Drive </td><td>250 GB - Serial ATA-150 - 5400 rpm</td></tr>
<tr><td>Display </td><td>10.1" LED backlight TFT 1024 x 600 ( WSVGA )</td></tr>
<tr><td>Graphics Controller </td><td>Intel GMA 3150 Dynamic Video Memory Technology 4.0</td></tr>
<tr><td>Video Memory </td><td>128 MB</td></tr>
<tr><td>Audio Output </td><td>Sound card</td></tr>
<tr><td>Networking </td><td>Network adapter - Ethernet, Fast Ethernet, IEEE 802.11b, IEEE 802.11g, IEEE 802.11n, Bluetooth 3.0 EDR</td></tr>
<tr><td>Notebook Camera </td><td>Integrated - 0.3 Megapixel</td></tr>
<tr><td>Input Device </td><td>Keyboard, touchpad</td></tr>
<tr><td>Battery </td><td>6-cell Lithium Ion</td></tr>
<tr><td>Run Time (Up To) </td><td>14 hour(s)</td></tr>
<tr><td>Operating System </td><td>Microsoft Windows 7 Starter</td></tr>
<tr><td>Microsoft Office Preloaded </td><td>Includes a pre-loaded image of select Microsoft Office 2010 suites. Purchase an Office 2010 Product Key Card or disc to activate preloaded software on this PC.</td></tr>
<tr><td>Environmental Standards </td><td>ENERGY STAR Qualified , EPEAT Gold</td></tr>
<tr><td>Manufacturer Warranty </td><td>1 year warranty </td></tr>
</table>

Thanks

Zack Barresse
07-09-2011, 10:17 AM
Why not just copy the source code from the website?? From your browser, View | Source, copy, paste.