When I used the slice tool on each part and export as HTML, does it generate a skeletal HTML code where it consists of frame layouts? I would like to know for both Photoshop CS4 and GIMP.

  • 2
    When you slice and Save For Web as HTML with images, using Adobe Creative Suite 4 applications, you get 2002 code consisting of tables, not frames. This is nothing like how modern web sites are coded.
    – Scott
    Jun 28, 2013 at 2:23
  • 1
    I think perhaps everyone got caught up on the method without understanding the reasoning behind it. While it is absolutely true that no web site built since 2008 should be using tables for anything other than tabular data. There are instances where HTML with table layout are still used, such as email marketing. It may be helpful for you to edit the question and explain the desired final output and its use.
    – Scott
    Jun 28, 2013 at 9:17

2 Answers 2


To give you a candid answer, the answer is "terrible HTML". As Scott said, Photoshop will produce a table based layout. The same goes for GIMP.

Here is a sample output for GIMP:

<table cellpadding="0" border="0" cellspacing="0">
    <td><img alt="" src="slice_0_0.png"/></td>
    <td><img alt="" src="slice_0_1.png"/></td>
    <td><img alt="" src="slice_1_0.png"/></td>
    <td><img alt="" src="slice_1_1.png"/></td>

This is an incredibly outdated and incorrect way of web design. For a more detailed explanation on why, check out this article: Why tables for layout is stupid

The problem with using tables

  • mixes presentational data in with your content.
    • This makes the file sizes of your pages unnecessarily large, as users must download this presentational data for each page they visit.
    • Bandwidth ain't free.
  • This makes redesigns of existing sites and content extremely labor intensive (and expensive).
  • It also makes it extremely hard (and expensive) to maintain visual consistency throughout a site.
  • Table-based pages are also much less accessible to users with disabilities and viewers using cell phones and PDAs to access the Web.

It's okay to use Photoshop or GIMP to produce web design mock-ups, and it's okay to use the slice tool to subdivide and export necessary images for your site, but it is not okay to generate your HTML using the slice tool!

  • Why it's not okay to use the slice tool? Is it because when exported into HTML is not reliable? For all I know, layouts automatically adapt and retains each size of child layouts within the parent layout regardless of the screen resolution? And one thing, some images don't stretch when zooming in or out of the webpage. Jun 28, 2013 at 3:50
  • Because the slice tool produces table based layouts. Read the link I provided for a better explanation than I give on that subject
    – JohnB
    Jun 28, 2013 at 3:56
  • Actually you can create div based html from photoshop. Although... it's not any better than the tables, since every parent div uses absolute positioning and it only makes everything so much more difficult. i.stack.imgur.com/8eRCg.png
    – Joonas
    Jun 28, 2013 at 8:32
  • @Joonas that's CS6+, right?
    – JohnB
    Jun 28, 2013 at 21:51
  • I can only confirm that it's at least cs3+
    – Joonas
    Jun 28, 2013 at 21:54

Adding to John's answer:

The slice tool (both in Photoshop or Gimp) lets you define rectangular areas to export as individual images, with some limitations: only one set of slices can exist per document, and slices cannot overlap.

The final result will be a table filled with images. Apart from the reasons mentioned before, tables are the worst idea for responsive layouts, because you can't change the order of the TDs (even frames are better for this).

Graphic programs are good for trying styles and preparing mockups (along with wireframing tools), but once you need to transition to HTML, the best thing you can do is write your own code.

  • Is it only that no matter how many slices I've made and when I export it there will be only one file at a time or not? Jun 28, 2013 at 3:44
  • 2
    If you save all your images at one, there will be one HTML, yes.
    – Yisela
    Jun 28, 2013 at 3:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.