Beginner challenge

Beginner challenge
0

#1

Hi guys lm new to this camp. lm going through the HTML challenge and l got stuck, l followed the instructions but l could not get it. PLEASE ANY HELP!!!

this is what they asked:

Create a class called thick-green-border that puts a 10-pixel-wide green border with a style of solid around an HTML element, and apply that class to your cat photo.

Remember that you can apply multiple classes to an element by separating each class with a space within its class attribute. For example:

<img class="class1 class2"

AND THIS IS WHAT I DID:

img .smaller-image .thick-green-border {
    width: 100px;
    border: 10px solid green;
  }
  
</style>

<h2 class="red-text">CatPhotoApp</h2>

<img class="smaller-image" class="thick-green-border"  src="https://bit.ly/fcc-relaxing-cat" alt="A cute orange cat lying on its back. "

#2

css looks good

the html element could be written as:

<img class="smaller-image thick-green-border" src="https://bit.ly/fcc-relaxing-cat" alt="A cute orange cat lying on its back. ">

needs a closing > it seems


#3

Rather than using “class=” multiple times, you can put all of your class names inside quotes together- like

img class=“class-1 class-2 class-3”

Then in your css, you don’t need to select all the classes at once. It should be fine just to say

.thick-green-border {
your code
}

I’ve found that sometimes their code checkers are very specific.

And I just noticed the closing >. That might be the problem, too.


#4

@miwst, @paintingfire Ohhh yeah it worked thank you. l was able to complete the THML part. im quite sure you guys will be hearing from me more often… l do appreciate your help.


#5

I cleaned up your code.
You need to use triple backticks to post code to the forum.
See this post for details.


#6

Glad you were able to get through it. These forums have been amazingly helpful for me, don’t hesitate to ask for help!


#7

@paintingfire, hi l need help l was not able to answer the question 4

  1. Use the $(“button”) selector.
  2. Use the $(".btn") selector.
  3. Use the $("#target1") selector.
  4. Only add one class with each of your three selectors.
  5. Your #target1 element should have the classes animated‚ shake and btn-primary.
  6. Only use jQuery to add these classes to the element.

HERE IS THE CODE

jQuery Playground

#left-well

#target1 #target2 #target3

#right-well

#target4 #target5 #target6