1 Reply Latest reply on Jun 6, 2015 12:49 AM by David_Powers

    extracting image css for x,y properties?

    Trevor Eugene

      I was just curious if there is a way extract the x and y coordinates of an image when I extract the css code from it? It seems that I can only do the height and width of the image.


      I don't have much knowledge with code (hence why I'm using the extract feature), so if I'm trying to do this the hard way then please advise. Any and all help is welcomed.


      Thank you,


      Trevor Melton

        • 1. Re: extracting image css for x,y properties?
          David_Powers Level 7

          Yes, there is a way to get the x and y coordinates of an image. Select the image, then hold down the Shift key, and select the body of the PSD (you'll need to click in a blank area near the top-left). This will displaythe distance between the top-left and bottom-right of the image and the sides (see screenshot).



          However, the fact that you want the x and y coordinates suggests that you're trying to lay out the web page using absolute positioning. That's a very bad idea because absolute positioning is extremely difficult to control, and it doesn't make web pages responsive to different sized screens.


          The best use of selecting two elements is to find the correct amount of margin or padding to use. For example, selecting the image and the preceding element in the following screenshot tells me that the image needs 10px of margin on the left and 46px on the top.



          If you don't have much knowledge of code, I'd recommend that you devote some time each day or week to improving your knowledge. The better you understand HTML and CSS, the easier you'll find it to work with Dreamweaver. Knowledge doesn't come overnight, but the more you learn, the less frustration you'll have when building web pages.


          Good luck.