Where communities thrive

  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
  • Aug 17 09:32
    User @bjorno43 unbanned @linkin-park
  • Jun 20 21:19
    @bjorno43 banned @shenerd140
  • Apr 25 17:13
    @mstellaluna banned @cmal
  • Jan 08 22:05
    @mstellaluna banned @dertiuss323
  • Nov 07 2018 04:42
    User @texas2010 unbanned @ows-ali
  • Nov 02 2018 16:25
    @texas2010 banned @ows-ali
  • Oct 12 2018 05:50
    @bjorno43 banned @NACH74
  • Oct 05 2018 23:02
    @mstellaluna banned @JomoPipi
  • Sep 16 2018 12:21
    @bjorno43 banned @yash-kedia
  • Sep 16 2018 12:16
    @bjorno43 banned @vnikifirov
  • Sep 05 2018 08:12
    User @bjorno43 unbanned @androuino
  • Sep 05 2018 07:38
    @bjorno43 banned @androuino
  • Aug 23 2018 16:57
    User @bjorno43 unbanned @rahuldkjain
  • Aug 23 2018 16:23
    @bjorno43 banned @rahuldkjain
  • Jul 29 2018 14:13
    User @bjorno43 unbanned @jkyereh
  • Jul 29 2018 01:00
    @bjorno43 banned @jkyereh
  • Jul 10 2018 22:09
    @bjorno43 banned @manafn
  • Jul 06 2018 15:20
    @texas2010 banned @imlegend19
  • Jul 03 2018 12:28
    @bjorno43 banned @vbvmatta
  • Jun 29 2018 13:54
    @bjorno43 banned @OGTechnoBoy
@drbe4t if you are designing for mobile first, or if thats what your intent is, it won't matter unless you use pictures
@drbe4t use %s instead of pixels and your site should look half decent without the queries
Danny Rubio
So this is for an assignment for school. I think that my professor just wants us to get the “concept down.”
so i think he wants us to leave the parts that I did code as response to be responsive.
So i figured it out .now my question is when i desgin for mobel first. I’d set up each individual media query?
hi guys. it seems like a big jump from the json/ajax tutorial to the random quote generator, mostly because of the twitter api
i've been doing some initial research and I see that there are a lot of bloat with Twitter's new 1.1 API
one of the solutions I've seen is from Rafase282 (github) and I don't know where he got the idea of using the tools he used e.g. forismatic
Juan Moraza
i think its pretty decent isnt it? http://codepen.io/morazajuan/pen/zBPAqJ
@johnsalcedonetwork you don't have to use any APIs on that one. i'm guessing he found forismatic by googling something like "random quote API", which has forismatic show on the first page.
Elbert Cortez
@johnsalcedonetwork there are many api services that provides quotes
one thing i recomend is to search for one that serves in HTTPS
otherwise u will deal with troubles xD
I found an amazing api for quotes if anyone is interested
it doesnt return the temperature
can someone fix it ?
Sorin Ruse
@NixonRichard just use data.main.temp to retrive the temperature
    $("#weather").html("City: " + data.name+data.main.temp);
    $("#weather").append("<p>Weather: " + data.weather[0].main + "</p>");
like this @sorinr ?
Sorin Ruse
@NixonRichard yes. if you want to put the temp inline with the city name. but i would add a span like <span class="myclass">data.main.temp<span> to be able to format the temp as i wish using myclass
    $("#weather").html("City: " + data.name+ <span class="myclass">data.main.temp<span> );
    $("#weather").append("<p>Weather: " + data.weather[0].main + "</p>");
i think im adding the span element the wrong way
Sorin Ruse
@NixonRichard just close the span </span> instead of <span> at the end
@NixonRichard and add some css to that class like: padding-left: 10px to move it to the right from the city name, ecc
    $("#weather").html("City: " + data.name+ <span class="myclass">data.main.temp</span> );
still wrong
it says unexpected token <
Sorin Ruse
@NixonRichard $("#weather").html("City: " + data.name+ "<span class='myclass'>"+data.main.temp+"</span>" );
$("#weather").html("City: " + data.name+
"<span class="myclass">"+data.main.temp+"</span>" );
i made this and it s also wrong
$("#weather").html("City: " + data.name+
"<span class="myclass">"+data.main.temp+"</span>" );
it worked
Sorin Ruse
@NixonRichard it is here: "myclass". i wrote 'myclass' because you have the span
is thes fahrenheit degree ?
Sorin Ruse
yes @NixonRichard
how to make it appear under my city name like the weather ?
anyway thx u first @sorinr
nixonrichard sends brownie points to @sorinr :sparkles: :thumbsup: :sparkles:
:cookie: 468 | @sorinr |http://www.freecodecamp.com/sorinr
Sorin Ruse
@NixonRichard make a new <div id="temp"></div> below your weather one and make $("#temp").html(data.main.temp);
<div id="weather">
  <div id="temp">
    <p class="center">Click the button to get your local weather.</p></div></div>

<div class="center-div">
make a new div id like this ?
Sorin Ruse
@NixonRichard <div id="temp" class="center-div">
$("#weather").html("City: " + data.name
$("#temp").html("Temperature:" +data.main.temp);
$("#weather").append("<p>Weather: " + data.weather[0].main + "</p>");