These are chat archives for FreeCodeCamp/HelpFrontEnd

20th
Jan 2017
JD Tadlock
@jdtdesigns
Jan 20 2017 00:05
@FatTone225 I added some css to the score display and changed some js for the scroll function. Hope this helps. ;) http://codepen.io/jdtadlock/pen/dNvpeg?editors=0010
Tony Miri
@TonyMiri
Jan 20 2017 00:08
@jdtdesigns Wow. That looks really good! Thank you!
CamperBot
@camperbot
Jan 20 2017 00:08
fattone225 sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
:cookie: 862 | @jdtdesigns |http://www.freecodecamp.com/jdtdesigns
JD Tadlock
@jdtdesigns
Jan 20 2017 00:08
@FatTone225 Welcome!
on some phones it looks weird
reyscott1968
@reyscott1968
Jan 20 2017 00:48
why does my page doesnt look like the sample given ??
Chiu Yong
@chiuyong
Jan 20 2017 00:49
can somebody help me ?
reyscott1968
@reyscott1968
Jan 20 2017 00:49
Pranay Kumar
@pranaykumar389
Jan 20 2017 00:50
Hello everyone!
I'm making a simple Angular Web Page. For Routing I'm using Angular-ui-router. When I click on Home, About, Contact the templates are not loading. Can someone please help me with my Mistake? Here is the link for plunker https://plnkr.co/edit/8LlDl08JVbQKiD5eWEah?p=preview
reyscott1968
@reyscott1968
Jan 20 2017 00:57
no one is here i guess
cms202
@cms202
Jan 20 2017 01:14
Hi there. Can anyone help me with how to set an image in the middle of a page? Working on my tribute page. Thanks tons :smile:
reyscott1968
@reyscott1968
Jan 20 2017 01:17
import the bootstrap
follow the sample on freecodecamp. if it doesnt look like same on the one on freecodecamp then u may wanna check your bootstrap @cms202
Tyler Moeller
@TylerMoeller
Jan 20 2017 01:21
@reyscott1968 If you want an exact copy, fork the page. It's recommended not to look at the code in the project until you try to build the project on your own. :)
reyscott1968
@reyscott1968
Jan 20 2017 01:24
i guess i rili have to do that @TylerMoeller
Tyler Moeller
@TylerMoeller
Jan 20 2017 01:24
@cms202 You can use bootstrap grid offsets or the center-block class to center an image.
http://getbootstrap.com/css/#grid-offsetting
http://getbootstrap.com/css/#images
Derek
@dfketcher
Jan 20 2017 01:24
has anyone completed the portfolio webpage?
Tyler Moeller
@TylerMoeller
Jan 20 2017 01:25
yes :)
Derek
@dfketcher
Jan 20 2017 01:25
I'm a little lost on what to do....are we just strictly using HTML
or should we dive in and use CSS and JS as well
Tyler Moeller
@TylerMoeller
Jan 20 2017 01:25
You can use HTML, CSS, and JavaScript
You'll likely have to go back later to add more to it as you learn more
reyscott1968
@reyscott1968
Jan 20 2017 01:25
same here. im kinda overwhelmed.. lol. i dnt think i can make it
Derek
@dfketcher
Jan 20 2017 01:25
gotcha
yea it seems like a lot I have a good handle on html and CSS but it was just a bit intimidating seeing the project
Tyler Moeller
@TylerMoeller
Jan 20 2017 01:27
I think they say to budget 50 hours for building your tribute page and portfolio
Derek
@dfketcher
Jan 20 2017 01:29
yea i'd be lucky if I finish it by that time haha, but sometimes once you get the ball rolling it helps
Thanks for the answers tyler have a good one
Tyler Moeller
@TylerMoeller
Jan 20 2017 01:35
np, good luck :+1:
Jakory Dozier
@NAYBOURsound
Jan 20 2017 01:36
any know what a class is?
like i feel like it’s something really simple to understand but for some reason it’s not clicking
Tyler Moeller
@TylerMoeller
Jan 20 2017 01:37
@NAYBOURsound You may want to sign up for Free Code Camp and start doing the challenges to learn more. https://www.freecodecamp.com/challenges/use-a-css-class-to-style-an-element
Jakory Dozier
@NAYBOURsound
Jan 20 2017 01:38
i,ve signed up
Tyler Moeller
@TylerMoeller
Jan 20 2017 01:38
A class is a way to style an element or use it via JavaScript. The challenge I linked above will help you get started
Jakory Dozier
@NAYBOURsound
Jan 20 2017 01:39
thank u
Edgar Pan
@edgaryp
Jan 20 2017 01:48
Hi
What I have missed with my code please?
function Fruit (theColor, theSweetness, theFruitName, theNativeToLand) {
  this.color = theColor;
  this.sweetness = theSweetness;
  this.fruitName = theFruitName;
  this.nativeToLand = theNativeToLand;
  this.showName = function () {
    console.log("This is " + this.fruitName);
  };
  this.nativeTo = function () {
    this.nativeToLand.forEach(function (eachCountry)  {
      console.log("Grown in:" + eachCountry);
    });
  };
}
var kiwiFruit = new Fruit (green, 4, kiwi, ["NewZealand", "Australia"]);
console.log(kiwiFruit.showName());
ah found it
Phillip Kelley-Dotson
@pkdotson
Jan 20 2017 02:06
What background image or icon did you guys use for your weather app?
i'm trying to use skycons but having a hard time implementing it
ConorsCode
@ConorsCode
Jan 20 2017 02:09
Hey everyone. I'm having some trouble customizing a bootstrap navbar that scales appropriately, and the menu not opening for a mobile size when minimized. (the hamburger drop down) I was messing around with trying to style a custom navbar, I also realize my navbar-brand gets all messed up. Not really sure what's wrong with my code as right now it's just trial and error. Any input? http://codepen.io/Achillesisabro/pen/bBpbym
like, the brand doesn't stay left it just pulls over as im resizing. it's like custom styling the nav creates havoc
cms202
@cms202
Jan 20 2017 02:18
@reyscott1968 I tried to follow FCC sample. I'll try the second suggestion you gave. Let you know. :)
Manuel Almeida
@netstudenton
Jan 20 2017 02:20
Hello i'm trying to do the lest Intermediate challenge. My code passed almost all test except the last on indicated in the last line.
what wrong did I do?
function addTogether(x) {
    if (arguments.length<=2){

        if(arguments.length===2 && (typeof(arguments[0])=='number' && typeof(arguments[1])=='number')){
            return arguments[0]+arguments[1];
        }
           if(arguments.length===1 && (typeof(arguments[0])=='number')){
            return function(y){
                return y+x;
            };
        }
    }
return undefined;
}

addTogether(2)([3]);  //<====== THIS TEST CAN'T PASS
JD Tadlock
@jdtdesigns
Jan 20 2017 02:34
@netstudenton Might be because it's an array and not a number?
Manuel Almeida
@netstudenton
Jan 20 2017 02:42
@jdtdesigns I found out it before read ! But thank anyway !!
CamperBot
@camperbot
Jan 20 2017 02:42
netstudenton sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
:cookie: 863 | @jdtdesigns |http://www.freecodecamp.com/jdtdesigns
Manuel Almeida
@netstudenton
Jan 20 2017 02:44
@jdtdesigns Please tell if it was a dumb aks for help . In the other chat a guy tell to search on google .
that Joseph make me feel sad
Tyler Moeller
@TylerMoeller
Jan 20 2017 03:09
@pkdotson Lots of people use these icons: https://erikflowers.github.io/weather-icons/
JD Tadlock
@jdtdesigns
Jan 20 2017 03:19
@netstudenton It's never dumb to ask. I will say, that if you say the problem out loud to yourself, you'll think of the solution a lot of times without needing to ask.
But when you can't figure something out, always ask. ;)
or search
Ken Haduch
@khaduch
Jan 20 2017 03:49
@ConorsCode - one thing that you need to make this work is to load jquery.js and bootstrap.js, those are needed for the bootstrap-style navbar and collapse /expand function.
@ConorsCode - just adding those two, in the JS config panel, with Jquery first and bootstrap.js second should make your collapsed menu expand.
jaghvi
@mehtajaghvi
Jan 20 2017 04:01
Hi I have a question, We say that document ready functions executes the JS once the page is loaded, then how are functions like on_click executed if this is not running in an infinte loop?
Ken Haduch
@khaduch
Jan 20 2017 04:12
@mehtajaghvi - your question is not clear to me? document ready executes the block of code that it contained within its callback function once the page is loaded. It only will execute one time. If you establish callback handlers for things like "click" or mouse events, etc. those will get called as the events occur, but it is not really in an "infinite loop"? Maybe I'm not getting the gist of your question?
Kantra
@removed~kantrakantra
Jan 20 2017 04:16

Can anybody help me figure out why my "menu" links (the little circles on the left) aren't adding the ".active" class when clicked, and changing to their respective styling when active. Also the first menu circle breaks after you scroll or click to a section below section 1

https://codepen.io/kantrakantra/pen/egvvZd

I'm getting some majorly weird styling on the active link (lines, spacing, etc.)

Sam Griffen
@ssgriffen
Jan 20 2017 04:23

@ssgriffen
Anyone know why my current console.log equation is evaluating to false?
@jkdjf
Escape Sequences in Strings
i m not being able to write code in that
@Garabed96
is that the q name
@EzraPlato
What did I do wrong? Another typo? Am I dislexic?
// Setup
var outerWear = "T-Shirt";

function myOutfit() {
// Only change code below this line
var myOutfit = "sweater";

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

myOutfit();
@jkdjf
waht is way the of write
@EzraPlato
Should return sweater
@Garabed96
FirstLine\n\\SecondLine\\\r\ThirdLine
idk how i could help u with that without the answer tbh
@revisualize
You have to assign 'FirstLinenewlinebackslashSecondLinebackslashcarriage-returnThirdLine' to the variable myStr.
But, you have to replace the words with the proper escape sequences.
How do you escape a newline? With: \n
How do you escape a backslash? With: \\
How do you escape a carriage-return? With \r
So, you have break the problem down.
FirstLinenewlinebackslashSecondLinebackslashcarriage-returnThirdLine
FirstLine\nbackslashSecondLinebackslashcarriage-returnThirdLine
FirstLine\n\\SecondLinebackslashcarriage-returnThirdLine
FirstLine\n\\SecondLine\\carriage-returnThirdLine
FirstLine\n\\SecondLine\\\rThirdLine
And you assign that to myStr as a string.
@Garabed96 You actually did it wrong.
@Garabed96
@revisualize it works...
@revisualize
@Garabed96 Okay.
@Garabed96
whats wrong with it
oh u mean for my code
or are you talking about the answer i gave him?
@revisualize
@Garabed96 You have a \ before ThirdLine which doesn't need to be there.
@jroper19

var count = 0;

function cc(card) {
  // Only change code below this line


  return "Change Me";
  // Only change code above this line
}

// Add/remove calls to test your function.
// Note: Only the last will display
cc(2); cc(3); cc(7); cc('K'); cc('A');

Can anyone tell me the purpose of the "var count" line in this?
@revisualize
@Garabed96 I'm just posting the answer because the guy is an ass and impatient.
@jroper19 Yeah. It is a global variable.
@jroper19 It tells you about the global variable in the instructions.
@Garabed96
@revisualize thanks for letting me know
@camperbot

garabed96 sends brownie points to @revisualize :sparkles: :thumbsup: :sparkles:
:star2: 3062 | @revisualize |http://www.freecodecamp.com/revisualize
@Garabed96
seemed redundant
good that i k the right way now
@revisualize
@jroper19 I've taken the time to rewrite the instructions for that challenge.
Counting Cards is a challenge where your function will receive a card parameter. You're supposed to increment or decrement the global count variable according to the card's value
If the value of the card parameter is 2, 3, 4, 5 or 6 you need to increment the global variable count.
If the value of the card parameter is 10, 'J', 'Q', 'K' or 'A' you need to decrement the global variable count.
Then the function will return a string with the current count and the string "Bet" if the count is positive, or "Hold" if the count is zero or negative.
The current count and the player's decision ("Bet" or "Hold") should be separated by a single space.
@jroper19
@revisualize Yeah, I've read it a couple times but i dont kmow what its actually doing lol
@revisualize
@jroper19 It's a global variable.
@jroper19 It needs to stay persistent each time the function runs.
http://codepen.io/ssgriffen/pen/vgLjYX?editors=1012

CamperBot
@camperbot
Jan 20 2017 04:23
ssgriffen sends brownie points to @jkdjf and @garabed96 and @ezraplato and @revisualize and @jroper19 and @camperbot :sparkles: :thumbsup: :sparkles:
:cookie: 242 | @garabed96 |http://www.freecodecamp.com/garabed96
:cookie: 169 | @ezraplato |http://www.freecodecamp.com/ezraplato
:cookie: 129 | @jkdjf |http://www.freecodecamp.com/jkdjf
:cookie: 201 | @jroper19 |http://www.freecodecamp.com/jroper19
:star2: 2910 | @camperbot |http://www.freecodecamp.com/camperbot
:star2: 3063 | @revisualize |http://www.freecodecamp.com/revisualize
why is one of the images munted
JD Tadlock
@jdtdesigns
Jan 20 2017 04:30
@SimpleRoger It's not in a col like the others
SimpleRoger
@SimpleRoger
Jan 20 2017 04:33
ah i see
Dan Hisey
@dchisey
Jan 20 2017 04:38
hey all! i'm having some issues with the navbar on my personal portfolio page. i want the nav to be right justified and then collapse when the screen is shrunk. for the life of me i can't get it to work and i don't understand the documentation
Tim Ardan
@tim-ardan
Jan 20 2017 04:43
I want to make sure I understand this correctly. In the "Sum All Primes" challenge, are we to program a function to find primes or are we to just go get a list of primes and sum them?
JD Tadlock
@jdtdesigns
Jan 20 2017 04:49
@dchisey Remove <body> from the html. That's added by codepen. You need to add jQuery and bootstrap js in Settings->JS->Quick Add. Make sure jQuery is above Bootstrap. The nav code should look like this:
<nav class="navbar navbar-default navbar-fixed-top navbar-inverse">
  <div class="container-fluid">

    <div class="navbar-header">
      <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1" aria-expanded="false">
        <span class="sr-only">Toggle navigation</span>
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
      </button>
      <a class="navbar-brand" href="#">Brand</a>
    </div>

    <div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">

      <ul class="nav navbar-nav navbar-right">
        <li class="active"><a href="#home">Home</a></li>
        <li><a href="#my-projects">Projects</a></li>
        <li><a href="#contact-me">Contact Me</a></li>
        <li><a href="#">Social</a></li>
      </ul>
    </div><
  </div>
</nav>
The <link> should also be moved to Settings->HTML->Stuff for Head
@tim-ardan You get the primes and sum them
Tim Ardan
@tim-ardan
Jan 20 2017 04:52
Just get a list? Well, that's going to make it a lot easier!
Thanks @jdtdesigns
CamperBot
@camperbot
Jan 20 2017 04:52
tim-ardan sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
:cookie: 864 | @jdtdesigns |http://www.freecodecamp.com/jdtdesigns
Dan Hisey
@dchisey
Jan 20 2017 04:57
@jdtdesigns Thanks JD! So I've removed <body> from the html. I added jQuery and Bootstrap to JS, and replaced the code. That definitely fixed the formatting when it expands. How do I get the hamburger to expand with the menu options though? I'm still missing that part along with linking to different parts of the page
CamperBot
@camperbot
Jan 20 2017 04:57
dchisey sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
:cookie: 865 | @jdtdesigns |http://www.freecodecamp.com/jdtdesigns
Dan Hisey
@dchisey
Jan 20 2017 04:58
oh wait, scratch that last part...it's linking to the other parts
but how can i get the hamburger to open into a menu
JD Tadlock
@jdtdesigns
Jan 20 2017 04:59
@dchisey Just move jQuery above Bootstrap in Settings->JS
Bootstrap js requires jQuery to work
Also, remove the nav styles you added in css.
Sam
@Samwise12
Jan 20 2017 05:00
Does anyone know how to randomly generate a route? i.e. localhost:8080/<random>
JD Tadlock
@jdtdesigns
Jan 20 2017 05:02
@SimpleRoger Why would you need a random route?
Dan Hisey
@dchisey
Jan 20 2017 05:02
oh wow. thanks so much @jdtdesigns
CamperBot
@camperbot
Jan 20 2017 05:02
dchisey sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
:warning: dchisey already gave jdtdesigns points
JD Tadlock
@jdtdesigns
Jan 20 2017 05:08
@Samwise12 FakerJS can create random uuid's easily https://cdnjs.com/libraries/Faker
var route = faker.random.uuid();

console.log(route);
Alexander Huynh
@caesarsalad93
Jan 20 2017 05:51
Is it okay to use <br> tags to include a line break in html?
Nirmal Patel
@nirmpate
Jan 20 2017 05:54
@caesarsalad93 Typically in modern web design you wouldn’t want your html to have <br> tags. Larger projects will look very unclean and messy if your using a lot of them. I would recommend using paddings and margins to get the same effect.
Sorin Ruse
@sorinr
Jan 20 2017 05:56
@caesarsalad93 i would try to avoid it. use display: block in css
Gordon
@kklgordon
Jan 20 2017 07:06
Hi guys, got a quick question. I build my personal web portfolio page on codepen and it looks perfectly fine in computer (navbar stayed at the top, scrollspy is working). But how come why it does not work if I look at the same page using mobile?
SimpleRoger
@SimpleRoger
Jan 20 2017 07:11
@SimpleRoger
have i skipped part of the course?
i don't know how to any of the challenges
A tribute page and a personal portfolio
i'm cluelesss
i think i've done everything before it
i don't know how to make a nav bar
and a lot of other things
i don't know javascript as well
deepakSpatil
@deepakSpatil
Jan 20 2017 07:15
{
  "has": "User 1",
  "prefers": "External Ip 0",
  "count": "1",
  "color": "skyblue"
},{
  "has": "User 1",
  "prefers": "External Ip 1",
  "count": "1",
  "color": "skyblue"
}
any idea wat is wrong in this json as i am getting invalid json error
SimpleRoger
@SimpleRoger
Jan 20 2017 07:16
@kklgordon how did you make your personal page
i've got no clue
on how to make any of it
it's not covered in the course
kirbyedy
@kirbyedy
Jan 20 2017 07:17
@SimpleRoger read, search ask
google is your friend
nobody expect you to know everything
it is normal, we all went through that stage
hell, I am still in that stage :P
Muhammad Hasham
@MohammadHasham
Jan 20 2017 07:18
you are not at that stage.If you are at that stage then i haven't started anything.
@kirbyedy
SimpleRoger
@SimpleRoger
Jan 20 2017 07:19
how did you do it
it's hard as
which site do i rely on
Gordon
@kklgordon
Jan 20 2017 07:20

@SimpleRoger

The good thing about FCC which I like is the project is not hand-holding. For me, the FCC course before the project challenges taught you the framework of how html, css and bootstrap works. And now you can start construction your site and search for stuff that you dont know

kirbyedy
@kirbyedy
Jan 20 2017 07:20
@SimpleRoger most answers you will find by googling
Gordon
@kklgordon
Jan 20 2017 07:20
for example: Navbar wasnt covered in the course, but you can google it.
Since you already understand how the framework of bootstrap is - You can learn by googling the answer
SimpleRoger
@SimpleRoger
Jan 20 2017 07:20
that's a lot of googling
am i right
Gordon
@kklgordon
Jan 20 2017 07:20
Best way to learn
You already know its called a Navbar - so it is quite straight forward
SimpleRoger
@SimpleRoger
Jan 20 2017 07:21
like i know it but i don't know it thoroughly
Gordon
@kklgordon
Jan 20 2017 07:21
It gets tricky when you dont even know what you are searching for
SimpleRoger
@SimpleRoger
Jan 20 2017 07:21
i know little bits
Gordon
@kklgordon
Jan 20 2017 07:22
Yea then google you way out - if you google navbar is should gives you site like w3school which basically explain the whole logic
it* not is
SimpleRoger
@SimpleRoger
Jan 20 2017 07:23
what does your portfolio page look like
Gordon
@kklgordon
Jan 20 2017 07:25

http://codepen.io/kklgordon/pen/bgBwwp

photos are supposed to be deadline since I dont wanna upload a photo and I dont have a portfolio yet

SimpleRoger
@SimpleRoger
Jan 20 2017 07:26
that's a very beautiful page
Suresh Manimaran
@thisisSuresh
Jan 20 2017 07:42
How to start with tributepage project?
SimpleRoger
@SimpleRoger
Jan 20 2017 07:44
@SimpleRoger
why building your portfolio did any of you know javascript
when
Gordon
@kklgordon
Jan 20 2017 07:47
@SimpleRoger Not for me lol
Sorin Ruse
@sorinr
Jan 20 2017 07:57
@kklgordon try to use some placeholder imgs
@thisisSuresh pick a subject. "grab" some info (imgs, text, etc) from internet. put them on a page using common html tags like div, p, img. then go style the html structure in css
Dipal Gudhka
@dipalgudhka
Jan 20 2017 08:13
Hello
How can I access JSON objects
If you click that and parse the json, I want to acces the ids
Sorin Ruse
@sorinr
Jan 20 2017 08:24
@dipalgudhka how have you named it in the callback function of your api call? lets say you have $.getJSON('that ur you posted abovel', function(response) ). then you can iterate through the response and show what you want
Dipal Gudhka
@dipalgudhka
Jan 20 2017 08:26
How do you iterate, lets say I want the first part, how will i access it?
@sorinr
api.query.pages[number], but each number is different, so how will I access it?
Sorin Ruse
@sorinr
Jan 20 2017 08:28
@dipalgudhka use the each or forEach function to go through the pages in the response
Dipal Gudhka
@dipalgudhka
Jan 20 2017 08:30
@sorinr let me try
Sorin Ruse
@sorinr
Jan 20 2017 08:30
@dipalgudhka giving u the full solution will not help u at all. :+1:
Dipal Gudhka
@dipalgudhka
Jan 20 2017 08:32
@sorinr :+1: Thanks
CamperBot
@camperbot
Jan 20 2017 08:32
dipalgudhka sends brownie points to @sorinr :sparkles: :thumbsup: :sparkles:
:star2: 1118 | @sorinr |http://www.freecodecamp.com/sorinr
Dipal Gudhka
@dipalgudhka
Jan 20 2017 08:32
@sorinr I will come back to you if I'm still confused
Sorin Ruse
@sorinr
Jan 20 2017 08:33
@dipalgudhka welcome. if u stuck just ask :)
@dipalgudhka am sure you will do it
sathish95
@sathish95
Jan 20 2017 08:38
hello guys could any one suggest the api to get the weather report based on latitude and longitude
kirbyedy
@kirbyedy
Jan 20 2017 08:39
@sathish95 darksky or wunderground
Sorin Ruse
@sorinr
Jan 20 2017 08:41
@sathish95 there r plenty of free weather apis but the most important thing is how do u plan to get the location(lat and lon) coordinates?
sathish95
@sathish95
Jan 20 2017 08:41
ya iam using latitude and longitude to get weather report
Sorin Ruse
@sorinr
Jan 20 2017 08:42
@kirbyedy apixu.com its also working on free plan both http and https
kirbyedy
@kirbyedy
Jan 20 2017 08:42
cool :thumbsup:
sathish95
@sathish95
Jan 20 2017 08:42
thanks
Sorin Ruse
@sorinr
Jan 20 2017 08:42
@sathish95 how do u get that lat and lon its important
sathish95
@sathish95
Jan 20 2017 08:43
i get through using this api http://freegeoip.net/json/
Sorin Ruse
@sorinr
Jan 20 2017 08:48
@sathish95 using that api means you make all other calls using http. all weather apis r working over http. the only problem you will encounter using ip location is that if a user have a dynamic ip very surely the location reported will be wrong. for a more precisely you can use navigator.location but it has the downturn of working only on https so you must choose a weather api supporting https calls :)
kirbyedy
@kirbyedy
Jan 20 2017 08:49
oh crap, I just typed the wrong password for my github account, and now this apixu does not let me in... damn it
Sorin Ruse
@sorinr
Jan 20 2017 08:51
@kirbyedy see that u also have a registration form below the social media btns. just scroll down
sathish95
@sathish95
Jan 20 2017 08:54
thanks sorin ruse it really working great and i used city name instead of latitude and longitude and i will concern our view regarding getting latitude and location
kirbyedy
@kirbyedy
Jan 20 2017 08:54
@sorinr yea, but I would prefer to use my github account
I guess I would have to clear the cookies maybe
and cache
Philipp Scholz
@philipp32
Jan 20 2017 08:55
Hey, short question. How can I animate an object to move upwards in CSS? With keyframes?
kirbyedy
@kirbyedy
Jan 20 2017 08:55
transform?
Sorin Ruse
@sorinr
Jan 20 2017 08:57
@kirbyedy yes. try that. i had no problem with that api. but sincerely i don't remember how i did registered wityh them :)
Muhammad Hasham
@MohammadHasham
Jan 20 2017 09:00
@sorinr
kirbyedy
@kirbyedy
Jan 20 2017 09:00
the funny thing is, I think I already visited that site before, seems familiar :)
Muhammad Hasham
@MohammadHasham
Jan 20 2017 09:01
function greaterThan(n) 
{ return function(m) 
 { return m > n; }; 

}
 var greaterThan10 = greaterThan(10);
 console.log(greaterThan10(11)); // → true
why does it not work when i name the inner function
is it true that higher order functions when given an inner function should ke kept annonoymus
Philipp Scholz
@philipp32
Jan 20 2017 09:05
Hey, how can I trigger a CSS keyrame on the click of a button with JS?
Sorin Ruse
@sorinr
Jan 20 2017 09:43
@philipp32 if you mean keyframe i would create a class for that and apply that class using js
Darth Skywalker
@adityaparab
Jan 20 2017 09:49
@MohammadHasham : I don't think it doesn't work when you name the inner function. It should work regardless of whether you name inner function
function greaterThan(n) { 
  return function Test(m) {
    return m > n;
  }; 
}

var greaterThan10 = greaterThan(10);

console.log(greaterThan10(11)); //true
console.log(greaterThan10(4)); //false
Muhammad Hasham
@MohammadHasham
Jan 20 2017 09:50
I tried that
but it works when giving value to puter function twice
😅
SimpleRoger
@SimpleRoger
Jan 20 2017 09:56
hey guys i wanna see some of your personal portfolio pages
just looking for some inspiration
if you get what i mean
Sorin Ruse
@sorinr
Jan 20 2017 10:02
@adityaparab where is the m parameter in there? and think what var greaterThan10 = greaterThan(10); will hold as a value
Sorin Ruse
@sorinr
Jan 20 2017 10:08
@SimpleRoger google for free code camp portfolio and u will see plenty of it :)
jaghvi
@mehtajaghvi
Jan 20 2017 10:10
I do not like the json tutorial, not sure what is going on, who can we tell to rectify this
Sorin Ruse
@sorinr
Jan 20 2017 10:13
@mehtajaghvi i would just go and search for using json.
@mehtajaghvi read on your own as much as you can. don't rely only on fcc data
badalsaibo
@heyDante
Jan 20 2017 10:15
@mehtajaghvi you tried w3schools
jaghvi
@mehtajaghvi
Jan 20 2017 10:16
@khaduch This is the answer I was looking for, how is this callback executed when events occur when java script is already done processing the code
@sorinr @heyDante whats the point of freecodecamp if I had to learn from w3
badalsaibo
@heyDante
Jan 20 2017 10:17
FCC is just showing directions. You need to follow up some resources alternatively for a better understanding.
Sorin Ruse
@sorinr
Jan 20 2017 10:20
@mehtajaghvi w3 have its + and - . fcc gives u some projects to work on. but in the end it all depends on your motivation to learn
jaghvi
@mehtajaghvi
Jan 20 2017 10:22
@sorinr they have really good basic tutorials for html, css and JS, I was expecting something similar, and ofcourse I can always refer to other websites to learn more but I was hoping they had keep the level
anyway, I am sure the next tasks will take care of that
Sorin Ruse
@sorinr
Jan 20 2017 10:24
@mehtajaghvi w3 have a lot of stuff that its not much updated
Chaitanya thakre
@Chaitanya009
Jan 20 2017 10:52
I'm trying to add another image below my first image but it is not working https://codepen.io/Chaitanya009/pen/eggPXX
Dipal Gudhka
@dipalgudhka
Jan 20 2017 10:58
@sorinr i solved it, thanks
CamperBot
@camperbot
Jan 20 2017 10:58
:star2: 1119 | @sorinr |http://www.freecodecamp.com/sorinr
dipalgudhka sends brownie points to @sorinr :sparkles: :thumbsup: :sparkles:
You seem to use a lot of inline styling as well.
Sorin Ruse
@sorinr
Jan 20 2017 11:05
@Chaitanya009 if you not registered your pics will expire after some time :)
Chaitanya thakre
@Chaitanya009
Jan 20 2017 11:06
I can still see it
Sorin Ruse
@sorinr
Jan 20 2017 11:08
@Chaitanya009 you still see it coz its cached on locally :) just try the link above mentioned by @oppiniated
Chaitanya thakre
@Chaitanya009
Jan 20 2017 11:14
@sorinr yeah ur right
Sorin Ruse
@sorinr
Jan 20 2017 11:17
@Chaitanya009 now your job is making that img appear again :)
Chaitanya thakre
@Chaitanya009
Jan 20 2017 11:19
@sorinr now see
Sorin Ruse
@sorinr
Jan 20 2017 11:20
@Chaitanya009 :+1:
Chaitanya thakre
@Chaitanya009
Jan 20 2017 11:22
@sorinr you could see?
Sorin Ruse
@sorinr
Jan 20 2017 11:23
@Chaitanya009 yes was blind and now i can see it :)
Sorin Ruse
@sorinr
Jan 20 2017 11:32
@Chaitanya009 i would add overflow-x: hidden; to the body{} in css
Chaitanya thakre
@Chaitanya009
Jan 20 2017 11:34
@sorinr what it will do
Sorin Ruse
@sorinr
Jan 20 2017 11:35
@Chaitanya009 u don't deed that horizontal scrollbar. do u?
Chaitanya thakre
@Chaitanya009
Jan 20 2017 11:36
@sorinr i'm trying to add another image help
Geggen98
@Geggen98
Jan 20 2017 11:38
hey guys, im building a personal portofolio, and i really dont see where i have learn, or gotten all of the resources necessary to build it, is it just me or
Sorin Ruse
@sorinr
Jan 20 2017 11:38
@Chaitanya009 just add it and ask if you have some problems :)
Chaitanya thakre
@Chaitanya009
Jan 20 2017 11:39
@Geggen98 same
Geggen98
@Geggen98
Jan 20 2017 11:40
yeah, well maybe you just need some good links with an overview of the different funktions needed
anyone got a place for that?
Sorin Ruse
@sorinr
Jan 20 2017 11:41
@Geggen98 here some example but not sure if its helpfull for u
any suggestions??
Sorin Ruse
@sorinr
Jan 20 2017 11:51
@Code-of-the-noob why do u need <div id="re" style="background-color:black;"> ?
Arpan Das
@Code-of-the-noob
Jan 20 2017 11:53
@sorinr I was just playing around with it... that would be changed... most of css code is just temporary... i would change it later
Sorin Ruse
@sorinr
Jan 20 2017 11:54
@Code-of-the-noob i would get rid of all inline styling. at least move it to css codepen part
Sorin Ruse
@sorinr
Jan 20 2017 12:00
@Code-of-the-noob then i would change my css and if something not working i'll ask for help :)
Clyde Lobo
@oppiniated
Jan 20 2017 12:15
In your css?
@Code-of-the-noob What on earth is this color:colors[4];?
Sorin Ruse
@sorinr
Jan 20 2017 12:21
@oppiniated :point_up: January 20, 2017 1:53 PM
Srđan Međo
@PerpetualWar
Jan 20 2017 12:57
Guys, how can I make background-color in a div stretch to browser length ?
Im using bootstrap container-fluid
abhijith shenoy
@shenoyabhijith
Jan 20 2017 13:05
ease out not working
Marianissimus
@Marianissimus
Jan 20 2017 13:06
@PerpetualWar Hi, you can over-ride the container-fluid in your css like this .container-fluid{background-color: #123123;} As long as container-fluid is not inside another element, that should do it
Ken Haduch
@khaduch
Jan 20 2017 13:07

@mehtajaghvi I don't know if you got an answer, just going through the chat comments to catch up. But the idea is that when you assign a handler for an event, even though the code that assigned the handler executed in the context of the "document ready" function, that code is now in memory, ready to be triggered when an event occurs. It is similar to the way that any function is created - you might only run the code that creates the function one time function myFunc( arg1, arg2 ) { if ( arg1 > arg2 ) { return "arg1 wins!"; } else return "arg2 wins!"; } but then any other point in your code you can call myFunc( 3, 10 ); and it will activate the code of that function and return the answer. This is the same idea - the "document ready" block of code waits until the document is fully loaded to begin executing. All of the code that you write might be within that code block, or not - but it will execute once or as many times as necessary.

I don't know if you got a better answer or if that is of any help, but I hope that you are getting a better understanding of this as you go along. Good luck!

Srđan Međo
@PerpetualWar
Jan 20 2017 13:10
@Marianissimus ye but why should I overwrite ? Shouldn't container-fluid already be max width ?
Ken Haduch
@khaduch
Jan 20 2017 13:12
@shenoyabhijith - it looks like you have the CSS selector written as .input, which would target a class, but you want input, to target the input element, I think that's what you are missing?
jolio007
@jolio007
Jan 20 2017 13:12
Hey guys, quick question. I've made a form. I'd like to know how I can add more vertical space to my box
Found it! never mind
Marianissimus
@Marianissimus
Jan 20 2017 13:14
@PerpetualWar you just over-ride the background-color style, not the width. So - you want the div inside the container-fluid to be a different color? Make it have a class of "row mystyle", and then write the color in the css: .mystyle {background-color: red;}
abhijith shenoy
@shenoyabhijith
Jan 20 2017 13:17
yay @khaduch working
thanks @khaduch
CamperBot
@camperbot
Jan 20 2017 13:17
shenoyabhijith sends brownie points to @khaduch :sparkles: :thumbsup: :sparkles:
:star2: 2322 | @khaduch |http://www.freecodecamp.com/khaduch
Ken Haduch
@khaduch
Jan 20 2017 13:17
@shenoyabhijith :+1: great! Good luck!
abhijith shenoy
@shenoyabhijith
Jan 20 2017 13:19
:smile: :+1:
can some 1 explain in brief how this wiki pedia api works
looks so complicated
Srđan Međo
@PerpetualWar
Jan 20 2017 13:34
@Marianissimus thanks for your reply.... I will try to make it work now
CamperBot
@camperbot
Jan 20 2017 13:34
perpetualwar sends brownie points to @marianissimus :sparkles: :thumbsup: :sparkles:
:cookie: 333 | @marianissimus |http://www.freecodecamp.com/marianissimus
Srđan Međo
@PerpetualWar
Jan 20 2017 13:46
Apparently my body in css had margins set which prevented container-fluid to reach end of the browser.
Muhammad Hasham
@MohammadHasham
Jan 20 2017 14:18
can anyone give me some example of any app that is purely made of JS.
How do you define scope of JS apps?
Is JS only used in websites?if not then where else it is used.And in combination to what?
Ken Haduch
@khaduch
Jan 20 2017 14:45
@shenoyabhijith - I haven't done the wikipedia project, yet, but basically you make an AJAX request to the URL, with all of the parameters appropriately filled in, and it processes your request and returns the data. Your callback function is then triggered, and you have to get the JSOn data that they provide and break it down into the various articles or whatever information they provide and parse it into information that you then present to your HTML page as HTML code (through jquery or javascript functions, adding information to the DOM.) From what I've seen of the wikipedia data, they provide three sections in the information, the list of articles, some summary info, and I think a third one which I cannot remember. I think that I saved one of them on codebeautify, I wonder if I can find that?
abhijith shenoy
@shenoyabhijith
Jan 20 2017 14:46
thank you so much @khaduch that was so much help !
CamperBot
@camperbot
Jan 20 2017 14:46
shenoyabhijith sends brownie points to @khaduch :sparkles: :thumbsup: :sparkles:
:star2: 2323 | @khaduch |http://www.freecodecamp.com/khaduch
Ken Haduch
@khaduch
Jan 20 2017 14:49
@shenoyabhijith - I did find a link to the results for searching for "potato" on wikipedia - http://codebeautify.org/jsonviewer/cbb94735 - it shows the structure of the returned data, not exactly as I remembered it, but there is an array of objects for the various pages that it found matching your query. Maybe helpful as you start to write that code, although you can take your own JSON data and put it in the Code Beautify site and have it format it.
abhijith shenoy
@shenoyabhijith
Jan 20 2017 14:51
awesome ill start coding probably later tonite
now need a break :fire: :smile:
Ken Haduch
@khaduch
Jan 20 2017 14:52
@shenoyabhijith - definitely good to take a break before starting this one! :) Enjoy your break!
Pieter Stokkink
@forkerino
Jan 20 2017 14:56
@MohammadHasham There's many of them. Many apps use another language in the backend, like Ruby or Python or Java, but it is possible to use NodeJS as well, which is JavaScript, and makes communication between front and backend quite easy. Pretty much anything that can be made for the web, could theoretically be made using just JS, HTML and CSS (often with the addition of a database). You'll learn these techniques in the backend portion here on FCC. This of course doesn't mean that JS is always the best choice for the backend.
Nowadays it is also possible to make non-web applications in JS, using Electron. So JS is pretty flexible in that regard.
JD Tadlock
@jdtdesigns
Jan 20 2017 15:03
@forkerino I love Node, but Laravel/Vue has grown on me. What's ur fav?
Pieter Stokkink
@forkerino
Jan 20 2017 15:03
@khaduch @shenoyabhijith I'm using a Chrome Add On called JSON Viewer, which basically does similar things as the codebeautify site, but no need to copy paste the code. It just transforms JSON to something easier to read. With lots of custom styling options.
Sorin Ruse
@sorinr
Jan 20 2017 15:04
@jdtdesigns Laravel its in my heart as a php frame. i like also a lot symfony
Pieter Stokkink
@forkerino
Jan 20 2017 15:09
@jdtdesigns Well, I'm just getting started, so far only used node.
aenila
@aenila
Jan 20 2017 15:10
Good morning everybody!
Sorin Ruse
@sorinr
Jan 20 2017 15:10
@aenila good morning
aenila
@aenila
Jan 20 2017 15:11
I'm working on the random quote machine right now. Got it working yesterday. Today it will work on my mobile browser but not my desktop even though I haven't made any changes since I tested. Anybody ever come across this before?
JD Tadlock
@jdtdesigns
Jan 20 2017 15:12
@aenila Sounds like a CORS error in Chrome.
Post your pen
Sorin Ruse
@sorinr
Jan 20 2017 15:13
@aenila how do u load the pen http or https?
aenila
@aenila
Jan 20 2017 15:13
It's loaded https on my desktop
The tweet link/button isn't finished, but on my mobile browser the new quote button works find
fine*
Sorin Ruse
@sorinr
Jan 20 2017 15:14
@aenila that api its working on http only so load the pen over http
aenila
@aenila
Jan 20 2017 15:14
Oh. Thank you.
Frank
@Frankbono
Jan 20 2017 15:17
Hi I am having a problem with a Javascript challenge "Profile Lookup" I just can't see what I did wrong with my code here. Please help https://www.freecodecamp.com/challenges/profile-lookup

//Setup
var contacts = [
    {
        "firstName": "Akira",
        "lastName": "Laine",
        "number": "0543236543",
        "likes": ["Pizza", "Coding", "Brownie Points"]
    },
    {
        "firstName": "Harry",
        "lastName": "Potter",
        "number": "0994372684",
        "likes": ["Hogwarts", "Magic", "Hagrid"]
    },
    {
        "firstName": "Sherlock",
        "lastName": "Holmes",
        "number": "0487345643",
        "likes": ["Intriguing Cases", "Violin"]
    },
    {
        "firstName": "Kristian",
        "lastName": "Vos",
        "number": "unknown",
        "likes": ["Javascript", "Gaming", "Foxes"]
    }
];


function lookUpProfile(firstName, prop){
// Only change code below this line
    for (i = 0; i < contacts.length; i++) {
      if (contacts[i].firstName === firstName) {
        if (contacts[i].firstName.hasOwnProperty(prop)) {
          return contacts[i].prop ;
        } else {
          return "No such property";
        }
      }
    }
// Only change code above this line
}

// Change these values to test your function
lookUpProfile("Akira", "likes");
aenila
@aenila
Jan 20 2017 15:20
The problem is in your nested if statement I believe. Double check where you're asking it to look for the prop value
Also check the requirements of the challenge. I think you need to notify the user if the name is not found. Otherwise it looks like you're pretty close.
Frank
@Frankbono
Jan 20 2017 15:27
ok I going to tweek it now
aenila
@aenila
Jan 20 2017 15:28
Can anybody point me in the right direction on what to look up to learn how to make the tweet button work? I can't figure out how to take the quotes and pass them to the link for the twitter post.
Sorin Ruse
@sorinr
Jan 20 2017 15:43
@Frankbono just read again that challenge request. where do u return "No such contact" in case there is no match for a contact?
caseym94
@caseym94
Jan 20 2017 15:44
yo
need help achieving that imgur in the codepen
Kenneth Nwaeze
@kengin2013
Jan 20 2017 15:45
how do i write a "twitter icon" to this
caseym94
@caseym94
Jan 20 2017 15:45
that being a seperation between the purple box and dogbox
Kenneth Nwaeze
@kengin2013
Jan 20 2017 15:45
how do i write a "twitter icon" to this html: <button class="btn"><i class="fa fa-twitter" ></i>
</button>
Sorin Ruse
@sorinr
Jan 20 2017 15:47
@caseym94 its just 2 rows and 2 columns :)
caseym94
@caseym94
Jan 20 2017 15:47
;( I don't get it
Muhammad Hasham
@MohammadHasham
Jan 20 2017 15:49
How this function can run?
function repeat(times, body) 
{
   for (var i = 0; i < times; i++) {
     body(i);
   }
}
repeat(3,function(n){

console.log('n is');
});
@sorinr
Sorin Ruse
@sorinr
Jan 20 2017 15:50
@caseym94 do u want to use bootstrap?
Muhammad Hasham
@MohammadHasham
Jan 20 2017 15:50
i want to get all the values of i
caseym94
@caseym94
Jan 20 2017 15:50
not sure how to use it lol
Eric K
@EricK425
Jan 20 2017 15:50
does this link work for my trib page? https://codepen.io/EricK425/pen/ENjqwJ
sweet
caseym94
@caseym94
Jan 20 2017 15:51
would rather know if it's possible or not with css/html alone
Sorin Ruse
@sorinr
Jan 20 2017 15:52
@MohammadHasham this way body(i); you r calling for a function called body and you pass a var i to it. this is what you want?
Muhammad Hasham
@MohammadHasham
Jan 20 2017 15:53
i was missing n in console.log
@sorinr
now it works
Sorin Ruse
@sorinr
Jan 20 2017 15:56
@caseym94 its only up to u using a css framework or not. i just asked to know what advice could i give you
Kenneth Nwaeze
@kengin2013
Jan 20 2017 15:56
how do i write a "twitter icon" to this html: <button class="btn"><i class="fa fa-twitter" ></i>
</button> https://codepen.io/kengin2013/pen/yVmXwM?editors=1100
caseym94
@caseym94
Jan 20 2017 16:01
@sorinr sorry I'm really confused
Sorin Ruse
@sorinr
Jan 20 2017 16:02
@caseym94 about what?
caseym94
@caseym94
Jan 20 2017 16:06
lol so is it possible to do this?
create the seperation between the 2 boxes
and have the red box wrap the green like that
with this codepen
Ken Haduch
@khaduch
Jan 20 2017 16:10
@forkerino - that sounds like a useful utility - thanks for posting. There are so many useful tools out there, just have to learn about them all! :point_up: January 20, 2017 10:03 AM
CamperBot
@camperbot
Jan 20 2017 16:10
khaduch sends brownie points to @forkerino :sparkles: :thumbsup: :sparkles:
:cookie: 700 | @forkerino |http://www.freecodecamp.com/forkerino
Pieter Stokkink
@forkerino
Jan 20 2017 16:11
@khaduch yes, I saw it in one of the instruction videos for the backend API projects and looked it up in the chrome extensions. & thanks for 700!
CamperBot
@camperbot
Jan 20 2017 16:11
forkerino sends brownie points to @khaduch :sparkles: :thumbsup: :sparkles:
:star2: 2324 | @khaduch |http://www.freecodecamp.com/khaduch
Sorin Ruse
@sorinr
Jan 20 2017 16:22
@caseym94 something like example ?
Tyler Moeller
@TylerMoeller
Jan 20 2017 16:23
Was just about to post a pen with an example too :) https://s.codepen.io/TylerMoeller/pen/WRpgWw
Sorin Ruse
@sorinr
Jan 20 2017 16:27
@TylerMoeller ha ha. :) today it seems i'm out of this world
Tyler Moeller
@TylerMoeller
Jan 20 2017 16:29
@kengin2013 Font awesome is another CSS file you need to add to your project, just like you did with Bootstrap. Add this to the CSS settings in your codepen: https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.6.3/css/font-awesome.min.css
@sorinr Well, it's Friday at least :)
caseym94
@caseym94
Jan 20 2017 16:29
@sorinr nah imagine cutting out the area under the purple box
so that dogbox turns into an L shape
Sorin Ruse
@sorinr
Jan 20 2017 16:30
@TylerMoeller lol. yep. it seems started a little earlier for me :)
@caseym94 yes i know. @TylerMoeller already provided a solution for that
Igor Amidzic
@igoramidzic
Jan 20 2017 16:31
Just finished my replica of GitHub :)
https://floating-plains-58175.herokuapp.com/
Well, the homepage only
Kenneth Nwaeze
@kengin2013
Jan 20 2017 16:31
@TylerMoeller got it
Tyler Moeller
@TylerMoeller
Jan 20 2017 16:32
@kengin2013 I see it now - nice work :+1:
Igor Amidzic
@igoramidzic
Jan 20 2017 16:33
Crap nvm I forgot the mobile view navbar
caseym94
@caseym94
Jan 20 2017 16:35
@sorinr still not what I want lol
it looks like what I want
I want it so there is nothing in the area where the white border is
so it shows the background
Tyler Moeller
@TylerMoeller
Jan 20 2017 16:43
@caseym94 This pen: https://s.codepen.io/TylerMoeller/pen/WRpgWw is the same as the image you sent. Send a different image to give a better idea of what you are hoping to accomplish.
@TylerMoeller
I want the red area to not go under the images
red area is basically background-color:red; for <p> content, but it still goes under the images
which i don't want
Tyler Moeller
@TylerMoeller
Jan 20 2017 16:56
@caseym94 You could give the images a background-color of white:
.right, .left {
  background-color: white;
}
caseym94
@caseym94
Jan 20 2017 16:58
what if I have a background img as the body background?
then there would be white behind the images
@TylerMoeller
Tyler Moeller
@TylerMoeller
Jan 20 2017 17:00
@caseym94 There are lots of ways to approach it - depending on exactly what you want.
My concern now is that I help show you how to handle this scenario with a background image and you tell me it isn't what you want :)
Be specific, show the exact requirements, and maybe we can help out better.
Sorin Ruse
@sorinr
Jan 20 2017 17:01
@caseym94 do you try to achieve something like: https://css-tricks.com/image-under-text/
Tyler Moeller
@TylerMoeller
Jan 20 2017 17:02
These pens may also give an idea of the requirements around images and backgrounds with text:
Adel
@AdelMahjoub
Jan 20 2017 17:04
you can open gimp or photoshop and make what you need, if you don't find a way
caseym94
@caseym94
Jan 20 2017 17:08
@TylerMoeller sec
on the right is a sidebar/login area that's red
let me fix it
ok reload it
I want a seperation between the entries and the side content
caseym94
@caseym94
Jan 20 2017 17:14
u can see the sidebars overlapping the entries
I want the entries to wrap around instead
Josie
@Josie-N
Jan 20 2017 17:22
Build a Tribute Page 😳😣😟😧🙀
I don't even know what to start with.
Amit Patel
@AmitP88
Jan 20 2017 17:31
hey everyone, what are your opinions on using SASS and Jade for streamlining CSS and HTML code?
JD Tadlock
@jdtdesigns
Jan 20 2017 17:32
@AmitP88 You'll 99% of the time use sass when coding your css as you grow in development.
Amit Patel
@AmitP88
Jan 20 2017 17:33
@jdtdesigns ah ok. so most development companies don't use regular CSS anymore?
JD Tadlock
@jdtdesigns
Jan 20 2017 17:33
jade is kinda up in the air
i prefer vanilla html due to jade getting clustered the more code you have
with frameworks, jade is pretty much useless
Amit Patel
@AmitP88
Jan 20 2017 17:34
@jdtdesigns I have a ton of html code for my client's site, so that's why I was curious about jade https://amitp88.github.io/Khmer-Family-Cafe/#home
JD Tadlock
@jdtdesigns
Jan 20 2017 17:34
@AmitP88 You should probably look into a js framework then.
Amit Patel
@AmitP88
Jan 20 2017 17:35
@jdtdesigns a js framework for writing html? hmmm, well, a lot of the code is modals
JD Tadlock
@jdtdesigns
Jan 20 2017 17:35
@AmitP88 It's all about speed and clean code when developing. That's why devs use frameworks, sass, webpack, ect.
Amit Patel
@AmitP88
Jan 20 2017 17:36
@jdtdesigns so for my client's website, how fast should I be able to code it if I were working at a company?
JD Tadlock
@jdtdesigns
Jan 20 2017 17:36
@AmitP88 Yes, because js frameworks allow you to split your html into components and organize everything how you want it
Amit Patel
@AmitP88
Jan 20 2017 17:37
@jdtdesigns oooh, I didn't know js frameworks could do that. I thought they were pretty much exclusive for javascript and JS applications
@jdtdesigns lol sorry if I sound dumb for saying/thinking that haha
JD Tadlock
@jdtdesigns
Jan 20 2017 17:39
@AmitP88 It depends on the company. If you're hired by a new company without much experience in dev, they might be more lenient with how you code. A seasoned dev company will expect you to know certain things always (sass, angular, react, gulp, webpack, ect).
no worries, we're always learning ;)
Amit Patel
@AmitP88
Jan 20 2017 17:40
@jdtdesigns ah I see. I'm actually started freelancing (the site I showed you is for my first client) in order to gain experience to get hired. Seems like a lot of dev companies these days won't even reply if you don't have any pro exp
@jdtdesigns ah well, might as well learn the extra tools now huh? lol
JD Tadlock
@jdtdesigns
Jan 20 2017 17:42
@AmitP88 It's not as easy as it used to be to get hired for sure. If you have some connections and/or get lucky, you can land a job with a new company that doesn't know any better. Don't be surprised if they fire you shortly after though, when they realize you don't know what they need.
Amit Patel
@AmitP88
Jan 20 2017 17:44
@jdtdesigns oh man, that's what I'm most scared of. I definitely don't want to get fired
JD Tadlock
@jdtdesigns
Jan 20 2017 17:44
It's important to know html, css to a point you can do anything with them and also know js to an intermediate level with at least one major framework up your sleave.
Amit Patel
@AmitP88
Jan 20 2017 17:45
@jdtdesigns my main concern though for now is, should I just focus on developing websites for small businesses, or should I focus more on application development?
oh yeah, I feel I definitely have a good handle on html, css along with bootstraps framework
js I know some but I need to get better at app dev and algorithms (hence why I started fcc)
JD Tadlock
@jdtdesigns
Jan 20 2017 17:46
@AmitP88 You won't find many jobs for a simple site. There's 1 billion $5 devs doing those, albeit doing a terrible job.
Amit Patel
@AmitP88
Jan 20 2017 17:46
I tend to struggle to come up with good app ideas though
yeah, that's what I was thinking =/
MrPiethon
@MrPiethon
Jan 20 2017 17:47
Hey guys can you critique my first project I had to make a tribute page
JD Tadlock
@jdtdesigns
Jan 20 2017 17:47
To make real money, you'll need to be at a 'professional' level with web development. It usually takes around 3 to 4 years minimum to get to that point. And that's if you really dive in hardcore and don't stop coding. @AmitP88
Amit Patel
@AmitP88
Jan 20 2017 17:47
my goal for this year was to make 5 responsive websites for actual businesses, then do maybe 3 really good web apps using the latest frameworks (react, angular, etc)
MrPiethon
@MrPiethon
Jan 20 2017 17:48
How did they margin the original row without using css?
where the timeline is
Amit Patel
@AmitP88
Jan 20 2017 17:48
damn, I was really hoping I could get hired sometime by the end of this year. I did the Udacity front end nanodegree from may '15 to july '16 and now I started fcc to advance my skills
I mean really, I just want to start somewhere professionally
even if the salary isnt there yet
MrPiethon
@MrPiethon
Jan 20 2017 17:50
any ideas?
JD Tadlock
@jdtdesigns
Jan 20 2017 17:50
@AmitP88 It's one thing to make the goals, which is great to do. But, you have to realize that 'knowing' a framework comes with understanding so many things that come along with doing it right(OOP, Best Design Patterns, ect). These can take awhile to 'click' for the normal person.
@MrPiethon They just set the content in a smaller column and used offsets to center it. ;)
Amit Patel
@AmitP88
Jan 20 2017 17:51
@jdtdesigns for sure. I mean, through Udacity I have some knowledge of OOP and several things related, but it's gonna take a lot of time to have them solidified
@jdtdesigns so it would take the avg person 3-4 years min. of practice to be able to get hired as a dev?
@jdtdesigns even just to start out on the professional level?
MrPiethon
@MrPiethon
Jan 20 2017 17:53
@jdtdesigns do you mean nest a <div> class (<div><div>)?
JD Tadlock
@jdtdesigns
Jan 20 2017 17:53
@AmitP88 Usually, though people do get hired sooner. Like I said, you might get hired because you pass a simple interview or just get lucky. It'll then be based on how lenient the company is.
Amit Patel
@AmitP88
Jan 20 2017 17:54
@jdtdesigns damn, that doesn't sound good =(
JD Tadlock
@jdtdesigns
Jan 20 2017 17:54
@MrPiethon <div class="col-xs-12 col-sm-10 col-sm-offset-1 col-md-8 col-md-offset-2">
that's the column classes for the bio that make it centered
Amit Patel
@AmitP88
Jan 20 2017 17:55
@jdtdesigns this sounds crazy, but I was hoping I could power through these next 6 months getting some websites and apps done (as well as fcc certs) and would be a good candidate for a jr level role, but it sounds unlikely now
MrPiethon
@MrPiethon
Jan 20 2017 17:55
@jdtdesigns ah i remember doing that for buttons thanks for the help
JD Tadlock
@jdtdesigns
Jan 20 2017 17:55
you'll need to research bootstrap thoroughly to understand what it's doing @MrPiethon
CamperBot
@camperbot
Jan 20 2017 17:55
mrpiethon sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
:cookie: 866 | @jdtdesigns |http://www.freecodecamp.com/jdtdesigns
JD Tadlock
@jdtdesigns
Jan 20 2017 17:56
which is why i recommend learning css before jumping into bootstrap @MrPiethon
MrPiethon
@MrPiethon
Jan 20 2017 17:56
@jdtdesigns its basically a grid/row with the size parameter
similar to python in a way when it comes to GUI
Arpan Das
@Code-of-the-noob
Jan 20 2017 17:57

can someone help i get this error when i call open weather api.. what am i doing wrong

http://codepen.io/Code-of-the-noob/pen/LxWBJx
Uncaught SyntaxError: Unexpected token o in JSON at position 1

JD Tadlock
@jdtdesigns
Jan 20 2017 17:59
@AmitP88 Don't lose hope. If you dive in non-stop and get serious with it, you can go far in 6 to 8 months. Just understand the retention rate is very low as far as people sticking with learning professional web dev. This is due to the fact that it's one of the hardest fields to learn these days. There's literally 4 languages you have to learn from scratch and a stack of extras that come along with it. Imagine trying to learn Spanish, German and Chinese in 8 months.
Amit Patel
@AmitP88
Jan 20 2017 18:01
@jdtdesigns true. I mean, after Udacity's program I still feel like I have a lot to learn/sharpen up on. however, I feel like my html,css,js core is strengthening up. it seems like learning the frameworks/tools is a lot quicker once I have a better understanding of those 3 fundamentals
@jdtdesigns the biggest thing i'm working on strengthening up is my JS, as I want to become a javascript developer someday
JD Tadlock
@jdtdesigns
Jan 20 2017 18:05
@AmitP88 JS is a beast due to the 'versatility' of it's programming paradigm. You can do things so many different ways which can be super confusing for awhile when learning from different outlets that might teach you their favorite way. You face many walls where you'll wonder 'What is the right way?'.
I love js because of it's versatility, but i went through hell to get where i am now lol.
Amit Patel
@AmitP88
Jan 20 2017 18:06
@jdtdesigns here's my portfolio site (I'm gonna change it soon) of my udacity projects just to give you an idea of what I've done so far: https://amitp88.github.io/New-Portfolio/
Daniel
@DanJP2016
Jan 20 2017 18:07
@jdtdesigns can you recommend some good books or sites that cover what a person needs to know to get work in this field, or the more advanced parts html, css, javascript?
Amit Patel
@AmitP88
Jan 20 2017 18:08
@jdtdesigns yeah, I get that. however, I was taught that when it comes to code "less is more" so I always tend to look for the simplest way possible when trying to achieve a task
JD Tadlock
@jdtdesigns
Jan 20 2017 18:11
@AmitP88 Which is what every good dev does. Readable, clean, symantically correct code is what separates the professional devs from the novice.
Amit Patel
@AmitP88
Jan 20 2017 18:13
@Code-of-the-noob hey thank you Arpan, I really appreciate that. Yeah, i've taken a little break from coding, but especially since starting freelancing website building, I'm diving in further. it's tough because sometimes I work crazy amount of hours at my job (im a lab tech), but I'm hoping I can make the best of these next 6 months and hopefully land a jr dev job
CamperBot
@camperbot
Jan 20 2017 18:13
:cookie: 266 | @code-of-the-noob |http://www.freecodecamp.com/code-of-the-noob
amitp88 sends brownie points to @code-of-the-noob :sparkles: :thumbsup: :sparkles:
JD Tadlock
@jdtdesigns
Jan 20 2017 18:15
@AmitP88 Just remember the more you take a break, the more you forget and the more you have to restart. That's the reason a lot of people give up after a few months or so. They get burned out on a certain thing and take a break. They then come back and don't remember all the stuff that they were struggling with in the first place.
It can be a never ending cycle if you don't stick with it and never stop coding.
Amit Patel
@AmitP88
Jan 20 2017 18:16
@jdtdesigns true. yeah, that kinda happened to me with JS, but now that i'm getting back into it, I'm not gonna stop :)
JD Tadlock
@jdtdesigns
Jan 20 2017 18:16
I had a 2 year cycle of burn outs when i was in school and working full time.
Amit Patel
@AmitP88
Jan 20 2017 18:16
I even started reading Eloquent Javascript and I feel i'm getting to the point where I can start working on apps again. I just struggle to come up with good ideas for web apps
JD Tadlock
@jdtdesigns
Jan 20 2017 18:16
In those 2 years i didn't learn as much as i learned in 4 months when i stuck with it.
Amit Patel
@AmitP88
Jan 20 2017 18:17
yeah, I think i'm at that point where I'm willing to sacrifice some sleep just to get more done on a daily basis
JD Tadlock
@jdtdesigns
Jan 20 2017 18:21
@AmitP88 I went to a code meet up a little while back and met 4 people who all had just started and wanted to quit their jobs and become full time web devs. They were all fooled by the youtube ads into thinking they'd be making good money in 6 months or less. Needless to say, none of them are doing web dev now lol.
Amit Patel
@AmitP88
Jan 20 2017 18:24
@jdtdesigns hmmm I see. Yeah, i've been reflecting on whether or not I really want to go into this field, and although a big reason is that I don't want to be a lab tech for the rest of my life, I think a bigger reason is I like creating things that other people will enjoy. I realized this after my client said that him and his wife liked the website so far
btw in your opinion, do you think Free Code Camp is worth it?
JD Tadlock
@jdtdesigns
Jan 20 2017 18:28
FCC just pushes you to learn. It doesn't teach you much of anything.
Patrick Black
@Mortiferr
Jan 20 2017 18:29
Amit Patel
@AmitP88
Jan 20 2017 18:31
@jdtdesigns yeah, I'm halfway through the algorithm scripting challenges on the front end part. I like how it challenges you though. Just wondered if it was still worth doing in terms of getting a job.
JD Tadlock
@jdtdesigns
Jan 20 2017 18:33
@AmitP88 FCC won't get you a job and the cert won't do anything for you. What'll get you a job is a great portfolio with projects related to the hiring company's needs and passing the interview/testing process. ;)
Amit Patel
@AmitP88
Jan 20 2017 18:33
@jdtdesigns for sure. yeah that's what I was thinking too. I'm hoping the challenges will at least help prep for the interview tests though
@jdtdesigns however, as far as freelancing goes, how do I start getting work for application development? should I just try to make some independent web apps to show and try to get clients through upwork.com?
rami90
@rami90
Jan 20 2017 18:35
hi all, how to put 3 items in one row in html and control the positions of those items. I tried the bootstrap row but i cant control the position of item, as bootstrap automatically assign the positions in one row and when you try to edit the "col" with css it will break. Any advice?
JD Tadlock
@jdtdesigns
Jan 20 2017 18:35
@AmitP88 You can build things on your own and/or take on a pro-bono job for a restaurant/church/non profit.
@Mortiferr You can use a weather api that supports https like Weather Underground or APIXU. ;)
Amit Patel
@AmitP88
Jan 20 2017 18:36
@jdtdesigns lol that's what I just did with my first client's site. he has a cambodian restaurant. I also have a 2nd client lined up for a pest control service. I was referring to more along the lines of web applications rather than just websites
JD Tadlock
@jdtdesigns
Jan 20 2017 18:37
@rami90 Do you have an example of the how the items should be positioned in the row?
rami90
@rami90
Jan 20 2017 18:37
@jdtdesigns can i send photo here to show you?
JD Tadlock
@jdtdesigns
Jan 20 2017 18:37
@AmitP88 Have you touched any backend stuff yet?
@rami90 sure
rami90
@rami90
Jan 20 2017 18:38
not yet anyway the page i am doing has no back end. its only a one page portfolio
Amit Patel
@AmitP88
Jan 20 2017 18:38
@jdtdesigns not yet. I'm primarily trained in front end development. I was hoping to do more backend stuff later on down the line once I get more exp with JS and JS frameworks
once I make maybe 1-2 web apps using react and angular 2, then I might dive into PHP
JD Tadlock
@jdtdesigns
Jan 20 2017 18:40
@AmitP88 For a web app, you'll need to know some backend and a database(MongoDB).
Fullstack web dev can take a minimum of 5 years to learn. Just a reality check for you lol.
rami90
@rami90
Jan 20 2017 18:40
@jdtdesigns how to send image here?
JD Tadlock
@jdtdesigns
Jan 20 2017 18:41
@rami90 http://prnt.sc/ and just post the link
Amit Patel
@AmitP88
Jan 20 2017 18:41
@jdtdesigns damn. well, honestly I just want to start out as a front end dev for now, get into the field professionally, then start expanding towards full stack
rami90
@rami90
Jan 20 2017 18:41
blob
Sorin Ruse
@sorinr
Jan 20 2017 18:41
@rami90 just drag and drop
rami90
@rami90
Jan 20 2017 18:42
@jdtdesigns here is the photo, what you suggest to make those in one row
JD Tadlock
@jdtdesigns
Jan 20 2017 18:43
@AmitP88 A good place to start to create a complete app would be Firebase. It's free to use for small apps and all done with js.
I wish i would've had Firebase around when i started lol
@rami90 You didn't post the photo
rami90
@rami90
Jan 20 2017 18:44
blob
@jdtdesigns
JD Tadlock
@jdtdesigns
Jan 20 2017 18:44
ah
Amit Patel
@AmitP88
Jan 20 2017 18:45
@jdtdesigns hmmm, is Firebase only for Android/iOS mobile apps? because I have 0 exp in those
JD Tadlock
@jdtdesigns
Jan 20 2017 18:49
@AmitP88 Firebase is for multiple platforms including web
Amit Patel
@AmitP88
Jan 20 2017 18:49
@jdtdesigns nvm, I'm on the getting started page and it says that it's for if you already have an app created
now I just gotta come up with an idea for an app =/
@AmitP88 Firebase is a database and authentication service
You use it to serve data to your app and allow users to log in/out
JD Tadlock
@jdtdesigns
Jan 20 2017 19:02
It has a pretty intense learning curve, but can make your life so much simpler compared to dealing with a backend like node or php
George Phalen
@gphalen
Jan 20 2017 19:02
Hey, can anyone help with the Pomodoro Clock? I can't figure out how to properly reset the clock while it's already counting down. It causes the clock to alternate between the two different values and makes the loading bar go all wonky. http://codepen.io/gphalen/pen/BpWyOy
JD Tadlock
@jdtdesigns
Jan 20 2017 19:05
@gphalen You can easily control timers(setTimeout, setInterval) by attaching them to the window. A simple example:
window.timer = setInterval(function() {
  // count down
}, 1000):

$('#pause').on('click', function() {
  clearInterval(window.timer);
}):
George Phalen
@gphalen
Jan 20 2017 19:07
@jdtdesigns I've tried clearTimeout, it just freezes the clock from the outset.
Riccardo M. Pesce
@RiccardoMPesce
Jan 20 2017 19:08
To complete the portfolio page, what resources have you consulted?
JD Tadlock
@jdtdesigns
Jan 20 2017 19:09
@gphalen One major issue i see is the lack of separation of functionality. Create functions that do certain things (ie. startTimer(), resetTimer(), pauseTimer(), ect).
Your code is in spaghetti style right now :P
@RiccardoMPesce You can build the portfolio with basic html, css. A little js will make it more functional but it's not required.
Youtube is your friend when it comes to finding learning resources. ;)
Sorin Ruse
@sorinr
Jan 20 2017 19:12
@gphalen why do you mix vanilla JavaScript with jquery code? i would just go for one or another
Amit Patel
@AmitP88
Jan 20 2017 19:12
@jdtdesigns lol actually I was also planning on learning Node.js as well =P
@jdtdesigns but I'll still look into using Firebase though
George Phalen
@gphalen
Jan 20 2017 19:13
@sorinr Honestly, I learned vanilla JS alongside jQuery. I've never differentiated that much.
@jtdesigns Creating a pause feature is a good idea unto itself, might try that before tacking the resetting.
Mostafa Masri
@thefakeweed
Jan 20 2017 19:15
@Blockshot12 it's old i fixed it now
JD Tadlock
@jdtdesigns
Jan 20 2017 19:16
@gphalen What @sorinr is saying is if you're using jQuery, go ahead and take advantage of it's funtionality:
var startBtn = document.getElementById('start');

$('#start'); // easier <--- :)
@AmitP88 For fullstack js, you'll need to learn Node for sure and most likely MongoDB. Just be aware, you don't have to learn backend. You can land a job with just Front End experience. The sad news is that most Front End jobs today require some backend knowledge.
Amit Patel
@AmitP88
Jan 20 2017 19:20
@jdtdesigns yeah, I noticed that too. Although, I don't think too much backend knowledge is required. I'm hoping that if I just learn maybe PHP and MongoDB that that'll be enough (providing I use them in some projects of course)
@jdtdesigns I think for now, I'll focus on learning/implementing Sass/Less/Stylus and WordPress, get a few client sites under my belt, and go from there into application development
JD Tadlock
@jdtdesigns
Jan 20 2017 19:22
@AmitP88 I'd stick with js full stack. Skip PHP for now and maybe jump into it down the road when you're comfortable with JS full stack.
Amit Patel
@AmitP88
Jan 20 2017 19:22
@jdtdesigns hmmm, so what do I learn for JS full stack?
JD Tadlock
@jdtdesigns
Jan 20 2017 19:22
@AmitP88 WordPress is a monster. I woudn't touch it unless you're planning on getting paid $10 to pop a pre-built theme in for someone.
Amit Patel
@AmitP88
Jan 20 2017 19:23
@jdtdesigns really? so for the websites I should stick to making custom sites?
JD Tadlock
@jdtdesigns
Jan 20 2017 19:24
@AmitP88 I'm talking real money here. You can waste your time learning WordPress for 2 to 4 years and compete with a very saturated market or learn something that's still growing and in high demand.
Daniel
@DanJP2016
Jan 20 2017 19:25
hey guys I was wondering if i could get some feedback on what i got so far for my weather app. mostly wondering if the data is showing up correctly for others. thanks
http://codepen.io/bones211/full/vgxbGq/
Andrew
@rexmorgan89
Jan 20 2017 19:25
Has anyone completed the twitch tv webapp? I'm unsure of how to populate the list of channels into the API call
JD Tadlock
@jdtdesigns
Jan 20 2017 19:25
WordPress dev is extremely frustrating and hard to learn. I know this because i spent 4 years learning how to be a professional WP dev.
@AmitP88
Amit Patel
@AmitP88
Jan 20 2017 19:25
@jdtdesigns I see. so WordPress is basically not worth learning
at least in todays market
@jdtdesigns its just that when I search for front end jobs in california via indeed, I've noticed that several of them note WP in their tech list
JD Tadlock
@jdtdesigns
Jan 20 2017 19:27
In my opinion it's not worth it
Andrew
@rexmorgan89
Jan 20 2017 19:27
@DanJP2016 , my comp is saying that an error occurred. No temp/weather/geolocation data was displayed
JD Tadlock
@jdtdesigns
Jan 20 2017 19:28
@AmitP88 You won't be qualified for those jobs for 5 to 10 years. Just sayin
When a company is hiring a WordPress expert, it is some serious skill you need
Amit Patel
@AmitP88
Jan 20 2017 19:28
@jdtdesigns ah I see. ok, crossing that off the list of must-knows lol
JD Tadlock
@jdtdesigns
Jan 20 2017 19:28
and that skill takes countless hours to attain
Adel
@AdelMahjoub
Jan 20 2017 19:28
better buy wordpress's themes and charge the clients for it, I guess, if you are talking about building a wp theme
Daniel
@DanJP2016
Jan 20 2017 19:28
ok thanks, i will try to fix it
Amit Patel
@AmitP88
Jan 20 2017 19:29
@jdtdesigns ah I see. eh, I wanna focus more on JS related projects tbh. seems that's where the real programming is
Sorin Ruse
@sorinr
Jan 20 2017 19:30
@DanJP2016 as i said just try to lower the values in the text-shadow :)
Amit Patel
@AmitP88
Jan 20 2017 19:30
@jdtdesigns should I still learn Jade though for html?
JD Tadlock
@jdtdesigns
Jan 20 2017 19:31
I love PHP. Laravel is probably my favorite framework. But I'm giving you some good advice that i didn't have when i started. Stick with a stack and learn it. Then move on if you have time. @AmitP88
Daniel
@DanJP2016
Jan 20 2017 19:31
@sorinr still to bright huh...ok i will mess with it some more thank you.
CamperBot
@camperbot
Jan 20 2017 19:31
danjp2016 sends brownie points to @sorinr :sparkles: :thumbsup: :sparkles:
:star2: 1120 | @sorinr |http://www.freecodecamp.com/sorinr
JD Tadlock
@jdtdesigns
Jan 20 2017 19:31
@AmitP88 I'd skip Jade for now. It's not really worth the learning curve.
Amit Patel
@AmitP88
Jan 20 2017 19:32
@jdtdesigns ah ok. what I really want to learn is React and Angular 2. so I guess that would mean learning MEAN stack?
JD Tadlock
@jdtdesigns
Jan 20 2017 19:32
;)
Amit Patel
@AmitP88
Jan 20 2017 19:32
those 2 I've seen are in the most demand
JD Tadlock
@jdtdesigns
Jan 20 2017 19:33
The MEAN stack is a great idea to begin with.
Amit Patel
@AmitP88
Jan 20 2017 19:33
oh this is perfect actually lol (just visited mean.io)
JD Tadlock
@jdtdesigns
Jan 20 2017 19:33
Just realize, learning a full stack will take much longer than just learning a front end stack.
Muhammad Hasham
@MohammadHasham
Jan 20 2017 19:34
isn't it really complicated....Can anyone help me to wrap my head around this
function unless(test, then) 
{ 
  if (!test) then(); 
} 
function repeat(times, body) 
{
   for (var i = 0; i < times; i++) {
     body(i);
   }
}
repeat(3, function(n) 
{ 
unless(n % 2, function() );
{ console.log(n, "is even"); 
}); 
});
Amit Patel
@AmitP88
Jan 20 2017 19:34
@jdtdesigns what are some front end stacks that are in most demand?
rami90
@rami90
Jan 20 2017 19:34
@jdtdesigns Thanx Alot you are Amazing man!!
CamperBot
@camperbot
Jan 20 2017 19:34
rami90 sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
:cookie: 867 | @jdtdesigns |http://www.freecodecamp.com/jdtdesigns
Sorin Ruse
@sorinr
Jan 20 2017 19:34
@DanJP2016 don't know how its looking for others but for my eyes its kinda killing. do not rush to change it until u get more oppinions
Muhammad Hasham
@MohammadHasham
Jan 20 2017 19:35
@sorinr can you help me with that snippet?
at times js really hurts
Adel
@AdelMahjoub
Jan 20 2017 19:36
I guess it is the function's names that hurt
nvm
Muhammad Hasham
@MohammadHasham
Jan 20 2017 19:36
no it's the concept thing for me....
@AdelMahjoub
JD Tadlock
@jdtdesigns
Jan 20 2017 19:37
@AmitP88 Angular, React, Vue Js
Sorin Ruse
@sorinr
Jan 20 2017 19:37
@MohammadHasham you said you got it working :smile:
Adel
@AdelMahjoub
Jan 20 2017 19:37
@MohammadHasham javascript is a brilliant script langage, really brilliant
Muhammad Hasham
@MohammadHasham
Jan 20 2017 19:37
no this is another example
@AdelMahjoub i know that but this example is really difficult to understand
@sorinr
Amit Patel
@AmitP88
Jan 20 2017 19:38
@jdtdesigns ah I see. I think i've heard of Vue but havent heard much buzz about it. I think i'll learn that then, just those 3 frameworks for now till I get some apps done with them
I still have to learn ES6 too
JD Tadlock
@jdtdesigns
Jan 20 2017 19:38
@AmitP88 Vue is my favorite so far. It's basically the best of Angular and React imo
But i'd start with Angular as there are countless businesses built on it
and Angular 2 is great
Amit Patel
@AmitP88
Jan 20 2017 19:40
@jdtdesigns ah ok. yeah, I started reading a little bit into Typescript for Ang2
Sabrina Ferguson
@itsacoyote
Jan 20 2017 19:40
I'm enjoying Vue as well, just started on some tuts to get familiar with it. Definitely feels like all the good things of Angular/React
Sorin Ruse
@sorinr
Jan 20 2017 19:40
@MohammadHasham take a look in here: unless(n % 2, function() );
{ console.log(n, "is even");
});
Amit Patel
@AmitP88
Jan 20 2017 19:40
also, what is Redux?
is that a compiler like Typescript?
Muhammad Hasham
@MohammadHasham
Jan 20 2017 19:41
@sorinr typos sorry...
Sabrina Ferguson
@itsacoyote
Jan 20 2017 19:41
Nope, more of a state handler for data in your app
Amit Patel
@AmitP88
Jan 20 2017 19:41
ah ok
man, I really gotta get into app dev
Sabrina Ferguson
@itsacoyote
Jan 20 2017 19:41
bit more complicated stuff that I'd probably say not to get too deep into yet until you get familiar with at least one single page app framework
JD Tadlock
@jdtdesigns
Jan 20 2017 19:42
@AmitP88 Yeah don't worry about Redux lol
Amit Patel
@AmitP88
Jan 20 2017 19:42
lol im starting to wonder if I'll be ready for job hunting after 6 months of this lol
JD Tadlock
@jdtdesigns
Jan 20 2017 19:42
most likely not
but like i said, it's possible
Sabrina Ferguson
@itsacoyote
Jan 20 2017 19:42
at a junior level, perhaps, once you're in a job, you're always learning no matter what :D
Amit Patel
@AmitP88
Jan 20 2017 19:43
@itsacoyote yeah, that's what I'm aiming for, jr front end role
I just want a starting point really
even if the salary isnt there yet
I just want to start somewhere professionally and grow from there
Muhammad Hasham
@MohammadHasham
Jan 20 2017 19:43
@sorinr can you help me to figure out the function calling
JD Tadlock
@jdtdesigns
Jan 20 2017 19:44
@AmitP88 Here's the tip of the day. Stick to one stack and learn it and only it to a comfortable level where you can build whatever you want. If you do this and work your arse off, you can land a junior dev job in 6 to 8 months.
If you flop around and try this and that (like i did), you won't be ready.
Sabrina Ferguson
@itsacoyote
Jan 20 2017 19:44
@AmitP88 for the front end role, focus and really get familiar with HTML5 and CSS3, and alongside that get a good knowledge of Javascript. That'll help you to get into starting something like Angular, which shouldn't be a real requirement for a front-end role
By that I mean, you can start into a front end role with very little knowledge of something like Angular, but grow that. But you'll definitely need to be solid in HTML and CSS, Javascript a plus
Amit Patel
@AmitP88
Jan 20 2017 19:46
@itsacoyote oh yeah, I have a good grasp of html,css already, as well as bootstrap. I'm diving more back into JS territory
@itsacoyote here's my portfolio so far: https://amitp88.github.io/New-Portfolio/
Sabrina Ferguson
@itsacoyote
Jan 20 2017 19:46
@AmitP88 cool! Have you checked out You Don't Know JS? Also Wes Bos' 30 days of Javascript is frikkin' amaaaazing
Amit Patel
@AmitP88
Jan 20 2017 19:47
@itsacoyote oh yeah, ive heard of the 1st one. I'm reading Eloquent JS for now and also a little bit of JS the Good Parts
@jdtdesigns thank you! yeah, I feel like theres so much more to learn that I'm flopping all over the place, but i'll stick to the Ang2, react, vue stack once I get better at JS
CamperBot
@camperbot
Jan 20 2017 19:47
amitp88 sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
:cookie: 868 | @jdtdesigns |http://www.freecodecamp.com/jdtdesigns
deaninous
@deaninous
Jan 20 2017 19:47
@AmitP88 spot on. Spot on, sir
Sabrina Ferguson
@itsacoyote
Jan 20 2017 19:48
@AmitP88 hah, then you're doing fine
Amit Patel
@AmitP88
Jan 20 2017 19:48
i'll also learn Sass real quick to convert my clients css to sass
JD Tadlock
@jdtdesigns
Jan 20 2017 19:48
@AmitP88 Sass isn't used in the browser
Amit Patel
@AmitP88
Jan 20 2017 19:48
@itsacoyote here's my first clients site: https://amitp88.github.io/Khmer-Family-Cafe/#home
JD Tadlock
@jdtdesigns
Jan 20 2017 19:49
it's just a development tool for coding css faster
Amit Patel
@AmitP88
Jan 20 2017 19:49
@jdtdesigns oh I know, I want to use it to lessen and clean up my css code
I have like 400 lines of css style code and 400+ of media query code haha
and like 600 lines of html =P
and 200+ lines of JS, but I need to reduce that for sure
Sorin Ruse
@sorinr
Jan 20 2017 19:50
@MohammadHasham help me figure out what you want to achieve :)
Muhammad Hasham
@MohammadHasham
Jan 20 2017 19:50
shall i send you the book screenshot?
@sorinr
@AmitP88 can i ask which framework you have used?that is pretty nice
Amit Patel
@AmitP88
Jan 20 2017 19:52
@MohammadHasham thank you :) I used bootstraps grid system
CamperBot
@camperbot
Jan 20 2017 19:52
amitp88 sends brownie points to @mohammadhasham :sparkles: :thumbsup: :sparkles:
:cookie: 342 | @mohammadhasham |http://www.freecodecamp.com/mohammadhasham
Sorin Ruse
@sorinr
Jan 20 2017 19:52
@MohammadHasham just explain in plain words and if i can i'll hep
Amit Patel
@AmitP88
Jan 20 2017 19:52
still need some polishing though, but it's like 90% done
JD Tadlock
@jdtdesigns
Jan 20 2017 19:54
@AmitP88 The more you learn design patterns in js, the more you'll continually think your old code is terrible lol.
Muhammad Hasham
@MohammadHasham
Jan 20 2017 19:55
i was trying to understand higher order functions
This function was demonstrating to that how control flow of functions can change
@sorinr
Amit Patel
@AmitP88
Jan 20 2017 19:55
@jdtdesigns lmao, tbh, i'm already starting to think so because of the sheer amount of code I wrote =P
JD Tadlock
@jdtdesigns
Jan 20 2017 19:55
DRY is a concept you can use in anything you code though @AmitP88
Amit Patel
@AmitP88
Jan 20 2017 19:56
@jdtdesigns definitely. I'm actually trying to figure out how to do that with my modal code since that's taking up a lot of repetitive code on my clients site
JD Tadlock
@jdtdesigns
Jan 20 2017 19:56
I love creating modals :D
Muhammad Hasham
@MohammadHasham
Jan 20 2017 19:56
@AmitP88 which framework you have used to make this site?
@jdtdesigns how can i learn design patterns in js?
Amit Patel
@AmitP88
Jan 20 2017 19:57
@MohammadHasham I used bootstraps framework
@jdtdesigns same here. btw, what do you think of the website in general?
JD Tadlock
@jdtdesigns
Jan 20 2017 19:57
@MohammadHasham Search 'javascript design patterns' on youtube or google ;)
Muhammad Hasham
@MohammadHasham
Jan 20 2017 19:58
@AmitP88 That is really cool! how did you made that blinds for carousel of images
Amit Patel
@AmitP88
Jan 20 2017 19:58
@MohammadHasham oh you mean the fade-out effect? I used flickity API
just for the carousel though
Muhammad Hasham
@MohammadHasham
Jan 20 2017 19:59
really cool though!
Amit Patel
@AmitP88
Jan 20 2017 19:59
@MohammadHasham thank you! :D
CamperBot
@camperbot
Jan 20 2017 19:59
amitp88 sends brownie points to @mohammadhasham :sparkles: :thumbsup: :sparkles:
:warning: amitp88 already gave mohammadhasham points
JD Tadlock
@jdtdesigns
Jan 20 2017 19:59
@AmitP88 It's pretty good. There's a lot of empty space that could be condensed and certain content that could be placed in rows instead of line by line.
Muhammad Hasham
@MohammadHasham
Jan 20 2017 20:00
@jdtdesigns i'll check.
Sorin Ruse
@sorinr
Jan 20 2017 20:00
@AmitP88 i would position that .close class btn on top right of the img. its kinda wired to have it on bottom left from ux point of view
Amit Patel
@AmitP88
Jan 20 2017 20:00
@jdtdesigns oh yeah, I still gotta adjust all that. waiting to meet with the client to get the descriptions to fill it in
@sorinr oh yeah, I gotta just that too lol. I need to adjust the scaling of the modal images (they're too big onclick)
JD Tadlock
@jdtdesigns
Jan 20 2017 20:01
@AmitP88 You should lighten the carousel indicators as well. You can only see the active one.
A typical design would be a border for the inactive and background for the active
Amit Patel
@AmitP88
Jan 20 2017 20:02
@jdtdesigns oh there's only one carousel indicator for the active one
JD Tadlock
@jdtdesigns
Jan 20 2017 20:02
yes
but the inactive are too dim and can't be seen
Amit Patel
@AmitP88
Jan 20 2017 20:03
@jdtdesigns oh actually I think that's how flickity designed their carousel in the API
JD Tadlock
@jdtdesigns
Jan 20 2017 20:03
it's just their css conflicting with your background color
you can overwrite their css ;)
Amit Patel
@AmitP88
Jan 20 2017 20:04
@jdtdesigns oh I see. so the background color of their carousel i should make lighter?
JD Tadlock
@jdtdesigns
Jan 20 2017 20:10
yes and you might need to adjust the background color of the dots
.flickity-page-dots .dot {
  background: #aaa;
}
Amit Patel
@AmitP88
Jan 20 2017 20:10
@jdtdesigns oh yeah, I tried that, but for some reason the color doesnt change. I'll have to look at it again though
hey guys, I g2g, but thank you so much for the tips. I really appreciate it and will definitely take them to heart and put them to good use! :) feel to private message me if you'd like and I'll get back to you when I get back on here
JD Tadlock
@jdtdesigns
Jan 20 2017 20:12
@AmitP88 cya
Amit Patel
@AmitP88
Jan 20 2017 20:13
@jdtdesigns tc man, and thanks again :)
CamperBot
@camperbot
Jan 20 2017 20:13
amitp88 sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
:warning: amitp88 already gave jdtdesigns points
John Nunns
@johnnunns
Jan 20 2017 20:14
what is the immediate solution that comes to mind if asked to get a character count of a string?
I thought the map method but maybe I'm wrong
JD Tadlock
@jdtdesigns
Jan 20 2017 20:16
@johnnunns myString.length;
John Nunns
@johnnunns
Jan 20 2017 20:16
sorry, let me rephrase
if the string is banana, how many bs, how many a's, etc
JD Tadlock
@jdtdesigns
Jan 20 2017 20:18
does it need to be dynamic or are you looking for specific charaters provided?
@johnnunns
John Nunns
@johnnunns
Jan 20 2017 20:19
dynamic
I'm going to have a million of these questions btw JD sorry in advance and thanks for any future help @jdtdesigns
CamperBot
@camperbot
Jan 20 2017 20:22
johnnunns sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
:cookie: 869 | @jdtdesigns |http://www.freecodecamp.com/jdtdesigns
John Nunns
@johnnunns
Jan 20 2017 20:22
I've figured it starts off with a for loop for the string
var output = countAllCharacters('banana');
console.log(output); // --> {b: 1, a: 3, n: 2}
that's the goal return
Sorin Ruse
@sorinr
Jan 20 2017 20:24
@johnnunns its a one word string? or we deal with a whole <p> ? :)
John Nunns
@johnnunns
Jan 20 2017 20:25
just one string
with yes I believe only one word
Sorin Ruse
@sorinr
Jan 20 2017 20:28
@johnnunns as you figured it out already think no help needed
John Nunns
@johnnunns
Jan 20 2017 20:29
far from figured it out haha, that's the example answer of what they want that function to produce
I wouldn't ask for help on problems I've already solved :)
JD Tadlock
@jdtdesigns
Jan 20 2017 20:39
@johnnunns What's the challenge name?
John Nunns
@johnnunns
Jan 20 2017 20:39
same thing I've been doing just a prep course for a school, not inside of this site
countAllCharacters
Write a function called "countAllCharacters".

Given a string, "countAllCharacters" returns an object where each key is a character in the given string. The value of each key should be how many times each character appeared in the given string.

Notes:
* If given an empty string, countAllCharacters should return an empty object.

var output = countAllCharacters('banana');
console.log(output); // --> {b: 1, a: 3, n: 2}

Starter Code :
function countAllCharacters(str) {
  // your code here
}
lunaceee
@lunaceee
Jan 20 2017 20:41
Anyone has time to take a look at my personal redesign project? I'm having trouble displaying the background image on the home page. I think I know what the problem is but not sure how to solve it.
kevinliu6102
@kevinliu6102
Jan 20 2017 20:42
Did codepen suddenly start hating openweathermap/ip-api? I went to check on my portfolio and noticed my weather app broke.
Adel
@AdelMahjoub
Jan 20 2017 20:42
var str = "bananas";
        var chars = {};

        for(var i = 0; i < str.length; i++){
            chars[str[i]] = 0;
            for(var j = 0; j < str.length; j++ ){
                if(str[i] === str[j]){
                    chars[str[i]]++;
                }
            }
        }

        console.log(chars);
@johnnunns maybe a solution
kevinliu6102
@kevinliu6102
Jan 20 2017 20:43
Anyone wanna help debug? I think i know where exactly it stops working but can't tell what's wrong.
http://codepen.io/keebin/pen/oBvXgg?editors=1112
Starts at line 18
JD Tadlock
@jdtdesigns
Jan 20 2017 20:45
@johnnunns I figured it out.
lunaceee
@lunaceee
Jan 20 2017 20:46
Here's the URL to my project: http://lunaceee.github.io/landmark/
JD Tadlock
@jdtdesigns
Jan 20 2017 20:46
The only question is do you want the answer or figure it out on your own :P
@johnnunns
Adel
@AdelMahjoub
Jan 20 2017 20:48
posted a solution above, but maybe he want another one too, for his friend's homework too lol
Addison Dalton
@Addison-Dalton
Jan 20 2017 20:49
I'm working on the twitchTV project and I have a problem. My links to a streamer's channel doesn't work. It bring up the page, but it's blank. This isn't just on my project. This happens on any of the twitchTV projects, even the one listed in the guidelines for the project. Just wondering if anyone has run into this before.
JD Tadlock
@jdtdesigns
Jan 20 2017 20:50
Ritvars
@RitvarsZ
Jan 20 2017 20:51
@Addison-Dalton is the page just blank or is there a broken url? Just checked, mine works :)
John Nunns
@johnnunns
Jan 20 2017 20:52
it'll always be figure it out on my own haha. I've started with a for loop
Adel
@AdelMahjoub
Jan 20 2017 20:52
@jdtdesigns I counted the non word chars too
Addison Dalton
@Addison-Dalton
Jan 20 2017 20:52
@RitvarsZ blank page
Ritvars
@RitvarsZ
Jan 20 2017 20:52
@Addison-Dalton Check your json result object, maybe youre targeting the wrong key
Adel
@AdelMahjoub
Jan 20 2017 20:52
@jdtdesigns thanks for that link btw
CamperBot
@camperbot
Jan 20 2017 20:52
adelmahjoub sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
:cookie: 870 | @jdtdesigns |http://www.freecodecamp.com/jdtdesigns
Ritvars
@RitvarsZ
Jan 20 2017 20:53
@Addison-Dalton codepen?
Addison Dalton
@Addison-Dalton
Jan 20 2017 20:53
@RitvarsZ I will, but it's not just my project. It's any project.
JD Tadlock
@jdtdesigns
Jan 20 2017 20:54
@AdelMahjoub Welcome
I wasn't sure if he needed spaces counted. The example looked like it wasn't counting them
John Nunns
@johnnunns
Jan 20 2017 20:55
yeah not sure it's going to test spaces
Ritvars
@RitvarsZ
Jan 20 2017 20:55
@Addison-Dalton well, it works on my phone, not sure whats wrong
Addison Dalton
@Addison-Dalton
Jan 20 2017 20:56
@RitvarsZ I'm thinking one of my chrome extensions may be messing with external links to twitch.
Ritvars
@RitvarsZ
Jan 20 2017 20:56
@Addison-Dalton could be it, try another browser
Addison Dalton
@Addison-Dalton
Jan 20 2017 20:59
@RitvarsZ I think that's it. Thank you for taking a look.
CamperBot
@camperbot
Jan 20 2017 20:59
:cookie: 286 | @ritvarsz |http://www.freecodecamp.com/ritvarsz
addison-dalton sends brownie points to @ritvarsz :sparkles: :thumbsup: :sparkles:
JD Tadlock
@jdtdesigns
Jan 20 2017 21:01
@johnnunns @AdelMahjoub Here's the reduce way. Even shorter. :P http://jsbin.com/tutezuz/edit?js,console
Adel
@AdelMahjoub
Jan 20 2017 21:03
@jdtdesigns nice
Chiu Yong
@chiuyong
Jan 20 2017 21:05
is there someone to help me?
John Nunns
@johnnunns
Jan 20 2017 21:07
man this prep course is intense. I feel as though I haven't learned any of that @jdtdesigns
it runs correctly but for some reason is failing, btw. Don't know why
JD Tadlock
@jdtdesigns
Jan 20 2017 21:07
@chiuyong Post your question
Chiu Yong
@chiuyong
Jan 20 2017 21:07
how can I build this structure with boostrap? @jdtdesigns
Capturar.PNG
JD Tadlock
@jdtdesigns
Jan 20 2017 21:08
@johnnunns What are the test values?
@chiuyong I wouldn't build it with bootstrap. I'd do it with regular css and use flexbox.
Chiu Yong
@chiuyong
Jan 20 2017 21:09
oooh because I'm coding with bootstrap
It can be done by bootstrap?
Melissa Guerrero
@Mmgfrog
Jan 20 2017 21:09
OK, on my Random Quote Machine, I can press a button to generate a quote. But once I do that my Twitter button to tweet the quote isn't clickable. http://codepen.io/Mmgfrog/pen/egOxwq?editors=1010#0
JD Tadlock
@jdtdesigns
Jan 20 2017 21:10
@chiuyong Yes, but you'll need some intermediate Bootstrap knowledge
Melissa Guerrero
@Mmgfrog
Jan 20 2017 21:10
Or, I can click the Twitter button first and it will open a window, but without a quote. Does this have to do with $(document).ready(function() or ??
Chiu Yong
@chiuyong
Jan 20 2017 21:10
I don't have :'(
Because of that, I want to learn
@jdtdesigns
Melissa Guerrero
@Mmgfrog
Jan 20 2017 21:11
@chiuyong getbootstrap.com is very user-friendly
There are many YouTubes about Bootstrap also
Chiu Yong
@chiuyong
Jan 20 2017 21:11
i've read this documentation, but in practice I don't have any idea to start building like the img i've sent
Sorin Ruse
@sorinr
Jan 20 2017 21:12
@jdtdesigns take a look at T and t. it counts T also as t
JD Tadlock
@jdtdesigns
Jan 20 2017 21:12
@chiuyong That's what the learning process is all about. You need to watch some videos on HTML, CSS.
Bootstrap won't make any sense until you know CSS
Which is why i always recommend learning CSS before jumping into BS
@johnnunns It might work now. I just wasn't removing the capital clones. http://jsbin.com/tutezuz/edit?js,console
@sorinr Thanks for noticing that
CamperBot
@camperbot
Jan 20 2017 21:14
jdtdesigns sends brownie points to @sorinr :sparkles: :thumbsup: :sparkles:
:star2: 1121 | @sorinr |http://www.freecodecamp.com/sorinr
Sorin Ruse
@sorinr
Jan 20 2017 21:16
@jdtdesigns welcome. u did a nice job in there
Chiu Yong
@chiuyong
Jan 20 2017 21:19
@jdtdesigns , but do you know how to build with BS that img?
Riccardo M. Pesce
@RiccardoMPesce
Jan 20 2017 21:19
@AmitP88 if you're lookimg for (unpaid) opportunities, you'll have no problem. If your dream is to be front end, just set up a github website and do as much as you can.
Do I really need to use media queries even though I use bootstrap?
JD Tadlock
@jdtdesigns
Jan 20 2017 21:22
@chiuyong The image isn't done with the Bootstrap code. It's done with a background(regular css).
Arpan Das
@Code-of-the-noob
Jan 20 2017 21:22
Hey can you guys give me some advice on how to make it more presentable
JD Tadlock
@jdtdesigns
Jan 20 2017 21:23
@RiccardoMPesce Media queries might be needed for custom styling that BS doesn't cover.
@Code-of-the-noob I have the two unit buttons centered and a little bit further below the text content. Also, add outline: none; to your button css
Chiu Yong
@chiuyong
Jan 20 2017 21:25
@jdtdesigns okay. I'm sorry, but can you help me to build like that?
JD Tadlock
@jdtdesigns
Jan 20 2017 21:26
@chiuyong Me building it for you won't help you learn. You have to start at the bottom and work your way up. If you want to be a web dev, you can't skip ahead in your learning. This stuff doesn't come quickly or easily. You'll have to stick with it and push through the walls you face. ;)
Sorin Ruse
@sorinr
Jan 20 2017 21:28
@Code-of-the-noob i would show data at page load without asking the user to press the Celsius or Fahrenheit buttons. i would also make the temp math.floor to round it to an integer
Riccardo M. Pesce
@RiccardoMPesce
Jan 20 2017 21:28
@jdtdesigns probably, but for very edge cases. They might compromise fluidity tbh.
JD Tadlock
@jdtdesigns
Jan 20 2017 21:30
@johnnunns JS is intense. It's like learning chinese from scratch. You'll never stop learning it and all the things you can do. There's a focus you must have on what you want to achieve with it. Web dev has a certain track and game dev has another. Just keep at it and it will click more and more as you progress.
Chiu Yong
@chiuyong
Jan 20 2017 21:30
@jdtdesigns okay, I got it. Thank you about that
CamperBot
@camperbot
Jan 20 2017 21:30
:cookie: 871 | @jdtdesigns |http://www.freecodecamp.com/jdtdesigns
chiuyong sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
John Nunns
@johnnunns
Jan 20 2017 21:31
@jdtdesigns still not working but it is "working" just as the problem asks
JD Tadlock
@jdtdesigns
Jan 20 2017 21:31
@RiccardoMPesce There's never a case where BS does everything you want out of the box, unless you're building the most simplest of designs.
John Nunns
@johnnunns
Jan 20 2017 21:32
No idea why. It is obvious to me though that there is no way I understand enough js to be doing these problems. Where would you recommend going? just completing the front end here first? @jdtdesigns
I've completed basic java and objects
JD Tadlock
@jdtdesigns
Jan 20 2017 21:33
@johnnunns You'll hit that road block with every challenge to be honest. You just have to keep research and trying new code until something clicks.
I spent a couple of days on some of the advanced algorithms just thinking through how the crap to make it work lol.
John Nunns
@johnnunns
Jan 20 2017 21:34
I think the major difference is that there are hints here in this site and codeacademy so that starts my brain headed to the right direction, but in this course it's defintiely a more "you're on your own" feel
JD Tadlock
@jdtdesigns
Jan 20 2017 21:35
@johnnunns Is there a way for me to run the code on your course just how they have it setup?
Sorin Ruse
@sorinr
Jan 20 2017 21:35
@johnnunns in my opinion just thinking logically about a problem its kinda 50% solved
JD Tadlock
@jdtdesigns
Jan 20 2017 21:35
That's probably the only way to know what's failing.
John Nunns
@johnnunns
Jan 20 2017 21:36
the course is free to sign up for, they may email you but you can easily unsubscribe
that's the only way I could actually think of doing it
@sorinr It depends on the problem. Logic can only take you so far if the skillset is lacking
JD Tadlock
@jdtdesigns
Jan 20 2017 21:38
@johnnunns So they probably have test cases like this right?
countCharacters('Some string.');
countCharacters('Second string.');
countCharacters('Another string.');
countCharacters('One more string.');
John Nunns
@johnnunns
Jan 20 2017 21:39
failed
should_return_an_object
should_return_an_object_where_each_property_gives_a_character_in_the_string_with_its_number_of_appearances
should_return_an_object_empty_object_if_passed_an_empty_string
it can't be right, you're definitely returning an object
and I ran the empty string it worked there as well
Sorin Ruse
@sorinr
Jan 20 2017 21:40
@johnnunns the logic takes you 50% of the road. the skillset adds the remaining mealage :)
Joshua Steele
@joshuapsteele
Jan 20 2017 21:41
@forkerino perfect! Thanks for the the help.
CamperBot
@camperbot
Jan 20 2017 21:41
joshuapsteele sends brownie points to @forkerino :sparkles: :thumbsup: :sparkles:
:cookie: 714 | @forkerino |http://www.freecodecamp.com/forkerino
JD Tadlock
@jdtdesigns
Jan 20 2017 21:42
@johnnunns Are you consoling out the result yourself to see what they're getting?
John Nunns
@johnnunns
Jan 20 2017 21:42
they're not showing me their arguments
I removed the console.log bit because it was printing it and then finishing with undefined
so i just left in the function and it works perfect but same result
no undefined
OH
haha :0
JD Tadlock
@jdtdesigns
Jan 20 2017 21:43
@johnnunns It sounds like you might have changed something you're not supposed to in their code
John Nunns
@johnnunns
Jan 20 2017 21:43
countAllCharacters is what it's looking for
haha
should_return_an_object_where_each_property_gives_a_character_in_the_string_with_its_number_of_appearances
only failure now
JD Tadlock
@jdtdesigns
Jan 20 2017 21:45
did it have something like this?
// Only code below this line

// Only code above this line
@johnnunns
John Nunns
@johnnunns
Jan 20 2017 21:45
Instructions from your teacher:
Write a function called "countAllCharacters".

Given a string, "countAllCharacters" returns an object where each key is a character in the given string. The value of each key should be how many times each character appeared in the given string.

Notes:
* If given an empty string, countAllCharacters should return an empty object.

var output = countAllCharacters('banana');
console.log(output); // --> {b: 1, a: 3, n: 2}

Starter Code :
function countAllCharacters(str) {
  // your code here
}
Joshua Steele
@joshuapsteele
Jan 20 2017 21:46
So, in my <nav> I'd like all the links to be on the right. I used CSS to float: right; the ul in my #mainNav, but the links bleed off the right side of the page. At least, they do in Codepen. Any suggestions? I'm working on my Personal Portfolio Page.
John Nunns
@johnnunns
Jan 20 2017 21:46
the only bit you start with is the startercode
JD Tadlock
@jdtdesigns
Jan 20 2017 21:46
@johnnunns So what's your final code look like?
John Nunns
@johnnunns
Jan 20 2017 21:47
```
var string = 'banana';

function countAllCharacters(str) {
  return str.replace(/\W/g, '')
    .toLowerCase()
    .replace(/(.)(?=.*\1)/g, '')
    .split('')
    .reduce(function(result, letter) {
      var regex = new RegExp('[^' + letter + ']', 'g');
      result[letter] = string.replace(regex, '').length;

      return result;
  }, {})
}

countAllCharacters(string);
JD Tadlock
@jdtdesigns
Jan 20 2017 21:47
@joshuapsteele are you using Bootstrap?
John Nunns
@johnnunns
Jan 20 2017 21:47
=> { b: 1, n: 2, a: 3 }
mikecerang
@mikecerang
Jan 20 2017 21:47
Hi, I am working on "Build a Tribute Page". Do I need to use Bootstrap only or can I only use HTML?
JD Tadlock
@jdtdesigns
Jan 20 2017 21:48
@mikecerang You can use whatever framework, library you want
Francois van Leersum
@Blockshot12
Jan 20 2017 21:48
@mikecerang Bootstrap is optional
Joshua Steele
@joshuapsteele
Jan 20 2017 21:48
@jdtdesigns for the navbar, you mean? No. Should I be, in your opinion?
mikecerang
@mikecerang
Jan 20 2017 21:48
Thank you everyone
JD Tadlock
@jdtdesigns
Jan 20 2017 21:48
I wouldn't, but needed to know to get you an answer. @joshuapsteele
Joshua Steele
@joshuapsteele
Jan 20 2017 21:49
@jdtdesigns here's the code
<nav id="mainNav">
  <ul>
    <li><a href="#page-one">Home</a></li>
    <li><a href="#page-two">About</a></li>
    <li><a href="#page-three">Portfolio</a></li>
    <li><a href="#page-four">Contact</a></li>
  </ul>
</nav>
#mainNav {
  background-color: black;
  color: #ffffff;
  line-height: 4em;
  padding: 0 1em;
  position: fixed;
  top: 0em;
  width: 100%;
}

#mainNav {
  a,
  a:link,
  a:visited,
  a:hover,
  a:active {
    color: #eee;
    text-decoration: none;
    display: inline-block;
    text-align: right;
    padding: 0 1em;
  }
  a:hover {
    color: #262626;
    background-color: #e0e0e0
  }
  ul {
    float: right;
    margin-right: 50px;
  }
  li {
    display: inline;
  }
}
Joshua Steele
@joshuapsteele
Jan 20 2017 21:51
Right now, I'm bumping it to the left with that margin-right: 50px;
ehutchllew
@ehutchllew
Jan 20 2017 21:59
Anyone really familiar with Bootstrap? Specifically navbar and collapsed navbar buttons?
Why won't this navbar scroll with the page?
<nav class="navbar navbar-inverse">
  <div class="container-fluid">
    <div class="navbar-header">
      <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#myNavbar">
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>                        
      </button>
      <a class="navbar-brand" href="#">Joshua P. Steele</a>
    </div>
    <div class="collapse navbar-collapse" id="myNavbar">
      <ul class="nav navbar-nav navbar-right">
        <li class="active"><a href="#page-one">Home</a></li>
        <li><a href="#page-two">About</a></li>
        <li><a href="#page-three">Portfolio</a></li>
        <li><a href="#page-four">Contact</a></li>
      </ul>
    </div>
  </div>
</nav>
nvm, fixed it with navbar-fixed-top :)
ehutchllew
@ehutchllew
Jan 20 2017 22:23
@joshuapsteele i fixed my issue, thanks though :)
CamperBot
@camperbot
Jan 20 2017 22:23
ehutchllew sends brownie points to @joshuapsteele :sparkles: :thumbsup: :sparkles:
:cookie: 147 | @joshuapsteele |http://www.freecodecamp.com/joshuapsteele
Joshua Steele
@joshuapsteele
Jan 20 2017 22:34
I need help achieving the same kind of alignment as the "sample" Personal Portfolio (https://codepen.io/freeCodeCamp/full/YqLyXB) How does that page achieve the "center column" in which all the elements are contained down the entire page -- even the nav bar elements?
I'm assuming this is some sort of div container, but I'm unsure how to apply that to the nav bar and everything else.
Rimi.
@Codevotee
Jan 20 2017 22:49
@joshuapsteele you can just place everything in a div and then style that div by giving it a width and centering it,
width and centering example:
div {
width: 70%; /*gives it the width of 70% of the parent element*/
margin: auto; /*centers the div*/
}
Sunny Wong
@swong194
Jan 20 2017 23:13
hi every1
im attempting my portfolio page
im wondering why there is a gap between my sections
Anabel
@AnabelSalomone
Jan 20 2017 23:14
Hello everybody! Can anybody tell me why the last <div> goes down? https://jsfiddle.net/marieanabel/Lms2190g/show/
is there anyway I can fix that so the last div stays inline with the others?
Simon Cordova
@gbsimon87
Jan 20 2017 23:17
@AnabelSalomone...divs are block-level elements
In other words, they'll take up a whole block...
MarkABrady
@MarkABrady
Jan 20 2017 23:18
I need help
Simon Cordova
@gbsimon87
Jan 20 2017 23:18
change the display property to inline block to have it act as an inline element (ie, not go down to the next line)
You may need to adjust the widths of the elements to fit the screen though
@MarkABrady what do you need buds?
MarkABrady
@MarkABrady
Jan 20 2017 23:19
I'm on the Random Quote Machine and I can't figure out this Ajax request thing to save my life
It's crazy confusing
Simon Cordova
@gbsimon87
Jan 20 2017 23:19
I see...d
do you have a codepen or anything?
MarkABrady
@MarkABrady
Jan 20 2017 23:20
I use workspaces on teamtreehouse
Are there any layman resources to better understand this?
Simon Cordova
@gbsimon87
Jan 20 2017 23:21
hold on let me dig in my files one second
Sunny Wong
@swong194
Jan 20 2017 23:22
NVM I SOLVED IT XD
Simon Cordova
@gbsimon87
Jan 20 2017 23:23
@MarkABrady this guy is amazing...
https://www.youtube.com/watch?v=6mT3r8Qn1VY
He uses P5 framework, but the getjson and ajax functionalities also work in vanilla JS and jQuery
cjljohnson
@cjljohnson
Jan 20 2017 23:39
@cjljohnson
Is there a tool i can use to draw asvg shape using a pen tool then export it as html to use in my project?
My Bernie Tribute page, do the weblinks send you to the website?