do you know css

Ye' old general discussion board. Basically, for everything that isn't covered elsewhere. Come here to shoot the breeze, shoot your mouth off, or whatever suits your fancy.
This forum is not for asking programming related questions.

Moderator: General Moderators

Post Reply
m2babaey
Forum Contributor
Posts: 364
Joined: Sun May 20, 2007 9:26 am

do you know css

Post by m2babaey »

Hi
I don't know css.
Do you thinks that makes a big problem for me as a php programmer
User avatar
Benjamin
Site Administrator
Posts: 6935
Joined: Sun May 19, 2002 10:24 pm

Post by Benjamin »

Not if you have a designer ;)
m2babaey
Forum Contributor
Posts: 364
Joined: Sun May 20, 2007 9:26 am

Post by m2babaey »

but what if I go bidding in freelance services :(
User avatar
guitarlvr
Forum Contributor
Posts: 245
Joined: Wed Mar 21, 2007 10:35 pm

Post by guitarlvr »

if you have someone to write your CSS for you then no it won't be a problem. If you plan on writting the visual presentation as well as the PHP code then yes it will become and issue if you don't know CSS.
m2babaey
Forum Contributor
Posts: 364
Joined: Sun May 20, 2007 9:26 am

Post by m2babaey »

can css be written by something like fronpage or so? or it must be coded manually like php?
User avatar
guitarlvr
Forum Contributor
Posts: 245
Joined: Wed Mar 21, 2007 10:35 pm

Post by guitarlvr »

I've never really tried to get a WYSIWYG editor to write CSS. If it did, I immagine it would put it inside the page and not in a separate file (which is easier for administration). It might, all you can do is test it.
m2babaey
Forum Contributor
Posts: 364
Joined: Sun May 20, 2007 9:26 am

Post by m2babaey »

cannot i move the internal code to an external style sheet?
also, how useful is that editor in css?
nickvd
DevNet Resident
Posts: 1027
Joined: Thu Mar 10, 2005 5:27 pm
Location: Southern Ontario
Contact:

Post by nickvd »

Frontpage is a useless editor for any language... in my opinion at least...
User avatar
Chalks
Forum Contributor
Posts: 447
Joined: Thu Jul 12, 2007 7:55 am
Location: Indiana

Post by Chalks »

incidently, CSS is _very_ easy to learn. Just search google for "CSS tutorial", and you'll find plenty of resources.

Heck, I even taught my mother how to do some css so that I didn't have to keep changing her site... and she hates computers.
User avatar
RobertGonzalez
Site Administrator
Posts: 14293
Joined: Tue Sep 09, 2003 6:04 pm
Location: Fremont, CA, USA

Post by RobertGonzalez »

If you plan on being a web developer that does more than server side coding then you will need to know most the newer levels of (X)HTML as well as CSS. Not knowing them makes you that much less of a valid choice for clients.

Frontpage is crap. Don't use it. Dreamweaver is also crap, but it does a decent job of writing CSS. I would recommend you learn CSS (the way you learned PHP), get a light editor (Notepad2 or Programmers Notepad) and starting making CSS rules for generic templates to see what it does (you know, kinda like the way you are supposed to try things in PHP to see what they do?).
User avatar
superdezign
DevNet Master
Posts: 4135
Joined: Sat Jan 20, 2007 11:06 pm

Post by superdezign »

Chalks wrote:incidently, CSS is _very_ easy to learn. Just search google for "CSS tutorial", and you'll find plenty of resources.

Heck, I even taught my mother how to do some css so that I didn't have to keep changing her site... and she hates computers.
Not "easy." Just like PHP, you will likely run into a lot of problems due to a lack of understanding. There are concepts that are different, and a lot of things where the only way you'll really understand it is to actually DO it. foreach is a PHP thing, float is a CSS thing.

If anything, make sure that you learn and *understand* the box model. Margin, border, padding, content.
User avatar
Chalks
Forum Contributor
Posts: 447
Joined: Thu Jul 12, 2007 7:55 am
Location: Indiana

Post by Chalks »

superdezign wrote:Not "easy." Just like PHP, you will likely run into a lot of problems due to a lack of understanding. There are concepts that are different, and a lot of things where the only way you'll really understand it is to actually DO it. foreach is a PHP thing, float is a CSS thing.

If anything, make sure that you learn and *understand* the box model. Margin, border, padding, content.
I guess it depends on how you define "easy". I simply meant that compared to php, css is a breaze. You don't have to deal with functions, classes, objects, built in functions, predefined variables, etc. I could teach css to a brand new beginner _far_ easier than I could teach php... the concepts are simpler.


Edit: I suppose I may feel that way because I'm more familiar with css than php though. *shrug*
User avatar
superdezign
DevNet Master
Posts: 4135
Joined: Sat Jan 20, 2007 11:06 pm

Post by superdezign »

Chalks wrote:I guess it depends on how you define "easy". I simply meant that compared to php, css is a breaze. You don't have to deal with functions, classes, objects, built in functions, predefined variables, etc. I could teach css to a brand new beginner _far_ easier than I could teach php... the concepts are simpler.


Edit: I suppose I may feel that way because I'm more familiar with css than php though. *shrug*
I guess also because as PHP programmers, we spend so much time on the back-end that we don't put that much effort into the CSS part. A lot of the more experienced programmers here still run into big CSS problems.
User avatar
RobertGonzalez
Site Administrator
Posts: 14293
Joined: Tue Sep 09, 2003 6:04 pm
Location: Fremont, CA, USA

Post by RobertGonzalez »

superdezign wrote:If anything, make sure that you learn and *understand* the box model. Margin, border, padding, content.
And how they differ among user agents. IE is the bane of many a developer's existence.
User avatar
Ollie Saunders
DevNet Master
Posts: 3179
Joined: Tue May 24, 2005 6:01 pm
Location: UK

Post by Ollie Saunders »

CSS syntax is easy but CSS based design is not. Truely.

I've read two books on CSS and have been using CSS based design and following blogs about it for almost 2 years and I still experience problems that require some creative thinking.

On one hand I'd say it's seriously worth learning because you can't really be left on your own to produce something without it but on the other it's a really big pain in the ass that you're better not being bothered with. For your CV's benefit you should probably do it. I recommend Bulletproof Web Design and the CSS Anthology and then there are a bunch of good sites: It's also well worth using simple PHP so you can compute CSS expressions and deliver slightly different CSS to different browsers.

Code: Select all

<?php
header('Content-Type: text/css');
$browser = get_browser(null, false);

$width = 600;
$leftWidth = 200;
$rightWifth = 205;
?>
body {
    <?php if ($browser->browser === 'IE'): ?>
    width:850px;
    <?php else: ?>
    min-width:500px;
    max-width:1150px;
    <?php endif; ?>
}
#main {
    width:<?php echo $width - $rightWidth - $leftWidth?>px;
}
#left {
    width:<?php echo $leftWidth ?>px;
}
#right {
    width:<?php echo $rightWidth?>px;
}
etc.
Post Reply