These are chat archives for FreeCodeCamp/HelpFrontEnd

30th
Jul 2016
Jeff Dera
@jeff-dera
Jul 30 2016 00:12
I'm having the same issue as @soori8
Nevermind, I appended a random number after the callback="
before the function
seems to work now
soroush behmardi
@soori8
Jul 30 2016 00:37
@Evercleared yeah its work, thaks
Liman Abba
@limanCode
Jul 30 2016 00:40
Hi guys, please help me look at this, the navbar is overflowing to the jumbotron, what could be wrong here? http://codepen.io/limanCode/pen/XKBNgg
any body here?
Gary Siu
@GarySiu
Jul 30 2016 00:46
@limanCode I don’t get the same problem as you?
Or you fixed it already
Ken Haduch
@khaduch
Jul 30 2016 00:58

@limanCode - if you are using navbar-fixed-top (or were using it) you have to add some margin-top to the body element so that the page content shifts down. I added that class (you might have had it and removed it?, navbar-fixed-top) and then added this to the CSS:

body {
  margin-top: 120px;
}

If you make your navbar shorter, then you can use a smaller margin-top. That nav class padding that you are adding is making the navbar extra tall.

can someone help me with javascript part
what did i do wrong?
Liman Abba
@limanCode
Jul 30 2016 01:14
@khaduch Thanks. I understand.
CamperBot
@camperbot
Jul 30 2016 01:14
limancode sends brownie points to @khaduch :sparkles: :thumbsup: :sparkles:
:star2: 1495 | @khaduch |http://www.freecodecamp.com/khaduch
Liman Abba
@limanCode
Jul 30 2016 01:15
@GarySiu see the solution above.
John Doe
@codingisfun11
Jul 30 2016 01:18
function myLocalScope() {
  'use strict';


  console.log(myVar);
}
myLocalScope();

// Run and check the console
// myVar is not defined outside of myLocalScope


// Now remove the console log line to pass the test
i removed the console long line...now what to do?
I pressed run but the program wont work.
Never mind I figured it out.
Jiannine Torres
@jianninetorres
Jul 30 2016 01:23
Hey guys, I'm working on the weather app. I can't get the icon to show. Is anyone willing to review?
Gary Siu
@GarySiu
Jul 30 2016 01:38
Sure
Jiannine Torres
@jianninetorres
Jul 30 2016 01:42
CamperBot
@camperbot
Jul 30 2016 01:42
jianninetorres sends brownie points to @garysiu :sparkles: :thumbsup: :sparkles:
:cookie: 165 | @garysiu |http://www.freecodecamp.com/garysiu
Jiannine Torres
@jianninetorres
Jul 30 2016 01:42
it's working on codepen, but not in atom
Gary Siu
@GarySiu
Jul 30 2016 01:44
Atom has a previewer?
Jiannine Torres
@jianninetorres
Jul 30 2016 01:44
I mean, when I open the index file in chrome
Gary Siu
@GarySiu
Jul 30 2016 01:44
Any errors in the console?
Jiannine Torres
@jianninetorres
Jul 30 2016 01:45
yes, it keeps saying FILE NOT FOUND
Gary Siu
@GarySiu
Jul 30 2016 01:45
Well did you change the relative links like the ones to Bootstrap?
Jiannine Torres
@jianninetorres
Jul 30 2016 01:45
it works in codepen though
Gary Siu
@GarySiu
Jul 30 2016 01:46
Codepen has the files on their server but you probably don’t have them on your machine
Are you just visiting the file directly? (file://) or are you serving it locally from a webserver?
Jiannine Torres
@jianninetorres
Jul 30 2016 01:47
in the console it returns GET file://cdn.apixu.com/weather/64x64/day/116.png net::ERR_FILE_NOT_FOUND
how do I access it from the server?
Gary Siu
@GarySiu
Jul 30 2016 01:50
Change the url to start with http:// or just //
But if you do // you need to serve the file from a webserver
Jiannine Torres
@jianninetorres
Jul 30 2016 01:51
it's coming from an API
John Doe
@codingisfun11
Jul 30 2016 01:51
// Example
var changed = 0;

function change(num) {
  return (num + 5) / 3;
}

changed = change(10);

// Setup
var processed = 0;

function processArg(num) {
  return (num + 3) / 5;
}

// Only change code below this line
  var processed = 2;

  function processArg(7) {
    return (num + 3) / 5;
    }
Assignment with a Returned Value
Gary Siu
@GarySiu
Jul 30 2016 01:51
‘http://' + urlFromApi
John Doe
@codingisfun11
Jul 30 2016 01:52
need help on it.
Gary Siu
@GarySiu
Jul 30 2016 01:53
@codingisfun11 Ok, do you understand what they are doing in the example?
dimitrije12
@dimitrije12
Jul 30 2016 01:53
Can someone help me with weather project?
Jiannine Torres
@jianninetorres
Jul 30 2016 01:53
ok I'll try it
Gary Siu
@GarySiu
Jul 30 2016 01:53
Hi @dimitrije12 what’s your problem?
dimitrije12
@dimitrije12
Jul 30 2016 01:54
http://codepen.io/dimitrije/pen/AXgrdm
I am getting wrong location
It gives me the location of Connaught Place, IN, but i am not from there
John Doe
@codingisfun11
Jul 30 2016 01:57
@GarySiu I sent you a private message check it out!
Gary Siu
@GarySiu
Jul 30 2016 02:00
@dimitrije12 I think your weather api call is happening before your location lookup. Try and check that.
Jiannine Torres
@jianninetorres
Jul 30 2016 02:02
it worked locally!! thank you @GarySiu
CamperBot
@camperbot
Jul 30 2016 02:02
jianninetorres sends brownie points to @garysiu :sparkles: :thumbsup: :sparkles:
:warning: jianninetorres already gave garysiu points
dimitrije12
@dimitrije12
Jul 30 2016 02:14
@GarySiu thanks, got it
CamperBot
@camperbot
Jul 30 2016 02:14
dimitrije12 sends brownie points to @garysiu :sparkles: :thumbsup: :sparkles:
:cookie: 166 | @garysiu |http://www.freecodecamp.com/garysiu
Gary Siu
@GarySiu
Jul 30 2016 02:14
@dimitrije12 :+1:
Alique Williams
@AliqueWilliams
Jul 30 2016 02:31
about @aliquewilliams
CamperBot
@camperbot
Jul 30 2016 02:31
:warning: no user found for aliquewilliams
Alique Williams
@AliqueWilliams
Jul 30 2016 02:31
about about @aliquewilliams
CamperBot
@camperbot
Jul 30 2016 02:31
:warning: no user found for aliquewilliams
Islam Ibakaev
@dagman
Jul 30 2016 02:49
hey guys can you see it? http://codepen.io/dagman/pen/yJqXdR
Ken Haduch
@khaduch
Jul 30 2016 03:00
Hello @dagman - no, just a grey screen. Some errors in the console?
Yaroslav Newman
@YaroNew
Jul 30 2016 03:17
Hi guys!
help me pls. with assingment
CamperBot
@camperbot
Jul 30 2016 03:17
no wiki entry for: me pls with assingment
Ken Haduch
@khaduch
Jul 30 2016 03:22
@YaroNew - I have a few minutes, something that I can try to help with?
@khaduch

// Setup
function phoneticLookup(val) {
  var result = "";

  // Only change code below this line
  var val = {
  1: "Adams", 
   2: "Boston",
    3: "Chicago",
    4: "Denver",
    5: "Easy",
    6: "Frank",


  }

  // Only change code above this line
  return result;
}

// Change this value to test
phoneticLookup("charlie");
Islam Ibakaev
@dagman
Jul 30 2016 03:29
Ken Haduch
@khaduch
Jul 30 2016 03:30

@YaroNew @YaroNew - they are passing values into the function, so the test data is something that you can use as a guide. If they are passing the word "charlie", as they are in this case, you have to use the value passed into function, within the function it will have the variable name val. So there should be a key in the object that corresponds to the name being passed in. For "charlie", you should return a value "Chicago", so a key/value pair in the object should be "charlie" : "Chicago". Similarly for all of the possible input values.

Now, in my copy of the exercise, I have this in the editor window:

  // Only change code below this line
  var lookup = {

It appears that you have changed that name - it might be important to keep it as "lookup", and you certainly don't want to have the name val, because that is the function argument name.

and the final step, after you probably set up the object that is the lookup table, you want to address the object with the val and return the value as the result.

See if that gets you started?

@dagman - I'm now seeing a purple box centered in the window, with a digit 0, and a plus and minus control button that increments and decrements the count.
@dagman - I don't think that there is a way to make it count? At least not automatically? Other than clicking the + and -
Yaroslav Newman
@YaroNew
Jul 30 2016 03:36
@khaduch
// Setup
function phoneticLookup(val) {
  var result = "";

  // Only change code below this line
  var lookup = {
    "alpha": "Adams", 
    "bravo": "Boston",
    "charlie": "Chicago",
    "delta": "Denver",
    "echo": "Easy",
    "foxtrot": "Frank",

  };



  // Only change code above this line
  return result;
}

// Change this value to test
phoneticLookup("charlie");
@khaduch i've got this. but not shure WHAT result assignment wants from me.
Ken Haduch
@khaduch
Jul 30 2016 03:38
@YaroNew - okay - that is better. Now the next thing to solve is how to set the result. If you are passed the value "delta" (as val, the function argument), how could you use the variable val and the object lookup to set the variable result to "Denver"? It involves an object lookup using a variable, and remember (or review) "dot notation" and "bracket notation" for accessing an object with a variable that contains a potential key value.
@YaroNew - you do not need the last comma after "Frank" in your object initialization. (I forget if it gives you an error? Some languages allow that...)
Yaroslav Newman
@YaroNew
Jul 30 2016 03:43
@khaduch no . coma is not an issue.
@khaduch

// Setup
function phoneticLookup(val) {
  var result = "";

  // Only change code below this line
  var lookup = {
    "alpha" : "Adams" , 
    "bravo" : "Boston" ,
    "charlie" : "Chicago" ,
    "delta" : "Denver",
    "echo" : "Easy" ,
    "foxtrot" : "Frank" 

  };

  var value = "delta";
  lookup[Denver];

  // Only change code above this line
  return result;
}

// Change this value to test
phoneticLookup("charlie");
Dodi Yulian
@deododeidi
Jul 30 2016 03:44
where can i make thumbnails for my portfolio page?
Ken Haduch
@khaduch
Jul 30 2016 03:47
@YaroNew - almost there. I should have said: if the function call that was made was phoneticLookup("delta"); what do you have to do inside of the phoneticLookup function to use the value that is given to the function argument, using the variable name val within the function, to perform a lookup in the object name lookup. Your lookup[Denver] is not correct, but using bracket notation is correct. You just have to use something like result = lookup[ ??? ]; (you fill in the ???)
Yaroslav Newman
@YaroNew
Jul 30 2016 03:52
@khaduch

// Setup
function phoneticLookup(val) {
  var result = "";

  // Only change code below this line
  var lookup = {
    "alpha" : "Adams" , 
    "bravo" : "Boston" ,
    "charlie" : "Chicago" ,
    "delta" : "Denver",
    "echo" : "Easy" ,
    "foxtrot" : "Frank" 

  };


  var value = "delta";
  result=lookup[Denver];

  // Only change code above this line
  return result;
}

// Change this value to test
phoneticLookup("charlie");
Ken Haduch
@khaduch
Jul 30 2016 03:54
@YaroNew - in other words, nothing hardcoded in the lookup - you should not use any literal string value anywhere in the actual lookup step within the function - it should be all based on variables - the name lookup, the name of the function argument variable val, and the variable result should get the final answer to return. the names "alpha", "bravo", "Adams", "Boston", etc. should only exist in the object definition. None of those names should actually be in the lookup code for result = lookup[ ??? ];
Yaroslav Newman
@YaroNew
Jul 30 2016 03:55
@khaduch

// Setup
function phoneticLookup(val) {
  var result = "";

  // Only change code below this line
  var lookup = {
    "alpha" : "Adams" , 
    "bravo" : "Boston" ,
    "charlie" : "Chicago" ,
    "delta" : "Denver",
    "echo" : "Easy" ,
    "foxtrot" : "Frank" 

  };


  var value = "delta";
  result=lookup[val];

  // Only change code above this line
  return result;
}

// Change this value to test
phoneticLookup("charlie");
WORKS!
^)
Thanks.
Ken Haduch
@khaduch
Jul 30 2016 03:56
@YaroNew - do you understand exactly why you needed to do what you did? And what did you finally do?
Yaroslav Newman
@YaroNew
Jul 30 2016 03:57
@khaduch Lets review it once again.
  1. I changed switch statements to lookup table
  1. assined val value with a result for the lookup table
Ken Haduch
@khaduch
Jul 30 2016 04:01
@YaroNew - yes, and the lookup table has to be useful to provide the results that the tests are looking for, or in other cases, to fit a specification of what the lookup table should contain. In this case, looking at the test conditions and expected results was a guide, and that is something that is useful all the time when you're trying to sort out the solution to a problem.
Yaroslav Newman
@YaroNew
Jul 30 2016 04:02
@khaduch
alpha[2]; // "Y"
alpha[24]; // "C"

var value = 2;
alpha[value]; // "Y"
that part confused me but assignment don't need it. it works like so;
Ken Haduch
@khaduch
Jul 30 2016 04:03
@YaroNew - yes, the only code that you really needed to provide to do the lookup was result = lookup[ val ]; after, that is, the coding of the lookup table.
Yaroslav Newman
@YaroNew
Jul 30 2016 04:03
// Setup
function phoneticLookup(val) {
  var result = "";

  // Only change code below this line
  var lookup = {
    "alpha" : "Adams" , 
    "bravo" : "Boston" ,
    "charlie" : "Chicago" ,
    "delta" : "Denver",
    "echo" : "Easy" ,
    "foxtrot" : "Frank" 

  };



  result=lookup[val];

  // Only change code above this line
  return result;
}

// Change this value to test
phoneticLookup("charlie");
@khaduch thx. once again. have a good night!
CamperBot
@camperbot
Jul 30 2016 04:04
yaronew sends brownie points to @khaduch :sparkles: :thumbsup: :sparkles:
:star2: 1496 | @khaduch |http://www.freecodecamp.com/khaduch
Ken Haduch
@khaduch
Jul 30 2016 04:07

@YaroNew - I can see where that would be a bit confusing. Knowing how to convert the switch statement was something that should have been a little clearer. For example - in the switch, one of the cases

    case "alpha": 
      result = "Adams";
      break;

Meant that the value in the val was going to be "alpha", and for this switch / case, it would return "Adams". So to perform that same translation within the object, the "lookup" object, you would need "alpha" : "Adams" as one of the key-value pairs. The example that they gave you was using a numeric input to select letters in the alphabet, actually in reverse order... so there were a lot of fine points to learn from that little exercise.

@YaroNew - you're welcome... good luck with the work!
Islam Ibakaev
@dagman
Jul 30 2016 04:27
@khaduch this is simple counter i have built using redux :smile:
John Doe
@codingisfun11
Jul 30 2016 04:56

// Example
var changed = 0;

function change(num) {
  return (num + 5) / 3;
}

changed = change(10);

// Setup
var processed = 0;

function processArg(num) {
  return (num + 3) / 5;
}

// Only change code below this line

processArg = Arg(2,7); 
processed = 2;
Assignment with a Returned Value
how can I improve my code?
kyadondo Timothy
@chadwalt
Jul 30 2016 07:07
@codingisfun11 just asking. what is the code meant to do?
JiaLe Guo
@gabygoole
Jul 30 2016 07:22
anybody can help me with random quote machine?
Sorin Ruse
@sorinr
Jul 30 2016 07:23
@gabygoole whats the problem?
kyadondo Timothy
@chadwalt
Jul 30 2016 07:29
@gabygoole please show yo code
JiaLe Guo
@gabygoole
Jul 30 2016 07:31
I have no idea about the task , I mean totally
Sorin Ruse
@sorinr
Jul 30 2016 07:32
@gabygoole google and find a quote generator api. see how to call that api in your js then think on how would you like to present the returned response on your page
kyadondo Timothy
@chadwalt
Jul 30 2016 07:32
@gabygoole please explain about the task
Samraj Moorjani
@smoorjani
Jul 30 2016 07:34
@gabygoole you could always create a random number generator and then use a switch case with the variable (fairly simple in case you are a beginner)
Sorin Ruse
@sorinr
Jul 30 2016 07:38
@smoorjani somehow he has to start learning how to use an api. i think this challenge is the easiest way
JiaLe Guo
@gabygoole
Jul 30 2016 07:39
@sorinr idea is clear Let me see again
Muhammad Hasham
@MohammadHasham
Jul 30 2016 07:41
can anyone help me with nested functions in js
Sorin Ruse
@sorinr
Jul 30 2016 07:42
@MohammadHasham hi. whats the problem?
Muhammad Hasham
@MohammadHasham
Jul 30 2016 07:42
This message was deleted
@sorinr
okay sorry i figgured that out :smile:
@sorinr actually can u help me regarding array.reduce()
Muhammad Hasham
@MohammadHasham
Jul 30 2016 07:45
i can't get the documentation its way too complicated
can you tell me in a simpler way
Lev
@levgubin
Jul 30 2016 07:51
Hi! I'm doing twitch tv zipline. When I call channels array elements from inside getJson function I always get the last element. Does anybody know how to solve this?
Muhammad Hasham
@MohammadHasham
Jul 30 2016 08:05
@levgubin use forEach()
arrayname.forEach() u can check the documentation
actually you have to iterate through the array
buiphuking
@buiphuking
Jul 30 2016 08:22

hi guys,
i have a question

function flashMessage(msg, times){
      $('.count').text(msg);
      var lf = function(){
        $('.count').addClass('led-off');
        gameStatus.toHndlFl = setTimeout(function(){
          $('.count').removeClass('led-off');
        }, 250);
      };
      var cnt = 0;
      lf();
      gameStatus.flHndl = setTimeout(function(){
        lf();
        cnt++;
        if(cnt === times) clearInterval(gameStatus.flHndl);
      }, 500)
    };

if i set up times = 1, will gameStatus.flHndl run ?

Haib Zhang
@nperhb
Jul 30 2016 08:52
@buiphuking just run one time
Muhammad Hasham
@MohammadHasham
Jul 30 2016 09:05
This message was deleted
function sumAll(arr) {
  var result;

  var maxValue = Math.max.apply(null,arr);
  var minValue = Math.min.apply(null,arr);

  for (var i=minValue;i<maxValue;i++)
    {
      result += i;


    }
  return result;


}

sumAll([1, 4]);
why is this returning a null
fly_fox
@hbc22
Jul 30 2016 09:34
Build a Tribute Page???\
Ivan Temchur
@ttemcha
Jul 30 2016 09:38
@hbc22 build a tribute page
Mikail Bayram
@mikail1998
Jul 30 2016 09:40
@hbc22 what about it, could you be more specific
Pedro Abel Díaz Sánchez
@coderHook
Jul 30 2016 09:42

Can someone give a hand with REACT?
I am trying to add a comment from a form. Here is my codePen:

http://codepen.io/DiazPedroAbel/pen/oLrxpr?editors=0010

Adithya Reddy
@tallpants
Jul 30 2016 09:49
Hey, I'm trying to add a tweet button to my quote generator, can somebody point me in the right direction?
Mikail Bayram
@mikail1998
Jul 30 2016 09:50
@adithyakreddy http://getbootstrap.com/components/ you have many kind of buttons here
Adithya Reddy
@tallpants
Jul 30 2016 09:50
@mikail1998 I got the button already, I meant on Twitter's side
How do I get the button to load twitter with the quote text loaded into the tweet box?
fly_fox
@hbc22
Jul 30 2016 09:51
i do not known what next to do
Mikail Bayram
@mikail1998
Jul 30 2016 09:52
@adithyakreddy ('#tweetme').attr('href', 'https://twitter.com/intent/tweet?text=' + data.quoteText);
tweetme button name
data.quoteText is the api data i got
Adithya Reddy
@tallpants
Jul 30 2016 09:53
Oh okay thanks @mikail1998, can I know where you found this out?
CamperBot
@camperbot
Jul 30 2016 09:53
adithyakreddy sends brownie points to @mikail1998 :sparkles: :thumbsup: :sparkles:
:cookie: 232 | @mikail1998 |http://www.freecodecamp.com/mikail1998
Mikail Bayram
@mikail1998
Jul 30 2016 09:53
@adithyakreddy i just sent you my part of the code
Adithya Reddy
@tallpants
Jul 30 2016 09:54
I meant where did you find out how to do it :P
Mikail Bayram
@mikail1998
Jul 30 2016 09:54
but when i was doing it i googled a bit and sorted the problem out
spalqui
@spalqui
Jul 30 2016 10:37
hello does could someone have a look at my twitch API i don't know why it is not working
Mikail Bayram
@mikail1998
Jul 30 2016 10:38
sure could you send the link
it is not doing the for loops properly
Mikail Bayram
@mikail1998
Jul 30 2016 10:39
you want to add all streamers with the for loop right_
spalqui
@spalqui
Jul 30 2016 10:40
indeed
and then go through the array and make a request for each individual
Mikail Bayram
@mikail1998
Jul 30 2016 10:41

for (var i = 0; i < users.length; i++) {
  $.getJSON("https://api.twitch.tv/kraken/streams/" + users[i].toLowerCase() + "?callback=?", function(json) {
    if (json.stream === null) {
        $.getJSON(json._links.channel, function(json2) {
          console.log(json2);
          var name = "<div class='offline'><a href="+json2.url+" target='_blank'><img src="+json2.logo+"></a><p id='s'>"+json2.display_name+"</p> <p id='m'>offline</p></div>";
          $("#users").append(name);

        });
  }
   else{
      $.getJSON(json._links.channel, function(json2) {
     var name2="<div class='online'><a href="+json2.url+" target='_blank'><img src="+json2.logo+"></a><p id='s'>"+json2.display_name+"</p> <p id='m'>"+json2.game+"</p></div>"
do you see what is done here for each individual a new div is formed
depending if he is offline or online
spalqui
@spalqui
Jul 30 2016 10:43
yeaah
Mikail Bayram
@mikail1998
Jul 30 2016 10:43
i hope i could help, if you have some questions just ask
spalqui
@spalqui
Jul 30 2016 10:43
ok thank you
@mikail1998 thanks
CamperBot
@camperbot
Jul 30 2016 10:43
spalqui sends brownie points to @mikail1998 :sparkles: :thumbsup: :sparkles:
:cookie: 234 | @mikail1998 |http://www.freecodecamp.com/mikail1998
Mikail Bayram
@mikail1998
Jul 30 2016 10:44
:+1:
spalqui
@spalqui
Jul 30 2016 12:08
Can someone have a look at my code
I am having an issue retrieving the streams that are on and offline
labeebahmad414
@labeebahmad414
Jul 30 2016 12:24
Here is this cool effect called Starry Night by Chris Coyier. My question do we even need it? I mean user would not even notice if they don't resize their window.
Muahmmad Gad
@MuhammadGad
Jul 30 2016 12:30
guys do anyone of you know how to set browser and text zoom to 100% in css?
Greg Duncan
@GregatGit
Jul 30 2016 12:39
@spalqui You only really need the https://api.twitch.tv/kraken/streams/ if it is offline then it api gives you the the channels api - if its deleteted or wrong it just gives an error message
Philip Eckert
@pae4557
Jul 30 2016 12:51
@ndburrus man you are unstoppable
Norvin Burrus
@ndburrus
Jul 30 2016 12:52
@pae4557 :) i have a lot of learning/improving/building to do... :+1:
Philip Eckert
@pae4557
Jul 30 2016 12:53
@ndburrus are you like fcc official? You literally walked me through some problem a month ago that took like an hour to explain step by step. Thanks for all the work and help you have been putting in
CamperBot
@camperbot
Jul 30 2016 12:53
pae4557 sends brownie points to @ndburrus :sparkles: :thumbsup: :sparkles:
:star2: 1199 | @ndburrus |http://www.freecodecamp.com/ndburrus
Norvin Burrus
@ndburrus
Jul 30 2016 12:55
@pae4557 you're very welcome! glad the assistance was helpful... :smile:
i am a fcc camper/learner... working through the curriculum...
i have/hold no position/title with fcc.... time for some coffee - short break...
Sorin Ruse
@sorinr
Jul 30 2016 12:59
This message was deleted
Norvin Burrus
@ndburrus
Jul 30 2016 13:20
@pae4557 you may enjoy these, if you have room in your toolkit :sparkles:
Subroto
@Shub1427
Jul 30 2016 13:45

How can i use percent values in tranform: matrix3d();

transform: matrix3d(1,0,0,0,0,1,0,0,0,0,1,0,0,-50%,0,1);

Is not working

spalqui
@spalqui
Jul 30 2016 14:03
https://codepen.io/Spalqui/pen/KrZEry?editors=1011 I am having troubles accessing the preview and channel elements of the JSON object returned by the Twitch API
Greg Duncan
@GregatGit
Jul 30 2016 14:05
@spalqui https://api.twitch.tv/kraken/streams/freecodecamp that's all you need for each of the channels
var url = https://api.twitch.tv/kraken/streams/freecodecamp;
$.getJSON(url, function(data){
   console.log(data)
});
Olsvik
@Olsvik
Jul 30 2016 14:23
Can anyone explain why it adds a gap between the Divs when I add border-top-style: none?
https://codepen.io/Olsvik/pen/WxyqYz
It looked fine before and I'm not sure what I changed to have it be like that
Sorin Ruse
@sorinr
Jul 30 2016 14:44
@Olsvik try making: .about,.portfolio{ border-bottom-width: 0px;}
mixu1308
@mixu1308
Jul 30 2016 15:12
Can someone tell me why page does look the same on codepen when I put it on github pages?
Codepen:http://codepen.io/mixu1308/full/MyGvVL/
Github Pages:https://mixu1308.github.io/
Github:https://github.com/mixu1308/mixu1308.github.io
Kevin
@KevinBruland
Jul 30 2016 15:21
@mixu1308 what looks different?
Sam Griffen
@ssgriffen
Jul 30 2016 15:35
When you use google dev tools to view mobile previews of your page do you set the zoom to 100% on each device?
The default switches to lilke 80% for ip6
mixu1308
@mixu1308
Jul 30 2016 15:38
@Benalron there is no background color and the image of the social media buttons aren't centered
UtkarshShukla7
@UtkarshShukla7
Jul 30 2016 15:39
@mixu1308 because you don't have a body tag in your code . It is implicitly wrapped under body tag in codepen but you have to define it for hosting elsewhere
mixu1308
@mixu1308
Jul 30 2016 15:43
@UtkarshShukla7 adding a body tag didn't fix anything
vínαч puppαl
@vinaypuppal
Jul 30 2016 15:46
@mixu1308 place your main.css file after bootstrap.css in your head tag
mixu1308
@mixu1308
Jul 30 2016 15:47
@vinaypuppal so that fixed the background but the icons are still not centerd
vínαч puppαl
@vinaypuppal
Jul 30 2016 15:48
@mixu1308 okay let me check wait
mixu1308
@mixu1308
Jul 30 2016 15:54
@vinaypuppal so do you know what's wrong?
vínαч puppαl
@vinaypuppal
Jul 30 2016 15:55
@mixu1308 not able to find why line-height is not working
mixu1308
@mixu1308
Jul 30 2016 15:56
@vinaypuppal last question how can I move the "Contact Me" h2 without moving the hr ?
each time I do it it moves the hr
vínαч puppαl
@vinaypuppal
Jul 30 2016 15:57
@mixu1308 how u want to move??
mixu1308
@mixu1308
Jul 30 2016 15:58
@vinaypuppal slightly to the right
vínαч puppαl
@vinaypuppal
Jul 30 2016 15:58
@mixu1308 you tried with margin??
mixu1308
@mixu1308
Jul 30 2016 15:59
@vinaypuppal how do you use margin again?
vínαч puppαl
@vinaypuppal
Jul 30 2016 16:00
@mixu1308 your contact hr and.row div is inside h2 once check that
Marko Radosavljevic
@planetRock
Jul 30 2016 16:22
hey people
i must make a tribute page
spalqui
@spalqui
Jul 30 2016 16:22
Hello guys wanna give me some feedback on my latest project? :)
Kevin
@KevinBruland
Jul 30 2016 16:34
@spalqui I am getting a little overflow from some of the links... but other than that looks good. I like the style
Muhammad Hasham
@MohammadHasham
Jul 30 2016 16:51
really stuck at "Diff two arrays" can anyone help me out!
Norvin Burrus
@ndburrus
Jul 30 2016 16:55
@mixu1308 these may be helpful: :sparkles:
r2d2
@UsamaHameed
Jul 30 2016 17:05
Material Design Lite vs Angular Material Design?
Taras Yaremkiv
@Y-Taras
Jul 30 2016 17:47
@UsamaHameed Angular Material Design - is better then lite as far as I understood. Material lite is too simple

Hello everyone, please take a look at my calculator and give me a hint what is wrong in css with "Digital-7" font.
I've uploaded files on the github and put a link of the .ttf - file in CSS code as below - but It's not working

@font-face {
    font-family: 'digital-7';
    src: url("https://github.com/Y-Taras/FreeCodeCamp/raw/master/Calculator/fonts/digital-7%20(italic).ttf") format("truetype");
}

http://codepen.io/Y-Taras/pen/YWNpRw

Taras Yaremkiv
@Y-Taras
Jul 30 2016 18:14
@sorinr thanks wow) it's working. cross-site is the reason
:sparkles:
Sorin Ruse
@sorinr
Jul 30 2016 18:16
@Y-Taras it was cross origin problem. that crossorigin.me was to solve this.
nice job
Taras Yaremkiv
@Y-Taras
Jul 30 2016 18:18
@sorinr well seems it's working , but the way I didn't use eval function
Heather Kusmierz
@HKuz
Jul 30 2016 18:25
@MohammadHasham consider using a helper function that finds the unique items in one array that aren't in the other. (Versus trying to find the unique items in both all at once). It would take 2 arrays, loops over one, and saves any items not in the other (consider using indexOf) into a new array and returns that. Then you can call it in different ways with your original two array parameters and try to combine the solution.
AlexanderNelson
@AlexanderNelson
Jul 30 2016 18:34
http://codepen.io/AlexanderNelson/full/jAKrGj/ My project images have an overlay that zoom,blur and show the title and link over the image on hover. However, I broke it somehow and I've beenworking on fixing it all day. Any ideas?
Zeeshan Haider
@zeeshan72
Jul 30 2016 19:18
check out my random quote generator
John Doe
@codingisfun11
Jul 30 2016 19:21
// Example
function ourTrueOrFalse(isItTrue) {
  if (isItTrue) { 
    return "Yes, it's true";
  }
  return "No, it's false";
}

// Setup
function trueOrFalse(wasThatTrue) {

  // Only change code below this line.
   if (isItTrue) {
  return "Yes, that was true";
   }
  return "No, that was false";

  // Only change code above this line.

}

// Change this value to test
trueOrFalse(True);
Use Conditional Logic with If Statements.........................trueOrFalse(false) should return "No, that was false"
Norvin Burrus
@ndburrus
Jul 30 2016 19:21
@codingisfun11 lesson?
John Doe
@codingisfun11
Jul 30 2016 19:22
Use Conditional Logic with If Statements....JavaScript.
Norvin Burrus
@ndburrus
Jul 30 2016 19:27
@codingisfun11 isItTrueis different from wasThatTrue :sparkles:
also, review the test case/s input (note capitalization input), example: (true)
John Doe
@codingisfun11
Jul 30 2016 19:31
```
// Example
function ourTrueOrFalse(isItTrue) {
  if (isItTrue) { 
    return "Yes, it's true";
  }
  return "No, it's false";
}

// Setup
function trueOrFalse(wasThatTrue) {

  // Only change code below this line.
  if (wasthatTrue) {

  return "Yes, that was true";
    }
  return "No, that was false";


  // Only change code above this line.

}

// Change this value to test
trueOrFalse(wasthatTrue);
Norvin Burrus
@ndburrus
Jul 30 2016 19:33
@codingisfun11 see last comment - test case/s input :point_up: July 30, 2016 3:27 PM
compare to: (wasthatTrue)
John Doe
@codingisfun11
Jul 30 2016 19:34
get rid of wasthat?
@ndburrus
should i return it then.
John Doe
@codingisfun11
Jul 30 2016 19:40
blob
Luke
@lukenetti3
Jul 30 2016 20:12
Can someone please help me with my twitch.tv project. I am trying to do a live search with the text box and I'm having a hard time. Here's my code, I really haven't done anything for the live search, just having trouble starting. http://codepen.io/lukenetti3/pen/oLEmYK?editors=1010
Jacob Stewart
@JacobStewart1
Jul 30 2016 20:16
hey can someone help me on my quotes genetator https://codepen.io/JacobStewart1/pen/AXVkGk i know i need some jquery but can someone like kind of walk me through some of it to help me out
Norvin Burrus
@ndburrus
Jul 30 2016 20:37
This message was deleted
@codingisfun11 here: if (false) { should be what?
reference instructions, here: if the parameter wasThatTrue is true and return "No, that was false" otherwise.
matthew3454
@matthew3454
Jul 30 2016 20:41
Please help me with my code everyone. Thank you. The problem is that I can't get my calculator "equals button" to work http://codepen.io/codeabode20/pen/PzaGmB?editors=1000
Muhammad Hasham
@MohammadHasham
Jul 30 2016 20:46
need help with "Diff two arrays"
anyone please
Pedro Abel Díaz Sánchez
@coderHook
Jul 30 2016 20:48
@MohammadHasham copy the code you have
Muhammad Hasham
@MohammadHasham
Jul 30 2016 20:49

function diffArray(arr1, arr2) {


 var sliced = arr1.slice(0,1);
  var f = parseInt(sliced);

  if  (arr2.indexOf(f) > -1)
    {
      return arr2;
    }





  var filtered = arr1.filter(diffArray);

}

diffArray([1, 2, 3, 5], [1, 2, 3, 4, 5]);
@coderHook
what corrections shall i make
regards
Pedro Abel Díaz Sánchez
@coderHook
Jul 30 2016 20:50
@MohammadHasham let me check, I am not an expert though
Muhammad Hasham
@MohammadHasham
Jul 30 2016 20:50
@coderHook No problem
JuanLrr
@JuanLrr
Jul 30 2016 20:51
I need help with Random Quote Machine. I want to get an initial random quote when I open the pen, but it's blank. http://codepen.io/JuanLrr/pen/QEAGgp
Pedro Abel Díaz Sánchez
@coderHook
Jul 30 2016 20:53
@MohammadHasham Basically you are not doing what they are asking, sliced contains a whole array but you should have only the difference between both arrays
@MohammadHasham from my point of view, it would be easy if you compare both array with a for loop
then, at the point you get a difference you can slice that piece of array as you were doing or even better, store the different value in a new array
Muhammad Hasham
@MohammadHasham
Jul 30 2016 20:58
@coderHook even tried that u mean a nested one!
Pedro Abel Díaz Sánchez
@coderHook
Jul 30 2016 20:58
didn't work?
Roger Hart
@wilcombebolger
Jul 30 2016 21:05
Hi all how do I share my codepen tribute page with you all? how do I make a link for it? sorry to seem so dim here lol
Janine vN
@janine9vn
Jul 30 2016 21:12
@wilcombebolger You can share the browser url address. That'll link us to your specific one
matthew3454
@matthew3454
Jul 30 2016 21:23
What should I define doCalc(); as?? http://codepen.io/codeabode20/pen/PzaGmB?editors=0010
Roger Hart
@wilcombebolger
Jul 30 2016 21:34
ok will do
D. Gonzalez
@younglionking
Jul 30 2016 22:07
ok
Roger Hart
@wilcombebolger
Jul 30 2016 22:57
my Free Code Camp tribute page project it's URL is posted below
please feel free to give feedback and thank you for your advice
Simon Cordova
@gbsimon87
Jul 30 2016 23:20
Go Alfie!
Good to hear hes making a sound recovery :)
@wilcombebolger your title should go inside your head element
You've also got an open h1 tag
your css is also referencing an id named ul, but it doesn't exist, if you want to target the ul (unorganized list), remove the '#'
Roger Hart
@wilcombebolger
Jul 30 2016 23:34
@gbsimon87 :+1: BLIMEY !! Rechecking it you are so right and yet thank you for taking the time to look over it . I've gone back and corrected the work ( a case of can't see for looking on the most part) but cheers
CamperBot
@camperbot
Jul 30 2016 23:34
wilcombebolger sends brownie points to @gbsimon87 :sparkles: :thumbsup: :sparkles:
:cookie: 290 | @gbsimon87 |http://www.freecodecamp.com/gbsimon87
Simon Cordova
@gbsimon87
Jul 30 2016 23:35
@wilcombebolger no worries buds, keep at it!
Roger Hart
@wilcombebolger
Jul 30 2016 23:37
will do thank you Simon