Home > Web Front-end > HTML Tutorial > css problem! Details, God! _html/css_WEB-ITnose

css problem! Details, God! _html/css_WEB-ITnose

WBOY
Release: 2016-06-24 11:48:23
Original
1071 people have browsed it

Source of problem: Website applied to map. Icon marks are marked on certain longitudes and latitudes. When the mouse clicks on the corresponding mark, a prompt box will pop up as shown in Figure 1. The problem now is that when you click the fit icon on the upper edge of the map, the prompt box will be blocked as shown in Figure 2.
The question is: how to adjust it so that it fits on the edge so that the prompt box is displayed below the icon instead of above it. It can also be displayed correctly on the left and right edges.
Thanks!




Reply to discussion (solution)

The first js calculation position repositioning

The second method is to adjust the z-index of the prompt box

It would be better to relocate it to the middle

js obtains the upper distance of the trigger point Icon mark as the judgment condition. If the upper distance is insufficient, then Show down.

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template