Go Back   Digital Photography School - Photography Forums > General Discussion > General Chit Chat


Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old 05-09-2011, 11:31 PM
katia's Avatar
dPS Forum Member
 
Join Date: Jan 2008
Location: Canada!
Posts: 572
Default can anybody give me a quick Wordpress/CSS tip?

I've got very little experience with wordpress, and 0 experience with CSS, but i've been building this website for a bit now. one thing that drives me MENTAL

is the fact that the menu items are not centered. i know it's probably a very simple tweak in the coding but i don't even know what any of it means. the theme is TwentyTen, if that helps.

can anybody help me with this? squamishserpents.ca | Breeding and keeping quality snakes!
Reply With Quote
  #2 (permalink)  
Old 05-09-2011, 11:35 PM
maxharvard
Guest
 
Posts: n/a
Default

Google
Reply With Quote
  #3 (permalink)  
Old 05-09-2011, 11:36 PM
katia's Avatar
dPS Forum Member
 
Join Date: Jan 2008
Location: Canada!
Posts: 572
Default

thanks for that, but i don't even know what a < d i v > box is, let alone which one in the CSS page to change
Reply With Quote
  #4 (permalink)  
Old 05-10-2011, 12:35 AM
BuddhaPi's Avatar
Middle School Graduate
 
Join Date: May 2010
Location: Jupiter, Florida
Posts: 1,605
Default

I see you are using the twentyten theme.keep in mind this is the wordpress default theme, when you update to later version all of your customization will be overwritten..ALWAYS back up everything before doing any updates...with that being said if you want to proceed......

By default, the twentyten menu normally floats left. if you want a centered menu, you can change your css style sheet. go into edit the style sheet and look for:

#access {
background: #000;
margin: 0 auto;
width: 940px;
display:block; float:left; }

The above is a segment from the default css in twentyten. You need to take out the “float: left;” and add in “position:absolute; text-align:center;” then add a new line of “#access ul {display:inline-block;}” This will change it to the following:

#access { background: #000;
margin: 0 auto;
width: 940px;
display:block;
position:absolute;
text-align:center; }

#access ul{display:inline-block;}

that should do the trick!

In another life I worked with Philippe de Vosjoli a very well known herper, breeding chameleons, geckos, poison dart frogs and tarantulas and other varios critters..
__________________
Nikon D7000:18-105mm VR Kit, Nikkor 35-70mm 2.8AF, Nikkor 50mm f/1.8d AF, Sigma 150-500mm f/5-6.3 AF, SB600
Web Design of Palm Beach
Photo Blog
Become a Fan on Facebook

Last edited by BuddhaPi; 05-10-2011 at 12:49 AM.
Reply With Quote
  #5 (permalink)  
Old 05-10-2011, 01:47 AM
dlambert's Avatar
Take better pictures.
 
Join Date: Dec 2008
Location: Ohio, USA
Posts: 1,762
Default

Ok - which menu items are you trying to center?
__________________
David Lambert
lambertpix.com
More photos in my gallery and 500px
Reply With Quote
  #6 (permalink)  
Old 05-10-2011, 07:08 AM
katia's Avatar
dPS Forum Member
 
Join Date: Jan 2008
Location: Canada!
Posts: 572
Default

Quote:
Originally Posted by BuddhaPi View Post
I see you are using the twentyten theme.keep in mind this is the wordpress default theme, when you update to later version all of your customization will be overwritten..ALWAYS back up everything before doing any updates...with that being said if you want to proceed......

By default, the twentyten menu normally floats left. if you want a centered menu, you can change your css style sheet. go into edit the style sheet and look for:

#access {
background: #000;
margin: 0 auto;
width: 940px;
display:block; float:left; }

The above is a segment from the default css in twentyten. You need to take out the “float: left;” and add in “position:absolute; text-align:center;” then add a new line of “#access ul {display:inline-block;}” This will change it to the following:

#access { background: #000;
margin: 0 auto;
width: 940px;
display:block;
position:absolute;
text-align:center; }

#access ul{display:inline-block;}

that should do the trick!

In another life I worked with Philippe de Vosjoli a very well known herper, breeding chameleons, geckos, poison dart frogs and tarantulas and other varios critters..
very cool about Philippe! i think he's still active in the herp community.

as for that CSS i couldn't make it work, lol. i think i'm just going to give up. so what you're saying about the updates is everytime wordpress comes out with a new update i'm going to have to edit the CSS stylesheet again?
Reply With Quote
  #7 (permalink)  
Old 05-10-2011, 11:11 AM
BuddhaPi's Avatar
Middle School Graduate
 
Join Date: May 2010
Location: Jupiter, Florida
Posts: 1,605
Default

Quote:
Originally Posted by katia View Post
very cool about Philippe! i think he's still active in the herp community.

as for that CSS i couldn't make it work, lol. i think i'm just going to give up. so what you're saying about the updates is everytime wordpress comes out with a new update i'm going to have to edit the CSS stylesheet again?
which file did you edit? what did you edit it with? did you edit thru the WP interface? if so you will probably need to change the permission to write to that directory, it would be easie to download all the files via ftp, make a back-up of said files, then make your changes and upload the new file. I 've found the WP editor mostly useless..be sure to edit the file in a plaintext editor such as notepad, NOT MSWord, as this will cause issues.

by using the default theme and wordpress updates will over-right any cusomizations in any of the files wether it be style.cc or header,php ect...If you've kept the image filenames the same as the original they should be ok, but if you've renamed them and changed the paths they will most likely disappear..of coarse you could just forego updating wordpress and not have to worry about it at all..

Haven't heard from Phillipe in a very long time, it was certainly a cool experience working with him tho!
__________________
Nikon D7000:18-105mm VR Kit, Nikkor 35-70mm 2.8AF, Nikkor 50mm f/1.8d AF, Sigma 150-500mm f/5-6.3 AF, SB600
Web Design of Palm Beach
Photo Blog
Become a Fan on Facebook

Last edited by BuddhaPi; 05-10-2011 at 11:16 AM.
Reply With Quote
  #8 (permalink)  
Old 05-10-2011, 05:35 PM
katia's Avatar
dPS Forum Member
 
Join Date: Jan 2008
Location: Canada!
Posts: 572
Default

Quote:
Originally Posted by BuddhaPi View Post
which file did you edit? what did you edit it with? did you edit thru the WP interface? if so you will probably need to change the permission to write to that directory, it would be easie to download all the files via ftp, make a back-up of said files, then make your changes and upload the new file. I 've found the WP editor mostly useless..be sure to edit the file in a plaintext editor such as notepad, NOT MSWord, as this will cause issues.

by using the default theme and wordpress updates will over-right any cusomizations in any of the files wether it be style.cc or header,php ect...If you've kept the image filenames the same as the original they should be ok, but if you've renamed them and changed the paths they will most likely disappear..of coarse you could just forego updating wordpress and not have to worry about it at all..

Haven't heard from Phillipe in a very long time, it was certainly a cool experience working with him tho!
just popping in on my phone, will try the ftp editor thing later if i can possible figure it out :P

as for everything changing, my custom backgrounds & headers have all stayed around through various updates, so perhaps they've changed that? i hope, it would be a real drag to have to edit the CSS every single time. and yeah, i tried through the wordpress editor. i just deleted the part you said to look for and then copy and pasted the new thing you put. is that correct? lol
Reply With Quote
  #9 (permalink)  
Old 05-10-2011, 05:57 PM
BuddhaPi's Avatar
Middle School Graduate
 
Join Date: May 2010
Location: Jupiter, Florida
Posts: 1,605
Default

Quote:
Originally Posted by katia View Post
just popping in on my phone, will try the ftp editor thing later if i can possible figure it out :P

as for everything changing, my custom backgrounds & headers have all stayed around through various updates, so perhaps they've changed that? i hope, it would be a real drag to have to edit the CSS every single time. and yeah, i tried through the wordpress editor. i just deleted the part you said to look for and then copy and pasted the new thing you put. is that correct? lol
Well it wopuld be correct if you made the file writable first, this would need to be done on the server side by changing permissions.. If you did not do this first, then you didn't actually make any changes.. If you named your custom backgrounds and headers the same as the default names, then they would not change, only if you changed file names would you run into a problem..one other note you will need an ftp client, which is seprate from the editor, 2 completely differetn beasts..
__________________
Nikon D7000:18-105mm VR Kit, Nikkor 35-70mm 2.8AF, Nikkor 50mm f/1.8d AF, Sigma 150-500mm f/5-6.3 AF, SB600
Web Design of Palm Beach
Photo Blog
Become a Fan on Facebook
Reply With Quote
  #10 (permalink)  
Old 05-10-2011, 08:59 PM
inkista's Avatar
Gear Geek Girl
 
Join Date: Jan 2007
Location: San Diego, CA
Posts: 9,154
Default

I probably shouldn't be saying anything about this, but BuddhaPi, have you ever considered using a distributed version control system, like git, hg (Mercurial), svn (Subversion), or cvs?

A version control system lets you check in and check out different versions of source code files as you develop them. You can then access any version of the code that was recorded. So, multiple levels of "undo".

You can also "branch and merge" versions. I.e., keep the one that works as your latest version, muck and break and fix the code on a development branch until it works again, then merge it back on the latest versions that have been chugging along and moving forward on the trunk. This is useful in a Wordpress theme tinkering scenario. You can take the changes you made on the branch, and merge them back in on top of the new official version if you know what you're doing. Knowing what you're doing, alas, is the hard part (I'm not quite there yet). CVS and SVN pretty much leave the merging up to you to do by hand (ugh), but the newer tools, like git and hg can automate a lot of it.

And with distributed systems, you can check into the repository from any set of working files across the internet. (I.e., no more ftping files by hand. Just check versions into and synch the repository, and then update the files on the server from the repository). This is how people collaborating on open source projects share source code and work on the same files simultaneously across the 'net and everybody stays up to date and has access to all the latest changes. It's all about tracking changes and then applying them.

OSX, by default these days, comes with svn installed. Git and hg ports are easily found and installed. And nearly all the modern coding IDE applications, like vim, BBEdit, XCode, Eclipse, and and VisualStudio through plugins or in the default install can integrate with version control systems really well, so you don't have to open up a command line to perform version control commands like diffing, patching, checking out, checking in, and syncing to the repository.

I use CVS a lot at work, and I'm getting up to speed on git, and I'm getting to the point of trying to figure out the whole branch'n'merge part of the picture, just because it's such a continual pain to repeatedly have to merge my Wordpress theme changes in on top of newer versions. Being able to see which files changed and which ones didn't (and what the changes were) in the update are also good. I'd like a tool that does this automagically for me. Or at least makes it easier for me to do it by hand.

I tend to mess with website code in Eclipse for PHP Developers. I like it because, being an open source Java app, it looks the same to me on OSX, Windows, or Ubuntu. (Same reason I like OpenOffice). My only complaint about it right now is it will let me work directly on files on a remote server, and it will let me do CVS with local files, but it won't let me do CVS on files on a remote server.
__________________
I shoot with a Canon 5DmkII, 50D, and S90, and Pansonic G3. flickr stream and equipment list

Last edited by inkista; 05-11-2011 at 01:18 AM. Reason: typos
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On
Trackbacks are On
Pingbacks are On
Refbacks are Off



Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.

What’s Your Preference?

Daily Digest

Each day we send out a quick email to thousands of DPS readers to notify them of updates. This email is just short excerpt of the first few lines of our latest post with a link if you want to read it all. You can unsubscribe from this this service at any time.

This service is provided by a third party (Feedburner) and you can subscribe to it by leaving your email address in the following field and confirming your subscription when you get an email asking you to do so.

Enter your email address for
Daily Updates:

Weekly Summary

For those wanting a weekly summary of what happens on this site this free email newsletter is probably your best option. It includes a summary of the tips posted to the site each week. This newsletter is subscribed to by over 25000 readers (many who also subscribe to the other options above) - come join the community!

To subscribe to this weekly newsletter simply add your email address to the following field and then follow the confirmation prompts. You will be able to unsubscribe at any time.

Enter your email address for
Free Weekly Newsletter:

 
SEO by vBSEO 3.3.0