HTML imageready/dreamweaver/fireworks question

  • jblow
  • Student
  • Student
  • jblow
  • Posts: 96

Post 3+ Months Ago

Hello all,
I'm adept in photoshop and have been handwriting my html code for some time, I decided to give Imageready CS a try, and this slicing thing is supreme. The xhtml table code it auto generates is definitely an advantage over my old fashioned ways.
My only gripe is that imageready fills each slice (td) with a <img> tag to represent it's background - instead of just having a <td background="..."> so that you can put text inside it with the image as the background

It trivial enough to not have support for this, but I can't figure this out for the life of me. How can I do this? Can it be done easier with some other combination golive, fireworks, dreamweaver? Thanks
  • Anonymous
  • Bot
  • No Avatar
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post 3+ Months Ago

  • Belk Media Group
  • Graphic Monk
  • Professor
  • User avatar
  • Posts: 778
  • Loc: In the heart of California, Fresno.

Post 3+ Months Ago

I too am not an ImageReady expert and ran into the same problem. What I often do is open up the html file in DreamWeaver and insert the image into the td background. If there is an automated way to do this I would also like to know how, otherwise it looks like hands on code adjustment is necessary. :D
  • jblow
  • Student
  • Student
  • jblow
  • Posts: 96

Post 3+ Months Ago

Well I just came up with my own automated solution.
Slice up my layout in Imageready as normal, take it over to dreamewaver and then perform a Find and Replace. Check Regular Expressions and enter these into the find and replace

Code: [ Select ]
FIND:
<td(.*)>[\s]*<img.*src="([^"]*)".*>[\s]*</td>

REPLACE:
<td $1 style="background:url('$2')"></td>
  1. FIND:
  2. <td(.*)>[\s]*<img.*src="([^"]*)".*>[\s]*</td>
  3. REPLACE:
  4. <td $1 style="background:url('$2')"></td>


Bada Bing Bada Boom.
The regex could probably be optimized more but whatever, it works for me. I prefer to using the style attr for backgrounds.
  • RonJr
  • Novice
  • Novice
  • RonJr
  • Posts: 33
  • Loc: Louisville Ky

Post 3+ Months Ago

I feel like I've searched everywhere in IR to find a quicker way to make an image a back ground image and have yet to find any solution.

Post Information

  • Total Posts in this topic: 4 posts
  • Users browsing this forum: No registered users and 17 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
cron
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.