CSS, What should I put into the CSS... |
CSS, What should I put into the CSS... |
violingirl1978 |
Oct 24 2015, 02:32 AM
Post
#1
|
Member Group: Members Posts: 85 Joined: 20-March 15 Member No.: 22,400 |
so my social media icons are centered? I need the code verbatim. Thank you and here is the website: http://www.proviolin.com/
|
Frederiek |
Oct 24 2015, 03:40 AM
Post
#2
|
Programming Fanatic Group: Members Posts: 5,146 Joined: 23-August 06 From: Europe Member No.: 9 |
You mean like in setting text-align: center; to the div with class .social-share?
|
customcomputer.expert |
Oct 24 2015, 11:05 AM
Post
#3
|
Group: Members Posts: 2 Joined: 24-October 15 Member No.: 23,675 |
In your css type the following,
.center { text-align: center; } This will allow you to use the class="center" in any function not just div. your first <div> should look like this: <div class="center"> You can also use this in <p> <a> or any other function to express that it is center. |
Frederiek |
Oct 24 2015, 04:38 PM
Post
#4
|
Programming Fanatic Group: Members Posts: 5,146 Joined: 23-August 06 From: Europe Member No.: 9 |
Excuse me, but I don't see how your reply adds anything to what I already suggested.
|
violingirl1978 |
Oct 24 2015, 10:19 PM
Post
#5
|
Member Group: Members Posts: 85 Joined: 20-March 15 Member No.: 22,400 |
Yes, what is the code verbatim?
|
violingirl1978 |
Oct 24 2015, 10:21 PM
Post
#6
|
Member Group: Members Posts: 85 Joined: 20-March 15 Member No.: 22,400 |
|
violingirl1978 |
Oct 24 2015, 10:28 PM
Post
#7
|
Member Group: Members Posts: 85 Joined: 20-March 15 Member No.: 22,400 |
I typed
.center { text-align: center; } and the social share buttons were not centered after I did that even with clearing the cache (history). I also put .center { text-align: center; } <div class="center"> cleared the cache with this combination and the social share buttons were not centered. I also put <div class="center"> into the CSS and still the same problem. It's been awhile since I've worked on my website so I need step by step instructions for this to work. Do I put the code into the editor header part of things? |
pandy |
Oct 25 2015, 12:50 AM
Post
#8
|
🌟Computer says no🌟 Group: WDG Moderators Posts: 20,716 Joined: 9-August 06 Member No.: 6 |
QUOTE I typed .center { text-align: center; } and the social share buttons were not centered after I did that even with clearing the cache (history). I also put .center { text-align: center; } <div class="center"> What's the difference? |
pandy |
Oct 25 2015, 01:08 AM
Post
#9
|
🌟Computer says no🌟 Group: WDG Moderators Posts: 20,716 Joined: 9-August 06 Member No.: 6 |
I need the code verbatim. No, you don't. You need to figure out how things work and learn something. Frederiek's suggestion works fine. You probably either used it with the wrong DIV or you made a syntax error when adding this second class - the DIV in question already has a class. It's the DIV with the class 'social-share' you are after. If you don't know how to give an element multiple classes, here's how: http://htmlhelp.com/reference/html40/attrs.html#class . But it's better to use the class that's already there and add 'text-align: center' to the rule for '.social-share', unless you use that class for something else too and you don't want that to be centered. |
Frederiek |
Oct 25 2015, 06:01 AM
Post
#10
|
Programming Fanatic Group: Members Posts: 5,146 Joined: 23-August 06 From: Europe Member No.: 9 |
The .social-share class has no rules applied to it, so that can be used to set the text-align: center;. That DIV is used on all pages.
BTW, the pages are made in WordPress. @violingirl You need to understand that you can't just put HTML elements (such as A, P, DIV, etc.) everywhere. They don't belong in the HEAD of a page, nor in CSS. And you have several of those. A class attribute on an HTML element is a hook to style it with CSS, an ID can be used for that too, only they must have a unique value over each page. See http://htmlhelp.com/reference/css/structure.html . Where to put it? I suppose in the custom.css, instead of the <div class="center"> you have there now (where that doesn't belong). Put the style rule there, using the proper syntax. |
violingirl1978 |
Oct 25 2015, 12:28 PM
Post
#11
|
Member Group: Members Posts: 85 Joined: 20-March 15 Member No.: 22,400 |
I need the code verbatim. No, you don't. You need to figure out how things work and learn something. Frederiek's suggestion works fine. You probably either used it with the wrong DIV or you made a syntax error when adding this second class - the DIV in question already has a class. It's the DIV with the class 'social-share' you are after. If you don't know how to give an element multiple classes, here's how: http://htmlhelp.com/reference/html40/attrs.html#class . But it's better to use the class that's already there and add 'text-align: center' to the rule for '.social-share', unless you use that class for something else too and you don't want that to be centered. Your guidance and assistance will get anyone a lot further than snotty remarks. |
violingirl1978 |
Oct 25 2015, 01:22 PM
Post
#12
|
Member Group: Members Posts: 85 Joined: 20-March 15 Member No.: 22,400 |
The .social-share class has no rules applied to it, so that can be used to set the text-align: center;. That DIV is used on all pages. BTW, the pages are made in WordPress. @violingirl You need to understand that you can't just put HTML elements (such as A, P, DIV, etc.) everywhere. They don't belong in the HEAD of a page, nor in CSS. And you have several of those. A class attribute on an HTML element is a hook to style it with CSS, an ID can be used for that too, only they must have a unique value over each page. See http://htmlhelp.com/reference/css/structure.html . Where to put it? I suppose in the custom.css, instead of the <div class="center"> you have there now (where that doesn't belong). Put the style rule there, using the proper syntax. Thanks Frederiek. I used my other theme, not sure why the themes didn't transfer from one to the other but things should be working now In the mean time, I am working on another site as the general consensus is that I should have a one line menu instead of a two line menu. Here is my new site where I have made the change: http://proviolin.com/newsite/. For the drop down menus, do they seem to be organized efficiently? I'm not sure if one category should go in another drop down menu. I'm not the best at organizing things. I am also thinking of putting in this video about the Suzuki method and mention a quote from Dr. Suzuki: “When love is deep, much can be accomplished” But, my question is, is the video too sappy? http://us.labs.teads.tv/video/eden-grace---don-give-11186259 I am also thinking about having a quote from Dr. Suzuki at the header part of my website: “Man is a child of his environment” |
pandy |
Oct 25 2015, 04:59 PM
Post
#13
|
🌟Computer says no🌟 Group: WDG Moderators Posts: 20,716 Joined: 9-August 06 Member No.: 6 |
Your guidance and assistance will get anyone a lot further than snotty remarks. Probably. But I reserve that for those who do their bit and try to learn this stuff. You want people to do your job for you and to be honest I find that rather annoying not to say offensive. I guess I've seen too many "give me the code" type of guys to find it cute. I didn't give it to you "verbatim" but I did give you guidance. But of course, you would have to bother to read and type the stuff yourself. Too much to ask for, you think? |
violingirl1978 |
Oct 27 2015, 12:17 AM
Post
#14
|
Member Group: Members Posts: 85 Joined: 20-March 15 Member No.: 22,400 |
Your guidance and assistance will get anyone a lot further than snotty remarks. Probably. But I reserve that for those who do their bit and try to learn this stuff. You want people to do your job for you and to be honest I find that rather annoying not to say offensive. I guess I've seen too many "give me the code" type of guys to find it cute. I didn't give it to you "verbatim" but I did give you guidance. But of course, you would have to bother to read and type the stuff yourself. Too much to ask for, you think? What I read was like reading a foreign language. |
Frederiek |
Oct 27 2015, 05:19 AM
Post
#15
|
Programming Fanatic Group: Members Posts: 5,146 Joined: 23-August 06 From: Europe Member No.: 9 |
Sorry for my late reply.
This is your third template in which you try to create your site. And each time, you tweak it so much that you get stuck. That's the case with this Alhena template too. I suppose you are a freelance teacher, trying to make money with your lessons. So your site should reflect your professionalism and way of working, to attract new pupils/students. Your site is like your business card. I can understand that you have feelings about the quotes and video, but I don't think they would be in the right place on a violin teaching site. Put yourself in the place of your visitors who are looking for violin lessons. What would you expect to find and why should visitors choose you? |
violingirl1978 |
Oct 27 2015, 01:31 PM
Post
#16
|
Member Group: Members Posts: 85 Joined: 20-March 15 Member No.: 22,400 |
Sorry for my late reply. This is your third template in which you try to create your site. And each time, you tweak it so much that you get stuck. That's the case with this Alhena template too. I suppose you are a freelance teacher, trying to make money with your lessons. So your site should reflect your professionalism and way of working, to attract new pupils/students. Your site is like your business card. I can understand that you have feelings about the quotes and video, but I don't think they would be in the right place on a violin teaching site. Put yourself in the place of your visitors who are looking for violin lessons. What would you expect to find and why should visitors choose you? Hi Frederiek, Thank you for your reply. Yeah, I am not crazy about the Alhena template either. I am just messing around with different themes. Some violin teachers I have seen put quotes from Dr. Suzuki as a way to fill up the pages. I will keep looking at other violin teacher sites. Thank you very much for your help so far. |
Frederiek |
Oct 28 2015, 05:03 AM
Post
#17
|
Programming Fanatic Group: Members Posts: 5,146 Joined: 23-August 06 From: Europe Member No.: 9 |
You might consider to hand-code your site in a text editor. You'll then have full control, might not have the need for all those CSS and script files and don't have to fight someone else's code. And, you'll learn something along the way.
|
violingirl1978 |
Nov 2 2015, 12:37 AM
Post
#18
|
Member Group: Members Posts: 85 Joined: 20-March 15 Member No.: 22,400 |
You might consider to hand-code your site in a text editor. You'll then have full control, might not have the need for all those CSS and script files and don't have to fight someone else's code. And, you'll learn something along the way. What text editor should I use? Should I build a website using HTML you're saying? |
Frederiek |
Nov 2 2015, 04:58 AM
Post
#19
|
Programming Fanatic Group: Members Posts: 5,146 Joined: 23-August 06 From: Europe Member No.: 9 |
Yes, write your own HTML, instead of having to mess around with WP. Though WP is a rather good choice if you blog. But hey, I'm familiar with HTML/CSS, so it's easy to say for me. On the other hand, you might get better help here with plain HTML.
I suppose you're on PC, so I believe NotePad ++ is a good choice from what I hear. If you're on Mac, then I suggest TextWrangler (free) or better yet (its paid counterpart) BBEdit; see http://www.barebones.com . |
Lo-Fi Version | Time is now: 19th March 2024 - 02:33 AM |