Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • Aug 17 09:32
    User @bjorno43 unbanned @linkin-park
  • Jun 20 21:19
    @bjorno43 banned @shenerd140
  • Apr 25 17:13
    @mstellaluna banned @cmal
  • Jan 08 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
  • Jul 29 2018 01:00
    @bjorno43 banned @jkyereh
  • Jul 10 2018 22:09
    @bjorno43 banned @manafn
  • Jul 06 2018 15:20
    @texas2010 banned @imlegend19
  • Jul 03 2018 12:28
    @bjorno43 banned @vbvmatta
  • Jun 29 2018 13:54
    @bjorno43 banned @OGTechnoBoy
Tyler Moeller
@TylerMoeller
Weird, just tested again. It works for me on Firefox and Chrome, windows 7. Chrome/Edge Windows 10. Chrome/Safari Mac OS Sierra.
sennator
@sennator2
http://codepen.io/sennator/pen/egEeLP?editors=0110
why is that when i get undefined for one of my variables non of others gets displayed in my articles window?
h1tag
@h1tag
@sennator2 it's working fine for me
Tony
@FreakishLancer
Ugh...now I can get mine to work on every browser, even Firefox Developer Edition, EXCEPT vanilla Firefox.
This is annoying.
Willina Clark
@lclc68lclc

I'm attempting to make the tweet part of my random quote machine work and every time I enter the below code, the CORS error comes back on codepen:

var urlApi = "https://quotesondesign.com/wp-json/posts?filter[orderby]=rand&filter[posts_per_page]=1";
  $.getJSON(urlApi, function(a) {
  $("#message").append(a[0].content + "<p>— " + a[0].title + "</p>");
  $("#tweet_btn").on("click", function(e){
    var tweet = $("#message").text;
    $("#tweet_btn").attr('href', 'https://www.twitter.com/intent/tweet?text=' + message);
    });
  });

If I remove the tweet button, everything works fine.

Meli94
@meli94
take off the button from the getJSON request
Tyler Moeller
@TylerMoeller
@sennator2 Looking at this more closely, you are testing to see if some of the properties don't exist, but when you use return in a for loop, it stops the for loop and exits. So, you're exiting the for loop as soon as you get a result without a thumbnail or a description. Instead, add a placeholder thumbnail or placeholder text and keep the for loop going.
Roberto Di Lillo
@koop4
hi all
Willina Clark
@lclc68lclc
@meli94 that worked for one problem. Thank you
CamperBot
@camperbot
lclc68lclc sends brownie points to @meli94 :sparkles: :thumbsup: :sparkles:
:cookie: 289 | @meli94 |http://www.freecodecamp.com/meli94
Roberto Di Lillo
@koop4
I was cheching this challange and it seems to me that 7th test is wrong.
It should return a change, but it requires to return the string "insufficient Funds"
can anyoneelse confirm the bug?
sennator
@sennator2
@TylerMoeller thanks for your help
CamperBot
@camperbot
sennator2 sends brownie points to @tylermoeller :sparkles: :thumbsup: :sparkles:
:star2: 1476 | @tylermoeller |http://www.freecodecamp.com/tylermoeller
Meli94
@meli94
@lclc68lclc make a function tweet similar to this : function tweet() {
window.open("https://twitter.com/intent/tweet?text=" + encodeURIComponent($('#quote').text()) + '%0a' + $('#author').text());
}
and then call it on click
Srđan Međo
@PerpetualWar
guys, I use jquery's hide() and show() to disable and enable visible properties on screen. But the problem is placeholders stay, so for example if I hide all between 1st and 10th object, in between is empty space which looks not so good
how to go around that problem ?
Meli94
@meli94
addClass()
or .empty() to take off the placeholder
@PerpetualWar
Srđan Međo
@PerpetualWar
ok let me try
Tyler Moeller
@TylerMoeller
@PerpetualWar You probably aren't hiding the entire element or you have height and width as attributes to the element. .hide() is the same as display: none which will completely hide it. If you have a codepen, it would help debug
click on online and offline
you will see uneven distance between boxes
Tyler Moeller
@TylerMoeller
@PerpetualWar You aren't hiding the <a> tags, just the content between them
Click "Online" and then right-click -> inspect to see your HTML. There's a bunch of empty <a></a> tags
Srđan Međo
@PerpetualWar
so I just need to select them as well ?
Tyler Moeller
@TylerMoeller
Yeah, or put the online offline classes on the a tags instead of their divs inside
Jason Luboff
@JLuboff
@TylerMoeller Hey Tyler, question for you. What would be the best way to store a navigation bar in an html file that is served to multiple pages? PHP or iFrame? Or another solution?
Willina Clark
@lclc68lclc
@meli94 That didn't work. https://codepen.io/lclc68lclc/pen/EZLYae
Tyler Moeller
@TylerMoeller
@JLuboff In wordpress, they do this with a header.php template. Outside of wordpress, I'd probably just dynamically generate the HTML and have that run in a document.ready.
Srđan Međo
@PerpetualWar
yes @TylerMoeller that was coorect
I icompletely forgot about <a> tags
Jason Luboff
@JLuboff
@TylerMoeller Its for my companies Intranet site..that I created before I went through FCC, etc. So I'm looking at cleaning it up. What exactly do you mean by dynamically generating the HTML? To me, when I think dynamic, I think "constantly changing" versus static "fixed, not changing"
Sorin Ruse
@sorinr
@JLuboff plain html its the best solution. no need for for php a serverside and for sure NOT in an iframe
Tyler Moeller
@TylerMoeller
@JLuboff You would create a container for the navbar, like <header></header> and then in your JS:
$('header').html(
`Your navbar HTML`
);
Srđan Međo
@PerpetualWar
I need one more thing @TylerMoeller check the same codepen and shrink it to mobile size or whateva
Tyler Moeller
@TylerMoeller
Or just use $('body').prepend('navbar html code') if you don't have a container to latch onto
Jason Luboff
@JLuboff
@TylerMoeller Ah...duh...that makes sense. Then if I need to make any changes, I just change the JS file
Tyler Moeller
@TylerMoeller
@JLuboff Yes, exactly
Jason Luboff
@JLuboff
@sorinr You mention just plain HTML...are you mentioning a similar idea to @TylerMoeller or something different?
Srđan Međo
@PerpetualWar
how to make when certain width is achieved I force vertical alignement
instead of horisontaol
as right now each box scales differently dependable on the size of channel name
Tyler Moeller
@TylerMoeller
I'm sorry :( I have to go... 9am and time for my rainy commute to work...
Srđan Međo
@PerpetualWar
I mean length of channel name