4

I recently had a problem with centralizing an image in a carousel - specifically, I couldn't vertically align it in the center. I did some digging and found an answer here: How to center image in carousel. However, the answer by smidkristian only tells you how to horizontally align the image. So I wrote an answer below which also includes how to vertically align the image (I'm yjzhou).

I'm new to posting in SO - so I'm afraid I didn't fully follow guidelines though I hope I did. in the guidelines to writing answers I was prompted to not respond to other answers, so I didn't mention his answer. I hope what I did was okay? And if it wasn't could someone tell me where I went wrong and how can I improve?

  • You can "mention" other answers in your answer, such as saying "this answer is similar to answer xyz, but it also vertically aligns elements". Though usually when you can comment, a comment is better (but of course you need some reputation to comment). – tkruse Jan 8 at 9:53
5

Not usually. Your answer should ideally be significantly different.

If you have anything to add to another answer, then leaving a comment containing your enhancement is the best course of action. The author of the answer then has the choice of including your idea (and hopefully crediting you).

Leaving similar answers just becomes confusing for readers and doesn’t fully answer the question in one hit.

  • thank you for the answer - I will change my answer into a comment immediately. I was a little confused though since when I was writing an answer, it told me not to respond to other answers? @Snow. Edited to add: Oh - also I do not have enough reputation yet to leave a comment. What do I do in this scenario? – yjzhou Jan 6 at 19:22
  • Usually, you’d answer other questions that you know the answer to and gain up-votes. You’ll then gain the reputation needed to add a comment. Or you can attempt to engage the user in the relevant chat room for the site and offer your enhancements there and hope that they edit their answer. – Snow Jan 6 at 19:29
  • 3
    Looking at the answer @yjzhou wrote compared to the other answers, I think it would be better to try to expand it into a more comprehensive answer than make it a comment on a similar answer. In my opinion it’s already a better answer than the other one mentioning “flex” because it mentions additional information about matching the parent. I have no expertise in that area so I can’t judge the correctness. The content seems already worthy of a separate answer, although adding more explanation would be an improvement. – ColleenV Jan 6 at 20:07
  • I agree with @ColleenV that with a little more information it would've been a fine answer. – Mast Jan 7 at 17:48

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .