These are chat archives for FreeCodeCamp/HelpFrontEnd

29th
Jul 2016
Dario Idrovo
@djidrovo1
Jul 29 2016 00:00
@TylerMoeller where?
there are a few fields, I added them in some but i get an error message
Tyler Moeller
@TylerMoeller
Jul 29 2016 00:00
@djidrovo1 In your Codepen, do you see a settings button in the top, right?
Vercaelus
@Vercaelus
Jul 29 2016 00:01
@Steedler Ah, got it. Thanks for the clarification
CamperBot
@camperbot
Jul 29 2016 00:01
vercaelus sends brownie points to @steedler :sparkles: :thumbsup: :sparkles:
:warning: vercaelus already gave steedler points
Vercaelus
@Vercaelus
Jul 29 2016 00:01
@Steedler At the moment, I'm just excited to step up my Angular game
Dario Idrovo
@djidrovo1
Jul 29 2016 00:01
@TylerMoeller nvm, lol I was copying and pasting the entire code, then realized it was just the link that I needed.
thanks man @TylerMoeller
CamperBot
@camperbot
Jul 29 2016 00:01
djidrovo1 sends brownie points to @tylermoeller :sparkles: :thumbsup: :sparkles:
:cookie: 703 | @tylermoeller |http://www.freecodecamp.com/tylermoeller
Tyler Moeller
@TylerMoeller
Jul 29 2016 00:01
Ahh, lol, glad you got it!
Dario Idrovo
@djidrovo1
Jul 29 2016 00:05
@TylerMoeller another question, how can I center them?
right now some of them are touching the border
Tyler Moeller
@TylerMoeller
Jul 29 2016 00:05
@djidrovo1 Font-awesome icons are just like text. Use text-align: center
Dario Idrovo
@djidrovo1
Jul 29 2016 00:06
@TylerMoeller awesome, thanks!
CamperBot
@camperbot
Jul 29 2016 00:06
djidrovo1 sends brownie points to @tylermoeller :sparkles: :thumbsup: :sparkles:
:warning: djidrovo1 already gave tylermoeller points
Dario Idrovo
@djidrovo1
Jul 29 2016 00:09
@TylerMoeller didn't work :/
Tyler Moeller
@TylerMoeller
Jul 29 2016 00:10
@djidrovo1 They appear centered to me. Maybe I'm not understanding what you're trying to do
Dario Idrovo
@djidrovo1
Jul 29 2016 00:11
@TylerMoeller if you look at the linkedin icon, (in)
the bottom of the word "in" is touching the border
of the cricle
Tyler Moeller
@TylerMoeller
Jul 29 2016 00:12
@djidrovo1 Something to do with the padding, let me take a closer look
@djidrovo1 Yeah, it needed a little padding to make that circle around it work. Try this change to your CSS:
.fa {
    width: 45px;
    height: 45px;
    padding-top: 5px;
    font-size: 30px;
    vertical-align: middle;
    text-align: center;
    background-color: white;
    color: #005b8f;
    border: 2px solid #005b8f;
    border-radius: 100%;
    display: inline-block;
    cursor: pointer;
}
Dario Idrovo
@djidrovo1
Jul 29 2016 00:15
@TylerMoeller awesome! you you increased the dimensions by 5px, replaced the align with middle? and removed the line-align, and added a padding on top?
Sorry, just trying to learn so I can know how to fix things on my own in the future. :D
Tyler Moeller
@TylerMoeller
Jul 29 2016 00:20
@djidrovo1 Yes, that's what I did :) I also added cursor: pointer; to make them seem like links
Looking at it more closely, the padding-top: 5px was the biggest change. You could probably remove the vertical-align middle unless you want to add more text to that row outside of the circles.
Dario Idrovo
@djidrovo1
Jul 29 2016 00:22
@TylerMoeller i just noticed the pointer, thanks a lot!
CamperBot
@camperbot
Jul 29 2016 00:22
djidrovo1 sends brownie points to @tylermoeller :sparkles: :thumbsup: :sparkles:
:warning: djidrovo1 already gave tylermoeller points
Tyler Moeller
@TylerMoeller
Jul 29 2016 00:23
Any time :thumbsup:
Elbert Cortez
@trip16661
Jul 29 2016 01:16
how ever needs help shoot iit fast before i leave to study
Seems nobody
Okay i will come back in my breaks and see if someone needs it
Guilherme Or
@chameleonor
Jul 29 2016 01:25
hello guys!! could you help me ? I have two projects, one of them is in angular 2 and other in angular 1. I'm trying to run angular 2 inside angular 1, anybody already tried it ?
oiver55
@oiver55
Jul 29 2016 01:36
Do objects in Javascript have a length limit?
Nestor Figliuolo
@Makaan
Jul 29 2016 02:10
Hi guys, i have a question, i'm with the Twitch API proyect, i can make a single request with all the channels i have in an array regardless if they are online or offline? i can do it for al that are online but not the others, thanks!
Dario Idrovo
@djidrovo1
Jul 29 2016 02:16
hi guys
any feedback on this?
its my portfolio, I have re-made this about 5 times lol
I hope I am satisfied and keep going with JS lessons, because I keep coming back every week to change my portfolio
aagussn
@aagussn
Jul 29 2016 02:25
hi everyone! i'm Agustin and i'm making my tribute page
Nestor Figliuolo
@Makaan
Jul 29 2016 02:25
@djidrovo1 i really like it! good job!
Dario Idrovo
@djidrovo1
Jul 29 2016 02:26
@Makaan thanks! :D
CamperBot
@camperbot
Jul 29 2016 02:26
djidrovo1 sends brownie points to @makaan :sparkles: :thumbsup: :sparkles:
:cookie: 277 | @makaan |http://www.freecodecamp.com/makaan
Michael Smith
@droidvoider
Jul 29 2016 02:29
Build a Tribute Page; <== Is there a way to do this without having to use codepen.io?
Because I don't see CodePen.io being of any benefit to me since I have a huge home network, private Apache, tomcat, php, node.js.. don't need a codepen
aagussn
@aagussn
Jul 29 2016 02:33
@droidvoider i think that fcc uses codepen for host your projetcs so everybody can see it
Nestor Figliuolo
@Makaan
Jul 29 2016 02:33
make it wherever you want and when it's done paste it in codepen
Miguel T Rivera
@mtrivera
Jul 29 2016 02:47
Need help with random quote machine.
I cannot get my button to work properly, it does not get a new quote.
Do I make an another GET request when the button is pressed?
http://codepen.io/mtrivera02/pen/eZERBp
Haib Zhang
@nperhb
Jul 29 2016 02:52
@riveratmiguel u may be have not bind event to the button
Miguel T Rivera
@mtrivera
Jul 29 2016 02:54
@nperhb I tried this:
` $(document).ready(function() { getQuote(); $('#newQuote').click(getQuote()); });
Stephen James
@sjames1958gm
Jul 29 2016 02:58
@riveratmiguel Looks like your replaceWith is replacing the div with the class="quote-content"
@riveratmiguel Try this.
      $('div.quote-content').empty();
      $('div.quote-content').append(data.quote + '<br />');
      $('div.quote-author').empty();
      $('div.quote-author').append('-' + data.author);
Haib Zhang
@nperhb
Jul 29 2016 03:06
@sjames1958gm could you teach me why replaceWith doesn't worke
Stephen James
@sjames1958gm
Jul 29 2016 03:07
@nperhb I believe that replaceWith is replacing the div with the class quote-content and quote-author, so the next time these don't exist and can't be selected or replaced
@nperhb I used the inspect element and those divs were gone, I assumed replaced
Haib Zhang
@nperhb
Jul 29 2016 03:08
@sjames1958gm oh ,I get it now . it have replace the whole div html content ,thanks
Stephen James
@sjames1958gm
Jul 29 2016 03:09
@nperhb :+1:
Miguel T Rivera
@mtrivera
Jul 29 2016 03:12
@sjames1958gm yeah, I looked at the jquery API and it says "DOM Replacement" for replaceWith()
I didn't think about it
thanks!
CamperBot
@camperbot
Jul 29 2016 03:12
riveratmiguel sends brownie points to @sjames1958gm :sparkles: :thumbsup: :sparkles:
:star2: 2208 | @sjames1958gm |http://www.freecodecamp.com/sjames1958gm
Stephen James
@sjames1958gm
Jul 29 2016 03:16
@riveratmiguel I learned something new
Natasha Nazari
@natashanazari
Jul 29 2016 03:17
I’m stuck on the Profile Lookup Challenge in the JS Basics section. Can anyone tell me why this code doesn’t work?
```function lookUp(firstName, prop){
// Only change code below this line
for (i = 0; i < contacts.length; i++) {
if(contacts[i].firstName === firstName){
if(contacts[i].hasOwnProperty(prop)){
return contacts[i][prop];
} else {
return "No such property";
}
}
}
return "No such contact";
}
Michael Smith
@droidvoider
Jul 29 2016 03:17
@aagussn @Makaan Thanks guys..
CamperBot
@camperbot
Jul 29 2016 03:17
droidvoider sends brownie points to @aagussn and @makaan :sparkles: :thumbsup: :sparkles:
:cookie: 121 | @aagussn |http://www.freecodecamp.com/aagussn
:cookie: 278 | @makaan |http://www.freecodecamp.com/makaan
Stephen James
@sjames1958gm
Jul 29 2016 03:18
@natashanazari I think the name of the function has changed to lookUpProfile
Natasha Nazari
@natashanazari
Jul 29 2016 03:20
@sjames1958gm Omg, thank you! Shouldn’t have rewritten the function. 🙈
CamperBot
@camperbot
Jul 29 2016 03:20
:star2: 2209 | @sjames1958gm |http://www.freecodecamp.com/sjames1958gm
natashanazari sends brownie points to @sjames1958gm :sparkles: :thumbsup: :sparkles:
Stephen James
@sjames1958gm
Jul 29 2016 03:23
@natashanazari :)
EdenSweden
@EdenSweden
Jul 29 2016 04:04
@Vercaelus thank you
CamperBot
@camperbot
Jul 29 2016 04:04
edensweden sends brownie points to @vercaelus :sparkles: :thumbsup: :sparkles:
:cookie: 319 | @vercaelus |http://www.freecodecamp.com/vercaelus
labeebahmad414
@labeebahmad414
Jul 29 2016 05:48
Is there a way to change gutter size & in bootstrap?
labeebahmad414
@labeebahmad414
Jul 29 2016 05:59
Is there a way to change the gutter size in bootstrap?
buiphuking
@buiphuking
Jul 29 2016 06:00
what is the different : text method , html method javacript ?
ottomahn
@ottomahn
Jul 29 2016 06:06
guyz I need help
How can I get a bootstrap toggle?
Dan Santos
@CanIGetAPickle
Jul 29 2016 06:27
labeebahmad414
@labeebahmad414
Jul 29 2016 06:28
@CanIGetAPickle Thanks
CamperBot
@camperbot
Jul 29 2016 06:28
labeebahmad414 sends brownie points to @canigetapickle :sparkles: :thumbsup: :sparkles:
:cookie: 540 | @canigetapickle |http://www.freecodecamp.com/canigetapickle
Dan Santos
@CanIGetAPickle
Jul 29 2016 06:31
@buiphuking The .text() method sets or returns literal text. If you pass a string of HTML into it, it won't be inserted into your code as HTML but rather will display as the literal escaped string of text. The .html() method, on the other hand, will take your HTML string and treat it as HTML.
Sorin Ruse
@sorinr
Jul 29 2016 06:35
@ottomahn takea look here. http://codepen.io/sorinr/pen/WxKQyd and then here: http://www.bootstraptoggle.com/
buiphuking
@buiphuking
Jul 29 2016 06:49
@CanIGetAPickle give me some advice
when we use text()
when we use html()
Dan Santos
@CanIGetAPickle
Jul 29 2016 06:56
@ottomahn If you want to use Bootstrap Toggle, the issue seems to be bad CDN links in your CSS and JS settings (the ones from http://www.bootstraptoggle.com/ work). For Bootstrap Switch, you need to add CDN links for the bootstrap-switch.min.css/js in your settings and remove the "data-toggle" attribute.
@buiphuking Take a look at this example: https://jsfiddle.net/5f2rsrmv/
Dan Santos
@CanIGetAPickle
Jul 29 2016 07:02
@ottomahn - Here are examples of both: http://codepen.io/CanIGetAPickle/pen/VjBvNa
buiphuking
@buiphuking
Jul 29 2016 07:35
@CanIGetAPickle thanks
CamperBot
@camperbot
Jul 29 2016 07:35
buiphuking sends brownie points to @canigetapickle :sparkles: :thumbsup: :sparkles:
:cookie: 541 | @canigetapickle |http://www.freecodecamp.com/canigetapickle
Subroto
@Shub1427
Jul 29 2016 07:49

Hi,

I am beginner in css, I know a bit of it ... but whenever I see someones code, I always find some CSS properties that i have never seen before..

Recently, I got to know about there's some new CSS property named -webkit-font-smoothing

Can anyone guide me a book or website which can help me with all css properties.

Mozilla docs are great, but they are very scattered and not easily found

Thanx

Rahul Nayak
@pragyes31
Jul 29 2016 08:04
hi guys, for "show the local weather" project, how do I add background image or icon based on weahter description? There seems to be a lot of weather descriptions viz rain, thuderstorm, shower etc. How Do I know I'm not missing any?
Islam Ibakaev
@dagman
Jul 29 2016 08:09
hey guys atom on windows doesn't search for packages. Any suggestions?
Subroto
@Shub1427
Jul 29 2016 08:14

@pragyes31 css-tricks is an awesome blog, but everything there is also scattered and needs a lot of time to know about all CSS properties. Actually I posted the same on FreeCodeCamp channel, and got to know that i was looking for something like a Cheatsheet.

https://www.smashingmagazine.com/wp-content/uploads/images/css3-cheat-sheet/css3-cheat-sheet.pdf

Dan Santos
@CanIGetAPickle
Jul 29 2016 08:18
@Shub1427 I like to use the cheat sheets at http://overapi.com/css . Just be advised that a property like '-webkit-font-smoothing' isn't recommended, hence you won't necessarily find it so easily listed within any reference. For further information on that, visit: https://developer.mozilla.org/en-US/docs/Web/CSS/font-smooth
Dodi Yulian
@deododeidi
Jul 29 2016 08:18
Hi guys about the tribute page challenge do I free to choose whoever the person is or I need to make similar tribute page from the example?
Dan Santos
@CanIGetAPickle
Jul 29 2016 08:19
@deododeidi You can choose any person you'd like
Dodi Yulian
@deododeidi
Jul 29 2016 08:19
@CanIGetAPickle Cool, thanks!
CamperBot
@camperbot
Jul 29 2016 08:19
deododeidi sends brownie points to @canigetapickle :sparkles: :thumbsup: :sparkles:
:cookie: 542 | @canigetapickle |http://www.freecodecamp.com/canigetapickle
Subroto
@Shub1427
Jul 29 2016 08:22
@CanIGetAPickle Your link is even better. Thanks for the help.
CamperBot
@camperbot
Jul 29 2016 08:22
shub1427 sends brownie points to @canigetapickle :sparkles: :thumbsup: :sparkles:
:cookie: 543 | @canigetapickle |http://www.freecodecamp.com/canigetapickle
Dan Santos
@CanIGetAPickle
Jul 29 2016 08:22
@pragyes31 I would think it depends on the API you're using. I think most include weather icons for every possibility they support (example: https://apidev.accuweather.com/developers/weatherIcons). If the one you're using does not, take a look here: http://www.danvierich.de/weather/
@dagman Is it that you're unable to install packages?
Islam Ibakaev
@dagman
Jul 29 2016 08:26
@CanIGetAPickle oh nvm i already got it working but thx
CamperBot
@camperbot
Jul 29 2016 08:26
dagman sends brownie points to @canigetapickle :sparkles: :thumbsup: :sparkles:
:cookie: 544 | @canigetapickle |http://www.freecodecamp.com/canigetapickle
Ridoy Farhad
@ridoyf
Jul 29 2016 09:53
Hi guys, I would really appreciate some help here. I'm currently working on the tic tac toe game which is listed under the advanced front end developer project. Basically I want to integrate the min max algorithm however I'm having some trouble on a plan on how I'm going to do it. So far the only thing I'm missing is the AI in my game.
Bilkiss
@Bilkiss
Jul 29 2016 10:54
Hi there, I'm stuck in the "Falsy Bouncer", i'm having an issue when I'm verifying the NaN.
any idea how to do this?
kirbyedy
@kirbyedy
Jul 29 2016 11:12
@Bilkiss is NaN a Boolean ?
Bilkiss
@Bilkiss
Jul 29 2016 11:13
@kirbyedy let me show you may code
function bouncer(arr) { var result = arr.filter(function(elem) { var filterEach = arr.map(function(elem){ var index = ""; if (elem === false) { index = arr.indexOf(elem); if (index > -1) { arr.splice(index, 1); } } else if (elem === null) { index = arr.indexOf(elem); if (index > -1) { arr.splice(index, 1); } } else if (elem === 0) { index = arr.indexOf(elem); if (index > -1) { arr.splice(index, 1); } } else if (elem === "") { index = arr.indexOf(elem); if (index > -1) { arr.splice(index, 1); } } else if (elem === undefined) { index = arr.indexOf(elem); if (index > -1) { arr.splice(index, 1); } } else if (elem === isNaN(elem)) { index = arr.indexOf(elem); if (index > -1) { arr.splice(index, 1); } } }); }); console.log(arr); return arr; }
kirbyedy
@kirbyedy
Jul 29 2016 11:15
holly macaroni... thats a lot of code :)
Bilkiss
@Bilkiss
Jul 29 2016 11:15
@kirbyedy lol
let me re format it
Stephen James
@sjames1958gm
Jul 29 2016 11:15
@Bilkiss The key is if your filter function returns "false" or falsy for an array element it is removed from the resulting array.
You are attempting to remove false/falsy elements.
kirbyedy
@kirbyedy
Jul 29 2016 11:15
have you thought of filtering the Booleans ?
Bilkiss
@Bilkiss
Jul 29 2016 11:17
my issue is when i'm verifying when element is equal to NaN @sjames1958gm
kirbyedy
@kirbyedy
Jul 29 2016 11:18
I see you also asked on the other channel, so listen to that guy there
Stephen James
@sjames1958gm
Jul 29 2016 11:18
@Bilkiss You want to remove falsy (including NaN) if you return falsy from your filter function filter will remove the item, just return the item
kirbyedy
@kirbyedy
Jul 29 2016 11:18
I used filter(Boolean) or something like that
Harrison Freeman
@HarrisonLib
Jul 29 2016 11:24
Hi @aagussn I am Harrison I am also doing my tribute page. maybe we can work on it together.
spalqui
@spalqui
Jul 29 2016 11:27
can someone help me
Muhammad Hasham
@MohammadHasham
Jul 29 2016 11:34

http://codepen.io/Mohammad_Hasham/pen/QEAVWY?editors=0010

can someone help me that why my images are not having the effect?

Dion Hobdy
@hobdydion
Jul 29 2016 11:39

Hello, I'm on the tribute page challenge. I am stuck. Whenever we are stuck are we allowed to gather codes from previous lessons and Google and use said codes or do we strictly have to go by memory?

This is likely a dumb question given that it is currently 4 in the morning. lol

kirbyedy
@kirbyedy
Jul 29 2016 11:39
its 14:39 here so its fine :)
and yes, read, search ask, use your google fu force
Dion Hobdy
@hobdydion
Jul 29 2016 11:42
@kirbyedy, thank you. lol My tribute page is on a film director's cinematography. For something like this do you recommend using unsorted list or ordered list?
CamperBot
@camperbot
Jul 29 2016 11:42
hobdydion sends brownie points to @kirbyedy :sparkles: :thumbsup: :sparkles:
:star2: 1308 | @kirbyedy |http://www.freecodecamp.com/kirbyedy
kirbyedy
@kirbyedy
Jul 29 2016 11:44
flip a coin mate :)
Michal Kozlowski
@McBiggos
Jul 29 2016 11:51
Hey guys - could you tell me why my random quote machine works absolutely fine when I enter it through http url but doesn't when entered from my codepen profile, through https?
http://codepen.io/McBiggos/full/EyRRXo/
https://codepen.io/McBiggos/full/EyRRXo/
Oh, and why it doesn't work here in gitter
At all
kirbyedy
@kirbyedy
Jul 29 2016 11:53
@McBiggos its because of the mixed content
if you change all your links to https it will work
Michal Kozlowski
@McBiggos
Jul 29 2016 11:56
thanks @kirbyedy a lot <3
CamperBot
@camperbot
Jul 29 2016 11:56
mcbiggos sends brownie points to @kirbyedy :sparkles: :thumbsup: :sparkles:
:star2: 1309 | @kirbyedy |http://www.freecodecamp.com/kirbyedy
Michal Kozlowski
@McBiggos
Jul 29 2016 11:56
It works as it should now :thumbsup:
kirbyedy
@kirbyedy
Jul 29 2016 11:59
This message was deleted
Muhammad Hasham
@MohammadHasham
Jul 29 2016 12:04
how can i stop a certain jquery effect after sometime?
Roger Hart
@wilcombebolger
Jul 29 2016 12:09
Hi all
I have a circular by using "img-circle" within bootstrap framework but can't center it. I can centre it using "centre-block" but the image then returns on the page "Square". any advice anyone please? my code is as follows

<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.1/css/bootstrap.min.css"/>

<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script>

<script src="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script>
</head>
<!--No code to be changed above this comment-->
<body>

<div class="container">
<div class="jumbotron">
<div class="page-header">

 <title> Tribute Web Page </title>

<h1

<h1 class ="text-center">My Little Soldier </h1>
<h3 class="text-center"><i>Alfie Thomas Hart</i></h3>
<p class="text-center"><i> My Gorgeous and Courageous Son</i></p>
</div>
<div>

 </div>
 <div>
   <p class="text-center">Born on Saturday 28th June 2014
 </div>
 <div> 
   <img   class="center-block"   src="https://dl.dropboxusercontent.com/s/2t585qu6wfk4vtz/Newborn-Alfie.jpg?dl=0" class="img-circle" alt="Newborn Alfie" width="300" height="400">
 </div>
</body>

this is my tribute page project

my only css is .jumbotron {
background-color: #ff9933 ! important;
}
Muhammad Hasham
@MohammadHasham
Jul 29 2016 12:15
can anyone help me on jquery
  $(".online").hover(function(){        
           $( this ).fadeToggle("slow","swing")


        });
         $(".offline").hover(function(){    

           $( this ).fadeToggle("slow","swing");

        });
how can i terminate these functions after a particulr time they keep on running
Bilkiss
@Bilkiss
Jul 29 2016 12:21
setTimeout();
@MohammadHasham for example:
var greating= function(){
alert("Hello World!");
};
setTimeout(greating, 2000);
Roger Hart
@wilcombebolger
Jul 29 2016 12:21
Hi all
can anyone help me with the tribute page project please
Janine vN
@janine9vn
Jul 29 2016 12:22
@wilcombebolger What are you struggling with?
Roger Hart
@wilcombebolger
Jul 29 2016 12:23
thanks @janine9vn my problem is posted just above
CamperBot
@camperbot
Jul 29 2016 12:23
wilcombebolger sends brownie points to @janine9vn :sparkles: :thumbsup: :sparkles:
:cookie: 203 | @janine9vn |http://www.freecodecamp.com/janine9vn
Janine vN
@janine9vn
Jul 29 2016 12:23
@wilcombebolger can you post your codepen? It's a bit easier for me to see what's happening
Roger Hart
@wilcombebolger
Jul 29 2016 12:24
i am trying whilst using bootstrap position a circular image in the centre of the page - will do

<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.1/css/bootstrap.min.css"/>

<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script>

<script src="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script>
</head>
<!--No code to be changed above this comment-->
<body>

<div class="container">
<div class="jumbotron">
<div class="page-header">

 <title> Tribute Web Page </title>

<h1

<h1 class ="text-center">My Little Soldier </h1>
<h3 class="text-center"><i>Alfie Thomas Hart</i></h3>
<p class="text-center"><i> My Gorgeous and Courageous Son</i></p>
</div>
<div>

 </div>
 <div>
   <p class="text-center">Born on Saturday 28th June 2014
 </div>
 <div> 
   <img   class="center-block"   src="https://dl.dropboxusercontent.com/s/2t585qu6wfk4vtz/Newborn-Alfie.jpg?dl=0" class="img-circle" alt="Newborn Alfie" width="300" height="400">
 </div>
</body>

the css is

.jumbotron {
background-color: #ff9933 ! important;
}
Janine vN
@janine9vn
Jul 29 2016 12:25
@wilcombebolger You can post the link from your codepen so I can view the codepen directly
Muhammad Hasham
@MohammadHasham
Jul 29 2016 12:25
@Bilkiss how can i set it for hover
Roger Hart
@wilcombebolger
Jul 29 2016 12:25
how as i am new to codepen
Janine vN
@janine9vn
Jul 29 2016 12:25
@wilcombebolger the link at the top of your browser
Bilkiss
@Bilkiss
Jul 29 2016 12:26
@MohammadHasham assign your function to a variable
@MohammadHasham like:
var greating= function(){
alert("Hello World!");
};
setTimeout(greating, 2000);
and then you pass your variable in the setTimeout();
Muhammad Hasham
@MohammadHasham
Jul 29 2016 12:28
@Bilkiss Thanks it worked
CamperBot
@camperbot
Jul 29 2016 12:28
mohammadhasham sends brownie points to @bilkiss :sparkles: :thumbsup: :sparkles:
:cookie: 255 | @bilkiss |http://www.freecodecamp.com/bilkiss
Janine vN
@janine9vn
Jul 29 2016 12:28
@wilcombebolger okay! I see that's going on.
So when you have your image code
Bilkiss
@Bilkiss
Jul 29 2016 12:28
your are welcome @MohammadHasham
Janine vN
@janine9vn
Jul 29 2016 12:29
You have class="center block" src="your-source" class="img-circle"
The problem is that you're declaring class twice which isn't how you include two classes. It's reading the "center-block" class and since no other classes are listed after it doesn't read your img-circle class
Roger Hart
@wilcombebolger
Jul 29 2016 12:30
okay i see what you are saying its reading just one class not img circle class
Janine vN
@janine9vn
Jul 29 2016 12:30
@wilcombebolger To put it a bit simpler
Instead of: <img class="center-block" src="src" class="img-circle">
Where you have class="stuff" twice, you want it:
<img class="center block img-circle" src="src">
So that you're listing both classes that you want, but only declare class="stuff" once
Roger Hart
@wilcombebolger
Jul 29 2016 12:32
okay let me have a quick recode and i will get back to you thank you
@janine9vn something like this then?
<img class="center-block" class="img-circle" src="https://dl.dropboxusercontent.com/s/2t585qu6wfk4vtz/Newborn-Alfie.jpg?dl=0" alt="Newborn Alfie" width="300" height="400">
</div>
</body>
Janine vN
@janine9vn
Jul 29 2016 12:39
@wilcombebolger Close, but instead of having class="center-block" and class="img-circle" in separate class="stuff", combine it into ONE class="center-block img-circle"
If you combine it into one with a space between the different classes, it'll read it correctly
Roger Hart
@wilcombebolger
Jul 29 2016 12:40
okay ty
@janine9vn you are a star :+1: thank you
CamperBot
@camperbot
Jul 29 2016 12:41
wilcombebolger sends brownie points to @janine9vn :sparkles: :thumbsup: :sparkles:
:warning: wilcombebolger already gave janine9vn points
Janine vN
@janine9vn
Jul 29 2016 12:42
@wilcombebolger No problem~
aagussn
@aagussn
Jul 29 2016 12:57
Can someone showme the tribute page?
Im new and i dont know how its good
Janine vN
@janine9vn
Jul 29 2016 13:05
@aagussn What do you mean?
Clyde
@hea-hea
Jul 29 2016 13:07
Hi, I have a jquery question - maybe someone can help. I want to append a div, with a paragraph and give this paragraph a class at the same time. What's a good way to do it? I have `$("#myDivID").append("<p>" + title + "</p>");` so far.
And $("#myDivID").append("<p class="myClass">" + title + "</p>"); won't work.
Stephen James
@sjames1958gm
Jul 29 2016 13:08
@hea-hea Use single quotes around myClass
Clyde
@hea-hea
Jul 29 2016 13:09
@sjames1958gm right, a simple thing :)) thanks!
CamperBot
@camperbot
Jul 29 2016 13:09
hea-hea sends brownie points to @sjames1958gm :sparkles: :thumbsup: :sparkles:
:star2: 2214 | @sjames1958gm |http://www.freecodecamp.com/sjames1958gm
Stephen James
@sjames1958gm
Jul 29 2016 13:11
@hea-hea :+1:
kyadondo Timothy
@chadwalt
Jul 29 2016 13:25
@hea-hea var div = $("<div id='myDivID'/>"); var para = $("<p class='title'/>"); div.append(para);
@hea-hea use that to create html elements using jquery without using html
Roger Hart
@wilcombebolger
Jul 29 2016 13:43
@wilcombebolger
Hi All
is it possible to "center" an unordered list ? within a bootstrap framework?
I can get the text to center but not the "dots"
kyadondo Timothy
@chadwalt
Jul 29 2016 13:48
@wilcombebolger post yo code
Roger Hart
@wilcombebolger
Jul 29 2016 13:49
<h3 class="text-center">Alfies short little Time Line</h3>
<ul>
<li class="text-center"><li>help needed here</li></ul>
here it is
its my tribute page project
kyadondo Timothy
@chadwalt
Jul 29 2016 13:53
<li class="text-center">help needed here</li>
the first tag is not closed
Roger Hart
@wilcombebolger
Jul 29 2016 13:57
if i close the tag the class no longer works and the full text is displayed on the page which is not what i need.
Bilkiss
@Bilkiss
Jul 29 2016 14:03
@wilcombebolger you have open <li> twice. <li class="text-center"><li>

for only one close li tag:

<li class="text-center"><li>help needed here</li> @wilcombebolger

Harrison Freeman
@HarrisonLib
Jul 29 2016 14:18
@wilcombebolger Does putting the list in a div work?
Ken Haduch
@khaduch
Jul 29 2016 14:29
@HarrisonLib - you can put lists in a div.
Muhammad Hasham
@MohammadHasham
Jul 29 2016 14:32
 var greeting = $(".online").hover(function(){        
           $( this ).fadeToggle("slow","swing")
          });
         setTimeout(greeting, 10);
why is this not working?
Liman Abba
@limanCode
Jul 29 2016 14:53
<nav class="navbar navbar-default">
<div class="container-fluid">
<a class="navbar-brand" href="#">Liman Abba</a>
<div class="navbar-header navbar-right">
<ul class="nav navbar-nav nav-tabs">
<li><a href="#">About</a>
<li><a href="#">Portfolio</a>
<li><a href="#">Contact</a>
</ul>
</div>
</div>
</nav>
My code pen is not showing the navbar when i type this
Janine vN
@janine9vn
Jul 29 2016 14:53
@limanCode can you link your codepen?
@janine9vn see the link above
Janine vN
@janine9vn
Jul 29 2016 15:01
@limanCode If your CSS and JS sections, you need to quick add the Bootstrap files
Liman Abba
@limanCode
Jul 29 2016 15:02
bootstrap in both css and js? and again I saw two rows, do i need to add to both rows or just once?
Janine vN
@janine9vn
Jul 29 2016 15:03
@limanCode You want to add it in both to get the navbar to fully function in case you add a dropdown or something. You just need to add it once
Liman Abba
@limanCode
Jul 29 2016 15:04
@janine9vn thanks so much, it works
CamperBot
@camperbot
Jul 29 2016 15:04
limancode sends brownie points to @janine9vn :sparkles: :thumbsup: :sparkles:
:cookie: 221 | @janine9vn |http://www.freecodecamp.com/janine9vn
Liman Abba
@limanCode
Jul 29 2016 15:04
@janine9vn I will follow your handle, pls follow back
Haelmorn
@Haelmorn
Jul 29 2016 15:11
hey, anyone could help me? I want to place the image in a set distance from the edge of the background, how can I do that?
Artis Raudive
@ar14059
Jul 29 2016 15:14
Hi everyone. I have a problem with getting information from wikipedia API, here is my program code in codepen: http://codepen.io/artisraudive/pen/JKkWXR?editors=0010 . I use "$.getJSON" method to get json data from URL.
Muhammad Hasham
@MohammadHasham
Jul 29 2016 15:18
http://codepen.io/Mohammad_Hasham/pen/QEAVWY?editors=0010
why are my mouse events not working properly
JeansBolong
@JeansBolong
Jul 29 2016 15:21
wiki Where do I belong
CamperBot
@camperbot
Jul 29 2016 15:21

:point_right: algorithm where do i belong [wiki]

Algorithm Where do I Belong

:triangular_flag_on_post: Remember to use Read-Search-Ask if you get stuck. Try to pair program :busts_in_silhouette: and write your own code :pencil:

:checkered_flag: Problem Explanation:

This can be a tricky problem to understand. You need to find where in the array a number should be inserted by order, and return the index where it should go.

Relevant Links

:pencil: read more about algorithm where do i belong on the FCC Wiki

Xihai Luo
@coolsday
Jul 29 2016 15:34
guys, can you suggest some custom fonts i can use and where/how i can get them?
Diego Souza
@diegosouza
Jul 29 2016 15:39
@coolsday google fonts
Xihai Luo
@coolsday
Jul 29 2016 15:43
@diegosouza where can i get them from?
Angel Eduardo
@angelfeliz
Jul 29 2016 15:46
hello people
Diego Souza
@diegosouza
Jul 29 2016 15:47
@coolsday https://www.google.com/fonts see the usage instructions there
Artis Raudive
@ar14059
Jul 29 2016 15:48
Hi everyone! I can't understand, why "getJSON" method don't work with certain url, here is my code in CodePen: http://codepen.io/artisraudive/pen/JKkWXR?editors=0010 . Code works, if i use variable "api", that is commented above code.
Diego Souza
@diegosouza
Jul 29 2016 15:52
@ar14059 it works with any address you can have a GET request
Angel Eduardo
@angelfeliz
Jul 29 2016 16:05
@ar14059 i had this problem too "Access-Control-Allow-Origin", when i call the wiki api . that is because you need to call using Jsonp function and add a call_back function at the end of the url to trick the proxy, what i did is use angular. You can do it with jquery or angularjs. this is my codePen if you like to check out http://codepen.io/erodriguezfeliz/pen/KMddWy
Xavier Velez
@JonSnow08
Jul 29 2016 16:06
Has anybody here completed the Simon Game and have a moment to help me out?
I've got a few of the functions done, a good amount of code but im lost as to where to go next
Veron Oparebea
@Veron247
Jul 29 2016 16:08
hello
A friend introduced me to freecodecamp. And am much happy to join
Muhammad Hasham
@MohammadHasham
Jul 29 2016 16:12
Diego Souza
@diegosouza
Jul 29 2016 16:12
@Veron247 welcome
Beth Qiang
@bethqiang
Jul 29 2016 16:20
is anyone in here familiar with the materialize framework, especially with respect to grids?
Ken Haduch
@khaduch
Jul 29 2016 16:21
@MohammadHasham - a couple things I noticed
  • when first loading, there is (or at least was) an empty space in the the grid - a row in the middle of the rows that was not completely filled in (This might be random - I just reloaded and there were several gaps in the rows)
  • clicking on "online" still leaves the "Account Closed" images there. (And should those have a name attached? Since you used a name to find them)
  • the "Account closed" uses also show up for the "Offline users"
  • After clicking "online users", "offline users" and then "All users" - the online users are no longer shown? Also "Online Users" and then "All Users" doesn't show the offline users?
@bethqiang - I'm not, but would give it a shot? Do you have a link and a specific question?
Tyler Moeller
@TylerMoeller
Jul 29 2016 16:24
@bethqiang Yes, I've used the materialize grid.
@khaduch Similar concept to bootstrap, but no xs grid size: http://materializecss.com/grid.html
Ken Haduch
@khaduch
Jul 29 2016 16:25
@TylerMoeller @bethqiang - yes, I was just looking at the docs... very similar.
Xavier Velez
@JonSnow08
Jul 29 2016 16:27
 var LightUp = function() {
      for (var i = 0; i < sequence.length; i++) {
           switch (sequence[i]) {
            case 1:
               $('.cntrl1').css('background-color', "#ff0000");
               setTimeout(function() {
                  $('.cntrl1').css('background-color', '#330000');

               }, 500);
               break;
            case 2:
               $('.cntrl2').css('background-color', "#00ff00");
               setTimeout(function() {
                  $('.cntrl2').css('background-color', '#003300');

               }, 500);
               break;

            case 3:
               $('.cntrl3').css('background-color', "#ffff00");
               setTimeout(function() {
                  $('.cntrl3').css('background-color', '#4d4d00');

               }, 500);
               break;
            case 4:
               $('.cntrl4').css('background-color', "#0000ff");
               setTimeout(function() {
                  $('.cntrl4').css('background-color', '#000033');

               }, 500);
               break;
         }
      }
how would I set this up to not light up all at the same time
right now it's going all at once, I need it in order
Beth Qiang
@bethqiang
Jul 29 2016 16:28

@khaduch @TylerMoeller so i have a grid, where the left column has a picture and the right column has some text. i've been trying to get the picture to be vertically aligned, but i haven't yet succeeded. (i have tried a myriad of placements of "valign-wrapper" and "valign") a snippet of the code without the valign-wrappers/valign (i'm adding html via javascript/jquery) is below, as well as a link to the codepen that i'm attempting to use.

      onlineHTML = '<a href="' + url + '" target="_blank"><div class="row online"><div class="col s3 m2 center"><img src="' + logo + '" class="logo-style"></div><div class="col s9 m10"><p class="name">' + name + '</p><p>'+ game + ': ' + description + '</p></div></a>';
      $("#streamers").prepend(onlineHTML);

what it looks like now: http://codepen.io/bethqiang/pen/xOzJGr

@khaduch @TylerMoeller i've tried putting valign-wrapper and valign in various places in the various divs/elements and i just haven't been able to get it yet. also, sorry, i didn't realize that snippet of code would be slightly annoying to read, haha. i can reformat it if it makes y'all's life easier.
Tyler Moeller
@TylerMoeller
Jul 29 2016 16:30
@bethqiang lol, I just went through this with my Twitch.tv project in Materialize. It was hard to get the images to align correctly. I'll try to take a closer look at your pen and see if I can help.
Ken Haduch
@khaduch
Jul 29 2016 16:31
@bethqiang - vertical alignment is a bit of a nasty thing, unless you can use flex - that seems to make things really easy. I think that you might be able to put your image inside a flexbox that has it set for centering? I'm not that familiar with flex, but I'll bet it would work... let me see if I can figure out how to add it? Unless someone else here (I know there are some flex devotees here from time to time) knows if it can be done.
Beth Qiang
@bethqiang
Jul 29 2016 16:34
@khaduch i've been considering trying to learn how flex works to incorporate flex into future projects, but i figured i'd at least finish this series of projects before embarking on something new haha. but yes, if it can be done in flex, happy to learn! @TylerMoeller awesome! let me know :)
Tyler Moeller
@TylerMoeller
Jul 29 2016 16:34
@bethqiang Add the classes responsive-img circle to your <img> tags in your JS. Remove the height and width settings from your CSS for the class .logo-style, and then add a top margin to get them vertically aligned.
You can set a min-width on the image as well to keep it from getting too small at certain media sizes
Beth Qiang
@bethqiang
Jul 29 2016 16:44
@TylerMoeller hmm ok cool, most of that worked--is there any way to auto set the top margin so that it's always vcentered, regardless of the size? for example, the way i have it now (set to 25%), it's okay at some screen widths but really really not in others
Ken Haduch
@khaduch
Jul 29 2016 16:46
@bethqiang - I'm close to getting the flex thing working - if I set the height of the flex div to 200px - it looks nice! I'll post a screenshot
Tyler Moeller
@TylerMoeller
Jul 29 2016 16:47

@bethqiang You could do something like this:

.logo-style {
  margin: 15px auto 0 auto;
  min-width: 80px;
}

Flex also works well with materialize.

Ken Haduch
@khaduch
Jul 29 2016 16:47
blob
@bethqiang - that's for the offline users. I need to figure out how to get the thing automatically to set the height to the container div? Not sure about that one.
Beth Qiang
@bethqiang
Jul 29 2016 16:49
@TylerMoeller - still not quite what i was envisioning, but def closer...hmm.
@khaduch - that does look awesome! what is the "thing" you're referring to?
Rich
@richard-ball
Jul 29 2016 16:53
Is there some default behaviour that blocks the use of the submit event, since I cannot get it to work. all that happens is my console clears and the text input empties.
Ken Haduch
@khaduch
Jul 29 2016 16:54
@bethqiang - I have added a div to hold the image, but if I do not specify a height, it does not inherit the height of the parent div, the "row", so it ends up just looking as it did before. If I set the height with a hard-coded value, looks like about 106px works, then it is vertically centered, thanks to the flex settings... still researching.
CamperBot
@camperbot
Jul 29 2016 16:54
khaduch sends brownie points to @bethqiang :sparkles: :thumbsup: :sparkles:
:cookie: 272 | @bethqiang |http://www.freecodecamp.com/bethqiang
Travmatth
@Travmatth
Jul 29 2016 16:55
i’m slightly confused about the twitchtv project - is the point just to pull & display the list of current streamers?
Tyler Moeller
@TylerMoeller
Jul 29 2016 17:00
@Travmatth Yes, and filter that list by their online/offline/closed account status.
Beth Qiang
@bethqiang
Jul 29 2016 17:02
@khaduch - would setting the height to 100% do anything?
Anshul Jain
@ajain706
Jul 29 2016 17:03
hello world !!!!!!!!
CamperBot
@camperbot
Jul 29 2016 17:03

welcome to FreeCodeCamp @ajain706!

Stephen James
@sjames1958gm
Jul 29 2016 17:03
@ajain706 HEELLOOO
Anshul Jain
@ajain706
Jul 29 2016 17:04
hy @sjames1958gm
Ken Haduch
@khaduch
Jul 29 2016 17:06
@bethqiang - I just figured it out - I needed to make the parent contaner also be a flex container. I'll just fork your project for you to check out - the changes that I made are only for the offline users, there was change to the offlineHTML, and the addition of a .flexCenter class, as well as adding display:flex; to the .offline class. Here is a link - see if you get it working. I think that you had an error in your original HTML, maybe missing a closing </div> tag? Anyway, I think that the offline users is working here.
Beth Qiang
@bethqiang
Jul 29 2016 17:11
@khaduch - awesome, i'll take a look at it! i wouldn't be surprised if i had an error in my original HTML...i find it so difficult to keep track of closing tags. :/ and @TylerMoeller - thanks to both of you for taking a shot at it!
CamperBot
@camperbot
Jul 29 2016 17:11
bethqiang sends brownie points to @khaduch and @tylermoeller :sparkles: :thumbsup: :sparkles:
:star2: 1493 | @khaduch |http://www.freecodecamp.com/khaduch
:cookie: 704 | @tylermoeller |http://www.freecodecamp.com/tylermoeller
Tyler Moeller
@TylerMoeller
Jul 29 2016 17:13
@khaduch Nice work :)
May have to borrow some of that for my Twitch project and get rid of those media queries!
CloudyShows
@CloudyShows
Jul 29 2016 17:17
"
Rule #2: Fulfill the below user stories. Use whichever libraries you need. Give it your own personal style"
what does this mean?
Beth Qiang
@bethqiang
Jul 29 2016 17:18
@khaduch - so i looked up a couple of things relating to the flexbox class that you added in, and found this on mdn -
/ Pack items around the center /
justify-content: center;
CloudyShows
@CloudyShows
Jul 29 2016 17:18
nvm im dumb
Beth Qiang
@bethqiang
Jul 29 2016 17:18
@khaduch - what does that mean? i tried deleting it from the css and nothing (visibly) changed haha
Muhammad Hasham
@MohammadHasham
Jul 29 2016 17:19
@khaduch tried to fix those issues i guess that they are fixed!
http://codepen.io/Mohammad_Hasham/full/QEAVWY/
Marc Vesper
@marcvesper
Jul 29 2016 17:19
does document.ready() only fire the first time the DOM is loaded, or also after your scripts complete changes to the DOM?
Angel Eduardo
@angelfeliz
Jul 29 2016 17:22
@marcvesper in my expirence is only once. when the DOM is ready //executes when HTML-Document is loaded and DOM is ready , there is a document.load() //// executes when complete page is fully loaded, including all frames, objects and images
Muhammad Hasham
@MohammadHasham
Jul 29 2016 17:24
any good resource i.e; video tutorials or anything to learn AJAX actually i know how to ue getJSON but not AJAX,
that requires less time
Angel Eduardo
@angelfeliz
Jul 29 2016 17:25
@MohammadHasham here is a document to learn AJAX https://learn.jquery.com/ajax/
Paul F. Aponte
@DrAponte
Jul 29 2016 17:28
Where can I buy two quality 4GB RAMs at a reasonable price, for my MacBook Pro 13’’ Mid-2009?
Ken Haduch
@khaduch
Jul 29 2016 17:28

@bethqiang

@khaduch - so i looked up a couple of things relating to the flexbox class that you added in, and found this on mdn -
/ Pack items around the center /
justify-content: center;

I think that is horizontal centering, so it might not be needed here, since the width of the image probably determines the width of the div?

Beth Qiang
@bethqiang
Jul 29 2016 17:29
@khaduch ah, right, now that i'm reading the description again, that makes sense!
Ken Haduch
@khaduch
Jul 29 2016 17:30
@bethqiang - if you split your HTML strings into separate lines, as I did (because I needed to try and give myself some level of understanding of what you were generating and how I wanted to change it) that makes it easier to read.
Beth Qiang
@bethqiang
Jul 29 2016 17:31
@khaduch yeah, i really liked that and will definitely continue doing that, it makes it sooo much easier
Don Price
@KingHippo
Jul 29 2016 17:41
Has anyone here worked with React JS and knows of a good tutorial or book?
Sorry Node JS\
abhijith shenoy
@shenoyabhijith
Jul 29 2016 17:42
why do u use node js?
Stephen James
@sjames1958gm
Jul 29 2016 17:43
@KingHippo So not React?
abhijith shenoy
@shenoyabhijith
Jul 29 2016 17:43
i heard its an alternative to php
Don Price
@KingHippo
Jul 29 2016 17:43
Just for learning\
Stephen James
@sjames1958gm
Jul 29 2016 17:43
@KingHippo This channel has node js, their React series was good so hopefully would be the same for node
https://www.youtube.com/user/learncodeacademy/playlists
Don Price
@KingHippo
Jul 29 2016 17:44
Thanks @sjames1958gm
CamperBot
@camperbot
Jul 29 2016 17:44
kinghippo sends brownie points to @sjames1958gm :sparkles: :thumbsup: :sparkles:
:star2: 2221 | @sjames1958gm |http://www.freecodecamp.com/sjames1958gm
Stephen James
@sjames1958gm
Jul 29 2016 17:44
@KingHippo :+1:
Tyler Moeller
@TylerMoeller
Jul 29 2016 17:45
@KingHippo I'm a nodeschooler, so I point people to http://nodeschool.io. Lots of tutorials there and local nodeschool chapters for in-person help.
Don Price
@KingHippo
Jul 29 2016 17:46
@TylerMoeller Thanks! I'll give that a look!
CamperBot
@camperbot
Jul 29 2016 17:46
kinghippo sends brownie points to @tylermoeller :sparkles: :thumbsup: :sparkles:
:cookie: 705 | @tylermoeller |http://www.freecodecamp.com/tylermoeller
Guilherme Or
@chameleonor
Jul 29 2016 18:11
Hello guys, I need your help! I have two projects one running in angular 1 and other in angular 2, is it possible run the angular 2 inside angular 1 ?
mr4199
@mr4199
Jul 29 2016 18:27
hi guys I am making the twitch app http://codepen.io/mr4199/pen/EyRzYm and i have a problem with photos, they dont show up allways, i should klick on any button or reload the page few times to see the photos of channels
DuskyPixel
@DuskyPixel
Jul 29 2016 18:31
@mr4199 It looks like you are doing multiple api calls everytime you click something.. maybe that is the problem?
@mr4199 whynot just save the data once you get it
Angel Eduardo
@angelfeliz
Jul 29 2016 18:33
@mr4199 set the image in a <img> tag and try it out
vínαч puppαl
@vinaypuppal
Jul 29 2016 18:40
@KingHippo A collection of awesome things regarding React https://github.com/enaqx/awesome-react
DuskyPixel
@DuskyPixel
Jul 29 2016 18:48
http://www.hackingwithreact.com/ a react book I found from github although I have not read through it much yet
mr4199
@mr4199
Jul 29 2016 18:57
@DuskyPixel ok I will try it out
@angelfeliz doesnt work
@DuskyPixel but there is to much work, i thing the problem is becous I make css background to photo before first JSON is called and div witch class that I want to change doesn exist in moment of execution, what can I do about it?
DuskyPixel
@DuskyPixel
Jul 29 2016 19:08
@mr4199 not sure what you mean.. When I first got the ajax result I added the onlines to an online container and the offlines to an offline container which I just toggled their display when ever a button was clicked
DavidR
@davidrinconv
Jul 29 2016 19:14
Hi guys, Im doing the Sorted Union challenge but im stuck on how to do it.... any tips on how to start it?
Jaren Escueta
@jarenescueta731
Jul 29 2016 19:18
@davidrinconv read the arguments object link in the problem description. using reduce on an array can be similar to using a for loop.
Chris Drain
@Chrislearns
Jul 29 2016 19:23
Hey everyone is there anyone that can help with my weather app zipline I can't get the getJSON to work
Michael Smith
@droidvoider
Jul 29 2016 19:28
Build a Tribute Page: I don't understand the grey DIV area, how they did it.. http://codepen.io/droidvoider/pen/OXwyWR
Original: (I'm not supposed to look)
It's all grey and rounded, like a class they used but I can't guess it.
Also my image looks different but I think I can adjust that closer
Sorin Ruse
@sorinr
Jul 29 2016 19:38
hi there. i would appreciate any feedback on this pen even its still under construction: http://codepen.io/sorinr/pen/YWjkZx
Alique Williams
@AliqueWilliams
Jul 29 2016 19:43
Has anyone done the express.js challenges?
DavidR
@davidrinconv
Jul 29 2016 19:47
'''
test = a
'''
CamperBot
@camperbot
Jul 29 2016 19:47
:bulb: to format code use backticks! ``` more info
DavidR
@davidrinconv
Jul 29 2016 19:47

function uniteUnique(arr) {
  var a = arguments[0];
  var b = arguments[1];
  var c = arguments[2];
  var d = [];
  var e = [];
  var f = [];
  var g = [];

b.forEach(function(element,index,array){
  var z = element;
  for(var i = 0; i < a.length; i++){
 if (z == a[i]){
   d.push(index);
 }}  
});

 b.splice(d.slice(0,1),d.length);

if (c !== undefined) {  
c.forEach(function(element,index,array){
  var z = element;
  for(var i = 0; i < a.length; i++){
 if (z == a[i]){
   f.push(index);
 }}  
});
  c.splice(f.slice(0,1),f.length); 
  return a.concat(b).concat(c);

} else {
  return a.concat(b);
} 
  //return a.concat(b).concat(c);
}

uniteUnique([1, 3, 2], [5, 2, 1, 4], [2, 1]);
Ken Haduch
@khaduch
Jul 29 2016 19:51
@sorinr - neat site!
Sorin Ruse
@sorinr
Jul 29 2016 19:53
@khaduch just fulling around today with html tags, css and a little jq. thank you
CamperBot
@camperbot
Jul 29 2016 19:53
sorinr sends brownie points to @khaduch :sparkles: :thumbsup: :sparkles:
:star2: 1494 | @khaduch |http://www.freecodecamp.com/khaduch
Ken Haduch
@khaduch
Jul 29 2016 19:58
@sorinr - one thing that is a little disturbing is that if you go from, say, the "ABOUT" page to the "PORTFOLIO" page, a scroll bar pops up and shifts the background. Everything else is so clean. A great little project!
Sorin Ruse
@sorinr
Jul 29 2016 20:02
@khaduch i've seen that. but my idea was to make all the project (still unfinished) using just two html tags (an inline <span> and <input> that i cannot recreate otherwise :) i didn't paid attention to rest of aspects
Ken Haduch
@khaduch
Jul 29 2016 20:03
@sorinr - I just thought you might have some way to fix it... it's a very cool concept.
Sorin Ruse
@sorinr
Jul 29 2016 20:05
@khaduch i think its all about the background img. i'll fix it. even i will make some other versions using only tags like <a>
Ken Haduch
@khaduch
Jul 29 2016 20:17
@droidvoider - they use one of the Bootstrap classes on a div to enclose the whole page content - <div class="jumbotron">. It doesn't look like you have balanced tags to close all of your divs that you currently have. But this jumbotron div should be the next in the hierarchy after your "container" div.
@droidvoider - oh, I see that you are not using Bootstrap, or are not including it in your CSS settings. If you are trying to use Boostrap classes, then you have to include it. If you are not using bootstrap classes, then you need to mimic the setup for the "jumbotron" div, which sets the background-color to a light gray value.
backspaceit
@backspaceit
Jul 29 2016 20:25
Hello, could I get a pointer please, I'm trying to check for a property in an object, if its not there I need to then create it. But the new property is an array, this is what I have so far - else if (prop === "tracks" && collection[id].hasOwnProperty("tracks") === false) {
var newArray = [];
collection[id].push(newArray);
So the object is called correction and I want to push the "tracks" value into it as an empty array
Collection!
Nathaniel
@DeathStarGnR
Jul 29 2016 20:42
Hello, I am working on the random quote machine project. I am attempting to do it using an api, and I got my function working that pulls in the quote, but it will only work once. clicking the button a second time doesn't do anything, or if i call the function when the page loads, the button will not work at all. any pointers would be much appreciated. http://codepen.io/nsbailey2010/pen/bZrgEY
Luke
@lukenetti3
Jul 29 2016 20:45
Hi guys, I am working on the twitch.tv project. Can anyone help me get started on how I would do a live search? Read some stuff online but still don't quite understand it. http://codepen.io/lukenetti3/pen/oLEmYK?editors=1000
Luke
@lukenetti3
Jul 29 2016 20:52
@DeathStarGnR You need a random number generator after your api call. So in your function just make a random number variable and make it roughly like 30 numbers(not sure how big your son object is) and then concatenate that with the end of the url call.
@DeathStarGnR I would also advise taking your function out of the document ready call. So just have your function first, then add your document.ready call with the function name inside of it. Then after that, have your click event. Does that make sense?
Troy
@Socrates714
Jul 29 2016 20:55
I need help getting my buttons to scroll to various divs on my web page with jquery. I am on the personal portfolio page challenge. I copied and edited some code from stack overflow to the best of my abilities but it isn't working. Here is my codepen: https://codepen.io/Socrates714/pen/EybzRV
How do I get the buttons to scroll?
_
Luke
@lukenetti3
Jul 29 2016 20:55
@DeathStarGnR So ".....callback=" + randNum. This will concatenate a random quote each time.
@Socrates714 So for each section I would label it. So for your About Me I would id="section1" and so on for as many sections as you want. Then in your navbar element make an "<a>" element inside your <li> for your different headers, and put an href="#section1" in that. So when that is clicked it will take you to that section. Does that make sense?
Nathaniel
@DeathStarGnR
Jul 29 2016 20:59
@lukenetti3 Thanks. I will give a shot. I had it outside the document.ready at one point but have been moving it around trying different things. I will give the randNum thing a try, but it confuses me because the function generates a different quote each time I refresh the page, or if I call the function multiple times, but not when I click the button.
CamperBot
@camperbot
Jul 29 2016 20:59
deathstargnr sends brownie points to @lukenetti3 :sparkles: :thumbsup: :sparkles:
:cookie: 282 | @lukenetti3 |http://www.freecodecamp.com/lukenetti3
Troy
@Socrates714
Jul 29 2016 21:01
@lukenetti3 Not remotely. Can you explain more? I feel like the front end stuff didn't teach me how to do this yet.
Luke
@lukenetti3
Jul 29 2016 21:02
@DeathStarGnR Yeah because when you click the button its running the same number through each time. If you just manually enter numbers in after "callback=1" and save and refresh the page and keep changing that number. That is using a different quote. So when you refresh the page its changing the number but when you click and the function runs again its using the same number thus not changing the quote.
@Socrates714 http://v4-alpha.getbootstrap.com/components/navbar/ This explains a little better than I do. If you scroll down a little the first section of code has different lists for the headers. In each "a" element it also has an href="#" after that pounds sign, put your section id.
Troy
@Socrates714
Jul 29 2016 21:06
@lukenetti3 Thank you. I will take a look.
CamperBot
@camperbot
Jul 29 2016 21:07
socrates714 sends brownie points to @lukenetti3 :sparkles: :thumbsup: :sparkles:
:cookie: 283 | @lukenetti3 |http://www.freecodecamp.com/lukenetti3
Luke
@lukenetti3
Jul 29 2016 21:07
@Socrates714 Yeah Free Code Camp is awesome and I love it, but it does require a lot of outside reading and asking for help ha! Just learning to google things and ideas and weeding through articles will help
@Socrates714 If you really get stuck, you can look at mine a little to help you out. http://codepen.io/lukenetti3/pen/ZOzEvb
Troy
@Socrates714
Jul 29 2016 21:09
@lukenetti3 Thanks. I opened your page in a tab as well
CamperBot
@camperbot
Jul 29 2016 21:09
socrates714 sends brownie points to @lukenetti3 :sparkles: :thumbsup: :sparkles:
:warning: socrates714 already gave lukenetti3 points
Luke
@lukenetti3
Jul 29 2016 21:09
@Socrates714 No problem! Good luck!
hakimnasir
@hakimnasir
Jul 29 2016 21:11
does anyone here have experience with amazon api?
Mikail Bayram
@mikail1998
Jul 29 2016 21:12
No but maybe we can help
@hakimnasir
It cant be that different from the others :P
Troy
@Socrates714
Jul 29 2016 21:12
@lukenetti3 Ok that worked but it's scrolling to the middle of my about section rather than the top. How do I get it to scroll to the top of the about section?
hakimnasir
@hakimnasir
Jul 29 2016 21:14
@mikail1998 thanks. I just want to practice with different api's. I know a lot of api's are available publicly to use right away like yahoo weather and others. My main questions is how do you get access to amazon api. For example, if i want to use that api to look up price by UPC?
CamperBot
@camperbot
Jul 29 2016 21:14
hakimnasir sends brownie points to @mikail1998 :sparkles: :thumbsup: :sparkles:
:cookie: 230 | @mikail1998 |http://www.freecodecamp.com/mikail1998
Luke
@lukenetti3
Jul 29 2016 21:15
@Socrates714 Make sure your id to reference the section is the first thing in that sections. So the id for that section is first and then everything else in the section comes after.
Troy
@Socrates714
Jul 29 2016 21:16
@lukenetti3 Does my code not do that? I put the id in the div for the section. Should I put it for the h2?
Sorin Ruse
@sorinr
Jul 29 2016 21:16
hi there. here is a variation on using html tags. any feedback will be appreciated.: http://codepen.io/sorinr/pen/KrBmBg
Mikail Bayram
@mikail1998
Jul 29 2016 21:16
@hakimnasir http://docs.aws.amazon.com/AWSECommerceService/latest/DG/EX_LookupbyUPC.html here is some documentation about that you can check it out
Troy
@Socrates714
Jul 29 2016 21:17
@lukenetti3 Also, I just tried setting it as the h2 and it still only scrolls to the middle of the section...
Mikail Bayram
@mikail1998
Jul 29 2016 21:17
@hakimnasir there is an example of the api call and all needed info
Philip Eckert
@pae4557
Jul 29 2016 21:17
Can anybody help me with my horizontal scrolling issue? Not sure why the extra space is there, I think I've made a bootstrap error, but I can't find where my error is http://philipeckert.com
Troy
@Socrates714
Jul 29 2016 21:18
@lukenetti3 Is it that the navbar is blocking the view?
Mikail Bayram
@mikail1998
Jul 29 2016 21:18
@pae4557 could you be more specific
pleease
hakimnasir
@hakimnasir
Jul 29 2016 21:18
@mikail1998 thank you so much, do i need to sign up for aws to be able to use that api?
CamperBot
@camperbot
Jul 29 2016 21:18
hakimnasir sends brownie points to @mikail1998 :sparkles: :thumbsup: :sparkles:
:warning: hakimnasir already gave mikail1998 points
Manjot Singh
@msingh18
Jul 29 2016 21:18
Hello everyone, I am working on the Local Weather challenge. The website says the API data is available in different formats such as XML, JSON or HTML. How do you specify the type of format you want to choose?
Philip Eckert
@pae4557
Jul 29 2016 21:19
@mikail1998 Yeah. So when the page loads all the content is there, but there is a horizontal scrollbar added to my page that I don't want
Mikail Bayram
@mikail1998
Jul 29 2016 21:19
@hakimnasir there is a button("try now for free"), you can use that
Philip Eckert
@pae4557
Jul 29 2016 21:20
I've seen the same issue before with other's sites and it was an issue with bootstrap but I can't figure out where I've gone wrong
Mikail Bayram
@mikail1998
Jul 29 2016 21:20
@pae4557 do you have an codepen version of the page?
Philip Eckert
@pae4557
Jul 29 2016 21:20
@mikail1998 Unfortunately, no
Mikail Bayram
@mikail1998
Jul 29 2016 21:21
did you put your width to 100% or did you use pixels?
Philip Eckert
@pae4557
Jul 29 2016 21:22
hmmm... let me check. Can you view source or should I download all the files and upload them to codepen?
My issue is that on codepen I can't host the images
Mikail Bayram
@mikail1998
Jul 29 2016 21:23
just a sec let me see i will inform you
mnghm
@mnghm
Jul 29 2016 21:23
Using a 6 span col in bootstrap, using ul list and bullets are far left whilst text is center, want it all center.. any tips?
Mikail Bayram
@mikail1998
Jul 29 2016 21:23
@pae4557 yeah I know it freaks me out too
Philip Eckert
@pae4557
Jul 29 2016 21:23
@mikail1998 OH
For some reason, I had navbar width set to 101% lolololol
@mikail1998 Thanks!
CamperBot
@camperbot
Jul 29 2016 21:23
pae4557 sends brownie points to @mikail1998 :sparkles: :thumbsup: :sparkles:
:cookie: 231 | @mikail1998 |http://www.freecodecamp.com/mikail1998
Philip Eckert
@pae4557
Jul 29 2016 21:23
Man that was a dumb error
Mikail Bayram
@mikail1998
Jul 29 2016 21:24
Im so glad I could help
Philip Eckert
@pae4557
Jul 29 2016 21:24
@mikail1998 Yeah I would have never found that but the width thing made me cmd+f "width" and I saw it immediately
Mikail Bayram
@mikail1998
Jul 29 2016 21:25
AHAHAHAHAHAHAHAHA that tiny little 1 made a big impact :D
Troy
@Socrates714
Jul 29 2016 21:26
Ok so I got my buttons mostly working, but they still scroll to slightly below the top of my headers. How do I get the buttons to stop cutting off the top of my text?
Luke
@lukenetti3
Jul 29 2016 21:33
@Socrates714 I'm not sure. Maybe just move your text down a little bit.
Troy
@Socrates714
Jul 29 2016 21:45
@lukenetti3 Hmm. I have been playing with it and can't fix it. I will come back to it later. Thank's for your help!
CamperBot
@camperbot
Jul 29 2016 21:45
socrates714 sends brownie points to @lukenetti3 :sparkles: :thumbsup: :sparkles:
:warning: socrates714 already gave lukenetti3 points
Michael Smith
@droidvoider
Jul 29 2016 22:05
Today when I started the challenge Build a Tribute page I thought it would be easy.. But I have to admit I have fought all day and still I will need more tweaking.. I'm learning a lot more from a simple tribute page than I thought I would lol
Ivan Temchur
@ttemcha
Jul 29 2016 22:09
@droidvoider give me a link please to the project
Michael Smith
@droidvoider
Jul 29 2016 22:12
It's not done yet but I did link it above..
@ttemcha thanks and let me know if i'm confused.. i think you can see my stuff on codepen.io
CamperBot
@camperbot
Jul 29 2016 22:14
droidvoider sends brownie points to @ttemcha :sparkles: :thumbsup: :sparkles:
:cookie: 295 | @ttemcha |http://www.freecodecamp.com/ttemcha
John Doe
@codingisfun11
Jul 29 2016 22:23
How come this code works?
blob
Sorin Ruse
@sorinr
Jul 29 2016 22:33
hi there. here is a variation on using html tags. any feedback will be appreciated.:http://codepen.io/sorinr/pen/oLrWQa and the originl pen is here: http://codepen.io/sorinr/pen/YWjkZx
elminsterrr
@elminsterrr
Jul 29 2016 22:42
Hi, Is here someone good with JS loops?
matthew3454
@matthew3454
Jul 29 2016 22:51

Help. My code for da calculadora app woon't wurk. Tanks! Here Sha go:http://codepen.io/codeabode20/pen/PzaGmB

Especificamente dhe bootons por dhe "myanus", "doodyvision", ant dhe "hecool" signs doodynoon't woourk. Tanks! Preciate it. Lool

CamperBot
@camperbot
Jul 29 2016 22:51
no wiki entry for: my code for da calculadora app woont wurk tanks here sha gohttpcodepeniocodeabode20penpzagmbespecificamente dhe bootons por dhe myanus doodyvision ant dhe hecool signs doodynoont woourk tanks preciate it lool
Nathaniel
@DeathStarGnR
Jul 29 2016 23:11
Can anyone tell me why my function will only run once and not every time I click the button? http://codepen.io/nsbailey2010/pen/bZrgEY
Gary Siu
@GarySiu
Jul 29 2016 23:18
@DeathStarGnR Seems ok to me?
Nathaniel
@DeathStarGnR
Jul 29 2016 23:20
@GarySiu me too. I am stumped on this one.
Gary Siu
@GarySiu
Jul 29 2016 23:20
I mean I click the button a few time and it seems like it works
Nathaniel
@DeathStarGnR
Jul 29 2016 23:22
@GarySiu really? hmm. for me it only works the first time. Maybe I will try it in a different browser and see what happens.
Gary Siu
@GarySiu
Jul 29 2016 23:22
Hm. I forked your pen and put in a console log and it worked.
Went back to your pen and it stopped
Nathaniel
@DeathStarGnR
Jul 29 2016 23:23
@GarySiu weird.
Gary Siu
@GarySiu
Jul 29 2016 23:24
hmmmmmm
console.log(randNum); gives NaN
Math.random is a function
Math.floor won’t work on it
Math.random() will give a number between 0 and 1. Math.floor would convert that to 0
Maybe the console.log makes it evaluate and then the API handles it? :P
Nathaniel
@DeathStarGnR
Jul 29 2016 23:28
good point. I'm not sure the randNum is necessary. It seems to function the same without it. I will fix it though and see what happens.
Gary Siu
@GarySiu
Jul 29 2016 23:28
@DeathStarGnR You probably intended this: var randNum = Math.floor(Math.random() * 100);
soroush behmardi
@soori8
Jul 29 2016 23:28
hi, I'm in Build a Random Quote Machine project But i don't know where can i have a Quote API.
Gary Siu
@GarySiu
Jul 29 2016 23:29
There are a lot of different quote apis. Do you have any interests?
Nathaniel
@DeathStarGnR
Jul 29 2016 23:30
@GarySiu OMG i think that fixed it!!!
Gary Siu
@GarySiu
Jul 29 2016 23:30
The random number or not using the random number?
Nathaniel
@DeathStarGnR
Jul 29 2016 23:31
@soori8 I am using the Quotes on design Api. it seems to be doing well. Had some trouble with forismatic.
Peter Kenward
@PeterKenward
Jul 29 2016 23:31
Nathaniel
@DeathStarGnR
Jul 29 2016 23:32
@GarySiu with the random number, correcting the syntax.
Gary Siu
@GarySiu
Jul 29 2016 23:32
I seen a few people use this one: http://www.icndb.com/api/
Nathaniel
@DeathStarGnR
Jul 29 2016 23:33
@soori8 https://quotesondesign.com/api-v4-0/ the link to the one I am using
@GarySiu who would have thought a couple of little parentheses could cause so much trouble. lol.
soroush behmardi
@soori8
Jul 29 2016 23:34
@PeterKenward @DeathStarGnR thanks so much
CamperBot
@camperbot
Jul 29 2016 23:34
soori8 sends brownie points to @peterkenward and @deathstargnr :sparkles: :thumbsup: :sparkles:
:cookie: 282 | @deathstargnr |http://www.freecodecamp.com/deathstargnr
:cookie: 285 | @peterkenward |http://www.freecodecamp.com/peterkenward
Gary Siu
@GarySiu
Jul 29 2016 23:36
@DeathStarGnR It happens a lot when you’re starting out. Backtrack and check your values are what you think they are with devtools/console.log
Nathaniel
@DeathStarGnR
Jul 29 2016 23:41
@soori8 any time. @GarySiu good advice. gonna take a break for a while. Thank you so much.
CamperBot
@camperbot
Jul 29 2016 23:41
deathstargnr sends brownie points to @soori8 and @garysiu :sparkles: :thumbsup: :sparkles:
:cookie: 19 | @soori8 |http://www.freecodecamp.com/soori8
:cookie: 163 | @garysiu |http://www.freecodecamp.com/garysiu
soroush behmardi
@soori8
Jul 29 2016 23:43