Home > front end >  Beginners, can a label nested <div>
Beginners, can a label nested <div>

Time:12-15

That part of the figure 1 code is selected, the effect of figure 2

To click on the div anywhere can jump to the function of the target page, according to the pictures in the code to do so after can realize the jump function, but do not know or do not accord with the rules of
Also want to ask, how to figure this p tags nested div to add hyperlinks, thank you

CodePudding user response:

Div inside add onclick jump function:

CodePudding user response:

Can be set, also convenient user mouse right click to open a new window

CodePudding user response:

Can, but are generally use js to jump

CodePudding user response:

Industry cannot be nested block, transformation

CodePudding user response:

Cannot be directly set, put a label change my format, block or inline - block, should be

CodePudding user response:

Suggest you add an onclick event to div, use js jump

CodePudding user response:

refer to fifth floor programming and baidu 22 reply:
cannot be directly set, put a label change my format, block or inline - block, should be can

That excuse me according to my picture code, display: block after conversion, also need to a label set high, wide and can be used directly & lt; a>
?

CodePudding user response:

Well, thank you, but I later found out that I might need to use the anchor link to realize some function

CodePudding user response:

refer to 7th floor m0_51064989 response:
Quote: refer to fifth floor programming and baidu 22 reply:
cannot be directly set, put a label change my format, block or inline - block, should be can

That excuse me according to my picture code, display: block after conversion, also need to a label set high, wide and can be used directly & lt; a>
?
no, directly to deal with div