These are chat archives for FreeCodeCamp/HelpFrontEnd

12th
Feb 2017
ThurstianTsui
@ThurstianTsui
Feb 12 2017 00:14
Hey guys, I just started the "tribute" project and had a curious question. Do you remember all of the properties and functions off the top of your head? I find myself having to double check my notes to remember things like "font-family" or how to italicize a font. It seems impossible to remember all of these different options
Seth
@sethmchris
Feb 12 2017 00:21
@ThurstianTsui For me personally, I see memorization as a bonus. 99% of the time, I'm getting help with syntax no matter what I'm working on. Which is good in a way because it means I'm using new things or exploring concepts I haven't used as much. The stuff I use all the time inevitably ends up sticking and starts to become second nature.
NathanMcSparran
@NathanMcSparran
Feb 12 2017 00:21
I struggled to remember a lot of them. The best thing you can do is just have a reference available. Learning programming is less about memorization and more about knowing how to use your tools and how to look up documentation.
ThurstianTsui
@ThurstianTsui
Feb 12 2017 00:23
@sethmchris @NathanMcSparran Thanks for putting that to bed. Was starting to worry that I was expected to memorize everything. I've got the w3 schools reference open and it's been a great resource for finding functions. Any other recommendations for references to use?
CamperBot
@camperbot
Feb 12 2017 00:23
thurstiantsui sends brownie points to @sethmchris and @nathanmcsparran :sparkles: :thumbsup: :sparkles:
:cookie: 244 | @sethmchris |http://www.freecodecamp.com/sethmchris
:cookie: 265 | @nathanmcsparran |http://www.freecodecamp.com/nathanmcsparran
NathanMcSparran
@NathanMcSparran
Feb 12 2017 00:23
I use w3 schools because it's a simple at a glance type of reference
ThurstianTsui
@ThurstianTsui
Feb 12 2017 00:25
I agree. Thanks for the information!
NathanMcSparran
@NathanMcSparran
Feb 12 2017 00:25
You're welcome :)
Seth
@sethmchris
Feb 12 2017 00:26
@ThurstianTsui I like W3 Schools too for a quick reminder. If I want a more in-depth look, I often check MDN, usually from a Google search.
Thomas Nguyen
@todadqa
Feb 12 2017 00:37
I was wondering if anyone could help me out with a problem im having. I have a parallax image at the top of my website and the image inside the parallax container is of high resolution however it is zoomed in ALOT so that the picture looks horribly pixelated. I can't resize the image because it takes away from the parallax. Any ideas?
Tom
@moT01
Feb 12 2017 01:17
@todadqa got a pen? i could take a look
no promises
eshaffer321
@eshaffer321
Feb 12 2017 02:13
Hey does anyone know how I could upload an image to the internet to use on my website? Like how when you google search an image and you can hit view image and it takes you to a page with just the image and use that as your src. Does anyone know how I could do that?
Tom
@moT01
Feb 12 2017 02:17
@eshaffer321 upload it to a photo site, then it will have a url you can use
Luis Carlos Garcia Barajas
@Luiko
Feb 12 2017 02:22
<a href="./puppy.jpg"><img src="./puppy.jpg"></a> I think
Julius Robinson
@Julius-R
Feb 12 2017 02:30

Is there a way to get the top left color yellow when it gets full screen?

http://codepen.io/julisu-r/pen/JEwYJp

Tom
@moT01
Feb 12 2017 02:33
@Julius-R you could look into css media queries
eshaffer321
@eshaffer321
Feb 12 2017 02:34
@moT01 i can't get it to display the image that link something such as imgur provides brings it to the image and doesn't display it on my website
Tom
@moT01
Feb 12 2017 02:36
i havent used it, but ive seen people say not to use that site for this purpose, ...they don't allow it or something
not sure
do you have a codepen? i would take a look
eshaffer321
@eshaffer321
Feb 12 2017 02:38
@moT01 what I'm trying to do it make a thumbnail of one of codepen.io projects. I see they have an embedded link, but I dont like the way that it is displayed and would like it to be custom.
@moT01 here is the codepen http://codepen.io/eshaffer321/pen/oBQymp
Tom
@moT01
Feb 12 2017 02:42
your image isn't an image url
should end in a .jpg or other image type
might be the problem
wait, am i missing something, ..isnt the thumbnail there that you want
eshaffer321
@eshaffer321
Feb 12 2017 02:46
yeah but i wanted it without the extra things that the embedding from codepen adds
like the little android and apple symbols
so that if i post something else that isnt on codepen.io there is some consistency
like that? use that as the source url
eshaffer321
@eshaffer321
Feb 12 2017 02:47
@moT01 thanks! thats exactly what i needed! how did you get it?
CamperBot
@camperbot
Feb 12 2017 02:47
eshaffer321 sends brownie points to @mot01 :sparkles: :thumbsup: :sparkles:
:cookie: 507 | @mot01 |http://www.freecodecamp.com/mot01
Tom
@moT01
Feb 12 2017 02:48
opened the url you were using, right clicked the picture and then copy image location, and opened it in a new tab
eshaffer321
@eshaffer321
Feb 12 2017 02:48
oh thats was simple :P
thanks a lot though, that will be very useful in the future
Tom
@moT01
Feb 12 2017 02:49
yup
@eshaffer321 there's a little arrow on the top right of codepen, ...opens a dropdown menu, if you click analyze you might get some tips
top right of each section
Eric Weiss
@eweiss17
Feb 12 2017 03:33
got a hefty debugging project if somebody is familar with the twitch project section
Tom
@moT01
Feb 12 2017 03:34
whats up
Eric Weiss
@eweiss17
Feb 12 2017 03:35
been looking at the dev tools (console) and google searching
can't find my problem
Tom
@moT01
Feb 12 2017 03:36
any other info?
Eric Weiss
@eweiss17
Feb 12 2017 03:37
worked months ago
Tom
@moT01
Feb 12 2017 03:37
probly the url
yea, that url wont work anymore, ...go check the projects page
it will say on there the new url
Eric Weiss
@eweiss17
Feb 12 2017 03:38
ya but i signed up for an api key
my client id is my key
Tom
@moT01
Feb 12 2017 03:38
oh
but why else would it have stopped working all of a sudden
Eric Weiss
@eweiss17
Feb 12 2017 03:40
it's not all of a sudden, it stopped working when twitch updated their api, i just got around to looking at it now
I know but based on their documentation, mine should still work
obiously doesn't, : {"error":"Bad Request","status":400,"message":"Not a valid callback function"}
Gulsvi
@gulsvi
Feb 12 2017 03:40
@eweiss17 If I understand your code, you're making a $.ajax call to: https://api.twitch.tv/kraken/streams/' + user + '?callback=?',. In that success function, you make a getJSON call to the same URL which then makes a $.ajax call to the twitch user's channel (which returns no JSON). I don't see how that ever worked?
You have two identical API calls for each user which then try to make a third API call to data['_links']['channel'] which returns a 400 error message in your console
(I think because the user's twitch channel won't give you JSON, only /streams/, /channels/, and /users/)
Eric Weiss
@eweiss17
Feb 12 2017 03:45
it fails at the first api call
Eric Weiss
@eweiss17
Feb 12 2017 03:53
@moT01 Wow it works, what was wrong?
Gulsvi
@gulsvi
Feb 12 2017 03:53
@moT01 Will you write mine for me now? :)
Tom
@moT01
Feb 12 2017 03:54
i got rid of the .getjson and the callback=?, and added the format: json parameter
Eric Weiss
@eweiss17
Feb 12 2017 03:55
i was looking at the difference here, http://stackoverflow.com/questions/5922175/jquery-getjson-vs-ajax-json, to be honest i didn't know the difference
Gulsvi
@gulsvi
Feb 12 2017 03:56
lol :)
Tom
@moT01
Feb 12 2017 03:57
@eweiss17 i think getjson is specific for json formatted requests, ...ajax can get other types
Eric Weiss
@eweiss17
Feb 12 2017 04:03
oh thanks for the help @moT01
CamperBot
@camperbot
Feb 12 2017 04:03
eweiss17 sends brownie points to @mot01 :sparkles: :thumbsup: :sparkles:
:cookie: 508 | @mot01 |http://www.freecodecamp.com/mot01
i am stuck at this point
can anyone guide me through this :)
hey guys i need help with the search and disable - functions through the page
any help would be appreciated
Deepak8717
@Deepak8717
Feb 12 2017 05:47
hi, i have built my portfolio. Can someone have a look and fix the image in home and about section i want image to be responsive, in the center of thesection. my pen is http://codepen.io/Deepak8717/pen/xRodaq?editors=1100
Johnny
@jtan3
Feb 12 2017 05:54
@Deepak8717 try #home, img{
margin: auto;
}
Deepak8717
@Deepak8717
Feb 12 2017 06:04
@jtan3 thanks
CamperBot
@camperbot
Feb 12 2017 06:04
deepak8717 sends brownie points to @jtan3 :sparkles: :thumbsup: :sparkles:
:cookie: 302 | @jtan3 |http://www.freecodecamp.com/jtan3
Johnny
@jtan3
Feb 12 2017 06:05
try putting your container in a row and column to see if that fixes the picture
Deepak8717
@Deepak8717
Feb 12 2017 06:16
@jtan3 can you check once again is it okey now ? i feel the the home image is not in circle.
@jtan3 can you also tell me why the image are coming out of the div when resizing ?
Johnny
@jtan3
Feb 12 2017 06:27
look at your portfolio section
you have rows and co-sm-6
try it in your home and about section
@Deepak8717 you also spelled portfolio wrong
Deepak8717
@Deepak8717
Feb 12 2017 06:32
Thanks again @jtan3 can you explain why rows and co -sm-6 in home and about section ?
CamperBot
@camperbot
Feb 12 2017 06:32
deepak8717 sends brownie points to @jtan3 :sparkles: :thumbsup: :sparkles:
:warning: deepak8717 already gave jtan3 points
Johnny
@jtan3
Feb 12 2017 06:36
do you know bootstrap?
there's 12 columns . I think it might be responsive if you used the bootstrap columns.
you made your portfolio section responsive using the bootstrap columns
Johnny
@jtan3
Feb 12 2017 06:42
@Deepak8717 it doesn't have to be col-sm-6. Its up to you.
joopt
@joopt
Feb 12 2017 06:48
What does it mean by : User Story: I will see a placeholder notification if a streamer has closed their Twitch account (or the account never existed). You can verify this works by adding brunofin and comster404 to your array of Twitch streamers.
What is a placeholder notification?
Johnny
@jtan3
Feb 12 2017 06:50
@joopt those account don't exists
@joopt they want you to display them as well the other accounts
Deepak8717
@Deepak8717
Feb 12 2017 06:59
@jtan3 i do not agree. first the website is responsive its just the image and second even the portfolio images are runing out of the section when resized.
Johnny
@jtan3
Feb 12 2017 06:59
@Deepak8717 did you try it out?
@Deepak8717 you have images in your other section and they resized.
rarevalo92
@rarevalo92
Feb 12 2017 07:02
Hi everyone, I was wondering if someone can assist me with my zipline. I'm building my personal portfolio, and I was wondering how do I add my projects to my site?
Johnny
@jtan3
Feb 12 2017 07:09
@rarevalo92 are you using codepen for you projects?
rarevalo92
@rarevalo92
Feb 12 2017 07:15
@jtan3 yes I am.
Johnny
@jtan3
Feb 12 2017 07:15
@rarevalo92 click on one of your projects and at the bottom there's a button embed
@rarevalo92 copy and paste that link
rarevalo92
@rarevalo92
Feb 12 2017 07:17
@jtan3 thank you Johnny, I will try that. appreciate the fast response :)
Deepak8717
@Deepak8717
Feb 12 2017 07:34
@jtan3 can you see why body css is not working .
Johnny
@jtan3
Feb 12 2017 07:37
@Deepak8717 link?
Johnny
@jtan3
Feb 12 2017 07:37
what's wrong?
Deepak8717
@Deepak8717
Feb 12 2017 07:40
font has not changed @jtan3
@jtan3 can i msg you privately ?
Johnny
@jtan3
Feb 12 2017 07:45
sure
Alo
@aloRanking
Feb 12 2017 07:54
hii..im tryin to create a portfolio webpage, but the navbar displays in block
Alo
@aloRanking
Feb 12 2017 08:05
and i want it to display inlined
Sultan Ahmed
@sultanshaik
Feb 12 2017 08:06
Hi people
the code for tribut page reveals different outputs when one of these is used
why is it so?
isn't bootstrap from twitter
?
Nicol
@NicolNonga
Feb 12 2017 08:17
hello
yes bootstrap is from twitter
Sultan Ahmed
@sultanshaik
Feb 12 2017 08:29
then why do th both reveal a different out for the same code of tribute page
?
Johnny
@jtan3
Feb 12 2017 08:33
new version of bootstrap
Bootstrap navigation not working properly Please help
@muneermk
Muneer MK
@muneermk
Feb 12 2017 08:54
It Worked !!! Thanks @jtan3
CamperBot
@camperbot
Feb 12 2017 08:54
muneermk sends brownie points to @jtan3 :sparkles: :thumbsup: :sparkles:
:cookie: 303 | @jtan3 |http://www.freecodecamp.com/jtan3
at first
Why this didnt worked?
Johnny
@jtan3
Feb 12 2017 08:55
i think its because its the new version of bootstrap
Muneer MK
@muneermk
Feb 12 2017 08:56
ya ok
kirbyedy
@kirbyedy
Feb 12 2017 08:56
@muneermk thats the bootstrap version 4 which is still in testing phase, does not work properly yet
Muneer MK
@muneermk
Feb 12 2017 08:56
Ok Thank you guys
Chase
@Athabasco
Feb 12 2017 09:03
how would i assign html text input to a js variable??
Mahak Narayan Singh
@makkBit
Feb 12 2017 09:31
@Athabasco if you mean you need to get value from a html input tag and assign it to a var,
just select that element and use .value method, like this
var input = document.querySelector('selector').value;
Alo
@aloRanking
Feb 12 2017 09:41
@jtan3 thnks. i also added that link nd it worked
Albert L. C.
@sirus3020
Feb 12 2017 10:26
guys I need help with the .keypress method

$('#input').keypress(function (e){
if ( e.which == 13 ) {
e.preventDefault();

}
var query = $('#input').val();
$('#random').html(query)
})

either the keypress is not working or I'm not passing the values right.
halp?
Radek
@radekjohn
Feb 12 2017 10:43
@JohnnyBizzel thanks
CamperBot
@camperbot
Feb 12 2017 10:43
radekjohn sends brownie points to @johnnybizzel :sparkles: :thumbsup: :sparkles:
:star2: 1274 | @johnnybizzel |http://www.freecodecamp.com/johnnybizzel
Snir Ben Yossef
@snirben
Feb 12 2017 11:08
why is my portfolio is with gray areas? can someone explain to me how to fix it?
http://codepen.io/snirben/pen/YNdWWj
by the way: it is ok to give everything id? or should I use class?
viorelfoamete
@viorelfoamete
Feb 12 2017 11:26
https://codepen.io/viorelfoamete/full/wgRwvm/ can you guys tell me why I have a space between the navbar and the background image of my homepage?
Sorin Ruse
@sorinr
Feb 12 2017 11:39
@viorelfoamete add in css:
.navbar {
  margin-bottom: 0;
}
krckyboy
@krckyboy
Feb 12 2017 11:40

Inside of @keyframes animation - can you select different elements, modify their elements or you can only select one (for example h1, and that's it)?

Some kind of noob example:

@keyframes animation {
    h1 {
        <!-- some kind of animation here -->
    }

    h2 {
        <!-- some kind of animation here, as well -->
    }
}
viorelfoamete
@viorelfoamete
Feb 12 2017 11:42
@sorinr thanks
CamperBot
@camperbot
Feb 12 2017 11:42
viorelfoamete sends brownie points to @sorinr :sparkles: :thumbsup: :sparkles:
:star2: 1172 | @sorinr |http://www.freecodecamp.com/sorinr
Sorin Ruse
@sorinr
Feb 12 2017 11:43
@viorelfoamete also to mask that little white spaces in the corners of the navbar you can give your body: background: #000;
@viorelfoamete welcome
viorelfoamete
@viorelfoamete
Feb 12 2017 11:44
@sorinr i set up navbar border-radius:0px; for those white spaces
@sorinr you’re by any chance from romania ? :D
alican karalar
@alicankaralar
Feb 12 2017 12:21
hey guys
i need help
on one specific area
how can i make the close buttons functional?
i am asking because every close button has to operate on its own tree
so i cant make a general rule about buttons
i have to give them unique id's that are similar in a way to their parents
but how can i write a function for a specific button that i don't know the name of?
Adam Jacks
@AdamHJ123
Feb 12 2017 13:36
Can I get some opinions on my calculator project please?
http://codepen.io/AdamHJacks/pen/dNQwGx
Janina Pohorecki
@janepohorecka
Feb 12 2017 13:39
Hey guys!! This is the second time I have ever tried installing a JQuery plugin into a website and I could use a little help. Nothing is appearing when I open this code in the browser. This is my code: https://github.com/janepohorecka/Maria-Photography This is what I am trying to install: https://austenpayan.github.io/skippr/
Could someone please help me with this? I would really, really appreciate it :)
I did exactly what the instructions said to do.
kirbyedy
@kirbyedy
Feb 12 2017 13:44
<script type="text/jquery" src="jquery-3.1.1.min.js"></script>
I dont think this is ok
try to make it like this src="/jquery-3.1.1.min.js">
Janina Pohorecki
@janepohorecka
Feb 12 2017 13:46
@kirbyedy thank you!!! That worked!!
CamperBot
@camperbot
Feb 12 2017 13:46
janepohorecka sends brownie points to @kirbyedy :sparkles: :thumbsup: :sparkles:
:star2: 1773 | @kirbyedy |http://www.freecodecamp.com/kirbyedy
Philipp Scholz
@philipp32
Feb 12 2017 13:48
Hey campers. :)

So I am working on the Twitch App. When I call a channel which is offline I get the error message: "Cannote read property of channel of "null"."
This is an example API call. https://wind-bow.gomix.me/twitch-api/streams/freecodecamp?callback=?
And here is my code:

// if channel is offline
    if (jsonData.stream === "null"){

    }

And a link to the full project: http://codepen.io/philipp32/full/QdrgYR/

Tom
@moT01
Feb 12 2017 14:00
@philipp32 its getting stuck before that
i hardcoded the freecodecamp channel into the url
didn't make it to that test
David
@dkohlruss
Feb 12 2017 14:24
Howdy campers -- Looking for a bit of help importing react components. Anybody around able to take a look at my (extremely basic) setup?
Darth Skywalker
@adityaparab
Feb 12 2017 14:24
@dkohlruss shoot
David
@dkohlruss
Feb 12 2017 14:25
I'll just post my js/jsx in here... Here is my index.js:
import React from 'react';
import ReactDOM from 'react-dom';

import userInput from './components/user_input';

const App = () => {
    return (
        <div>
            <userInput />
        </div>
    );
}

ReactDOM.render(
  <App />,
  document.querySelector('#root')
);
Darth Skywalker
@adityaparab
Feb 12 2017 14:25
@dkohlruss would be great if you have codepen or something.
David
@dkohlruss
Feb 12 2017 14:26
Is there a way to structure external js files into a codepen?
Darth Skywalker
@adityaparab
Feb 12 2017 14:27
@dkohlruss no...
you will have to put everything in the same js file
but nvm...
show your code in ./components/user_input.jsx
David
@dkohlruss
Feb 12 2017 14:27
import React from 'react';

const userInput = () => {
    console.log("test");
  return <input />;
};

export default userInput;
Goran Dimitrijevic
@DimiG031
Feb 12 2017 14:28
Hi I am Goran
David
@dkohlruss
Feb 12 2017 14:28
oops, ignore that console.log statement
Goran Dimitrijevic
@DimiG031
Feb 12 2017 14:28
Can sombody help
David
@dkohlruss
Feb 12 2017 14:29
if it's matters, I'm using the create-react-app boilerplate off of npm
Goran Dimitrijevic
@DimiG031
Feb 12 2017 14:30
I start with coding few day ago, I need to set my buttons, when click to go to background image
Darth Skywalker
@adityaparab
Feb 12 2017 14:30
@dkohlruss hold on.. let me check
Goran Dimitrijevic
@DimiG031
Feb 12 2017 14:30
mine background is in slideshow
Goran Dimitrijevic
@DimiG031
Feb 12 2017 14:36
?
Darth Skywalker
@adityaparab
Feb 12 2017 14:48
@dkohlruss sorry for delay
you need to be using React.createClass to create a react component

something like

in your app component

import React from 'react';
import ReactDOM from 'react-dom';

import userInput from './components/user_input';

const App = React.createClass({
    render : function(){
      return(
        <div>
            <userInput/>
        </div>
      );
    }
});

ReactDOM.render(
  <App />,
  document.querySelector('#root')
);


export default App;
same thing for user_input component
David
@dkohlruss
Feb 12 2017 14:50
Alrighty, thanks
Hello911
@Hello911
Feb 12 2017 14:52
function sayHello2(name){
  var text='Hello'+name;
  var say=function(){
   console.log(text);
  };
  return say;
}

sayHello2("David");
Why when I executed these codes, the display window shows function(){console.log(text}?
David
@dkohlruss
Feb 12 2017 14:55
Hold on a moment... isn't React.createClass just a helper for those who aren't using ES6?
Oh duh... No babel dependencies in my package_json
Darth Skywalker
@adityaparab
Feb 12 2017 14:56
@dkohlruss yes... even though you're using arrow function, it's still not a class syntax
David
@dkohlruss
Feb 12 2017 14:56
*.json
Darth Skywalker
@adityaparab
Feb 12 2017 14:57
it can be argued that yours is ES5 syntax with a little ES6 sugar
David
@dkohlruss
Feb 12 2017 15:01
I was under the impression it was bad form to use non-changing components as classes and that they're better off being declared as constants
Darth Skywalker
@adityaparab
Feb 12 2017 15:03
@dkohlruss I like this boiler plate a lot more https://github.com/alicoding/react-webpack-babel
David
@dkohlruss
Feb 12 2017 15:04
I'll give it a shot, thanks
Ashwath Sivaswamy
@AshwathShivaz
Feb 12 2017 15:11
i have a doubt
can we use the bootstrap grid to an image and some text to align them in two columns ?
Goran Dimitrijevic
@DimiG031
Feb 12 2017 15:22
can you do that and I will get a look
Toffanelly
@Toffanelly
Feb 12 2017 15:41
var input = "test";
function myFunction() {  
  input = document.getElementById("searchbox").value;
}
$("#test").html(input);
I'm doing the wikipedia viewer project. I cant figure out why this function does not change the value of the global variable. The #test object always outputs "test".
Meli94
@meli94
Feb 12 2017 15:47
what are you trying to do? @Toffanelly
getting the search term from the input?
h1tag
@h1tag
Feb 12 2017 15:48
@AshwathShivaz yes
Toffanelly
@Toffanelly
Feb 12 2017 15:48
@meli94 The function is run when i click the button next searchbox. It is supposed to assign the textbox content to the input variable
Meli94
@meli94
Feb 12 2017 15:49
use this intead: var input = $('#test').val();
you don't need to create a function :) someone has already done it for you! @Toffanelly
in your function, by the way, I think that the problem is the return statement which I don't see
Toffanelly
@Toffanelly
Feb 12 2017 15:52
@meli94 Its not working either way :(
Goran Dimitrijevic
@DimiG031
Feb 12 2017 15:53
I done evrything , and now I can`t do tahat function for the buttons
Meli94
@meli94
Feb 12 2017 15:55
@Toffanelly send me the link of your code pen so I can understand better
Toffanelly
@Toffanelly
Feb 12 2017 15:55
@meli94 even if a use $('#searchbox').val(); , It only works with the value i assign beforehand and does not change while i type
taltmann42
@taltmann42
Feb 12 2017 15:58
Hey guys, just built my Twitch viewer, any suggestions/critique?
http://codepen.io/taltmann42/full/dNwvXB/
Meli94
@meli94
Feb 12 2017 16:03
@Toffanelly there are few problems: 1 you're declaring the var input twice
2 You're not using <form> in your HTML
3 it's missing an action after your for loop
Tom
@moT01
Feb 12 2017 16:07
@taltmann42 looks great
Rex
@rexbrooker
Feb 12 2017 16:11
Hey Coders! I want to put a boarder around my Divs so I can see their affect, but when I do, the boarder changes the padding and margins. Is there a way to outline a div so I can see it but not have it impact the other components? I'm using Codepen
taltmann42
@taltmann42
Feb 12 2017 16:12
@rexbrooker you have two options here:
  1. use outline instead of border in the CSS
  2. add box-sizing:border-box to the div (via CSS), then the border is not added to the elements width
Toffanelly
@Toffanelly
Feb 12 2017 16:16
@meli94 And how would adding the <form> help me?
Meli94
@meli94
Feb 12 2017 16:25
@Toffanelly
<form>
          <input type="text" id="searchbox" placeholder="Search for...">
        </form>
Meli94
@meli94
Feb 12 2017 16:38
$(document).ready(function() {
      $("form").submit(function(e) {
        e.preventDefault(); ///<< prevent the page refresh
        var input = $('#searchbox').val();
        //$("#test").html(input);

        //input = input.replace(/[^\w\s]/gi, '');
        var url = 'https://en.wikipedia.org/w/api.php?action=opensearch&search=' + input + '&format=json&callback=?';
        $.getJSON(url, function(val) {
          $('#container').html('');
          //var arr = JSON.stringify(val);
          for (i = 0; i < val[1].length; i++) {
            $("#container").append("<a target=\"_blank\" class=\"well result\" href=\"" + val[3][i] + "\"><h3>" + val[1][i] + "</h3><h5>" + val[2][i] + "</h5>" + "</a>");
          }
          return $('#searchbox').val('');
        });
      });
      });
@Toffanelly this is how your code should look like for wotking properly
Rex
@rexbrooker
Feb 12 2017 16:40
@taltmann42 Outline worked a charm! Thank you very much!
CamperBot
@camperbot
Feb 12 2017 16:40
rexbrooker sends brownie points to @taltmann42 :sparkles: :thumbsup: :sparkles:
:cookie: 481 | @taltmann42 |http://www.freecodecamp.com/taltmann42
Rex
@rexbrooker
Feb 12 2017 16:53
What's a good way to assign padding and margins to CSS items? If I give a bottom margin to an image class, and a top margin to Text, when the text follows the image, it gives it a gap that's too big. I know how to fix it, but was hoping someone could give me a pointer on better practice
viorelfoamete
@viorelfoamete
Feb 12 2017 17:05
hello. what do you guys think about my portfolio page ? please give me some feedback, good or bad xD https://codepen.io/viorelfoamete/full/wgRwvm/
Kevin
@kev-cs
Feb 12 2017 17:18
Hey guys, I'm starting a small new project, it's a simple utility interface for doing some management work at my job. I'm an almost-graduate CS student, so I know most basics in web development, but I have some concerns with which technology to chose and the structure of my app. I was about to do a React/Redux single page app with a REST backend, but the SPA part sounds a bit overkill in my opinion and I'm not too sure how I should do it otherwise. I know it's a bit unclear, but honestly I don't know much about what features I'll have to implement, I just know that I can chose whatever technology I want to use. Any suggestions?
Meli94
@meli94
Feb 12 2017 17:19
@viorelfoamete apart from a spelling mistake it looks great! '' I've made a tribute for completing freeCodeCamp - challange.-''
viorelfoamete
@viorelfoamete
Feb 12 2017 17:22
@meli94 thanks
CamperBot
@camperbot
Feb 12 2017 17:22
viorelfoamete sends brownie points to @meli94 :sparkles: :thumbsup: :sparkles:
:cookie: 291 | @meli94 |http://www.freecodecamp.com/meli94
Hello911
@Hello911
Feb 12 2017 17:52
var fruits=['cherry', 'apples','bananas'];
What is the difference between just doing fruits.sort(); and console.log(fruits.sort())?
Kevin
@kev-cs
Feb 12 2017 18:00
@Hello911 none kinda, except that the console.log one outputs the result to the console. The sort method of the array prototype sorts the array, but also returns the result.
YanivStern
@YanivStern
Feb 12 2017 18:00
Hi, do i really need to do the "Build a Personal Portfolio Webpage Incomplete " stage? Because i did the "Tribute Page" stage but i still don't know JS to do the Portfolio project yet.
Because JS is after the portfolio project.
NathanMcSparran
@NathanMcSparran
Feb 12 2017 18:03
You should be able to do it with what you've learned so far.
Luis Carlos Garcia Barajas
@Luiko
Feb 12 2017 18:04
@YanivStern you don't need javascript for the portfolio as far I can tell you
NathanMcSparran
@NathanMcSparran
Feb 12 2017 18:04
It's mainly html and css
Ian MacMillan
@IanMacMillan
Feb 12 2017 18:04

@fortMaximus OK....after a bit of a delay I coded from scratch this tribute to Maximilian Kolbe, a Franciscan Friar who swapped places with a condemed man in Auschwitz. I saw a random note on this when searching for something else the other day....and it hit a nerve. http://codepen.io/IanMacMillan/full/mRzqmb/

Yes, the structure of the code is similar to Quincy's, but I've learnt so much from it. The Jumbotron, how to lay out columns and change the offset with different screen widths....

On to the next challenge!

NathanMcSparran
@NathanMcSparran
Feb 12 2017 18:06
Nicely done Ian. I definitely have a similar style to mine as well. Since then, I've developed a few new ideas that I'll work on after I finish the certifications - to polish up the portfolio
Ian MacMillan
@IanMacMillan
Feb 12 2017 18:07
@NathanMcSparran Thanks.
CamperBot
@camperbot
Feb 12 2017 18:07
ianmacmillan sends brownie points to @nathanmcsparran :sparkles: :thumbsup: :sparkles:
:cookie: 266 | @nathanmcsparran |http://www.freecodecamp.com/nathanmcsparran
viorelfoamete
@viorelfoamete
Feb 12 2017 18:08
@IanMacMillan really nice. congrats
Luis Carlos Garcia Barajas
@Luiko
Feb 12 2017 18:09
html and css are very strong actually and can handle with many projects like that
Hello911
@Hello911
Feb 12 2017 18:09
What function can I use to show the index of an element in an array?
h1tag
@h1tag
Feb 12 2017 18:10
@IanMacMillan :+1:
YanivStern
@YanivStern
Feb 12 2017 18:11
@Luiko thanks
CamperBot
@camperbot
Feb 12 2017 18:11
:cookie: 395 | @luiko |http://www.freecodecamp.com/luiko
yanivstern sends brownie points to @luiko :sparkles: :thumbsup: :sparkles:
Ian MacMillan
@IanMacMillan
Feb 12 2017 18:12
@viorelfoamete Thanks. Having to add an older but working bootstrap library into CodePen (default v4 alpha not working) threw me at first.
CamperBot
@camperbot
Feb 12 2017 18:12
ianmacmillan sends brownie points to @viorelfoamete :sparkles: :thumbsup: :sparkles:
:cookie: 131 | @viorelfoamete |http://www.freecodecamp.com/viorelfoamete
viorelfoamete
@viorelfoamete
Feb 12 2017 18:13
@IanMacMillan i did the same thing :shipit:
Amit Patel
@AmitP88
Feb 12 2017 18:15
Hey guys, I'm working on my client's site and I'm having trouble getting all the content of my modals to show up. Demo: https://amitp88.github.io/Khmer-Family-Cafe/ Repo: https://github.com/AmitP88/Khmer-Family-Cafe/tree/gh-pages
modal_Ink_LI.jpg
I have no idea why the dish title, price, and descriptions aren't showing up in the modal, even though they are showing up in the DOM tree
taltmann42
@taltmann42
Feb 12 2017 18:19
@AmitP88 the text is below the menu that's why you don't see it. Also the modal backdrop seems to be above the modal itself
Amit Patel
@AmitP88
Feb 12 2017 18:21
@taltmann42 what do you mean by below the menu?
@taltmann42 do you mean like below the modal itself?
taltmann42
@taltmann42
Feb 12 2017 18:23

@AmitP88 okay the title of the dish is below the menu. the price isn't shown because it's not inside the modal. You have this structure:

- modal
- menu-info

but it should be

- modal
  -- menu-info
Amit Patel
@AmitP88
Feb 12 2017 18:24
@taltmann42 ahh I see. I'll check it out
taltmann42
@taltmann42
Feb 12 2017 18:24
the menu-info has no special positioning, it's still in the row itself, but doesn't get transfereed to the modal, like the picture for example
@AmitP88 ah and the description... well white text on white background ;)
jay397
@jay397
Feb 12 2017 18:25
header#banner.navbar.navbar-default.navbar-fixed-top
.container does anyone know what is this # sign doing here
taltmann42
@taltmann42
Feb 12 2017 18:25
@jay397 it selects the header element with the id banner
jay397
@jay397
Feb 12 2017 18:27
i see thankyou @taltmann42
CamperBot
@camperbot
Feb 12 2017 18:27
jay397 sends brownie points to @taltmann42 :sparkles: :thumbsup: :sparkles:
:cookie: 483 | @taltmann42 |http://www.freecodecamp.com/taltmann42
Luis Carlos Garcia Barajas
@Luiko
Feb 12 2017 18:27
@Kev-CS hey, have you seen this? next.js might help
Amit Patel
@AmitP88
Feb 12 2017 18:27
@taltmann42 lol I see
@taltmann42 ok, i'll work on it and let you know if I get it working :) thank you
CamperBot
@camperbot
Feb 12 2017 18:28
amitp88 sends brownie points to @taltmann42 :sparkles: :thumbsup: :sparkles:
:cookie: 484 | @taltmann42 |http://www.freecodecamp.com/taltmann42
Hello911
@Hello911
Feb 12 2017 18:30

function getIndexToIns(arr, num) {
  arr=arr.sort(function(a,b){
    return a-b;
});


var result=arr.filter(function(el){
                 return el>=num;
                 });

  if (result===[]){
    return ar.length;
  }else return arr.indexOf(result[0]);



}
getIndexToIns([2,5,10], 15);
Why doesn't it return 3? Something wrong with my if statement?
taltmann42
@taltmann42
Feb 12 2017 18:33
@Hello911 shouldn't you filter the elements inside the function?
Hello911
@Hello911
Feb 12 2017 18:36
@taltmann42 which function?
taltmann42
@taltmann42
Feb 12 2017 18:37
...
the function you have to write
getIndexToIns
aaah sorry, the indentation made it look like it's outside
@Hello911 then, how does your if work? you check if the array is empty, and if it is, you return its length? (should be arr.length btw, not ar.length)
@Hello911 you also can't check if an array is empty that way, the right if would be result.length === 0 (which is not what you want in this case)
Hello911
@Hello911
Feb 12 2017 18:39
yeah i correcte the spelling. -1 is returned
taltmann42
@taltmann42
Feb 12 2017 18:39
then result[0] is not in the array
Hello911
@Hello911
Feb 12 2017 18:40
I passed.
THanks man @taltmann42
CamperBot
@camperbot
Feb 12 2017 18:40
hello911 sends brownie points to @taltmann42 :sparkles: :thumbsup: :sparkles:
:cookie: 485 | @taltmann42 |http://www.freecodecamp.com/taltmann42
Hello911
@Hello911
Feb 12 2017 18:40
result===[] doesn't work ur right
Amit Patel
@AmitP88
Feb 12 2017 18:42
@taltmann42 it works now, thank you for your help! :D
CamperBot
@camperbot
Feb 12 2017 18:42
amitp88 sends brownie points to @taltmann42 :sparkles: :thumbsup: :sparkles:
:warning: amitp88 already gave taltmann42 points
Kevin
@kev-cs
Feb 12 2017 18:44
@Luiko I'm reading what you sent me, looks interesting, I'll be reading on thank you
CamperBot
@camperbot
Feb 12 2017 18:44
kev-cs sends brownie points to @luiko :sparkles: :thumbsup: :sparkles:
:cookie: 396 | @luiko |http://www.freecodecamp.com/luiko
Sam Griffen
@ssgriffen
Feb 12 2017 18:56
Does anyone know where to start when trying to fix "Octal literals are not allowed in strict mode" I have this challenge on a good track but when running the first test, which I have working in console, I get that error....
function makeFriendlyDates(arr) {
   var monthKeys = {
    01 : "January",
    02 : "February",
    03 : "March",
    04 : "April",
    05 : "May",
    06 : "June",
    07 : "July",
    08 : "August",
    09 : "September",
    10 : "October",
    11 : "November",
    12 : "December"
  };

  function addEnd(num){    
    switch (num){
      case "1":
         return num + "st";
      case "2": 
         return num + "nd";
      case "3": 
         return num + "rd";
      default:
         return num + "th";
     }
  }

  function convertDates (str){
    var date = str.split("-");
    var dateObj = {};
    dateObj.year = date[0];
    dateObj.month = monthKeys[parseInt(date[1],8)];
    dateObj.day = addEnd(date[2].substr(1,date[2].length));
    return dateObj;
  }
    var dateOne = convertDates(arguments[0][0]);
    var dateTwo = convertDates(arguments[0][1]);
    console.log(dateOne);
    console.log(dateTwo);
    var result = [];

  if(dateOne.year === "2016"){
    if(dateTwo.year === "2016"){
      result.push(dateOne.month + " " + dateOne.day + ", " + dateTwo.day);
      return result;
    }
  } 


}

makeFriendlyDates(['2016-07-01', '2016-07-04']);
Toffanelly
@Toffanelly
Feb 12 2017 18:56
I did the Wikipedia Viewer project based on the opensearch action. basically you get your results if it's title begins with your search. For example the Albus Dumbledor page will only show up if you search Albus, not if you only write Dumbledore. My question is: is it ok? Will it count as a completed project? If not, how can i fix it?
Paweł Karniej
@Karniej
Feb 12 2017 19:11
Hello everybody, could anyone help me with
positioning a divs
I have a big div-container, and inside this div there are 2 divs
Adam
@GoingAllTheWayUp
Feb 12 2017 19:11
where do they go?
Paweł Karniej
@Karniej
Feb 12 2017 19:11
I want a smaller div one appear on the north of another one
I don't want them to overlay but 1 should stick to the 2nd one from the top
Adam
@GoingAllTheWayUp
Feb 12 2017 19:13
Like stacked?
Paweł Karniej
@Karniej
Feb 12 2017 19:13
YEa
Adam
@GoingAllTheWayUp
Feb 12 2017 19:13
but you don't want to place the code in that order?
Paweł Karniej
@Karniej
Feb 12 2017 19:13
I can place
the code in that order
what css should i write?
Mandeep Singh
@MandeepMann
Feb 12 2017 19:15
col-offset-* not working . can you please tell me why ?
<div class="col-md-8 col-md-offset-4">
        <h3> Timeline  of  life of  Ma Yuan</h3>
          <ul>
            <li> born in 1970</li>
          </ul>
        </div>
Paweł Karniej
@Karniej
Feb 12 2017 19:16
@MandeepMann I think you took too much offset, change for 2 ?
Mandeep Singh
@MandeepMann
Feb 12 2017 19:18
@Karniej
still stuck at sam problem
<div class="col-md-10 col-md-offset-2">
Paweł Karniej
@Karniej
Feb 12 2017 19:20
@MandeepMann try col-md-8 and col-md-offset-2
@MandeepMann it takes 2 from the right and 2 from the left
Mandeep Singh
@MandeepMann
Feb 12 2017 19:23
@Karniej no still the same result
Johnny
@jtan3
Feb 12 2017 19:24
@MandeepMann are you using codepen?
Paweł Karniej
@Karniej
Feb 12 2017 19:24
@MandeepMann i am sorry i am not an expert
Mandeep Singh
@MandeepMann
Feb 12 2017 19:24
@jtan3 yes I am
@jtan3 yes I am using codeine
codepen
codepen is using the new version of bootstrap
Mandeep Singh
@MandeepMann
Feb 12 2017 19:27
@jtan3 yes that worked using older version ...thank you for that
@jtan3 do you know how to do this in newer version ... on bootstrap website it says the sam away as older version
Johnny
@jtan3
Feb 12 2017 19:29
@MandeepMann i think the new version still has bugs
not sure how to do it on the new one
Mahmoud Ahmed
@Lartwel
Feb 12 2017 19:43

Hello! What's wrong with this code

<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="refresh" content="1">
    </head>

  <body id="thebody" onload="show_pattern()">
      <div id="div" style="position:absolute"></div>
    </body>

    <script>
        function show_pattern(){
        var y=25, x=25;
        var width=500, height=500;
        var rand_color;
        var colors=["red","green","yellow","blue","olive","black"];
        var the_body=document.getElementById("thebody");

        while(width>30){
            var this_div=document.getElementById("div");
            var this_body=document.getElementById("thebody");
            this_div.style.left=x+'px';
            this_div.style.top=y +'px';
            this_div.style.height=height +'px';
            this_div.style.width=width +'px';
            rand_color=Math.floor(Math.random()*6);
            this_div.style.background=colors[rand_color];
            the_body.appendChild(this_div);
            x=x+25;
            y=y+25;
            width-=50 +'px';
            height-=50 +'px';
        }
        }
    </script>
</html>

Help please

Jakov Horvat
@Yaaqovv
Feb 12 2017 19:43
hello
Do you know why borders are not displayed between each div? http://codepen.io/Yaaqov/pen/LxXKrg
I've been struggling with this for hours
Pierre Humberdroz
@phumberdroz
Feb 12 2017 19:52

Any good way to nicely increment this ? https://gist.github.com/phumberdroz/98819f2eb31c931b9c37954f90d36f96

see line 5, 6, 9 and then 16, 17, 20

I use ejs so I could use javascript in the backend but well..
Jonathan Doron
@JonathanDn
Feb 12 2017 20:42
ANYONE here experienced with D3, building an horizontal timeline?
Dylan C. Israel
@PizzaPokerGuy
Feb 12 2017 20:49
Anyone here do the d3 projects and can help me figure out why my rects aren't displaying?
0livier1O1
@0livier1O1
Feb 12 2017 20:51
Hey guys, so for the Random Quotes Machine project, I’m not sure that the challenges on JSON and Ajax were really helpful. How/where are we supposed to grab the quotes ?
Dylan C. Israel
@PizzaPokerGuy
Feb 12 2017 20:52
You can create an array or use a quotes array
quotes api*
That is a video showing how to do it with an api
0livier1O1
@0livier1O1
Feb 12 2017 20:53
@PizzaPokerGuy Okay nice! Thanks :)
CamperBot
@camperbot
Feb 12 2017 20:53
0livier1o1 sends brownie points to @pizzapokerguy :sparkles: :thumbsup: :sparkles:
:cookie: 333 | @pizzapokerguy |http://www.freecodecamp.com/pizzapokerguy
Johnny
@jtan3
Feb 12 2017 20:54
@PizzaPokerGuy love your videos
Dylan C. Israel
@PizzaPokerGuy
Feb 12 2017 20:54
@jtan3 thanks man
CamperBot
@camperbot
Feb 12 2017 20:54
pizzapokerguy sends brownie points to @jtan3 :sparkles: :thumbsup: :sparkles:
:cookie: 304 | @jtan3 |http://www.freecodecamp.com/jtan3
David
@dkohlruss
Feb 12 2017 20:57
Could anybody let me know how to go about getting React to work on codepen? I have Babel included as my preprocessor, have React & ReactDOM set as external libraries... But no such luck in getting anything to display. Works fine locally
The error I get in the console is: Uncaught ReferenceError: require is not defined
at pen.js:45:14
So it seems like it's something to do with Babel, maybe?
jay397
@jay397
Feb 12 2017 21:00
header#banner.navbar.navbar-default.navbar-fixed-top
.container
a.scrollable(href='#top')
img(src='http://qlip.in/images/qlip.png', alt='qlip | UI/UX Design and Development', title='qlip | UI/UX Design and Development')
button.navbar-toggle.collapsed(type='button', data-toggle='collapse', data-target='#navbar', aria-expanded='false')
why is it the coder only use #,and 。 signs to indicate classes. that's different from what i learned
as far as i know , we should use <class= "">.
David
@dkohlruss
Feb 12 2017 21:04
Nevermind, fixed my issue.
@jay397 the hashtag indicates an ID, not a class
jay397
@jay397
Feb 12 2017 21:06
@dkohlruss i'm sorry for interrupting , i am just a beginner, what about the dot sign , does it indicate an class ?
Artur Arsalanov
@kurumkan
Feb 12 2017 21:08
@jay397 exactly class
jay397
@jay397
Feb 12 2017 21:13

@dkohlruss sorry again for extend the space, @kurumkan thank you , just one more question, i didn't learn this usage before, and it is still in html, i saw the coder used some @ signs in CSS too ,@use postcss-nested;
@use autoprefixer;
@use postcss-simple-vars;
@use postcss-discard-comments;

$fargglad:#722872;
$morkfarg:#592059;
$morkgra:#888;

CamperBot
@camperbot
Feb 12 2017 21:13
jay397 sends brownie points to @dkohlruss and @kurumkan and @use :sparkles: :thumbsup: :sparkles:
:warning: could not find receiver for use
:cookie: 381 | @kurumkan |http://www.freecodecamp.com/kurumkan
:cookie: 174 | @dkohlruss |http://www.freecodecamp.com/dkohlruss
jay397
@jay397
Feb 12 2017 21:14
where can i find the full info about this usage
and there is no closing sign after each dot
Joshua Travis
@jktravis
Feb 12 2017 21:22
Hi. I’m looking for a little help on positioning. I’m trying to write up an interactive tooltip, but I’m struggling with positioning it. Is there a calculation that I can use?
Here’s a sample of what I’m working with.
https://gist.github.com/jktravis/ec5be842a7eefaf2ec0013bf7737e4ea
aj-willi
@aj-willi
Feb 12 2017 21:34
you should put it in a jsfiddle @jktravis i cant really see what your trying to do. for tooltips i just use the title option
Joshua Travis
@jktravis
Feb 12 2017 21:36
Basically, there’s a boostrap well with an h4, a button, and a list. The button will eventually trigger the popup (I guess that’s a better term for it rather than tooltip.) Inside it, I plan on putting an input field that will add stuff to this list.
I guess I called it tooltip, because that seems like the logical first step. /shrug
aj-willi
@aj-willi
Feb 12 2017 21:41
ah so you want like a pop up with text?
Joshua Travis
@jktravis
Feb 12 2017 21:42
Will do. Thanks.
aj-willi
@aj-willi
Feb 12 2017 21:42
or if you want on hoover over, not too hard to change i think
Joshua Travis
@jktravis
Feb 12 2017 21:43
Yeah. Just wasn’t sure how to get it centered nicely over the trigger.
aj-willi
@aj-willi
Feb 12 2017 21:44
have you tried aligning to center?
joopt
@joopt
Feb 12 2017 21:48
hey guys im having trouble with my buttons how do i make it so that when I click betweeen online and offline it doesn't remove everything?
aj-willi
@aj-willi
Feb 12 2017 21:50
@joopt show the code
Johnny
@jtan3
Feb 12 2017 22:02
i'm having the same problem as @joopt
Jake
@Jaketh
Feb 12 2017 22:06
your pen doesn't even load over here. I think you have a closing curly brace somewhere you don't need in your js
opps
Joshua Travis
@jktravis
Feb 12 2017 22:08
So, I’m not sure if that w3schools example really helps me. I think what I need is a way to calculate the position on the fly. Thanks @aj-willi
CamperBot
@camperbot
Feb 12 2017 22:08
jktravis sends brownie points to @aj-willi :sparkles: :thumbsup: :sparkles:
:cookie: 264 | @aj-willi |http://www.freecodecamp.com/aj-willi
aj-willi
@aj-willi
Feb 12 2017 22:11
@jktravis no worries, sorry im not too knowledgeable on that
alpox
@alpox
Feb 12 2017 22:16
@jay397 you got confused because the referred coder uses preprocessors. The one for HTML probably being Jade (nowadays called pug templates.) The one for css probably SASS.
Johnny
@jtan3
Feb 12 2017 22:16
not sure if that's the correct way to use the hide/show for jquery
@jay397 Preprocessors are some kind of translators of templates with their own language, which gets translated into the languages used by the browser.
Pug (Jade) as preprocessor for HTML is a language which compiles to HTML. The pug files are called template files (Templates for HTML)
alpox
@alpox
Feb 12 2017 22:25
@jtan3 if you use hide/show on the container which has all streamers as its children, they will be all gone because of the html structure.
If you hide a html element, also its child elements will be hidden (Since the hidden main element is a container holding the rest)
So if you want to hide only some of the children, there needs to be some identifier on the elements to target them properly and only hide/show the elements referred to
Chelsea Scott
@chelseas9210
Feb 12 2017 22:28
hello!
Johnny
@jtan3
Feb 12 2017 22:28
@alpox thanks ill try it out
CamperBot
@camperbot
Feb 12 2017 22:28
jtan3 sends brownie points to @alpox :sparkles: :thumbsup: :sparkles:
:cookie: 767 | @alpox |http://www.freecodecamp.com/alpox
Chelsea Scott
@chelseas9210
Feb 12 2017 22:28
i'm doing my second project and i'm trying to change the color of my header to orange and it won't work. i'm not in the html section i'm trying to do it with css
please help
taltmann42
@taltmann42
Feb 12 2017 22:29
@chelseas9210 what do you have so far?
Chelsea Scott
@chelseas9210
Feb 12 2017 22:29
body {
background-image: url("https://images8.alphacoders.com/292/292379.jpg");
}
header{
color:orange;
}
the image worked
but the orange won't work
taltmann42
@taltmann42
Feb 12 2017 22:29
@chelseas9210 color is for the font-color, if you want to change the background-color of an element, you have to use background-color
Chelsea Scott
@chelseas9210
Feb 12 2017 22:30
ok maybe i need to put font-color too?
color:
taltmann42
@taltmann42
Feb 12 2017 22:30
@chelseas9210 depends, do you want the text to be orange, or the element?
Chelsea Scott
@chelseas9210
Feb 12 2017 22:30
font-color:
yes text please
taltmann42
@taltmann42
Feb 12 2017 22:30
@chelseas9210 then color should be fine... do you have a link to the codepen?
Chelsea Scott
@chelseas9210
Feb 12 2017 22:31
D: i don't want to show it to anyone lmao but i do
taltmann42
@taltmann42
Feb 12 2017 22:31
you can send it privately
Chelsea Scott
@chelseas9210
Feb 12 2017 22:31
ok thank you
Stephan Sharps
@ssharps711
Feb 12 2017 22:43
Hello world
Where would I upload a logo to use on my portfolio page?
Or any image for that matter
Joshua Travis
@jktravis
Feb 12 2017 22:44
You can use dropbox, imgur, flickr, or github.
Stephan Sharps
@ssharps711
Feb 12 2017 22:44
Cool thank you
Joshua Travis
@jktravis
Feb 12 2017 22:44
Or really anything else that will host a file.
Stephan Sharps
@ssharps711
Feb 12 2017 22:45
@jktravis Which do you use?
Joshua Travis
@jktravis
Feb 12 2017 22:45
I favor github
Stephan Sharps
@ssharps711
Feb 12 2017 22:46
@jktravis Thank you
CamperBot
@camperbot
Feb 12 2017 22:46
ssharps711 sends brownie points to @jktravis :sparkles: :thumbsup: :sparkles:
:cookie: 355 | @jktravis |http://www.freecodecamp.com/jktravis
Joshua Travis
@jktravis
Feb 12 2017 22:46
you can github pages to host whole static sites
Jake
@Jaketh
Feb 12 2017 23:06
using the github hosted page would probably look best to a prospective employer, only thing better than that would be, owning your own website I'd imagine.
berndbausch
@berndbausch
Feb 12 2017 23:08
Hi community. I am at the "random quote machine" project (challenge 259). It requires sending a tweet. I have to admit that the web resources I have found so far are way over my head. I see OAuth and PHP everywhere and have the feeling that the learning curve towards the Twitter API is very steep. In short, is there any guidance how to do that?
taltmann42
@taltmann42
Feb 12 2017 23:10

@berndbausch you probably won't need any of that. This is an example tweet:

https://twitter.com/intent/tweet?text=The%20next%20time%20you%20raise%20a%20hand%20to%20me%20will%20be%20the%20last%20time%20you%20have%20hands

so you only have to build the URL with the text-parameter and set it as hreffor an <a> tag

berndbausch
@berndbausch
Feb 12 2017 23:10
Thanks much. That is simple enough. I guess I went into the wrong direction then.
taltmann42
@taltmann42
Feb 12 2017 23:11
yup the documentation shows you what things you can do with the API + OAuth + Backend but for such a simple thing as tweeting something that's totally enough
berndbausch
@berndbausch
Feb 12 2017 23:13
I am now trying to find my brownie points to give you one, because that was a real brick wall. If I don't find them, no hard feelings please :)
Radek
@radekjohn
Feb 12 2017 23:14
@berndbausch just write thanks and mention
CamperBot
@camperbot
Feb 12 2017 23:14
radekjohn sends brownie points to @berndbausch :sparkles: :thumbsup: :sparkles:
:cookie: 3 | @berndbausch |http://www.freecodecamp.com/berndbausch
Radek
@radekjohn
Feb 12 2017 23:14
@berndbausch like me : -)
hi, guys. I nearly finished my wikipedia viewer
taltmann42
@taltmann42
Feb 12 2017 23:15
@radekjohn enter key not working :worried:
berndbausch
@berndbausch
Feb 12 2017 23:16
I will learn Gitter in time .... Thanks @taltmann42 and @radekjohn
CamperBot
@camperbot
Feb 12 2017 23:16
berndbausch sends brownie points to @taltmann42 and @radekjohn :sparkles: :thumbsup: :sparkles:
:cookie: 265 | @radekjohn |http://www.freecodecamp.com/radekjohn
:cookie: 488 | @taltmann42 |http://www.freecodecamp.com/taltmann42
berndbausch
@berndbausch
Feb 12 2017 23:16
Aha!
taltmann42
@taltmann42
Feb 12 2017 23:16
@radekjohn sorry first thing i noticed :P apart from that, looks clean :) maybe increase the space between the results because now it looks like the headline of the next articles belongs to the previous one
Radek
@radekjohn
Feb 12 2017 23:17
except of one problem. when i do a search, and then do another, the results of previous search stay on the bottom of the page
taltmann42
@taltmann42
Feb 12 2017 23:18
@radekjohn that's because you prepend the results $("#output").prepend("
Radek
@radekjohn
Feb 12 2017 23:18
@taltmann42 yes, thanks, maybe it needs more styling. It is not finished yet
CamperBot
@camperbot
Feb 12 2017 23:18
radekjohn sends brownie points to @taltmann42 :sparkles: :thumbsup: :sparkles:
:cookie: 489 | @taltmann42 |http://www.freecodecamp.com/taltmann42
taltmann42
@taltmann42
Feb 12 2017 23:18
which is fine, since you list all results
but it keeps prepending the results from a new search too. To prevent that, just use $("#output").html("") before entering the loop, this will delete the content from the output
Radek
@radekjohn
Feb 12 2017 23:20
@taltmann42 thanks i will try it right now
CamperBot
@camperbot
Feb 12 2017 23:20
radekjohn sends brownie points to @taltmann42 :sparkles: :thumbsup: :sparkles:
:warning: radekjohn already gave taltmann42 points
Radek
@radekjohn
Feb 12 2017 23:22
@taltmann42 thats it. tha was fast.
good night to all
taltmann42
@taltmann42
Feb 12 2017 23:22
@radekjohn :thumbsup:
VilfredSikker
@VilfredSikker
Feb 12 2017 23:44
Hey people I have problem. I've created a logo as a jpf file, but I can't upload it. The thing is, I don't want the background to be visible what do I do?
Jake
@Jaketh
Feb 12 2017 23:44
save as .png
@VilfredSikker needs to be a .png for transparent background.
Mac
@itchick85
Feb 12 2017 23:45
I'm done with my tribute page what link do I put it the box to go to the next challenge?
VilfredSikker
@VilfredSikker
Feb 12 2017 23:46
@Jaketh thanks! haha went all over the net and then thought of the perfect community here :)
CamperBot
@camperbot
Feb 12 2017 23:46
vilfredsikker sends brownie points to @jaketh :sparkles: :thumbsup: :sparkles:
:cookie: 331 | @jaketh |http://www.freecodecamp.com/jaketh
Jake
@Jaketh
Feb 12 2017 23:47
the link in your address bar while you have the pen open. @itchick85
Mac
@itchick85
Feb 12 2017 23:47
ok thanks
Jake
@Jaketh
Feb 12 2017 23:47
@VilfredSikker No problem :D