Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
The Dave
Sep 9, 2003

gbaby posted:

but you have to explicitly set all of those different column classes for different browser widths

Well to be fair that's only if you want the grid to change at those breakpoints. I find the bs grid semantics to be really easy to remember but I'm super used to it.

Adbot
ADBOT LOVES YOU

kedo
Nov 27, 2007

CSS frameworks are dumb and you shouldn't use them.

well why not
Feb 10, 2009




I like using Neat, presentational classes are ugly and annoying to use for most sites.

Impotence
Nov 8, 2010
Lipstick Apathy
I did it the lazy way and just bound things like .copyright { @include make-col(..); } because I didn't like having a dozen col-*

putin is a cunt
Apr 5, 2007

BOY DO I SURE ENJOY TRASH. THERE'S NOTHING MORE I LOVE THAN TO SIT DOWN IN FRONT OF THE BIG SCREEN AND EAT A BIIIIG STEAMY BOWL OF SHIT. WARNER BROS CAN COME OVER TO MY HOUSE AND ASSFUCK MY MOM WHILE I WATCH AND I WOULD CERTIFY IT FRESH, NO QUESTION

kedo posted:

CSS frameworks are dumb and you shouldn't use them.

we would all love to have unlimited time to develop projects but in reality you have to accept that you can't reinvent the wheel every time and so you use someone else's already written and meticulously tested code, is that so bad?

ddiddles
Oct 21, 2008

Roses are red, violets are blue, I'm a schizophrenic and so am I
Is there any good blog posts/tutorials on building your own grid system? I've always used a framework like Skeleton, but I want to actually learn how it all works.

ddiddles fucked around with this message at 07:38 on Dec 21, 2016

well why not
Feb 10, 2009




I'd just suggest you dig into the math for neat or susy, that's probably easier than starting 100% from scratch.

Heskie
Aug 10, 2002

kedo posted:

CSS frameworks are dumb and you shouldn't use them.

I used to agree with this completely, until I realised how much more productive I was using a framework.

Now I just see it as an extension of using something like Normalize. I can carry the conventions between projects and teams. Even when I was using BEM for everything, I'd often name components slightly differently between projects which was always annoying when I came back 12 months later.

ddiddles posted:

Is there any good blog posts/tutorials on building your own grid system? I've always used a framework like Skeleton, but I want to actually learn how it all works.

This is an oldie but goodie https://css-tricks.com/dont-overthink-it-grids/

Knifegrab
Jul 30, 2014

Gadzooks! I'm terrified of this little child who is going to stab me with a knife. I must wrest the knife away from his control and therefore gain the upperhand.
I have a simple problem that is perplexing me.

I have a div that surrounds two images. One is an overlay, and the other is full width.

code:
<div class="container">
   <img class="overlay">
   <img class="divImg">
</div>
Now since I want the overlay image to reside on top of the other, I gave it an absolute position. If I just give it a position: absolute, it sits overlayed nicely on the top left of the image. HOWEVER: As soon as I add a top, left, right, or bottom css field to adjust its positioning as an overlay, the overlay image suddenly breaks out of the box and uses the window to position itself, as though its position got set to fixed.

Any idea why this is happening?

ynohtna
Feb 16, 2007

backwoods compatible
Illegal Hen
Is your container class set to position: relative? Can you reproduce the problem in an isolated small fiddle/codepen?

Knifegrab
Jul 30, 2014

Gadzooks! I'm terrified of this little child who is going to stab me with a knife. I must wrest the knife away from his control and therefore gain the upperhand.

ynohtna posted:

Is your container class set to position: relative? Can you reproduce the problem in an isolated small fiddle/codepen?

I love you. Setting the parent container to position: relative fixed the issue!

I got another simple css question that I can't seem to google: I have a container that is slightly smaller than the image I want to put in it. FOr simplicity sake I don't want to stretch the image, I am fine with it being cut off, but I want the TOP of the image cut off not the bottom. What is the easiest way to accomplish this.

edit: Nvm I am an idiot, position:absolute bottom 0;

double edit: But how would I achieve this with a background-img?

Knifegrab fucked around with this message at 22:14 on Dec 21, 2016

ynohtna
Feb 16, 2007

backwoods compatible
Illegal Hen
If you're in modern CSS & browser land then a combination of background-size: cover and background-position: center bottom (may need other values) could do the job. I find doing this stuff with an <img> to be easier, though.

Lumpy
Apr 26, 2002

La! La! La! Laaaa!



College Slice

Knifegrab posted:

I love you. Setting the parent container to position: relative fixed the issue!

I got another simple css question that I can't seem to google: I have a container that is slightly smaller than the image I want to put in it. FOr simplicity sake I don't want to stretch the image, I am fine with it being cut off, but I want the TOP of the image cut off not the bottom. What is the easiest way to accomplish this.

edit: Nvm I am an idiot, position:absolute bottom 0;

double edit: But how would I achieve this with a background-img?

background: url(blah.png) bottom right;

Knifegrab
Jul 30, 2014

Gadzooks! I'm terrified of this little child who is going to stab me with a knife. I must wrest the knife away from his control and therefore gain the upperhand.
You guys rock.

ddiddles
Oct 21, 2008

Roses are red, violets are blue, I'm a schizophrenic and so am I

That's exactly what I was looking for, thanks!

Newf
Feb 14, 2006
I appreciate hacky sack on a much deeper level than you.
I made a kickin rad website for my kickin rad educational outreach group at http://ykmathcircle.com.

There's a problem though - lots of email servers are blocking emails that contain links to it, sometimes citing spam concerns. Most recently, I got:

quote:

The error that the other server returned was:
550 permanent failure for one or more recipients (person@company.com:quarantined)

There was a different failure code from a different mail server a while back, but I can't track it down right now.

Any ideas? Any red flags in the source / hosting / etc? It's gh-pages hosted, Jekyll built. The site is active on cloudflare (I can't say more than this, because I'm not sure what exactly cloudflare does for a website). I'm really at a loss. It sucks not to be able to link the page in emails about the group.

The Fool
Oct 16, 2003


Newf posted:

I made a kickin rad website for my kickin rad educational outreach group at http://ykmathcircle.com.

There's a problem though - lots of email servers are blocking emails that contain links to it, sometimes citing spam concerns. Most recently, I got:


There was a different failure code from a different mail server a while back, but I can't track it down right now.

Any ideas? Any red flags in the source / hosting / etc? It's gh-pages hosted, Jekyll built. The site is active on cloudflare (I can't say more than this, because I'm not sure what exactly cloudflare does for a website). I'm really at a loss. It sucks not to be able to link the page in emails about the group.

How are you sending mail out? Who's your mail provider? Are you actually sending mail from your domain or a service? Is your domain blacklisted?

ddiddles
Oct 21, 2008

Roses are red, violets are blue, I'm a schizophrenic and so am I

Newf posted:

I made a kickin rad website for my kickin rad educational outreach group at http://ykmathcircle.com.

There's a problem though - lots of email servers are blocking emails that contain links to it, sometimes citing spam concerns. Most recently, I got:


There was a different failure code from a different mail server a while back, but I can't track it down right now.

Any ideas? Any red flags in the source / hosting / etc? It's gh-pages hosted, Jekyll built. The site is active on cloudflare (I can't say more than this, because I'm not sure what exactly cloudflare does for a website). I'm really at a loss. It sucks not to be able to link the page in emails about the group.

I dunno what's up with your site, but it lags like crazy. Getting maybe 3-5fps when scrolling, even highlighting text is laggy? Happens for me in Chrome on Windows 10, seems to be fine on Edge though, no other sites are acting like this in Chrome.

Just a heads up.

Newf
Feb 14, 2006
I appreciate hacky sack on a much deeper level than you.

The Fool posted:

How are you sending mail out? Who's your mail provider? Are you actually sending mail from your domain or a service? Is your domain blacklisted?

I'm just sending an email via my own gmail account. I've got no idea how the domain might have been blacklisted.

ddiddles posted:

I dunno what's up with your site, but it lags like crazy. Getting maybe 3-5fps when scrolling, even highlighting text is laggy? Happens for me in Chrome on Windows 10, seems to be fine on Edge though, no other sites are acting like this in Chrome.

Just a heads up.

Thanks for that. I had seen this lovely behaviour on a mobile browser but shrugged it off. Chrome sort of matters, so I'll look into it. It's got an onscroll event that checks the scroll height in order to toggle the nag headers appearance. Maybe that gets fired more than once per frame in some browsers.

Ninja.Bob
Mar 31, 2005
Regarding the site performance, it's the svg in the header, just replace it with a png.

ddiddles
Oct 21, 2008

Roses are red, violets are blue, I'm a schizophrenic and so am I

Ninja.Bob posted:

Regarding the site performance, it's the svg in the header, just replace it with a png.

Yep, removed that svg and it scrolls normally. Thats a pretty intricate design that would need to be redrawn every frame.

Lumpy
Apr 26, 2002

La! La! La! Laaaa!



College Slice

Newf posted:



Thanks for that. I had seen this lovely behaviour on a mobile browser but shrugged it off.

Mobile/ devices now account for more than half of web traffic. Don't shrug it off unless you have a very specific use case.

putin is a cunt
Apr 5, 2007

BOY DO I SURE ENJOY TRASH. THERE'S NOTHING MORE I LOVE THAN TO SIT DOWN IN FRONT OF THE BIG SCREEN AND EAT A BIIIIG STEAMY BOWL OF SHIT. WARNER BROS CAN COME OVER TO MY HOUSE AND ASSFUCK MY MOM WHILE I WATCH AND I WOULD CERTIFY IT FRESH, NO QUESTION

Lumpy posted:

Mobile/ devices now account for more than half of web traffic. Don't shrug it off unless you have a very specific use case.

That very much depends on the audience. A site I worked on had 0.1% mobile traffic. Use analytics don't guess.

Lumpy
Apr 26, 2002

La! La! La! Laaaa!



College Slice

The Wizard of Poz posted:

That very much depends on the audience. A site I worked on had 0.1% mobile traffic. Use analytics don't guess.

So you are saying if you have a specific use case you can ignore it? :v:

Using analytics is wise though, but my point which I apparently failed to make was that offhandedly ignoring mobile is not a good idea.

seance snacks
Mar 30, 2007

The Wizard of Poz posted:

That very much depends on the audience. A site I worked on had 0.1% mobile traffic. Use analytics don't guess.

Even still I'm pretty sure google penalizes for not having a mobile friendly site. I use their checker tool all the time just to cross off a line item

McGlockenshire
Dec 16, 2005

GOLLOCKS!

Noslo posted:

Even still I'm pretty sure google penalizes for not having a mobile friendly site. I use their checker tool all the time just to cross off a line item

As of when this rolled out last year, the not-mobile-friendly penalty applied only for searches done from a mobile device.

Don't ignore mobile, but you don't need to panic about it.

Kekekela
Oct 28, 2004

McGlockenshire posted:

As of when this rolled out last year, the not-mobile-friendly penalty applied only for searches done from a mobile device.

Don't ignore mobile, but you don't need to panic about it.

Didn't they make mobile their primary index earlier this year though?

McGlockenshire
Dec 16, 2005

GOLLOCKS!

Kekekela posted:

Didn't they make mobile their primary index earlier this year though?

Can you say where you read about this?

The mobipocolypse was in April 2015, not this year. Everything I can find about the not-mobile-friendly search result penalty is from that era, and it only talks about searches made from mobile devices.

The Dave
Sep 9, 2003

Pretty easy to find tons of articles about it, but it's not exactly related to how you create your site, but how people access google.

Either way to not have some sort of mobile layout is just flat out ridiculous unless we're talking about a desktop web application.

Knifegrab
Jul 30, 2014

Gadzooks! I'm terrified of this little child who is going to stab me with a knife. I must wrest the knife away from his control and therefore gain the upperhand.
So I am wrestling with responsive design, and I have kind of come to a philosophy question. Is it sometimes best to just output the displayed information twice (one that is hidden at certain breakpoints and vice versa)? Once in a way that is organized for desktop and one for mobile (or whatever breakpoints you have set.)? I am realizing that while I can do A LOT with css to change the different responsive sizes, I can't do everything...

Knifegrab fucked around with this message at 01:45 on Dec 24, 2016

lunar detritus
May 6, 2009


Knifegrab posted:

So I am wrestling with responsive design, and I have kind of come to a philosophy question. Is it sometimes best to just output the displayed information twice (one that is hidden at certain breakpoints and vice versa)? Once in a way that is organized for desktop and one for mobile (or whatever breakpoints you have set.)? I am realizing that while I can do A LOT with css to change the different responsive sizes, I can't do everything...

I feel that if you have to do that kind of thing something went wrong in the design stage. Things flow in a certain, predictable, way.

So yeah, output whatever you need twice if changing the design is not an option. It's kinda out of your hands.

Edit: Or make a mobile site. It's a different kind of terribleness but a valid option if the design is not really that responsive.

lunar detritus fucked around with this message at 02:58 on Dec 24, 2016

Maluco Marinero
Jan 18, 2001

Damn that's a
fine elephant.
Screen readers don't see display none so it's 'fine', but usually makes things harder to trace and maintain down the line once the site gets to a certain size.

Whenever given a desktop design I always try to lay out the markup in a way that makes sense from a document perspective, and then do any design concessions after. 'Typically' that should result in a code structure that works in mobile, and then you're just gradually adding a smattering of layout styles as the page grows out to desktop sizes.

putin is a cunt
Apr 5, 2007

BOY DO I SURE ENJOY TRASH. THERE'S NOTHING MORE I LOVE THAN TO SIT DOWN IN FRONT OF THE BIG SCREEN AND EAT A BIIIIG STEAMY BOWL OF SHIT. WARNER BROS CAN COME OVER TO MY HOUSE AND ASSFUCK MY MOM WHILE I WATCH AND I WOULD CERTIFY IT FRESH, NO QUESTION

Lumpy posted:

So you are saying if you have a specific use case you can ignore it? :v:

Using analytics is wise though, but my point which I apparently failed to make was that offhandedly ignoring mobile is not a good idea.

Eh, you're right I misread your post my bad. We agree

No Gravitas
Jun 12, 2013

by FactsAreUseless
This thing is driving me insane. Someone gave it to me as a riddle and I cannot crack this puzzle. I conceded defeat, but it keeps haunting me.

I have a list of requirements:

1. Text centered vertically in boxes.
2. Text centered horizontally in the said boxes.
3. The whole body of the boxes are clickable links, both horizontally and vertically.
4. The boxes sometime have one line of text in it, sometimes two, sometimes three.
5. :siren: No Javascript. :siren: That's the rule of the riddle. Otherwise I'd just onclick and call it a day.
6. All of the boxes must be of the same height, enough to fit the whole content in the most full box. It is totally fine to set some fixed height to any of the components, but not the number of lines they contain.
7. Not attached to any specific method, besides avoiding JS.

Skil level: I'm a web design moron who thought he is smarter than he is.

Here is the closest I got to be at, using table cells: http://jsfiddle.net/m1mskfbe/3/

The second box is clickable anywhere, even not on the text. The first box is clickable on the entire width of the box, but only for the heights that have the text. I want the whole box to be always clickable, even if there is no text for a given verticality.

please help it hurts so much

lunar detritus
May 6, 2009


No Gravitas posted:

please help it hurts so much

With flexbox: http://jsfiddle.net/m1mskfbe/4/

No Gravitas
Jun 12, 2013

by FactsAreUseless

I think I love you.

Kekekela
Oct 28, 2004

McGlockenshire posted:

Can you say where you read about this?


Can't remember if this was the original article that I saw, but they talk about it here: http://www.businessinsider.com/google-changing-index-splitting-into-desktop-and-mobile-2016-10

the third paragraph posted:

...Google is prioritising the mobile index over the desktop one...

HappyHippo
Nov 19, 2003
Do you have an Air Miles Card?

Knifegrab posted:

So I am wrestling with responsive design, and I have kind of come to a philosophy question. Is it sometimes best to just output the displayed information twice (one that is hidden at certain breakpoints and vice versa)? Once in a way that is organized for desktop and one for mobile (or whatever breakpoints you have set.)? I am realizing that while I can do A LOT with css to change the different responsive sizes, I can't do everything...

I've been wondering this myself. I've been working on a site with a lot of diagrams to go with the text, and I want it so that on wide enough screens some diagrams move to a second column alongside the text, while on narrower screens everything is just a single column. I've got this working fine using "display: inline-block," but every now and then I come across a situation where the best two column layout would require the content in a different order than the best single column layout, and I can't decide which to favour. I feel like the best solution might just be to duplicate some stuff with one element hidden and use a media query to switch between them.

McGlockenshire
Dec 16, 2005

GOLLOCKS!

Kekekela posted:

Can't remember if this was the original article that I saw, but they talk about it here: http://www.businessinsider.com/google-changing-index-splitting-into-desktop-and-mobile-2016-10

After following that to the source article, I eventually was reminded by this article that the Google Webmasters blog still exists.

Mobile-first indexing went live in November.

quote:

To make our results more useful, we’ve begun experiments to make our index mobile-first. Although our search index will continue to be a single index of websites and apps, our algorithms will eventually primarily use the mobile version of a site’s content to rank pages from that site, to understand structured data, and to show snippets from those pages in our results. Of course, while our index will be built from mobile documents, we're going to continue to build a great search experience for all users, whether they come from mobile or desktop devices.
[...]
If you have a responsive site or a dynamic serving site where the primary content and markup is equivalent across mobile and desktop, you shouldn’t have to change anything.
So, there we have it. Go responsive or go home. The "dynamic servicing" there is user-agent sniffing to serve different markup, and that's a painful road that nobody should seriously consider (except for maybe CSS files if you have to)

McGlockenshire fucked around with this message at 19:01 on Dec 24, 2016

Adbot
ADBOT LOVES YOU

putin is a cunt
Apr 5, 2007

BOY DO I SURE ENJOY TRASH. THERE'S NOTHING MORE I LOVE THAN TO SIT DOWN IN FRONT OF THE BIG SCREEN AND EAT A BIIIIG STEAMY BOWL OF SHIT. WARNER BROS CAN COME OVER TO MY HOUSE AND ASSFUCK MY MOM WHILE I WATCH AND I WOULD CERTIFY IT FRESH, NO QUESTION

McGlockenshire posted:

After following that to the source article, I eventually was reminded by this article that the Google Webmasters blog still exists.

Mobile-first indexing went live in November.

So, there we have it. Go responsive or go home. The "dynamic servicing" there is user-agent sniffing to serve different markup, and that's a painful road that nobody should seriously consider (except for maybe CSS files if you have to)

They're not saying that they will rank your page higher or lower, they're not talking about pagerank at all. They're saying that the content included in the result text will be drawn from your page using a mobile-first approach. If your content is the same when visited on mobile and on desktop, (including not having a mobile version at all) then you won't see any difference.

quote:

If you only have a desktop site, we'll continue to index your desktop site just fine, even if we're using a mobile user agent to view your site.

(In fact, even the Business Insider article is not talking about pagerank either).

putin is a cunt fucked around with this message at 01:23 on Dec 26, 2016

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply