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
omadoyeabraham
@omadoyeabraham
@h4r1m4u Thank you for your clear answer. I was thinking though of pulling the quotes from an API, so that's what has me a little bit stumped. Any advice?
CamperBot
@camperbot
omadoyeabraham sends brownie points to @h4r1m4u :sparkles: :thumbsup: :sparkles:
:star: 1396 | @h4r1m4u | http://www.freecodecamp.com/h4r1m4u
h4r1m4u
@h4r1m4u
@omadoyeabraham did you go through the JSON APIs and Ajax FCC section?
omadoyeabraham
@omadoyeabraham
@h4r1m4u Yes i did, it was too short and i was not able to understand how to access external api's.
h4r1m4u
@h4r1m4u
@omadoyeabraham hmm. in a nutshell, API is an external service that you can call with your code and get a response from it. most commonly the response you receive is a JSON. the API has a URL that you need to use and often you need to add some parameters to it (these tell the API what specifically you're requesting - for example, you could choose quote from a specific category only or a certain language). once you receive the response from the API, you can do something with the returned object (e.g. display it in your page). if you're using jquery, you'll probably want to use the getJSON() method (which is a just a shorthand for a specific use of the ajax() method). unfortunately i don't have any good tutorials to direct you to, but i'm sure that if you google around, you should be able to find a ton of them.
@omadoyeabraham this looks pretty comprehensive: https://www.smashingmagazine.com/2012/02/beginners-guide-jquery-based-json-api-clients/. give it a read
omadoyeabraham
@omadoyeabraham
@h4r1m4u Thanks i really appreciate your help.
CamperBot
@camperbot
omadoyeabraham sends brownie points to @h4r1m4u :sparkles: :thumbsup: :sparkles:
:warning: omadoyeabraham already gave h4r1m4u points
h4r1m4u
@h4r1m4u
you're most welcome
Chris Webster
@cmwebby
Hey can someone help with the twitch.tv API challenge. I can't figure out how to do the last user story which uses a place holder if the account does not exist. I've looked on the docs and I can't seem to find out how I could do this. Here's my project so far - http://codepen.io/cmwebby/pen/MKLjKQ?editors=0010
Sergey
@SZharkov
http://codepen.io/Zharkov/full/wMNXYQ/
  • can anybody explain me what I wrote badly, because there is really bad adaptation on devices. And what I should do to make this project responsible? Using media queries or there is an easier way?
Nairuz.Abulhul
@nairuzabulhul
Hello every one I have a problem with a json file I upload it to one of the free hosting websites and tried to retrieve the data from it using $.getJSON method . it did not work !!! any suggestions
James
@jamesgraham10
hey ZeeMax what are you using to retrieve the data? I just tried a plunkr with your code but it didn't work because of security issues with serving your data.json from http instead of https
'https://plnkr.co/edit/ZqTlS9su3ifIHiGxqmKx?p=preview' was loaded over HTTPS, but requested an insecure XMLHttpRequest endpoint 'http://nairuzabulhul.esy.es/data.json'. This request has been blocked; the content must be served over HTTPS.
Nairuz.Abulhul
@nairuzabulhul
@jamesgraham10 so I should change it to https
@jamesgraham10 I am using $.getJSON method
James
@jamesgraham10
Try using a .json file that's served over https
like this one https://api.github.com/users/octocat
$.getJSON('https://api.github.com/users/octocat', function (data) { console.log(data); });
Nairuz.Abulhul
@nairuzabulhul
@jamesgraham10 withe link you gave me it works, but not with mine
James
@jamesgraham10
Yeah, it's because the file you uploaded to your hosting provider is served over http, which Codepen/Plunkr and other online code editors view as an insecure source
Nairuz.Abulhul
@nairuzabulhul
@jamesgraham10 any suggestion to work around this
classact1
@classact1
hey guys I'm working on tribute page and I have problem with placing image in frame with description underneath. What I mean is how to make frame fit image with small margins? Any tips? http://codepen.io/classact1/pen/pgGKMv?editors=1000
Nairuz.Abulhul
@nairuzabulhul
@classact1 Are you using Bootstrap, if so you can use class thumbnail for the image
James
@jamesgraham10
@ZeeMax you could try uploading your json file to DropBox or Google Drive or something, that might work.
classact1
@classact1
@ZeeMax I do use Bootstrap. How do I add description under picture then?
Nairuz.Abulhul
@nairuzabulhul
@jamesgraham10 I did dropbox but getJSOn could not read it
James
@jamesgraham10
The other solution is to run your server locally
Nairuz.Abulhul
@nairuzabulhul
@classact1 you could use span or <p> options. Example <img src="http://s11.postimg.org/4ngsk6pv7/local.jpg" alt="...">
<div class='caption'>
<h3>Local Weather App</h3>
<p class='well'>HTML, CSS, jQuery, Weather API </p>
</div>
@jamesgraham10 Yeah I know that but for the project I am doing currently Its to be hosted online
@classact1 I did the same with my protfolio image with description http://codepen.io/ZeeMax/pen/eJVJNr
James
@jamesgraham10
ah okay, do you need to use Codepen
Nairuz.Abulhul
@nairuzabulhul
@jamesgraham10 not really do you know other options. I chose Codepen because it is faster to setup
James
@jamesgraham10
@ZeeMax I think it would probably be easier to find a way of uploading your file over https. What hosting provider are you currently usign?
using*
Nairuz.Abulhul
@nairuzabulhul
@jamesgraham10 I am using Hostinger
classact1
@classact1
@ZeeMax So I've put my image in a div with thumbnail class but I still get huge margins on the left and right. What am I doing wrong?
Nairuz.Abulhul
@nairuzabulhul
@classact1 share with us ur pen
@classact1 codepen
Nairuz.Abulhul
@nairuzabulhul
@classact1 it should be like this <div>
<img class="img-responsive thumbnail" src="https://www.dropbox.com/s/2y3oocrbbgjfbe0/rotmistrz-pilecki-681x389.jpg?raw=1">
<text>One of the biggest heroes in Poland's contemporary history.</text>
</div>
@classact1 thumbnail class should be included withing the image <img>
classact1
@classact1
but now the image is outside of a frame
Nairuz.Abulhul
@nairuzabulhul
@classact1 how ?? I tried it and the image is inside the frame
Robert Uivarosi
@URobert
@classact1 what are you trying to do ?
classact1
@classact1
@URobert I'm trying to put the text under picture within the frame of thumbnail.