Omnimaga
General Discussion => Technology and Development => Web Programming and Design => Topic started by: flyingfisch on December 18, 2011, 05:22:27 pm
-
Post your favorite web design info sources!
I'll start:
http://www.justbenicestudio.com/studio/websymbols/
-
http://css-tricks.com (http://css-tricks.com)
^That. Contains a bunch more then CSS.
-
http://css-tricks.com (http://css-tricks.com)
^That. Contains a bunch more then CSS.
Oh yeah, I love that site! I would recommend signing up for their RSS feed. ;)
-
I don't do much web design, but I've found this useful multiple times for various things.
http://www.tedmontgomery.com/tutorial/ALTchrc-a.html
-
I don't do much web design, but I've found this useful multiple times for various things.
http://www.tedmontgomery.com/tutorial/ALTchrc-a.html
http://www.mclean.net.nz/ucf/ is my favorite place to find characters. For basic web design tutorials, I really like W3Schools (http://www.w3schools.com/).
-
IDK if i made this clear, but this page is not a character chart. It is a free webfont that I find very useful to use instead of SVG's. If you search css-tricks, you can find more info on this. ;)
Post your favorite web design info sources!
I'll start:
http://www.justbenicestudio.com/studio/websymbols/
-
Whoa, that's actually pretty cool O.O
-
Whoa, that's actually pretty cool O.O
Yeah i know. Erler dingbats are also good. And free. ;)
-
I just started using that WebSymbols font, and wow... That is one useful tool. Thanks for sharing!
-
you're welcome! It's amazing how helpful they can be.
Word of caution: use the ":before" pseudo-class instead of just putting symbols directly into the page. This will keep screen readers from reading it and also disallow highlighting for most browsers ;)
-
Hey, that's a nice trick, too.
-
I have to give credit for that trick to CSS-tricks (mentioned above)
-
with the little bit of web stuff i did i mostly learned from here:
http://www.w3schools.com/default.asp (http://www.w3schools.com/default.asp)
-
Yeah, w3schools is definitely the place for newbs to start and is great for reference.
Here's a cool css-tricks article: http://css-tricks.com/adobe-like-arrow-headers/
-
I really need to start following CSS-Tricks more. They've got some really cool stuff O.O
-
Check this out! (http://www.useragentman.com/blog/2012/01/03/cross-browser-html5-progress-bars-in-depth/)
Progress bars built into HTML5!!! Nice thing to know about ;)
-
Test out PHP online, without having to upload to server or use apache. Great for using if you are trying to do a tutorial and follow along at the same time. ;)
http://writecodeonline.com/php/
-
I just found that site a few days ago. It's been really, really useful since.
-
See how your site would look in IE, even if you don't have IE:
http://netrenderer.com/
(not that you'd want to or anything...) :P
-
SauceLabs (http://www.saucelabs.com/) is what I use for that. It's a full visualizer, which means you can interact with (and even debug!) browsers on Windows, Mac, and Linux going back to IE6.
-
Wow that's awesome! :D
-
The free version has a monthly time cap, but it's been incredibly useful nonetheless.
-
Somehow I seem to remember a similar service that was free....
-
See how your site would look in IE, even if you don't have IE:
http://netrenderer.com/
(not that you'd want to or anything...) :P
Who would even bother making it look good there?
-
People who care at all about a misinformed segment of their audience.
-
People who care at all about a misinformed segment of their audience.
And those who have not given their clients IE never, (ever, ever) (http://ourl.ca/12450/239231) yet.
-
Lol in IE6 Omnimaga doesn't look as bad as what Netham45 was describing a few years ago. Just the top is messed up.
Also some less tech-savy people will never want to switch from IE6-8 just because they prefer their interface and don't care about the risks.
-
Also some less tech-savy people will never want to switch from IE6-8 just because they prefer their interface and don't care about the risks.
I've found that sometimes they think switching to a better browser carries risks (since it's software they're installing from the web), and they don't want to do it for fear of trashing their computer somehow.
-
Also some less tech-savy people will never want to switch from IE6-8 just because they prefer their interface and don't care about the risks.
I've found that sometimes they think switching to a better browser carries risks (since it's software they're installing from the web), and they don't want to do it for fear of trashing their computer somehow.
Yeah, my uncle is still using an ancient version of flash because he thinks he is taking a risk by installing the new version...
-
Yeah that too. I remember one of the Omnimaga staff was stuck using IE because his dad thought Firefox was a virus. In my bro's case, he got a virus from Opera once and Firefox kept crashing so he switched back to IE. I myself got far more viruses in IE, though.
-
I myself use chromium, I don't know how i got there, lol
I got my host-mum to using firefox, she thought that it was slower and more complicated than IE
-
Yeah that too. I remember one of the Omnimaga staff was stuck using IE because his dad thought Firefox was a virus. In my bro's case, he got a virus from Opera once and Firefox kept crashing so he switched back to IE. I myself got far more viruses in IE, though.
adblock does wonders....
-
What does adblock have to do with viruses though? There's no adblock in Opera nor IE (they use their own pop up blockers and Opera has its own, very crappy and limited content blocker)
-
What does adblock have to do with viruses though? There's no adblock in Opera nor IE (they use their own pop up blockers and Opera has its own, very crappy and limited content blocker)
There is an adblock addon for both opera and IE, and adblock helps get rid of advertisements that non-tech-savvy people are wont to click on...which may get them a virus, spyware, scam, spam, etc.
-
Really? I didn't know about that. A while ago I went on Opera website and couldn't find any extensions/widget section other than weird widgets you downloaded and it added plenty of gimmick on your Windows desktop, and I didn't even know IE had extension/add-on support at all. However until now I didn't know in English extensions were called add-ons instead of extensions, so I guess I'll have to check more carefully.
I was really sure, however, that Adblock was a Firefox-only thing. In Opera the default Block Content feature just blocks the entire video box rather than just ads.
I'm betting that if kids installed that stuff on their parent's computers and those parents are scared of Internets softwares, then they would be scared and think that adblock is a scam and a virus, though <_<
-
Adblock for opera (https://addons.opera.com/en/extensions/details/opera-adblock/)
Adblock for IE (http://simple-adblock.com/)
I was wrong, the ie version isnt technically and addon....but it works.
anyway, i guess most people's situation is different than mine because it was my dad who introduced me to adblock, and my mom pretty much trusts me as far as computers go, as do all my aunts and uncles.
-
I think my mom doesn't even know what's going on on my computers, even though she knows her way around a computer.
-
Yeah that too. I remember one of the Omnimaga staff was stuck using IE because his dad thought Firefox was a virus. In my bro's case, he got a virus from Opera once and Firefox kept crashing so he switched back to IE. I myself got far more viruses in IE, though.
adblock does wonders....
I use ghostery, it blocks out tracking sites (like google adsence and facebook and many many others) and i don't even get youtube ads anymore XD
-
See how your site would look in IE, even if you don't have IE:
http://netrenderer.com/
(not that you'd want to or anything...) :P
Who would even bother making it look good there?
A large portion of people still use IE, and some computers users are unable to change their software (limited user permisions). Although looks are important, it's even more important that it actually works in IE. In web dev. it is very important that your website functions in all current browsers.
-
technically tricks fit in here, too :P
So yeah, just did this thing:
<?php
class Foo {
protected $hello = 'there';
public function __construct(){
$this->hello = 'world';
}
public function upgrade(){
$reflect = new ReflectionClass($this);
$props = array();
foreach($reflect->getProperties() as $p){
$name = $p->name;
$props[$name] = &$this->$name;
}
return new Bar($props);
}
}
class Bar extends Foo {
public function __construct($props){
foreach($props as $var => $val){
$this->$var = $val;
}
}
public function test(){
echo $this->hello;
}
}
$obj = new Foo();
var_dump($obj);
$obj = $obj->upgrade();
var_dump($obj);
$obj->test();
?>
Allows you to "upgrade" a class to another one and copy all the public/protected vars over to the new one.
-
Using ReflectionClass can be fun :)
I use it for argument pass-off in my sql class.
<?php
/**
* SQL class. Used for handling SQL connections
*
* @module sql
* @class SQL
* @constructor
*/
class SQL {
/**
* This is the mysqli connection beneath everything
*
* @property sql
* @type {mysqli}
* @private
* @required
*/
private $sql;
public function __construct($server,$user,$pass,$db){
$this->sql = new mysqli($server,$user,$pass,$db) or die('Unable to connect to mysql');
}
public function __invoke(){
return $this->sql;
}
public function __get($name){
switch($name){
case 'error':
return $this->sql->error;
break;
}
}
/**
* Returns a Query object based on inputs
*
* @method query
* @param {String} sql The sql expression to run
* @param {String=null} [types] A string containing all the types of arguments being passed
* @param {Mixed} [bindings]* The bindings to use in the sql statement
* @return {Query} Returns the query object
*/
public function query(){
$reflect = new ReflectionClass('Query');
$args = array_merge(array($this),func_get_args());
return $reflect->newInstanceArgs($args);
}
public function escape($s){
return $this->sql->escape_string($s);
}
public function charset($charset){
return $this->sql->set_charset($charset);
}
}
/**
* Query class. Returned by SQL::query()
*
* @class Query
* @constructor
*/
class Query {
private $query;
private $sql;
public function __construct($sql,$source,$types=null){
$args = func_get_args();
$args = array_splice($args,2);
$this->sql = $sql();
$this->query = $sql()->prepare($source);
if(!is_null($types)){
call_user_func_array(array($this->query, 'bind_param'),make_referenced($args)) or die($sql()->error);
}
}
public function __invoke(){
return $this->query;
}
public function execute(){
if($this->query){
$r = $this->query->execute();
$this->sql->commit();
return $r;
}else{
return false;
}
}
public function __get($name){
switch($name){
/**
* Returns the mysqli::results object for the
* query
*
* @property results
* @type {mysqli::results}
* @public
*/
case 'results':
if($this->query){
$this->execute();
$result = $this->query->get_result();
$this->query->close();
return $result;
}else{
return false;
}
break;
/**
* Returns an associative array of the query resulsts
*
* @property assoc_results
* @type {Array}
* @public
*/
/**
* Returns an associative array of the query resulsts
*
* @property resulsts_assoc
* @type {Array}
* @public
*/
case 'assoc_results':case 'results_assoc':
if($this->query){
$a = array();
$r = $this->results;
while($row = $r->fetch_assoc()){
array_push($a,$row);
}
return $a;
}else{
return false;
}
break;
/**
* Returns a numbered array of the query results
*
* @property num_results
* @type {Array}
* @public
*/
/**
* Returns a numbered array of the query results
*
* @property resulsts_num
* @type {Array}
* @public
*/
case 'num_results':case 'results_num':
if($this->query){
$a = array();
$r = $this->results;
while($row = $r->fetch_num()){
array_push($a,$row);
}
return $a;
}else{
return false;
}
break;
case 'assoc_result':case 'result_assoc':
if($this->query){
$r = $this->results;
return $r?$r->fetch_assoc():false;
}else{
return false;
}
break;
case 'num_result':case 'result_num':
if($this->query){
$r = $this->results;
return $r?$r->fetch_num():false;
}else{
return false;
}
break;
case 'insert_id':
return $this->sql->insert_id;
break;
}
}
}
function make_referenced(&$arr){
$refs = array();
foreach($arr as $key => $value){
$refs[$key] = &$arr[$key];
}
return $refs;
}
?>
-
I just stumbled upon this and it is really sweet: https://xerographer.github.io/multicoloure/
-
While we're on the topic of fonts...
I stumbled upon Fira Code (https://github.com/tonsky/FiraCode) recently. It blew my mind.
Basically, it uses ligatures (a feature whereby two adjacent characters may be displayed differently from the two characters by themselves) to render some common multiple-character programming operators in really neat ways. It's especially useful for Haskell, but it works great in other languages too, for example by combining things like != and >= into ≠ and ≥.
A picture is worth a thousand words. (https://raw.githubusercontent.com/tonsky/FiraCode/master/showcases/all_ligatures.png)
-
Wow, that's a pretty neat idea! I can easily imagine that it takes quite some time to get used to it, though.
Also, is it so that when you backspace both characters dis-appear then?
-
Nope, the file itself still has the two characters separately—it just shows up as a combined character, taking up twice the space. So pressing Backspace on ≠ gives you !.
It doesn't really take any getting used to, since the characters are all still there, just displayed slightly differently. If anything it's made my code more intuitive because I can see where one operator ends and another begins :D
-
Nope, the file itself still has the two characters separately—it just shows up as a combined character, taking up twice the space. So pressing Backspace on ≠ gives you !.
It doesn't really take any getting used to, since the characters are all still there, just displayed slightly differently. If anything it's made my code more intuitive because I can see where one operator ends and another begins :D
That's exactly what i mean: Stuff gets displayed differently. So it would take at first longer for me to realise what a certain piece of code means, as i'm soooooo used to != and === and stuff like that...
-
I really like this ite since it gives great examples for advanced stuff like parallax effects and fance animations :love:
http://callmenick.com/page/archive
-
Fira Code seems awesome, if only my editors supported it properly :(