These are chat archives for FreeCodeCamp/HelpFrontEnd

7th
Nov 2016
Coy Sanders
@coymeetsworld
Nov 07 2016 00:05
yeah FCC doesn't teach you everything you need to know necessarily to do projects, just points you in right direction
and a while back Random Quote Machine was actually a beginner-level project
it was before learning JSON/AJAX requests, technically you could do the challenge without using an api
just create an array of quotes locally
j1417
@j1417
Nov 07 2016 00:09
Hi! why i need to use stopPropagation here....the button #searchTerm shows data.....
$("#searchTerm").keypress(function(e){

    if(e.which==13) {$("#search").click();
    e.stopPropagation();
    return false;}
  });

search shows data

Walid Ashri
@walidashri
Nov 07 2016 00:14
@j1417 stopPropagation() to stop passing the event handler to parent element
j1417
@j1417
Nov 07 2016 00:19
what does it mean in my page??http://codepen.io/Juan1417/pen/XNJeWd @walidashri
Torrell Stokes
@coderStokes
Nov 07 2016 00:21
Hello I'm working on my tribute page; however, I have an image on my computer that I would like to use. How to I implement the image using CodePen.io?
Walid Ashri
@walidashri
Nov 07 2016 00:22
@j1417 if u removed the stopPropagation and the return false line no effect of ur keypress
j1417
@j1417
Nov 07 2016 00:23
you can upload it here https://imgsafe.org/ @coderStokes
why?? i dont understand :worried:
@walidashri
Walid Ashri
@walidashri
Nov 07 2016 00:25
@j1417 without it the event gonna be passed to the parent which has no event handler check this
j1417
@j1417
Nov 07 2016 00:25
@walidashri the parent is the form??
Torrell Stokes
@coderStokes
Nov 07 2016 00:27
Thank for you so much @j1417!
CamperBot
@camperbot
Nov 07 2016 00:27
coderstokes sends brownie points to @j1417 :sparkles: :thumbsup: :sparkles:
:cookie: 267 | @j1417 |http://www.freecodecamp.com/j1417
Walid Ashri
@walidashri
Nov 07 2016 00:35
@j1417 the parent is the form yes and try to add the form id to the func with no stopPropagation and the return false line and see the effect
and even try the form parent the div
j1417
@j1417
Nov 07 2016 00:40
@walidashri why i do not need to add it in the other func??
emamadordev
@emamadordev
Nov 07 2016 01:57
Just finished twitch project. Need some feedback: https://codepen.io/emmanuelamador/full/dOPzqv/
buiphuking
@buiphuking
Nov 07 2016 02:01
if i use bootstrap to create layout , is it can responsive ?
Walid Ashri
@walidashri
Nov 07 2016 02:14
@emamador nice work need more touch to the notification
and some button to toggle onlines and offlines
@buiphuking yes using the right classes
c0d0er
@c0d0er
Nov 07 2016 02:18
emamadordev
@emamadordev
Nov 07 2016 02:19
@walidashri thanks :)
CamperBot
@camperbot
Nov 07 2016 02:19
emamador sends brownie points to @walidashri :sparkles: :thumbsup: :sparkles:
:cookie: 594 | @walidashri |http://www.freecodecamp.com/walidashri
Tony Miri
@TonyMiri
Nov 07 2016 02:27
@c0d0er I would add a noise of some sort when the timer runs out to alert people. Also, I expected each timer to start automatically at the end of the other, but I suppose that is up to you. Otherwise I like it!
Walid Ashri
@walidashri
Nov 07 2016 02:27
@c0d0er Nice work
you can set the fill height back to zero before the start of the break
c0d0er
@c0d0er
Nov 07 2016 02:28
@FatTone225 there is a noise when the timer runs out

@walidashri what does this mean?

you can set the fill height back to zero before the start of the break

@FatTone225 @walidashri thanks
CamperBot
@camperbot
Nov 07 2016 02:30
c0d0er sends brownie points to @fattone225 and @walidashri :sparkles: :thumbsup: :sparkles:
:cookie: 595 | @walidashri |http://www.freecodecamp.com/walidashri
:cookie: 385 | @fattone225 |http://www.freecodecamp.com/fattone225
Tony Miri
@TonyMiri
Nov 07 2016 02:30
@c0d0er Oh maybe because I used the skip button
Walid Ashri
@walidashri
Nov 07 2016 02:31
@c0d0er the fill goes to 100% when work starts then reduces to zero when break starts if this what you want fine
I meant you can make it start from 0 to 100 again
c0d0er
@c0d0er
Nov 07 2016 02:32
@walidashri oh i see, got it
Walid Ashri
@walidashri
Nov 07 2016 02:32
@c0d0er :+1:
Tony Miri
@TonyMiri
Nov 07 2016 02:35
Can someone tell me if these links work? I'm getting a blank page. http://codepen.io/TonyMiri/pen/yamwVR
Spencer
@coderamen
Nov 07 2016 03:25
hei ppl...does anybody use atom code editor??
joshandevera
@joshandevera
Nov 07 2016 03:39
how to put color on the navbar http://codepen.io/joshdv92/pen/ENapZR
Bin Ling
@HoBinLing
Nov 07 2016 04:03
Hi would like to know where i can refer to to look at all the fonts available in bootsrap? searched google but i got answers for icons instead of the list of fonts i could use...
Coy Sanders
@coymeetsworld
Nov 07 2016 04:07
I don't think bootstrap provides fonts @HoBinLing
Abhishek Kumar
@Mr-Kumar-Abhishek
Nov 07 2016 04:07
Coy Sanders
@coymeetsworld
Nov 07 2016 04:08
I saw that too, I don't believe those come from Bootstrap though, I could be wrong
Abhishek Kumar
@Mr-Kumar-Abhishek
Nov 07 2016 04:18
@coymeetsworld these fonts are not originated from bootstrap but ermm...one could say inherited by bootstrap
@coymeetsworld which simplifies its usage
Coy Sanders
@coymeetsworld
Nov 07 2016 04:18
aren't they already provided in the browser?
Abhishek Kumar
@Mr-Kumar-Abhishek
Nov 07 2016 04:21
@coymeetsworld browser .. yes most of the browser have these fonts , (it depends on the system too) but think of them as variables or structures for storing configuration ...
Coy Sanders
@coymeetsworld
Nov 07 2016 04:21
yes but the original question was where to find fonts available in Bootstrap, there isn't any
fonts either come from the browser or you have to import them separately from another source, like Google Fonts
Abhishek Kumar
@Mr-Kumar-Abhishek
Nov 07 2016 04:23
@coymeetsworld correct ~ if the system doesn't have those fonts it wont show. so you have to import them separately
@coymeetsworld bootstrap only as icons as fonts with them if you are looking for font files
Coy Sanders
@coymeetsworld
Nov 07 2016 04:25
I'm not looking for anything :)
Abhishek Kumar
@Mr-Kumar-Abhishek
Nov 07 2016 04:27
@coymeetsworld oh... my apologies ...
@HoBinLing if you are looking for font files in your system and if its is a linux system it could be found at etc/fonts directory probably
/usr/share/fonts or here
joshandevera
@joshandevera
Nov 07 2016 04:42
do you use <a> for images you want to link from you document folder like photos?
Coy Sanders
@coymeetsworld
Nov 07 2016 04:50
@joshandevera you need to host photos or any files somewhere that's accessible from the internet
unless you're making a local website that doesn't need to be viewed anywhere besides your computer, then yeah you could do that
joshandevera
@joshandevera
Nov 07 2016 04:51
like facebooK?
Coy Sanders
@coymeetsworld
Nov 07 2016 04:51
something like dropbox would be better
if its images theres free image hosting you can use
if you do a google search you can find many
joshandevera
@joshandevera
Nov 07 2016 04:52
@coymeetsworld thanks man
CamperBot
@camperbot
Nov 07 2016 04:52
joshandevera sends brownie points to @coymeetsworld :sparkles: :thumbsup: :sparkles:
:star2: 1495 | @coymeetsworld |http://www.freecodecamp.com/coymeetsworld
Coy Sanders
@coymeetsworld
Nov 07 2016 04:52
no problem
joshandevera
@joshandevera
Nov 07 2016 04:55
i'm going to put a photo on my portfolio project.
@coymeetsworld would dropbox work?
Coy Sanders
@coymeetsworld
Nov 07 2016 04:56
yes, thats what I use for my projects
i also host other files too like JSON data just fine
joshandevera
@joshandevera
Nov 07 2016 04:56
ok thanks :)
WhiteLeaf1103
@WhiteLeaf1103
Nov 07 2016 05:06
CAN ANYONE HELP ME! I cant get my text inside my #main to float to the right of the navbar but not be to the right of the whole div.
Kenneth Malicay
@kennethlumalicay
Nov 07 2016 05:10
do float left on main
WhiteLeaf1103
@WhiteLeaf1103
Nov 07 2016 05:14
didn't work
Abhishek Kumar
@Mr-Kumar-Abhishek
Nov 07 2016 05:15
@WhiteLeaf1103 you want text from right aligned ? or want text to occupy space from right side ??
WhiteLeaf1103
@WhiteLeaf1103
Nov 07 2016 05:16
I want all the text to write right of the nav bar and never go under it.
Abhishek Kumar
@Mr-Kumar-Abhishek
Nov 07 2016 05:18
@WhiteLeaf1103 like this ?? http://codepen.io/anon/pen/mOyGMm
WhiteLeaf1103
@WhiteLeaf1103
Nov 07 2016 05:18
did you send me a virus? cause the pages just reloads and reloads
@Mr-Kumar-Abhishek something wrong with that
Abhishek Kumar
@Mr-Kumar-Abhishek
Nov 07 2016 05:20
it is not a virus . do not accuse of something of what you are not sure of
WhiteLeaf1103
@WhiteLeaf1103
Nov 07 2016 05:22
Accuse? excuse you.... I asked.
I didn't say @Mr-Kumar-Abhishek GAVE ME A VIRUS OMG SOMEONE HELP!....
Coy Sanders
@coymeetsworld
Nov 07 2016 05:23
:confused:
Abhishek Kumar
@Mr-Kumar-Abhishek
Nov 07 2016 05:23
excuse me ..I have better things to do than dealing with this childish tantrums
WhiteLeaf1103
@WhiteLeaf1103
Nov 07 2016 05:26
You the one that got butt hurt. I apologize tho. Thanks for the attempt. If it was outta your scope just say so... ;)
Abhishek Kumar
@Mr-Kumar-Abhishek
Nov 07 2016 05:27
oh yes sir I am butt hurt ~ your problem is a great scientific dilemma
WhiteLeaf1103
@WhiteLeaf1103
Nov 07 2016 05:29
Truly I am sorry. @Mr-Kumar-Abhishek I didn't mean to offend you or accuse you of anything. Have a good day.
Coy Sanders
@coymeetsworld
Nov 07 2016 05:30
lol
BehindTheMath
@BehindTheMath
Nov 07 2016 05:38
Where does the error message from element.setCustomValidity go?
*element.setCustomValidity()
Manuel Baez
@Many324
Nov 07 2016 06:02
what's up guys...I am in the portfolio webpage challenge and I am not sure if I should skip it to learn a little more before attempting to do the portfolio...should I just start it or skip it for now?
Aaron Kvarnlov-Leverty
@bozeman42
Nov 07 2016 06:03
I am also on that challenge.
I think the idea is probably to do what you can now.
You can come back and make it more beautiful later. Just fulfill the user stories and do your best
Manuel Baez
@Many324
Nov 07 2016 06:03
the example they give looks pretty hard...
yeah, that's what I thought I could do
thanks
Coy Sanders
@coymeetsworld
Nov 07 2016 06:36
yep @bozeman42 is right @Many324, I would give it a shot
doesn't have to be perfect, you can always go back and improve on it especially when you have more projects under your belt
reason it's listed so early is because it doesn't technically require JavaScript, just HTML and CSS
André
@pennyJack
Nov 07 2016 07:07
@Many324 @coymeetsworld Haha, I'm actually on to that challenge at the moment as well. It's pretty tough in some ways, but I already learned a lot. I try to make it as good as possible for the moment and return later if I required some new skills. I mainly used Bootstrap since I guess it's to hard right now to lay out a full grid system your own. Eventually it might make sense to do everything yourself in order to gain new knowledge, i.e. to figure out how things actually work (like frameworks). Do you agree or think differently!?
Coy Sanders
@coymeetsworld
Nov 07 2016 07:08
yeah I tossed out the Bootstrap once I learned Flexbox and more CSS
Bootstrap is nice to use initally because you don't have to mess around with CSS to get things looking how they're supposed to be
André
@pennyJack
Nov 07 2016 07:16
@coymeetsworld Totally agree on that. Heard about flexbox but haven't looked at it yet. Can you fully replace the Bootstrap grid with that "new" CSS technique? Is it difficult to learn? Can you recommend a source for it?
Coy Sanders
@coymeetsworld
Nov 07 2016 07:22
look up Flexbox Defense, and yes its a much better system for laying out things than BS grid
@pennyJack
André
@pennyJack
Nov 07 2016 07:25
@coymeetsworld Haha nice, this is great! Thanks!
CamperBot
@camperbot
Nov 07 2016 07:25
pennyjack sends brownie points to @coymeetsworld :sparkles: :thumbsup: :sparkles:
:star2: 1498 | @coymeetsworld |http://www.freecodecamp.com/coymeetsworld
André
@pennyJack
Nov 07 2016 07:52
@coymeetsworld You already seem to have invested quite some of your time in FCC. I'm wondering if you could shortly recap your experiences so far with FCC. I'm actually quite new to this whole coding thing and I sometimes question myself if FCC is the right fit, whether maybe it'd be a better choice to attend a Bootcamp (in terms of time input / skills output relation) or something alike. ;)
kat-mag
@kat-mag
Nov 07 2016 08:25
@pennyJack Nobody's gonna tell you if it's the right fit. If you can learn on your own and research a lot (like you will be doing on a day to day basis when you do work in this industry...), then no matter where you learn you're gonna be fine. FCC is great because it challenges you to do the work on your own (or come here if you got a problem). Bootcamps are great too. Whether you gonna learn more doing one or the other - totally depends on you.
André
@pennyJack
Nov 07 2016 08:41
@kat-mag Ok, thanks!
CamperBot
@camperbot
Nov 07 2016 08:41
pennyjack sends brownie points to @kat-mag :sparkles: :thumbsup: :sparkles:
:cookie: 399 | @kat-mag |http://www.freecodecamp.com/kat-mag
Coy Sanders
@coymeetsworld
Nov 07 2016 08:56
I am weary of paid bootcamps @pennyJack, I don't think you can be sufficiently trained or given enough knowledge in a short period of time
not to mention it costs a ridiculous amount of money and make some pretty faulty promises
I like FCC, also granted I do have a background, I have a CS-related degree and work in the industry, although not as a dev anymore
I would go with that first, if anything it'll be a cheaper alternative to figure out if this is something you may want to do for a career, or just a hobby perhaps
Sorin Ruse
@sorinr
Nov 07 2016 09:08
@coymeetsworld :+1:
André
@pennyJack
Nov 07 2016 09:25
@coymeetsworld Yeah, that's what I tought too. Most of them are quite steep, but some are doing really good marketing in fact. ;) Anyway, I'll stick to the free route for now, see how far I'll come. I mean in the end there's nothing to lose with that and some coding skills are probably worth a bit in tomorrows working environment. By the way, I don't aspire to particularly work in that kind of field, I just think coding is exciting and I have plenty of ideas I'd like see come to live. If I'll eventually end up there, it's fine too.
André
@pennyJack
Nov 07 2016 09:32
@coymeetsworld Anyway, thanks!
CamperBot
@camperbot
Nov 07 2016 09:32
pennyjack sends brownie points to @coymeetsworld :sparkles: :thumbsup: :sparkles:
:star2: 1499 | @coymeetsworld |http://www.freecodecamp.com/coymeetsworld
Coy Sanders
@coymeetsworld
Nov 07 2016 09:33
np @pennyJack, yeah if you're not looking particularly to get into the field then bootcamps wouldn't be what you want, as that is their main objective
joshandevera
@joshandevera
Nov 07 2016 10:05
how can you change fonts and color on jumbotrons?
Sorin Ruse
@sorinr
Nov 07 2016 10:17
@joshandevera i would just override the css attributes in jumbotron class with what i need like color: #myhexcolorhere; font-family: 'CrazyFontIWant'; etc
joshandevera
@joshandevera
Nov 07 2016 10:21
@sorinr thanks
CamperBot
@camperbot
Nov 07 2016 10:21
joshandevera sends brownie points to @sorinr :sparkles: :thumbsup: :sparkles:
:cookie: 825 | @sorinr |http://www.freecodecamp.com/sorinr
Sorin Ruse
@sorinr
Nov 07 2016 10:22
@joshandevera welcome
Aarya Bhorra
@aarya1302
Nov 07 2016 10:57
Hey guys
How can I make a json api that I can access through code pen
?
A_A
@Otto-AA
Nov 07 2016 11:23
@aarya1302 $.getJSON(linkToApiUrl).done(function(response) { your Code here}).fail(function() { fail message here});
Alexander
@indieveed
Nov 07 2016 11:55
Hello everyone, does anybody know the best way to track the reason why spinning tab loading indicator keeps spinning and the load event never comes? I've tried to use chrome devtools' timeline, but it tells me that there are no pending requests. I'm kind of frustrated. And it seems to be connected with ads (I'm using google DFP), because everything is OK with adblock enabled.
Aarya Bhorra
@aarya1302
Nov 07 2016 11:56
@Otto-AA thank you but i'm searching for a way to use the api that is stored on my computer and use it with code pen
CamperBot
@camperbot
Nov 07 2016 11:56
aarya1302 sends brownie points to @otto-aa :sparkles: :thumbsup: :sparkles:
:cookie: 366 | @otto-aa |http://www.freecodecamp.com/otto-aa
A_A
@Otto-AA
Nov 07 2016 11:57
@indieveed What about console.log when it should loading, loads and ended loading?
Thinh Cao
@tcao2
Nov 07 2016 12:47
thank you @TylerMoeller
CamperBot
@camperbot
Nov 07 2016 12:47
tcao2 sends brownie points to @tylermoeller :sparkles: :thumbsup: :sparkles:
:cookie: 919 | @tylermoeller |http://www.freecodecamp.com/tylermoeller
Thinh Cao
@tcao2
Nov 07 2016 12:53
@TylerMoeller I see that the URL you suggested is pretty much the same as mine, only with the 'callback=?' added. What does that do though? And it worked :)
Mitchell Stewart
@mitchstewart08
Nov 07 2016 13:03
I'm trying to figure out why my lat and lon variables are not being updated on lines 7&8 https://codepen.io/mitchellstewart08/pen/eBYyBq?editors=1111
any thoughts?
Clyde Lobo
@oppiniated
Nov 07 2016 13:14
@mitchstewart08 js error. Load jquery first and then bootstrap
Mitchell Stewart
@mitchstewart08
Nov 07 2016 13:19
@oppiniated fixed that bootstrap error but lat and lon still aren't being updated outside of the scope of that function
danielfiko
@danielfiko
Nov 07 2016 13:21
Does anyone have a clue about how i can vertically center the qoute relative to the image?
(Just saved an updated version, please rerun)
Thinh Cao
@tcao2
Nov 07 2016 13:23
@danielfiko I think taking out the grid layout will help
i don't see why you would need a grid layout here. Everything is vertically aligned in a single column
danielfiko
@danielfiko
Nov 07 2016 13:25
On a desktop the qoute is on the left and the image on the right
Thinh Cao
@tcao2
Nov 07 2016 13:25
@mitchstewart08 not related to your question, but your URL needs to have an API (appid) key, or it won't work
@mitchstewart08 and try this URL to get geolocation: http://ip-api.com/json
Mitchell Stewart
@mitchstewart08
Nov 07 2016 13:29
ty
Thinh Cao
@tcao2
Nov 07 2016 13:31
np bud :)
@danielfiko : did taking out the grid system work?
danielfiko
@danielfiko
Nov 07 2016 13:46
@tcao2 nope. Then the qoute placed on top of the image
I need it to be side by side
Hence the use of grid
Chima Amaike
@daUnborn
Nov 07 2016 13:47
Hello World
CamperBot
@camperbot
Nov 07 2016 13:47

welcome to FreeCodeCamp @daUnborn!

Chima Amaike
@daUnborn
Nov 07 2016 13:48
Hello World
CamperBot
@camperbot
Nov 07 2016 13:48

welcome to FreeCodeCamp @daUnborn!

Thinh Cao
@tcao2
Nov 07 2016 14:04
@danielfiko i still don't see why you need a grid system tbh, maybe I am not understanding your question correctly.
simply use paragraph
Sorin Ruse
@sorinr
Nov 07 2016 14:05
@oppiniated i would add: p cite { font-size: 2em; } for more readability
Thinh Cao
@tcao2
Nov 07 2016 14:07
@danielfiko and are you trying to re-create the sample solution, or make your own?
Sorin Ruse
@sorinr
Nov 07 2016 14:13
@tcao2 ip location sometimes reports wrong coordinates data if you have a dynamic ip
Nico Vergauwen
@kyriediculous
Nov 07 2016 14:16
Why isn't my API request to ip-api.com working? It was working yesterday on a different computer. Didn't change anything to the code http://codepen.io/kyriediculous/pen/jVEqMO.
danielfiko
@danielfiko
Nov 07 2016 14:18
@tcao2 i am making my own. What i am looking for is how to make the blockqoute align to the left of the images with equal distance from the top and bottom of the image height (aka vertical centered)
Sorin Ruse
@sorinr
Nov 07 2016 14:20
@danielfiko here some info that may help on centering: https://css-tricks.com/centering-css-complete-guide/
Nico Vergauwen
@kyriediculous
Nov 07 2016 14:22
@danielfiko use display:table;
or bootstrap collumn offsets, or margin auto;
Sorin Ruse
@sorinr
Nov 07 2016 14:31
@danielfiko this is what u want? example
Monesul Haque
@mones-cse
Nov 07 2016 14:36

hi can any one help me with jsx or react
i want to do someting like this

const Recipe =({recipe}) =>{
  return (
      <div>
        {let a=recipe.ingredient.split(',')} 
      </div>
  )

}

but looks like inside jsx i can't use var let const any key word so if i want to assign certain data to a variable what should i do ?

vínαч puppαl
@vinaypuppal
Nov 07 2016 14:51
@mones-cse you can do that kind of stuff before your return statement like below
const Recipe =({recipe}) =>{
  const a = recipe.ingredient.split(',')
  return (
      <div>
        {
          a.map({item} => {
            return <span>item</span>
          });
        } 
      </div>
  )
}
Zoe Charles
@zoecharles
Nov 07 2016 14:52
hey im having some trouble getting my <ul> center aligned with the bullets directly next to the words
joshandevera
@joshandevera
Nov 07 2016 14:54
how can i move the picture to right and responsive, also how can i make it into a perfect circle https://codepen.io/joshdv92/pen/ENapZR
will someone please look at my code and help me align the unordered list>
joshandevera
@joshandevera
Nov 07 2016 15:04
@zoecharles seems good to me
Nico Vergauwen
@kyriediculous
Nov 07 2016 15:17
@joshandevera class="img-respnsive" and border-radius:50%
img-responsive*
kat-mag
@kat-mag
Nov 07 2016 15:18
@zoecharles Pleeeeeeeeeeease, don't code like that... You've added bootstrap, use it. Giving such margins & values in pixels gives NO responsiveness and makes issues like the one you're having right now.
danielfiko
@danielfiko
Nov 07 2016 15:18
@sorinr exactly what i was looking for. thank you!
CamperBot
@camperbot
Nov 07 2016 15:19
danielfiko sends brownie points to @sorinr :sparkles: :thumbsup: :sparkles:
:cookie: 826 | @sorinr |http://www.freecodecamp.com/sorinr
Sorin Ruse
@sorinr
Nov 07 2016 15:19
@danielfiko welcome
Nico Vergauwen
@kyriediculous
Nov 07 2016 15:20
All that css just to center? so inefficient...
Sorin Ruse
@sorinr
Nov 07 2016 15:20
@danielfiko i've put that bg #ccc just to see better the elements are centered
Nico Vergauwen
@kyriediculous
Nov 07 2016 15:21
@zoecharles use bootstrap classes over custom css as much as possible, watch a youtube tutorial and work according to best practices. It's something I struggled with too because bootstrap isn't explained that well in freecodecamp
@zoecharles and the margins of the body can be written like this: margin:20px auto;
@zoecharles
body {
  margin:20px auto;
}

ul {
display:table;}
kat-mag
@kat-mag
Nov 07 2016 15:25
@zoecharles btw. <center> tag is deprecated, you shouldn't be using it
Monesul Haque
@mones-cse
Nov 07 2016 15:48
@vinaypuppal thanks
CamperBot
@camperbot
Nov 07 2016 15:48
mones-cse sends brownie points to @vinaypuppal :sparkles: :thumbsup: :sparkles:
:cookie: 638 | @vinaypuppal |http://www.freecodecamp.com/vinaypuppal
BehindTheMath
@BehindTheMath
Nov 07 2016 15:50
Where does the error message from element.setCustomValidity() go?
Sorin Ruse
@sorinr
Nov 07 2016 15:53
@BehindTheMath are you using devtools to debug?
BehindTheMath
@BehindTheMath
Nov 07 2016 15:54
Yes, I see it's set in the element's properties, but it doesn't seem to be reflected on the page.
If I have to manually display iy anyway, what's the point in setting a message instead of just a boolean if it's valid of not?
Sorin Ruse
@sorinr
Nov 07 2016 15:56
@BehindTheMath can you post the code or the link to ur pen? its hard to understand whats causing a problem without seeing the code
Kartik Mudgal
@Sprinting
Nov 07 2016 16:02
Would anyone be able to tell me why my link_context_menu function doesn't work
?
I call it for each node in a NodeList object
blob
and evt.preventDefault doesn't work
This is probably a scoping problem, I'm not understanding why
Nitin Chandran Nair
@NitinNair89
Nov 07 2016 16:13
Hello World! :)
CamperBot
@camperbot
Nov 07 2016 16:13

welcome to FreeCodeCamp @NitinNair89!

Sorin Ruse
@sorinr
Nov 07 2016 16:14
@Sprinting if you console log evt after 'node.addEventListener("onclick",(evt)=>{' what do u get?
Kartik Mudgal
@Sprinting
Nov 07 2016 16:14
@sorinr I derped for a moment there. I got it figured out
those console.log should be inside the addEventListener callback, not outside of it
BehindTheMath
@BehindTheMath
Nov 07 2016 16:21
@sorinr Sorry, here you go: https://codepen.io/BehindTheMath/pen/KNpKEZ
.validationMessage is set, and .validity.valid is false, but the message isn't displayed.
joshandevera
@joshandevera
Nov 07 2016 16:27
why are my buttons not align how do you fix this>
Tyler Moeller
@TylerMoeller
Nov 07 2016 16:33
@tcao2 The ? tells jQuery it's dealing with a JSONP request. Here's some more info: https://www.sitepoint.com/jsonp-examples/
WhiteLeaf1103
@WhiteLeaf1103
Nov 07 2016 16:40
can anyone help me with something. 10 people tried to help me last night and nobody could.
izakibikas
@izakibikas
Nov 07 2016 16:41
@WhiteLeaf1103 , may i try?
WhiteLeaf1103
@WhiteLeaf1103
Nov 07 2016 16:41
Please do.

This is the problem. I want my second codepen to look like the first one. Specificially the words to the right of the nav.

for whatever reason my words float all the way to the right of the container.

actually.. LOL I think I figured it out ;D
izakibikas
@izakibikas
Nov 07 2016 16:43
@WhiteLeaf1103 , see i solved it even without saying anything
:smile:
WhiteLeaf1103
@WhiteLeaf1103
Nov 07 2016 16:44
@izakibikas Thanks you deserve many points ;D
CamperBot
@camperbot
Nov 07 2016 16:44
whiteleaf1103 sends brownie points to @izakibikas :sparkles: :thumbsup: :sparkles:
:cookie: 277 | @izakibikas |http://www.freecodecamp.com/izakibikas
WhiteLeaf1103
@WhiteLeaf1103
Nov 07 2016 16:44
is there anyway to see how many points you have collected?
izakibikas
@izakibikas
Nov 07 2016 16:44
thanks to you too @WhiteLeaf1103 :smile: for your generosity
CamperBot
@camperbot
Nov 07 2016 16:44
izakibikas sends brownie points to @whiteleaf1103 :sparkles: :thumbsup: :sparkles:
:cookie: 145 | @whiteleaf1103 |http://www.freecodecamp.com/whiteleaf1103
Sorin Ruse
@sorinr
Nov 07 2016 16:44
@BehindTheMath think your function ' document.getElementById('submit').addEventListener("submit"` its not preventing the submit of the form to action="/change-password"
BehindTheMath
@BehindTheMath
Nov 07 2016 16:45
@sorinr Isn't that what event.preventDefault() does?
izakibikas
@izakibikas
Nov 07 2016 16:45
its just beside your user icon in any of freecodecamp page @WhiteLeaf1103
Nico Vergauwen
@kyriediculous
Nov 07 2016 16:46
preventdefault is to prevent the page to jump to the top when submitting for example a form
Sorin Ruse
@sorinr
Nov 07 2016 16:47
@BehindTheMath i'm afraid that function isnt triggered at all. try to make an alert("triggered") right after the function call and you will see its not working
BehindTheMath
@BehindTheMath
Nov 07 2016 16:49
@sorinr You're right. - "Note that submit is fired only on the form element, not the button or submit input. (Forms are submitted, not buttons.)" (From MDN)
WhiteLeaf1103
@WhiteLeaf1103
Nov 07 2016 16:49
@izakibikas Thanks again. You the man. Sheesh so low ;( gotta work on that. well I'm sure i'll be back for help one day people! until then KEEP CODING
CamperBot
@camperbot
Nov 07 2016 16:49
:warning: whiteleaf1103 already gave izakibikas points
whiteleaf1103 sends brownie points to @izakibikas :sparkles: :thumbsup: :sparkles:
BehindTheMath
@BehindTheMath
Nov 07 2016 16:49
I need to switch it to the form.
Ok, that works. And apparently event.preventDefault() does prevent the form from submitting.
But it's still not showing any message, it just stops it from submitting.
Sorin Ruse
@sorinr
Nov 07 2016 16:56
@BehindTheMath here what i say using jq :) submit example
BehindTheMath
@BehindTheMath
Nov 07 2016 16:57
Right, Now I see that.
But where's the error message that was set?
What's the point of element.setCustomValidity() if it doesn't show anything?
Sorin Ruse
@sorinr
Nov 07 2016 17:05
@BehindTheMath i was just testing the submit function part. you should add in there the logic :)
BehindTheMath
@BehindTheMath
Nov 07 2016 17:06
That's the part that's confusing me.
izakibikas
@izakibikas
Nov 07 2016 17:07
@BehindTheMath , try figuring out by yourself, take your time
BehindTheMath
@BehindTheMath
Nov 07 2016 17:07
I have, and I'm still stuck. That's why I came here.
Sorin Ruse
@sorinr
Nov 07 2016 17:15
@BehindTheMath just reload my pen now to see the logic for pass confirmation
BehindTheMath
@BehindTheMath
Nov 07 2016 17:16
@sorinr Right, I see. so what is element.setCustomValidity() for?
Sorin Ruse
@sorinr
Nov 07 2016 17:20
@BehindTheMath its your code. not mine. that function normally should custom validate your inputs
BehindTheMath
@BehindTheMath
Nov 07 2016 17:21
@sorinr I understand. I'm just confused about how it works. Thanks for your help.
CamperBot
@camperbot
Nov 07 2016 17:21
behindthemath sends brownie points to @sorinr :sparkles: :thumbsup: :sparkles:
:cookie: 827 | @sorinr |http://www.freecodecamp.com/sorinr
BehindTheMath
@BehindTheMath
Nov 07 2016 17:23
Ok, I just figured it out. The novalidate attribute on the form stops it from being displayed.
Sorin Ruse
@sorinr
Nov 07 2016 17:24
@BehindTheMath so, in my opinion, when you "submit" the form i would ask function validatePassword() if my passwords do validate and if so, i would proceed with my submit, otherwise i will show an error
BehindTheMath
@BehindTheMath
Nov 07 2016 17:32
@sorinr Right, that works. Or you can do it the way I did, which is to check on change, and if they're different use .setCustomValidity() to set an error message. That alone will prevent the form from submitting (assuming you don't set novalidate), and you don't need an onsubmit event handler at all.
Sorin Ruse
@sorinr
Nov 07 2016 17:35
@BehindTheMath yes. there are diff ways to implement the validation. mine was just a quick example. maybe not the best or what you intended to do :)
BehindTheMath
@BehindTheMath
Nov 07 2016 17:35
@sorinr Ok, thanks.
CamperBot
@camperbot
Nov 07 2016 17:35
behindthemath sends brownie points to @sorinr :sparkles: :thumbsup: :sparkles:
:warning: behindthemath already gave sorinr points
rmmohan
@rmmohan
Nov 07 2016 18:00
I have created a new pen for a personal portfolio webpage. Here is the link http://codepen.io/rmmohan/pen/oYgpXX. The code works for all the functionality except for automatically changing the active class in navbar.
could anyone have a look
Sorin Ruse
@sorinr
Nov 07 2016 18:10
@rmmohan just add to your pen settings in css: bootstrap then in javascript in this order: jquery then boostrap and it will work
rmmohan
@rmmohan
Nov 07 2016 18:17
@sorinr - Thanks a ton. It worked.
Tony Miri
@TonyMiri
Nov 07 2016 18:22
Hey guys, just about done with my twitch app but I can't get the title header to be responsive when I view it on my phone. Any suggestions? http://codepen.io/TonyMiri/pen/yamwVR
Sorin Ruse
@sorinr
Nov 07 2016 19:03
@rmmohan welcome
Shawn Grooms
@SEGrooms
Nov 07 2016 19:10
@FatTone225 what is wrong? It looks like it is working to me
Tony Miri
@TonyMiri
Nov 07 2016 19:10
@SEGrooms When I view it in full page mode on my phone the .tv gets pushed off to the side.
Shawn Grooms
@SEGrooms
Nov 07 2016 19:12
@FatTone225 hmm…I’m looking at it on chrome dev tools an it looks good to me...
What kind of phone do you have?
Tony Miri
@TonyMiri
Nov 07 2016 19:13
LG ummm G2?
G3 maybe
I think G2
Chrome browser
Shawn Grooms
@SEGrooms
Nov 07 2016 19:14
@FatTone225 Can you take a screen shot?
Tony Miri
@TonyMiri
Nov 07 2016 19:15
How do I post a screenshot on here from my phone?
lol
That didn't work
Shawn Grooms
@SEGrooms
Nov 07 2016 19:16
haha idk
Never tried before
Are you viewing your pen in full screen mode?
When I view it in editor on my phone it looks fine, but when I view it in full screen it is just too big to view on my phone. Is that your issue?
Shawn Grooms
@SEGrooms
Nov 07 2016 19:19
alright, yeah that’s happening on my phone too. Ok, I’m checking it out.
Sorin Ruse
@sorinr
Nov 07 2016 19:21
@FatTone225 yes you can use font-size:X.Yvw but in my oppinion to have more control on how your fonts are displayed on diff screens is to use em values in combination with @media screen to adjust the font size
Tony Miri
@TonyMiri
Nov 07 2016 19:25
@sorinr I had thought of that also, but I was hoping/wondering if there is a way to just have the text automatically be responsive the same way as the rest of the page content is.
Shawn Grooms
@SEGrooms
Nov 07 2016 19:27
@FatTone225 sorry man, but I don’t know. You’re using some stuff I’m not yet familiar with, and I don’t want to mess you up :/
Tony Miri
@TonyMiri
Nov 07 2016 19:30
@SEGrooms Ah. That's ok. Thank you. I guess it's really not a huge deal, but I just want it to be right lol
CamperBot
@camperbot
Nov 07 2016 19:30
fattone225 sends brownie points to @segrooms :sparkles: :thumbsup: :sparkles:
:cookie: 381 | @segrooms |http://www.freecodecamp.com/segrooms
Tony Miri
@TonyMiri
Nov 07 2016 19:31
@sorinr Thank you also.
CamperBot
@camperbot
Nov 07 2016 19:31
fattone225 sends brownie points to @sorinr :sparkles: :thumbsup: :sparkles:
:cookie: 828 | @sorinr |http://www.freecodecamp.com/sorinr
Minodora
@minodorag
Nov 07 2016 19:33
Hello !!
Tony Miri
@TonyMiri
Nov 07 2016 19:37
@sorinr I did end up using your suggestion. Looks much better now. Thanks again.
CamperBot
@camperbot
Nov 07 2016 19:37
:warning: fattone225 already gave sorinr points
fattone225 sends brownie points to @sorinr :sparkles: :thumbsup: :sparkles:
A_A
@Otto-AA
Nov 07 2016 19:37
Hi @minodorag
Sorin Ruse
@sorinr
Nov 07 2016 19:37
@FatTone225 vh and vw are two nice dimension elements but i would use them with very much care. sometimes you can benefit from them, sometimes it can be a pain in the a...
@FatTone225 welcome
Tony Miri
@TonyMiri
Nov 07 2016 19:38
@sorinr Honestly this is the first I've ever heard of those dimensions. I'll have to look them up.
nebastion
@nebastion
Nov 07 2016 20:08
@sorinr could you please give an instance where vh & vw could be problematic, I'm just curious as they kinda filled a hole for me with some things and I'd rather not write them off as the "answer to everything" and run into issues in the future. As you just said!
Sorin Ruse
@sorinr
Nov 07 2016 20:12
@nebastion lets say i wanna increase a font size on smaller screens to be more visible. if i would use font-size: vh or vw what will happen?
nebastion
@nebastion
Nov 07 2016 20:13
Ah yes you've opened up the can of worms for me now, thank you!
@sorinr but what about say dimensions of divs and other elements that should stay strictly sized? (thanks (from the last post)) XD.
Dmitriy
@klyushin
Nov 07 2016 20:16
Hi guys! Need help! I've finished with the task (https://www.freecodecamp.com/challenges/show-the-local-weather) and want to place it to http://codepen.io/ but I'm receiving an error in console (works fine on localhost). And https://openweathermap.org/api supports https only in a paid version of account. Is there a workaround? THX!
ERROR: pen.js:5 getCurrentPosition() and watchPosition() no longer work on insecure origins. To use this feature, you should consider switching your application to a secure origin, such as HTTPS. See https://goo.gl/rStTGz for more details.
Sorin Ruse
@sorinr
Nov 07 2016 20:17
@nebastion "stay strictly sized" in a responsive environment does not exist
nebastion
@nebastion
Nov 07 2016 20:22
@sorinr I see, that's very true. I get it more now. But OK, strictly proportional then?? Is it OK to "proportion" things by using vh & wh?
WhiteCaneGamer
@WhiteCaneGamer
Nov 07 2016 20:23

hi guys, I'm having major issues trying to make api calls, probably as I'm doing wrong, I need a little help :(.

window.onload = getQuote;
function getQuote(){
 $.ajax({
   url: "http://api.forismatic.com/api/1.0/",
   data: "method=getQuote&format=text&lang=en",
   dataType: "text"
 })
  .done(function(data){
   $("#quote").html(data);
 })
  .fail(function(){
    $("#quote").html("ERROR! FIX IT!");
  })
}

This is the code I'm using right now. I know we were shown to use $.get(JSON() in the previous lessons but I'm asking for a plain text response so that didn't seam right.

Sorin Ruse
@sorinr
Nov 07 2016 20:28
@nebastion as i said. depending on design u choose it is not bad sometimes to use vh/wh. but i will not make a rule of it
nebastion
@nebastion
Nov 07 2016 20:29
@sorinr gotcha, thanks.
CamperBot
@camperbot
Nov 07 2016 20:29
:cookie: 829 | @sorinr |http://www.freecodecamp.com/sorinr
nebastion sends brownie points to @sorinr :sparkles: :thumbsup: :sparkles:
Sorin Ruse
@sorinr
Nov 07 2016 20:30
@nebastion welcome
gadzet
@gadzet
Nov 07 2016 20:36
good evening
A_A
@Otto-AA
Nov 07 2016 20:36
@WhiteCaneGamer 1) Can you link your Pen?
2) I would still use $.getJSON
(but it should work with both)
gadzet
@gadzet
Nov 07 2016 20:40
I am using bootstrap nav-tabs, when hovering on one of them i can see link http://localhost/rejben/projektai/#orange and when i press it it opens the tab. But when i try to access the tab from another page with the link http://localhost/rejben/projektai/#orange it will open the first tab instead of this one. Anyone knows why it behaves like this ? I can send a code if needed, brownie points to anyone who can help :))
<ul class="nav nav-tabs" data-tabs="tabs">
    <li class="active"><a data-toggle="tab" href="#red">Red</a></li>
    <li><a data-toggle="tab" href="#orange">Orange</a></li>
    <li><a data-toggle="tab" href="#yellow">Yellow</a></li>
    <li><a data-toggle="tab" href="#green">Green</a></li>
    <li><a data-toggle="tab" href="#blue">Blue</a></li>
</ul>
<div class="tab-content">
    <div class="tab-pane active" id="red">
        <h1>Red</h1>
        <p>red red red red red red</p>
    </div>
    <div class="tab-pane" id="orange">
        <h1>Orange</h1>
        <p>orange orange orange orange orange</p>
    </div>
    <div class="tab-pane" id="yellow">
        <h1>Yellow</h1>
        <p>yellow yellow yellow yellow yellow</p>
    </div>
    <div class="tab-pane" id="green">
        <h1>Green</h1>
        <p>green green green green green</p>
    </div>
    <div class="tab-pane" id="blue">
        <h1>Blue</h1>
        <p>blue blue blue blue blue</p>
    </div>
</div>
Sorin Ruse
@sorinr
Nov 07 2016 20:41
@gadzet we cannot run code on your local host environment
gadzet
@gadzet
Nov 07 2016 20:42
it is simple as that @sorinr has nothing to do with the localhost it will behave same if it can be accessed externaly or noot
Sorin Ruse
@sorinr
Nov 07 2016 20:43
@gadzet the code you posted appeared after i was asking for it @gadzet :)
gadzet
@gadzet
Nov 07 2016 20:44
i wrote that i can send the code in the first msg, then I thought ill just send it right away :D :D but that's not the point
need to solve this problem
WhiteCaneGamer
@WhiteCaneGamer
Nov 07 2016 20:45
@Otto-AA here is my pen link http://codepen.io/WhiteCaneGamer/pen/pNvdGL
(please keep in mind it's not finished, barely started, so laughter to a minimum please :))
gadzet
@gadzet
Nov 07 2016 20:45
somehow when going to this url from the other page it skips the /#orange part
masteresp
@masteresp
Nov 07 2016 20:46

Hello! I just started on the personal portfolio page, but how am I supposed to complete this user story

User Story: I navigate to different sections of the webpage by clicking buttons in the navigation.

gadzet
@gadzet
Nov 07 2016 20:47
@masteresp what is your question
how to navigate ?
masteresp
@masteresp
Nov 07 2016 20:47
@masteresp Yeah
gadzet
@gadzet
Nov 07 2016 20:47
you add links
to anothe rpage
masteresp
@masteresp
Nov 07 2016 20:47
oops * @gadzet
WhiteCaneGamer
@WhiteCaneGamer
Nov 07 2016 20:47
@Otto-AA the buttons don't do anything yet, but it is supposed to provide a random quote when the page first loads. but my ajax isn't working.
A_A
@Otto-AA
Nov 07 2016 20:47
@WhiteCaneGamer Yeah, I see
masteresp
@masteresp
Nov 07 2016 20:47
@gadzet no but dosent it require js?
gadzet
@gadzet
Nov 07 2016 20:48
with <a href="./another-page.html">Link to another page</a>
./ means current directory
masteresp
@masteresp
Nov 07 2016 20:48
no but it is on the same page
have you completed that challange?
gadzet
@gadzet
Nov 07 2016 20:48
probably i dont remember
which one is that
masteresp
@masteresp
Nov 07 2016 20:49
"Build a Personal Portfolio Webpage"
Yeah...
A_A
@Otto-AA
Nov 07 2016 20:50
@masteresp give the div or section you want to jump to an id. Then you can target it with <a href="#theID">tfsdkfs</a>
gadzet
@gadzet
Nov 07 2016 20:50
@masteresp you can use the code i posted if you see up
masteresp
@masteresp
Nov 07 2016 20:50
like a css id?
@Otto-AA ?
ahhh
gadzet
@gadzet
Nov 07 2016 20:50
if you have bootstrap it will work
masteresp
@masteresp
Nov 07 2016 20:50
yeah
ok
will try
thx @gadzet and @Otto-AA
CamperBot
@camperbot
Nov 07 2016 20:51
:cookie: 367 | @otto-aa |http://www.freecodecamp.com/otto-aa
:cookie: 193 | @gadzet |http://www.freecodecamp.com/gadzet
masteresp sends brownie points to @gadzet and @otto-aa :sparkles: :thumbsup: :sparkles:
gadzet
@gadzet
Nov 07 2016 20:51
just style it in your own way
A_A
@Otto-AA
Nov 07 2016 20:51
@gadzet This isn't because of bootstrap?
Purcea Robert
@RobertPurcea
Nov 07 2016 20:51
how can i make buttons that navigate through my page?
gadzet
@gadzet
Nov 07 2016 20:51
@Otto-AA what ?
Purcea Robert
@RobertPurcea
Nov 07 2016 20:52
I'm unable to find this on internet maybe i'm not searching what i need to
A_A
@Otto-AA
Nov 07 2016 20:52
@gadzet oh, didn't understand it at first :/
(understood it the wrong way)
@Robertb4 look at the last 10 comments please
gadzet
@gadzet
Nov 07 2016 20:52
@Otto-AA you can do it in many ways hehe, later on you will see that you have to create router for example in ng 2 in order to make it work
WhiteCaneGamer
@WhiteCaneGamer
Nov 07 2016 20:54

can anyone help me with my ajax problem, I want to make an api call to complete this project rather than filling an array with random quotes. But I can't get ajax to work :(

This is my very unfinished, barely started pen
http://codepen.io/WhiteCaneGamer/pen/pNvdGL
any help will be warmly received.

A_A
@Otto-AA
Nov 07 2016 21:01
@WhiteCaneGamer I don't know why yours isn't working. If you want a working one: $.getJSON("http://api.forismatic.com/api/1.0/?method=getQuote&format=jsonp&jsonp=?&lang=en&callback=?")
gadzet
@gadzet
Nov 07 2016 21:03
@WhiteCaneGamer
I had same problem
it is because of the code pen
Sorin Ruse
@sorinr
Nov 07 2016 21:03
@WhiteCaneGamer here an ajax call version of it: quotes
gadzet
@gadzet
Nov 07 2016 21:03
it worked fine in my localhost
Greg D
@mosaic-greg
Nov 07 2016 21:07
hi @Robertb4 here is a working example of what you need http://www.w3schools.com/tags/tryit.asp?filename=tryhtml5_a_href_anchor
Purcea Robert
@RobertPurcea
Nov 07 2016 21:08
@mosaic-greg I figured it out thanks anyway
CamperBot
@camperbot
Nov 07 2016 21:08
robertb4 sends brownie points to @mosaic-greg :sparkles: :thumbsup: :sparkles:
:cookie: 387 | @mosaic-greg |http://www.freecodecamp.com/mosaic-greg
lacey irvin
@laceyIrvin
Nov 07 2016 21:14
can anyone explain hoe the offset works in bootstrap? whats the 2 values have to do with eachother?
Daniel
@DanielMW34
Nov 07 2016 21:18
@laceyIrvin do you have a link to something relating to "the offset"?
perhaps I am far behind you in the curriculum and thus, clueless
Tony Miri
@TonyMiri
Nov 07 2016 21:21
Move columns to the right using .col-md-offset-* classes. These classes increase the left margin of a column by * columns
Daniel
@DanielMW34
Nov 07 2016 21:23
Question: I am working on my Simon game and, am not clear what jQuery event handler to use when I am using a toggle switch like the one shown here (http://www.w3schools.com/howto/howto_css_switch.asp) for my ON/OFF button
anyone have any pointers?
is this a good place to start? --> http://www.bootstrap-switch.org/events.html
Brian
@BrianCodes33
Nov 07 2016 21:32
@laceyIrvin offset is easy
it creates empty spacing
it creates an empty column by increasing the margin. make sense?
how to remove the space from the left and right sides
of the image
tyl-er
@tyl-er
Nov 07 2016 21:45

This is really simple, but I'm stuck. I just need a function to clear out an input, but I'm not sure why it's not working. I've tried about every variation I can think of.

http://codepen.io/tyl-er/pen/vyYbmV?editors=1010

var text = document.getElementById('disp1');

function clear(){
text.value = '';
}

function addOne(num) {
text.value=text.value+num;
}

WhiteCaneGamer
@WhiteCaneGamer
Nov 07 2016 21:50
@sorinr @gadzet @Otto-AA Thanks guys, I'll work at it some more.
CamperBot
@camperbot
Nov 07 2016 21:50
whitecanegamer sends brownie points to @sorinr and @gadzet and @otto-aa :sparkles: :thumbsup: :sparkles:
:cookie: 830 | @sorinr |http://www.freecodecamp.com/sorinr
:cookie: 194 | @gadzet |http://www.freecodecamp.com/gadzet
:cookie: 368 | @otto-aa |http://www.freecodecamp.com/otto-aa
Parley Kennelly
@parleydk
Nov 07 2016 21:52

Hey everyone. I'm working through the JavaScript exercises and I don't understand why this works

// Setup
var myObj = {
  gift: "pony",
  pet: "kitten",
  bed: "sleigh"
};

function checkObj(checkProp) {
  // Your Code Here
 if(myObj.hasOwnProperty(checkProp)){
   return myObj[checkProp];
 }
  else return "Not Found";

  }

// Test your code by modifying these values
checkObj("gift");

and this doesn't


// Setup
var myObj = {
  gift: "pony",
  pet: "kitten",
  bed: "sleigh"
};

function checkObj(checkProp) {
  // Your Code Here
 if(myObj.hasOwnProperty(checkProp)){
   return myObj.checkProp;
 }
  else return "Not Found";

  }

// Test your code by modifying these values
checkObj("gift");
can I not use the dot notation with a variable?
Purcea Robert
@RobertPurcea
Nov 07 2016 22:14
nice support
Daniel
@DanielMW34
Nov 07 2016 22:20
@tyl-er check out my calculator, perhaps it might help.... http://codepen.io/Daniel_Widrich/pen/BLJVQv
Mooli
@Mooli88
Nov 07 2016 22:23
@parleydk you can only access proprieties on object with dot notation when you type the exact name of the property
Mario
@mariomeissner
Nov 07 2016 22:24
Hello Guys! Im working on the javascript algorithms
function destroyer(arr) {
  // Remove all the values
  var deleteNumbers = Array.from(arguments);
  deleteNumbers.shift();
  console.log(deleteNumbers);
  function cleaner(val){
    for (var i = 0; i++; i<deleteNumbers.length){
      if (deleteNumbers[i] == val) return false;
    }
    return true;
  }
  return arr.filter(cleaner);

}

destroyer([1, 2, 3, 1, 2, 3], 2, 3);
My destroyer isnt destroying.
WHY? :worried:
Found it.
Nevermind.
Zu Pippu
@ilzio
Nov 07 2016 22:53
Hello everyone, I have finished the basic frontend, (less than 2 days) and created a pseudo-tribute page. Now I am supposed to create a scrollable portfolio app which I find impossible to do given the skills I have acquired. When I try to look on google to see how I could proceed I am overwhelmed by tons of code I do not understand and I am unable to digest. Is it normal?
CodyJasonBennett
@CodyJasonBennett
Nov 07 2016 22:58
Well, try to break down what a portfolio is.
I recommend looking for inspiration at other sites, and begin drawing your site out. Digitally, or on paper and pen.
Zu Pippu
@ilzio
Nov 07 2016 22:59
The idea of what I want is quite clear in my mind. Simple navigation bar fixed on top and three full screen "boxes" that I can scroll down.
CodyJasonBennett
@CodyJasonBennett
Nov 07 2016 23:00
Maybe look at boostrap if you want rapid development.
Zu Pippu
@ilzio
Nov 07 2016 23:00
I have also looked at the example project's code and it contains a whole lot of Javascript which the course hasn't covered yet
thanks @CodyJasonBennett
CamperBot
@camperbot
Nov 07 2016 23:00
ilzio sends brownie points to @codyjasonbennett :sparkles: :thumbsup: :sparkles:
:warning: could not find receiver for codyjasonbennett
Erich Malfertheiner
@thenewbiemaster
Nov 07 2016 23:21
Hello
Can anyone help me with positioning on css?
Need Lock 4 boxes below nav bar
But code dont work
?
Waqas Abbasi
@Waqas909
Nov 07 2016 23:39
Hello
I'm unable to figure out why clicking Tweet button doesnt change background to blue

this is the Jquery code

~! $(document).ready(function(){
$("#tweet").on('click', function(){
$("body").css("color","blue"); ~

  $("#tweet").on('click', function(){
   $("body").css("color","blue");