super tired scroll down and right
I never have time, so this will be quick. Let’s say we want to find a pixel index amoung all that image data canvas returns with: The formula is simple: Basically, you need to draw this one out. Let’s say we have a 3×3 image. Each pixel would have it’s own zero based index. The width would be three. Each
Just wanted to post this. The source is pretty self explanatory and i’ll put up a github later once I clean up a few things. I’ll explain later. Be patient, it takes a second to load. DEMO –>
So you’ve been making ajax calls and everything is going great. Your onSuccess message looks something like this: All of a sudden your QA professional says things aren’t working in iOS8! No prob, bob. It’s actually that iOS8 and below doesn’t return a “responseURL” attribute of the xhr object. Look at the difference: iOS8 xhr object: Everything else: Anyway…
This one is quick. Usually you can do: But sometimes you need to vertically center something without the use of transforms. Here’s a little snippet: If you don’t know the height of the parent (as is most cases) this might work: And here’s a little demo. The “marker” div is using transforms. The “centered” div isn’t: See the Pen
I know I know… You’re afraid of the CLI, there’s not a good chrome extension and you can’t be bothered to boot up Firefox just for s3fox… Dude, the CLI is so simps:
There’s a great post about securing your new linux server (ubuntu) here: http://www.codelitt.com/blog/my-first-10-minutes-on-a-server-primer-for-securing-ubuntu/ I wanted to summarize here and explain some details. To start, create a password for your user (root) Make a new user for day to day logins (production) Require ssh logins instead of username/password Remove root login Only allow login from specific IP (if using a static IP)
If you lose your box tool: You can get it back by selecting it, as I’ve done in the photo above, then hitting “cmd + shft + 5” Boom.
Super simple edit the file: Uncomment the following: Then add an .htaccess file to your root: Restart MAMP and it should work like a charm!
So here’s the sitch yo: You have kaleidoscope as your diff tool. You go to make a patch: Then you realize that it’s opening kaleidoscope instead and not exporting your diff to a file. Well the problem is you’re using the wrong program. Do something like this: Now you’re using the right diff tool! Then you can apply the patch