I have a question that freaking me out, hope you can help me to figure it out.
I’ve design my new HTML website in photoshop and started to make it to tables with the slice tool.
I’m saving as to WEB, everything working fine as you can see in the link here:
but after I’m adding a link in the buttons, everything is going out of proportion like here:
I know after I’m creating a link i should make the image with border=”0″
but it still doesn’t seem to work.
I thought maybe I’m not cutting it good in the photoshop, but I’m not sure about it because sometimes it works for me fine.
Please help me :(
Apologies, you need to give your wrapper a width for it to center properly.
Having said that, the code that you’ve used is going to cause you problems in the long run – especially with cross-browser compatibility.
Is this code that has been generated for you? Are you trying to learn how to code? Or?
It changes my answer depending on what you say!
If you are using auto-generated code from a program, you are going to run into multiple difficulties like this, where simple problems go over your head because you haven’t taken the time to learn how the code is actually working.
Here is a very simple div structure that you can try to work from if you’d like:
To solve your problem, however, you need to add position: relative; to your wrapper div because you have absolutely positioned elements contained within it.
Remove all styling from your current #wrapper div and replace it with this:
margin: 0 auto;
The #wrapper should be the container. I looked at your index3 and you are still using the absolute and -360 left properties. Just take your index3 and change your #wrapper style to TheDoc’s last block of code, and you’ll see your wrapper flow into a centered position.
Keep at it man, this kind of trial and error will give you progressively better skills as you learn!
You must be logged in to reply to this topic.
*May or may not contain any actual "CSS" or "Tricks".