PHP Developers Network

A community of PHP developers offering assistance, advice, discussion, and friendship.
 
Loading
It is currently Wed Sep 30, 2020 12:53 pm

All times are UTC - 5 hours




Post new topic Reply to topic  [ 9 posts ] 
Author Message
PostPosted: Tue Jun 17, 2014 3:49 am 
Offline
Forum Newbie

Joined: Fri Jun 13, 2014 5:55 am
Posts: 17
Ok i did this design using Photoshop CS5 and once i was done i sliced it and did save for web. I got the index.html file and the images folder. I use Expression Web to do the rest as HTML. I tried many ways to center the website it just wont go to center stays to the left page. Is there a solution to this issue to put this website to center?


Top
 Profile  
 
PostPosted: Tue Jun 17, 2014 5:56 am 
Offline
Moderator
User avatar

Joined: Tue Nov 09, 2010 3:39 pm
Posts: 6425
Location: Montreal, Canada
Specify the width of the wrapper element and set left/right margins to auto.
http://jsfiddle.net/tnX8B/


Top
 Profile  
 
PostPosted: Tue Jun 17, 2014 3:38 pm 
Offline
Forum Newbie

Joined: Fri Jun 13, 2014 5:55 am
Posts: 17
Where does that wrapper go which section sorry i am new at this stuff


Top
 Profile  
 
PostPosted: Tue Jun 17, 2014 5:10 pm 
Offline
Moderator
User avatar

Joined: Tue Nov 09, 2010 3:39 pm
Posts: 6425
Location: Montreal, Canada
Just inside the body tag, typically. It wraps the rest of your markup. You don't necessarily need to add a div, mind you; you could easily apply the same CSS to an existing wrapping container.


Top
 Profile  
 
PostPosted: Wed Jun 18, 2014 12:43 am 
Offline
Forum Newbie

Joined: Fri Jun 13, 2014 5:55 am
Posts: 17
The thing is the sliced images and html that was exported as web from Photoshop don't even have tables i was told that you have to do it from scratch in order to center it and they need to have tables in order to work that's what this guy told me. Is that correct information?


Top
 Profile  
 
PostPosted: Wed Jun 18, 2014 6:32 am 
Offline
Moderator
User avatar

Joined: Tue Nov 09, 2010 3:39 pm
Posts: 6425
Location: Montreal, Canada
Sort of. Tables were used for layout maybe ten years ago. Modern web dev uses more semantic markup and uses CSS for more heavily. Long gone are the days of 1px spacer gifs. Still, if you're doing a PSD to HTML conversion, you will need to do the markup from scratch. My suggestions would be to forget pixel perfection, forget slicing up the PSD and trying to put the whole mess back together, and rather to export only the images that cannot be recreated through markup.


Top
 Profile  
 
PostPosted: Thu Jun 19, 2014 1:16 am 
Offline
Forum Newbie

Joined: Fri Jun 13, 2014 5:55 am
Posts: 17
One thing i do not understand the website i did before this one was the same PSD TO HTML and i was able to center it without a problem but this one no.


Top
 Profile  
 
PostPosted: Thu Jun 19, 2014 6:22 am 
Offline
Moderator
User avatar

Joined: Tue Nov 09, 2010 3:39 pm
Posts: 6425
Location: Montreal, Canada
How did you do it on the other one? I haven't seen the markup or the styling for either of them, so I certainly can't guess.


Top
 Profile  
 
PostPosted: Sun Jun 22, 2014 4:13 pm 
Offline
Forum Newbie

Joined: Fri Jun 13, 2014 5:55 am
Posts: 17
It just basically designed the layout template then sliced the parts that i need to be used once i did save as web and i opened with expression web i highlighted the whole layout change the position from left to center and it went to center as simple as that.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 9 posts ] 

All times are UTC - 5 hours


Who is online

Users browsing this forum: No registered users and 8 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

Jump to:  
Powered by phpBB® Forum Software © phpBB Group