in Education by
This question already has answers here: How to remove the space between inline/inline-block elements? (41 answers) Closed 3 years ago. I'm trying to use a text as a link, but I fails with 2 things: 1. There is a blank space between the 2 span elements but I failed to remove it (margin-right and margin-left did nothing): As I hover on the rapitec span element, I get a pointer cursor, whereas I get default cursor as I hover the .com span element. HTML: rapitec .com Run code snippetExpand snippet JavaScript questions and answers, JavaScript questions pdf, JavaScript question bank, JavaScript questions and answers pdf, mcq on JavaScript pdf, JavaScript questions and solutions, JavaScript mcq Test , Interview JavaScript questions, JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)

1 Answer

0 votes
by
A is an inline element, and any whitespace including linebreaks between inline elements is shown as a single space. You can remove the linebreak to make it work as desired: rapitec.com Run code snippetExpand snippet Another option can be to use CSS float:left for the span-elements, but that may cause other unwanted effects for your layout if you don't do it carefully. And about your 2) mouse pointer issue: I can't reproduce it here, and I don't see anything in what you posted that could cause it.

Related questions

0 votes
    This question already has answers here: How to remove the space between inline/inline-block elements? (41 ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked May 7, 2022 in Education by JackTerrance
0 votes
    This question already has answers here: How to remove the space between inline/inline-block elements? (41 ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked May 6, 2022 in Education by JackTerrance
0 votes
    This question already has answers here: How to remove the space between inline/inline-block elements? (41 ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked May 4, 2022 in Education by JackTerrance
0 votes
    Why text inside / list is not affected (color of "item1", "item2" is not changed) by CSS applied ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked May 1, 2022 in Education by JackTerrance
0 votes
    Why text inside / list is not affected (color of "item1", "item2" is not changed) by CSS applied ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Apr 29, 2022 in Education by JackTerrance
0 votes
    Why text inside / list is not affected (color of "item1", "item2" is not changed) by CSS applied ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Apr 26, 2022 in Education by JackTerrance
0 votes
    I have a search box. The box itself is an image and the button is an image too. The CSS is as ... , JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Feb 26, 2022 in Education by JackTerrance
0 votes
    This question already has answers here: Simulating transform-origin using translate (2 answers) Closed 3 years ... for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Apr 26, 2022 in Education by JackTerrance
0 votes
    This question already has answers here: Simulating transform-origin using translate (2 answers) Closed 3 years ... for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Apr 24, 2022 in Education by JackTerrance
0 votes
    What are the new form elements introduced in HTML5?...
asked Apr 10, 2021 in Education by JackTerrance
0 votes
    I have a Div element that pops up when clicking on a icon. This works fine on desktop. But when ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Jul 3, 2022 in Education by JackTerrance
0 votes
    I'm trying to figure out how can I create a vertical gap between two elements that are located in ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked May 4, 2022 in Education by JackTerrance
0 votes
    I am working on a code pen and am having an issue where initially my main element would be exactly ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Apr 26, 2022 in Education by JackTerrance
0 votes
    Which of the following attribute triggers event when an element is dragged?...
asked Apr 10, 2021 in Education by JackTerrance
0 votes
    Which Semantic element is best suitable for content like blog post that is self contained, independent and can be republished?...
asked Apr 10, 2021 in Education by JackTerrance
...