staceyland sends brownie points to @bomholt and @ashrisoft :sparkles: :thumbsup: :sparkles:
:cookie: 310 | @ashrisoft |http://www.freecodecamp.com/ashrisoft
:cookie: 555 | @bomholt |http://www.freecodecamp.com/bomholt
jquery.js
, and bootstrap.js
, loaded in that order - jquery first, bootstrap second. That is what makes the menu expand.
keyspress sends brownie points to @khaduch :sparkles: :thumbsup: :sparkles:
:star2: 1705 | @khaduch |http://www.freecodecamp.com/khaduch
amidzicigor sends brownie points to @ashrisoft :sparkles: :thumbsup: :sparkles:
:cookie: 312 | @ashrisoft |http://www.freecodecamp.com/ashrisoft
weather.main
and weather.description
when they should be Rain
and heavy intensity rain
for the area I am debugging with (Minneapolis): http://codepen.io/a_melomaniac/pen/EgNyjbweather[0].main
algorri sends brownie points to @gikuyunderitu :sparkles: :thumbsup: :sparkles:
:cookie: 294 | @gikuyunderitu |http://www.freecodecamp.com/gikuyunderitu
nifled sends brownie points to @gemaderus :sparkles: :thumbsup: :sparkles:
:cookie: 273 | @gemaderus |http://www.freecodecamp.com/gemaderus
nifled sends brownie points to @gemaderus :sparkles: :thumbsup: :sparkles:
:warning: nifled already gave gemaderus points
<script>
$(document).ready(function() {
$("#myTitle").css("color","red");
});
</script>
<h1 id="myTitle">Leonhard Euler</h1>
dbtate sends brownie points to @sjames1958gm :sparkles: :thumbsup: :sparkles:
:star2: 3412 | @sjames1958gm |http://www.freecodecamp.com/sjames1958gm
/title/:name?
a href="/title/<%= user.name%>">Press</a>
but nooperes.render("title.ejs", { user: user });
#myTitle {
color: red;
}
dbtate sends brownie points to @kirbyedy :sparkles: :thumbsup: :sparkles:
:star2: 1403 | @kirbyedy |http://www.freecodecamp.com/kirbyedy
dbtate sends brownie points to @sjames1958gm :sparkles: :thumbsup: :sparkles:
:warning: dbtate already gave sjames1958gm points
dbtate sends brownie points to @sjames1958gm :sparkles: :thumbsup: :sparkles:
:warning: dbtate already gave sjames1958gm points
pleasein build a tribute page i am getting an error that the server unexpectedly closed the connection
pleasein build a tribute page i am getting an error that the server unexpectedly closed the connection
$(".temperature").html(Ctemp + CtempSym)
this probably always return something truthy so it never gets to the else in your click handler. if(celsius){
$(".temperature").html(Ftemp + FtempSym);
celsius = false;
}else{
$(".temperature").html(Ctemp + CtempSym);
celsius = true;
}
:star2: 3413 | @sjames1958gm |http://www.freecodecamp.com/sjames1958gm
mokubao sends brownie points to @sjames1958gm :sparkles: :thumbsup: :sparkles:
this is my code
$.ajax({
url: "http://api.forismatic.com/api/1.0/?method=getQuote&format=jsonp&lang=en&jsonp=?",
// The name of the callback parameter, as specified by the YQL service
jsonp : "callback" ,
// Tell jQuery we're expecting JSONP
dataType : "jsonp",
success: function( response ) {
console.log( response.quoteText); // server response
},
cache: false
});
<header class="main-header">
<div class="container">
<h1 class="name">Wild horses <span>tour</span></h1>
span{}
@sjames1958gm
this is my code
$.ajax({
url: "http://api.forismatic.com/api/1.0/?method=getQuote&format=jsonp&lang=en&jsonp=?",
// The name of the callback parameter, as specified by the YQL service
jsonp : "callback" ,
// Tell jQuery we're expecting JSONP
dataType : "jsonp",
success: function( response ) {
console.log( response.quoteText); // server response
},
cache: false
});
https://crossorigin.me/http://api.forismatic.com/api/1.0/?method=getQuote&format=jsonp&lang=en&jsonp=jQuery31007955132176370245_1474543217636&_=1474543217637
.name span{}
or h1.name span{}
@sjames1958gm so like this
function palindrome(str) {
str = str.split("");
str = str.reverse();
var newstr = str.join("");
if (str=== newstr){
return true;}
?({"quoteText":"Into each life rain must fall but rain can be the giver of life and it is all in your attitude that makes rain produce sunshine. ", "quoteAuthor":" Byron Pulsifer", "senderName":"", "senderLink":"", "quoteLink":"http://forismatic.com/en/035bb0a5bb/"})
@sjames1958gm Like this?
function palindrome(str) {
var str1 = str.split("");
var str2 = str1.reverse();
var str3 = str1.join("");
if (str=== str3){
return true;}
if (str != str3) {
return false;
}
hansi2468 sends brownie points to @sjames1958gm :sparkles: :thumbsup: :sparkles:
:star2: 3414 | @sjames1958gm |http://www.freecodecamp.com/sjames1958gm
return str === str3;
maeswilliam sends brownie points to @ndrsrv :sparkles: :thumbsup: :sparkles:
:cookie: 345 | @ndrsrv |http://www.freecodecamp.com/ndrsrv
@rujaraju the console returns this error
XMLHttpRequest cannot load http://www.geoplugin.net/json.gp?ip=137.163.145.183. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://s.codepen.io' is therefore not allowed access.
sourabhatt sends brownie points to @travcamer :sparkles: :thumbsup: :sparkles:
:cookie: 120 | @travcamer |http://www.freecodecamp.com/travcamer
sourabhatt sends brownie points to @travcamer :sparkles: :thumbsup: :sparkles:
:warning: sourabhatt already gave travcamer points
:cookie: 273 | @gordoh |http://www.freecodecamp.com/gordoh
rujaraju sends brownie points to @gordoh :sparkles: :thumbsup: :sparkles:
mokubao sends brownie points to @kirbyedy :sparkles: :thumbsup: :sparkles:
:star2: 1404 | @kirbyedy |http://www.freecodecamp.com/kirbyedy
div.card {
width: 250px;
box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
text-align: center;
}
Hey guys, just a little help with CSS layout, please...
According to every tutorial or Stackoverflow discussion I checked, this should make the 'content' div stretch to fill the rest of the container after the headers have taken up the alocated space. For me, that's not happening, the 'content' div is tightly wrapped around the content inside. Any ideas?
#container {
display: flex;
flex-direction: column;
width: 400px;
height: 400px;
}
#header1 {
flex: 0 1 40px;
}
#header2 {
flex: 0 1 80px;
}
#content {
flex: 1 1 auto;
}
grantknaver sends brownie points to @kirbyedy :sparkles: :thumbsup: :sparkles:
:star2: 1405 | @kirbyedy |http://www.freecodecamp.com/kirbyedy
kmulligan sends brownie points to @osfan501 :sparkles: :thumbsup: :sparkles:
:cookie: 273 | @osfan501 |http://www.freecodecamp.com/osfan501
jesscallahanseo sends brownie points to @bvipul :sparkles: :thumbsup: :sparkles:
:cookie: 285 | @bvipul |http://www.freecodecamp.com/bvipul
jesscallahanseo sends brownie points to @mones-cse :sparkles: :thumbsup: :sparkles:
:cookie: 393 | @mones-cse |http://www.freecodecamp.com/mones-cse
b1tc0de sends brownie points to @1338 :sparkles: :thumbsup: :sparkles:
:cookie: 119 | @1338 |http://www.freecodecamp.com/1338
rusmex sends brownie points to @1338 :sparkles: :thumbsup: :sparkles:
:cookie: 120 | @1338 |http://www.freecodecamp.com/1338
pleasein the tribute page challengehow to add these ul lists in the center under the above line1914 - born in cresco iowa1933 - leaves his familys farm to attend the university of minnesota thanks to a depression era program known as the national youth administration
is there any alternative way for this
<blockquote>
<footer><cite>Sir Donald Bradman</cite></footer>
</blockquote>
@sourabhatt Since ul and li elements are display: block by default — give them auto margins and a width that is smaller than their container.
ul {
width: 70%;
margin: auto;
}
If you've changed their display property, or done something that overrides normal alignment rules (such as floating them) then this won't work.
Hmmm
$(document).ready(function() {
$('#strict').click(function() {
$('#strictActive').toggleClass('clicked');
});
This should work to allow me to toggle the CSS on #strictActive
, right?
Feel like I am missing something simple: http://codepen.io/kmulligan/pen/ammPvA
!important
to the .clicked
css
sourabhatt sends brownie points to @mones-cse and @1338 :sparkles: :thumbsup: :sparkles:
:cookie: 126 | @1338 |http://www.freecodecamp.com/1338
:cookie: 394 | @mones-cse |http://www.freecodecamp.com/mones-cse
sourabhatt sends brownie points to @mones-cse :sparkles: :thumbsup: :sparkles:
:warning: sourabhatt already gave mones-cse points
new Date();
new Date(value);
new Date(dateString);
new Date(year, month[, day[, hour[, minutes[, seconds[, milliseconds]]]]]);
<script>
$(function() {
$('.countdown').countdown({
date: "June 7, 2087 15:03:26"
});
});
</script>
miriam-z sends brownie points to @1338 :sparkles: :thumbsup: :sparkles:
:cookie: 141 | @1338 |http://www.freecodecamp.com/1338
@miriam-z
you need to add this:
<script type="text/javascript" src="/path/to/jquery.countdown.js"></script>
As I believe it does not come standard with jQuery and is a plugin.
So if you have jQuery already add that and it should work.
(note: the page said it is tested with jQuery 1.7.2)
miriam-z sends brownie points to @mones-cse :sparkles: :thumbsup: :sparkles:
:cookie: 395 | @mones-cse |http://www.freecodecamp.com/mones-cse
$(document).ready(function(){
var value='';
try this
var url ='https://www.mediawiki.org/w/api.php?action=opensearch&search='+value+'&format=json&callback=?'
here value key word is undefined
$('#val').bind("enterKey",function(e){
var value=$('#val').val();
console.log(value);
});
$('#val').keyup(function(e){
if(e.keyCode == 13)
{
$(this).trigger("enterKey");
}
});
this portion of you code runing when there is no input field with val idvar famousQuotes = '{"quotes":[' +
'{"author":"Arnie", "quote":"I\'ll be back."},' +
'{"author":"Kevin Kruse", "quote":"Life isn’t about getting and having, it’s about giving and being."},' +
'{"author":"Napoleon Hill", "quote":"Whatever the mind of man can conceive and believe, it can achieve."},' +
'{"author":"Albert Einstein", "quote":"Strive not to be a success, but rather to be of value."},' +
'{"author":"Florence Nightingale", "quote":"I attribute my success to this: I never gave or took any excuse."},' +
'{"author":"Wayne Gretzky", "quote":"You miss 100% of the shots you don’t take."},' +
'{"author":"Michael Jordan", "quote":"I’ve failed over and over and over again in my life. And that is why I succeed."}]}';
var obj = JSON.parse(famousQuotes);
obj.quotes.length
sourabhatt sends brownie points to @1338 :sparkles: :thumbsup: :sparkles:
:cookie: 147 | @1338 |http://www.freecodecamp.com/1338
@emamador Try wrapping your form in a container like this.. and then instead of wrapping the button with an offset do this…
emamador sends brownie points to @1338 :sparkles: :thumbsup: :sparkles:
:cookie: 148 | @1338 |http://www.freecodecamp.com/1338
https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/js/bootstrap.min.js
steveamaki sends brownie points to @tylermoeller :sparkles: :thumbsup: :sparkles:
:cookie: 846 | @tylermoeller |http://www.freecodecamp.com/tylermoeller
@N1CKL3 You can modify the color of the links and remove underlines with this CSS:
.topnav a {
color: white;
}
.topnav a:hover {
text-decoration: none;
}
You could also use a template for your navbar: https://getbootstrap.com/examples/navbar-fixed-top/
n1ckl3 sends brownie points to @tylermoeller and @steveamaki :sparkles: :thumbsup: :sparkles:
:cookie: 204 | @steveamaki |http://www.freecodecamp.com/steveamaki
:cookie: 847 | @tylermoeller |http://www.freecodecamp.com/tylermoeller
n1ckl3 sends brownie points to @1338 :sparkles: :thumbsup: :sparkles:
:cookie: 149 | @1338 |http://www.freecodecamp.com/1338
:warning: n1ckl3 already gave tylermoeller points
:warning: n1ckl3 already gave 1338 points
n1ckl3 sends brownie points to @tylermoeller and @1338 :sparkles: :thumbsup: :sparkles:
emamador sends brownie points to @steveamaki :sparkles: :thumbsup: :sparkles:
:cookie: 205 | @steveamaki |http://www.freecodecamp.com/steveamaki
emamador sends brownie points to @steveamaki :sparkles: :thumbsup: :sparkles:
:warning: emamador already gave steveamaki points
awanjila sends brownie points to @steveamaki :sparkles: :thumbsup: :sparkles:
:cookie: 206 | @steveamaki |http://www.freecodecamp.com/steveamaki
awanjila sends brownie points to @steveamaki and @emamador :sparkles: :thumbsup: :sparkles:
:cookie: 64 | @emamador |http://www.freecodecamp.com/emamador
:warning: awanjila already gave steveamaki points
@1338 do this
/* Empty CSS file for your own CSS*/
on your CSS sheet
@1338 add
background: black;
to you “container-fluid"
1338 sends brownie points to @aprim05 and @steveamaki and @jdtdesigns :sparkles: :thumbsup: :sparkles:
:cookie: 207 | @steveamaki |http://www.freecodecamp.com/steveamaki
:cookie: 599 | @jdtdesigns |http://www.freecodecamp.com/jdtdesigns
:cookie: 150 | @aprim05 |http://www.freecodecamp.com/aprim05
aprim05 sends brownie points to @emamador :sparkles: :thumbsup: :sparkles:
:cookie: 65 | @emamador |http://www.freecodecamp.com/emamador
mhdavis sends brownie points to @emamador :sparkles: :thumbsup: :sparkles:
:cookie: 66 | @emamador |http://www.freecodecamp.com/emamador
mhdavis sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
:cookie: 600 | @jdtdesigns |http://www.freecodecamp.com/jdtdesigns
$.getJSON("http://ip-api.com/json", function(json){
$("#weather_widget").html(JSON.stringify(json));
});
zarruk sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
:cookie: 601 | @jdtdesigns |http://www.freecodecamp.com/jdtdesigns
// You had this -- Notice the closing paren after json" and no closing paren after the closing bracket
$.getJSON("http://ip-api.com/json"), function(json){
$("#weather_widget").html(JSON.stringify(json))
} // need closing paren here and semi-colon
zarruk sends brownie points to @sjames1958gm :sparkles: :thumbsup: :sparkles:
:star2: 3430 | @sjames1958gm |http://www.freecodecamp.com/sjames1958gm
json.city
) to var a
) and then afterwards the next json (therefore being able to include a in the url that calls the Open Weather Map api)?
zarruk sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
:warning: zarruk already gave jdtdesigns points
zarruk sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
:warning: zarruk already gave jdtdesigns points
zarruk sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
:warning: zarruk already gave jdtdesigns points
.NavButtons {
color: red !important;
}
$('input').focusout(function() {
$(this).css('border-color', 'red');
})
$.getJSON("http://ip-api.com/json").done(function(json){
$.getJSON("http://api.openweathermap.org/data/2.5/weather?q="+json.city+"&APPID=1f58400991b966bafb35c7f208b3817d", function(json){
$("#weather_widget").html(JSON.stringify(json))
\\ Do something with your weather data
});
});
.navbar-default .navbar-nav>li>a {
color:#2a2a2a;
}
.done(function(json)
to your .getJSON call.
n1ckl3 sends brownie points to @monotone2k and @1338 :sparkles: :thumbsup: :sparkles:
:cookie: 214 | @1338 |http://www.freecodecamp.com/1338
:cookie: 108 | @monotone2k |http://www.freecodecamp.com/monotone2k
$.getJSON(url,function(data) {
// first success
}).done(function() {
// second success
}).fail(function() {
// failures
}).always(function() {
// failures and successes reported here
});
zarruk sends brownie points to @jdtdesigns :sparkles: :thumbsup: :sparkles:
:cookie: 602 | @jdtdesigns |http://www.freecodecamp.com/jdtdesigns
.dp{
background-color: #c3c3c3;
height: 200px;
border-radius: 5px 5px 0px 0px;
background-size: cover;
background-repeat: no-repeat;
background-position: center;
-webkit-transition: all 2s;
transition: all 2s;
}
.dp:hover{
background-size: 300px;
-webkit-transition: all 2s;
}
Hi! Is there anyone that can help, please :/ I need strings that is spelled the same way foward as backwards to be true, so that is only characters and numbers
function palindrome(str) {
var str1 = str.toLowerCase();
var str2 = str1.replaceAll("[^a-zA-Z0-9]", "");
var str3 = str2.split("");
var str4 = str3.reverse();
var str5 = str4.join("");
if (str=== str5){
return true;}
if (str != str5) {
return false;
var items = [
["jan", "ik hou van alleman"],
["piet", "geeft hem niet"],
["dolf", "is een wolf"]
];
jwoo92 sends brownie points to @konikodes :sparkles: :thumbsup: :sparkles:
:cookie: 373 | @konikodes |http://www.freecodecamp.com/konikodes
@N1CKL3 -- it's all a matter of putting anchor tags on the places in the navbar with "href" attributes that link to the ID values in the sections that you want to scroll to. So you might have a "contact" link like this:
<a href="#contactSection">Contact</a>
and in the div or section where you have contact information:
<section id="contactSection">
which ties the two together
@N1CKL3 - add this CSS and a little bit of text to each section:
section {
min-height: 300px;
background-color: blue;
padding-top: 60px;
}
You'll see that it scrolls.
natashasetnik sends brownie points to @michielhuijse :sparkles: :thumbsup: :sparkles:
:cookie: 268 | @michielhuijse |http://www.freecodecamp.com/michielhuijse
@N1CKL3 check this out: http://getbootstrap.com/components/
Look at the right and read over nav and navbar.
In codepen, make sure you have bootstrap selected under the HTML settings.
n1ckl3 sends brownie points to @khaduch :sparkles: :thumbsup: :sparkles:
:star2: 1710 | @khaduch |http://www.freecodecamp.com/khaduch
setBackground()
function. After I did this, some of the elements of the page, disappeared. When I erase the setBackground()
function, they re appear. Does anybody know why this is happening? http://codepen.io/zarruk/pen/dpNyOj?editors=0010
please i defined the setbackgroundfunction after i did this some of the elements of the page disappeared when i erase the setbackgroundfunction they re appear does anybody know why this is happening httpcodepeniozarrukpendpnyojeditors0010
setBackground()
function. After I did this, some of the elements of the page, disappeared. When I erase the setBackground()
function, they re appear. Does anybody know why this is happening? http://codepen.io/zarruk/pen/dpNyOj?editors=0010
setBackground()
function. Why is the background not changing to the image pointed there although weather == clouds?
:cookie: 396 | @mones-cse |http://www.freecodecamp.com/mones-cse
zarruk sends brownie points to @mones-cse :sparkles: :thumbsup: :sparkles:
wrong
$(".general").css("background-image", url("http://www.familyandhome.org/sites/g/files/g20561/f/clouds.jpg"))
right
$(".general").css("background-image","url(http://www.familyandhome.org/sites/g/files/g20561/f/clouds.jpg)")
amitp88 sends brownie points to @glgirl28 :sparkles: :thumbsup: :sparkles:
:cookie: 343 | @glgirl28 |http://www.freecodecamp.com/glgirl28