Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • Jun 19 2020 20:09
    @krisb1220 banned @Gastony
  • May 14 2020 22:39
    @bjorno43 banned @minitechtips_twitter
  • May 14 2020 22:38
    @bjorno43 banned @real-action
  • Feb 01 2020 00:27
    @bjorno43 banned @Ndoua
  • Jan 07 2020 03:10
    @bjorno43 banned @doctor-sam
  • Aug 17 2019 09:32
    User @bjorno43 unbanned @linkin-park
  • Jun 20 2019 21:19
    @bjorno43 banned @shenerd140
  • Apr 25 2019 17:13
    @mstellaluna banned @cmal
  • Jan 08 2019 22:05
    @mstellaluna banned @dertiuss323
  • Nov 07 2018 04:42
    User @texas2010 unbanned @ows-ali
  • Nov 02 2018 16:25
    @texas2010 banned @ows-ali
  • Oct 12 2018 05:50
    @bjorno43 banned @NACH74
  • Oct 05 2018 23:02
    @mstellaluna banned @JomoPipi
  • Sep 16 2018 12:21
    @bjorno43 banned @yash-kedia
  • Sep 16 2018 12:16
    @bjorno43 banned @vnikifirov
  • Sep 05 2018 08:12
    User @bjorno43 unbanned @androuino
  • Sep 05 2018 07:38
    @bjorno43 banned @androuino
  • Aug 23 2018 16:57
    User @bjorno43 unbanned @rahuldkjain
  • Aug 23 2018 16:23
    @bjorno43 banned @rahuldkjain
  • Jul 29 2018 14:13
    User @bjorno43 unbanned @jkyereh
Arash D
@ArashDai
so i added these headers to my request
headers: {
"Access-Control-Allow-Origin": '*',
"Access-Control-Allow-Headers": "Origin, X-Requested-With, Content-Type, Accept"
}
am i on the right path?
Tyler Moeller
@TylerMoeller
@ArashDai What API are you trying to use?
Arash D
@ArashDai
the wikipedia viewer, it works fine when i paste it into my url bar
well thats the base url
thats a search for starwars
Tyler Moeller
@TylerMoeller
@ArashDai This Stack Overflow Answer should help you out: http://stackoverflow.com/a/38921370
Arash D
@ArashDai
god damn it
thank you
Tyler Moeller
@TylerMoeller
When I hit an error with a free code camp project, I usually search for "Stack Overflow" "Error text in quotes" "Free Code Camp" :)
Jason Luboff
@JLuboff
@TylerMoeller Hey Tyler, whats the easiest way to make two equal width columns using CSS? I can do it easily with Bootstrap, but trying to avoid using it
Tyler Moeller
@TylerMoeller
@JLuboff Hmm, width: 50% isn't working?
Arash D
@ArashDai
so if im understanding this properly some api's just require this? i dont remember ever running into this before
Tyler Moeller
@TylerMoeller
@ArashDai I think it's up to how the server is configured, a lot of APIs handle it differently
Arash D
@ArashDai
ok cool
Jason Luboff
@JLuboff
@TylerMoeller No..I tried it..but let me check something real quickl
mscirocco8
@mscirocco8
hey guys I'm using <nav> in my html text (bootstrap is enabled) and am trying the examples I see online and none of them work? how do I do a navbar?
Mois├ęs Man
@moigithub
@mscirocco8 u need to check IF the examples are for bootstrap v.3 or v.4
and use the corresponding library
also .. if the component u using on the example..is dynamic.. u will need to add the bootstrap JS library too
Tyler Moeller
@TylerMoeller
@JLuboff Lots of things can get in the way, like borders, padding, margin, collapsing margins. Might have to use width: calc(50% - 2px) or something like that. For example:
<style>
.column {
  float: left;
  width: calc(50% - 2px);
  height: 200px;
  border: 1px solid black;
}
</style>
<div class="column"></div>
<div class="column"></div>
The 2px accounts for the 1px border on each
mscirocco8
@mscirocco8
@moigithub cool ty
CamperBot
@camperbot
mscirocco8 sends brownie points to @moigithub :sparkles: :thumbsup: :sparkles:
:star2: 2723 | @moigithub |http://www.freecodecamp.com/moigithub
Tyler Moeller
@TylerMoeller
Or, if you want them to be equal width within a container with a fixed width:
<style>
  .wrapper {
    width: 400px;
  }
  .column {
    float: left;
    width: calc(50% - 2px);
    height: 200px;
    border: 1px solid black;
  }
</style>
<div class="wrapper">
  <div class="column"></div>
  <div class="column"></div>
</div>
Jason Luboff
@JLuboff
@TylerMoeller Let me ask this..I placed both div's inside of another div. I gave the parent a width of 700px. Then the child a width of 50%. I do have some padding both bottom and top, but I don't think any right/left padding..I'll have to look closer
@TylerMoeller Genius. I think its the float: left; that fixed it :+1: Thanks
CamperBot
@camperbot
jluboff sends brownie points to @tylermoeller :sparkles: :thumbsup: :sparkles:
:star2: 1507 | @tylermoeller |http://www.freecodecamp.com/tylermoeller
Tyler Moeller
@TylerMoeller
@JLuboff Cool, glad that helped :)
Jason Luboff
@JLuboff
@TylerMoeller As I said...I could easily do it with Bootstrap..but I figure I need to get better at straight CSS and dealing with positioning/display/etc
@TylerMoeller Mind if I ask another question for a different project?
Tyler Moeller
@TylerMoeller
@JLuboff Sure
By the way - this gives some other options, but I think float is what Bootstrap uses: https://css-tricks.com/fighting-the-space-between-inline-block-elements/
Jason Luboff
@JLuboff
codepen.io/jluboff/pen/KaLOJd
Right now I have my 9 boxes numbered. If I remove one number (say, the number 1), all of my other boxes get pushed down. I'm guessing its my sloppy css...
Tyler Moeller
@TylerMoeller
@JLuboff Uggh, I don't know the answer to that off the top of my head. I remember hitting it with tic tac toe and I ended up filling each div with &nbsp; :)
Jason Luboff
@JLuboff
@TylerMoeller :joy:
Tyler Moeller
@TylerMoeller
Then I just replaced that with X or O
I should research that one... :)
Jason Luboff
@JLuboff
Thats actually a fine work around. I was debating just adding in an Icon of some sort, but using a space works fine for me!
Thanks for the double answers. I'd give you more brownies but uh...you know...doesn't work that way
Tyler Moeller
@TylerMoeller
That's fine - have fun with Tic Tac Toe @JLuboff
If I come across an answer, I'll let you know
Jason Luboff
@JLuboff
Cool, thanks. TicTacToe is proving to be more entertaining than the Pomodoro clock
achudoz
@achudoz
Hi does anyone have a pointer as to how should I combine my to ajax calls? Also why doesn't my $.each() go over the array in order but puts them in seemingly random order?
http://codepen.io/achudoz/pen/VPoyEM?editors=1010
*two
Prakash Shiwakoti
@pshiwakoti1
hello guys I am working on a Wikipedia Viewer app. How do i start? Which API do I use?
Jason Luboff
@JLuboff
@pshiwakoti1 They provide you with the API to use...which is the Wikipedia API