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
David Griffin
@dgriffin123
I looked up fixes for the alignment but they involved things much more advanced than what I've learned yet, using javascript etc
Muhammad Hasham
@MohammadHasham
how can i execute a function on key press from keyboard without jquery using simple JS.
@sorinr
alpox
@alpox
@MohammadHasham
someDOMObject.addEventListener("keypress", function() { ... });
Muhammad Hasham
@MohammadHasham
@alpox so how can i get that which key is pressed?
alpox
@alpox
@MohammadHasham
someDOMObject.addEventListener("keypress", function(keyEvent) { 
    if(keyEvent.key === 'a') {
        // Key a is pressed
    }
 });
Muhammad Hasham
@MohammadHasham
@alpox Thanks
CamperBot
@camperbot
mohammadhasham sends brownie points to @alpox :sparkles: :thumbsup: :sparkles:
:cookie: 749 | @alpox |http://www.freecodecamp.com/alpox
alpox
@alpox
@MohammadHasham See this example:
https://codepen.io/pen/?editors=1010
Muhammad Hasham
@MohammadHasham
@alpox Thanks
CamperBot
@camperbot
mohammadhasham sends brownie points to @alpox :sparkles: :thumbsup: :sparkles:
:warning: mohammadhasham already gave alpox points
alpox
@alpox
@MohammadHasham Np :-)
Sorin Ruse
@sorinr
@dgriffin123 take a look at the example . this is what u want?
David Griffin
@dgriffin123
Yeah that seems to be what I wanted. They're all the same height.
img {
padding: 15px;
max-height: 216px;
margin: 0 auto;
}
is this the only change that had to be made?
Sorin Ruse
@sorinr
@dgriffin123 yes. because the last image was smaller height then the othersi put max-height: 216px as the last one. you can also add class="img-responsive" to each of your img tags so they scale well on lower screens
David Griffin
@dgriffin123
hmm. Well I really appreciate your help with that. I feel like I get stuck on the dumbest things.
Sorin Ruse
@sorinr
@dgriffin123 its quite ok for the beginning
Milos Ratkovic
@Shadow032
guys anyone knows a good weather API, I made a weather app like a week ago , and now i got an email from OpenWeather that my API got blocked.
Sorin Ruse
@sorinr
@Shadow032 there is also apixu.com, wunderground and some others. as soon as i remember i'll tell you
Milos Ratkovic
@Shadow032
@sorinr thanks, i'll google it out.
CamperBot
@camperbot
shadow032 sends brownie points to @sorinr :sparkles: :thumbsup: :sparkles:
:star2: 1134 | @sorinr |http://www.freecodecamp.com/sorinr
Sorin Ruse
@sorinr
@Shadow032 welcome
David Griffin
@dgriffin123
@sorin I hate to bother you, but I can't seem to figure out how to fix these issues. Your solution fixed the height, but there are a couple that have different widths. I tried messing with max-width but I can't figure out why it isn't getting the effect I want.
It's very frustrating
Sorin Ruse
@sorinr
@dgriffin123 no need for max-width because you have the imgs placed into <div class="col-xs-6"> so they take the full width of of this col-xs-6 div. to mee they seem to have same width and height
David Griffin
@dgriffin123
the only one with a different width was the Dark Souls pic, it is slightly wider than the one under it
Maybe that's just my display or something
Jarvis1247
@Jarvis1247
m getting this: CORS header ‘Access-Control-Allow-Origin’ missing
What to do?
Sorin Ruse
@sorinr
@dgriffin123 no no. u r right. the breaking bad is less wider then all the others. let me think
David Griffin
@dgriffin123
Honestly though @sorin I think I need to just move past it lol. I've been obsessing over those damn pictures not being exactly 100% the same I haven't moved on in like 2 days lol
Jarvis1247
@Jarvis1247
any solution to my prob??
Sorin Ruse
@sorinr
@dgriffin123 no. just add width: 100%; in css to img selector
@Jarvis1247 can u share the pen link to see what causing it?
David Griffin
@dgriffin123
@sorinr Such an easy fix, can't believe I didn't think of that. Thank you again
CamperBot
@camperbot
dgriffin123 sends brownie points to @sorinr :sparkles: :thumbsup: :sparkles:
:star2: 1135 | @sorinr |http://www.freecodecamp.com/sorinr
Jarvis1247
@Jarvis1247
i am working on my text editor @dgriffin123
Sorin Ruse
@sorinr
@dgriffin123 yes but now you have the same problem of height with dexter img. try to find another one bigger then that
David Griffin
@dgriffin123
@sorin I actually decided to change it to 2 rows instead of 3, and all the images seem to look good
Muhammad Hasham
@MohammadHasham
which one is better document.getElementById('') or document.quereySelector()
@sorinr
Sorin Ruse
@sorinr
@dgriffin123 nope . they are all same width but on 2nd row the first and the last are shorter in height
@MohammadHasham getbyid if the tag has an id.
David Griffin
@dgriffin123
jeez. you're right. How do you avoid these problems? Should I crop images before I even use them?
Sorin Ruse
@sorinr
@dgriffin123 yep. better to have them same dimensions