Похожие чаты

Hi guys i making more than 3 or 4 modals,

with HTML CSS , when clicking on picture the modal will open(picture is link)
but here i have to define #id in href of my a tag,
but there is many picture that has modal! and here i have to define many href id in my css for every pictures
what is your opinion for fix this problem?

8 ответов

16 просмотров
Plato- Автор вопроса

Can tou give us an example? I'm afraid the explanation isn't clear enough

Plato- Автор вопроса
Pedro Aguiar
Can tou give us an example? I'm afraid the explana...

all of these images are link <a> <img></a> so when i clicking to them should modal open, and the <a> tag have id for modal like this code section <a href = "#popup"><img src = "images/amirreza.jpg" class = "card" alt="amirreza pic"/></a> <div id = "popup"> and the problem is " id and href here are unic for each picture " so i have to define more id and different id in CSS for any modal picture, but i dont want do this, is there any idea for fix this?

Plato- Автор вопроса
Plato
screenshot all of these images are link <a> <img></a> so wh...

i think there is no solution for this, i have to make more #id 🤦‍♂️

Plato
i think there is no solution for this, i have to m...

find how the modal/popup is launched and replicate the same with JS i.e. on click on any of your a tags, execute the popup open logic. but your solution still is fine since you opted to spend your time duplicating HTML (as it can be done using <template> and a little of JS)

Plato- Автор вопроса
Perlik Yubenji
find how the modal/popup is launched and replicate...

so the solution is JS... and what is <template> i searching for this and i can't find have you any article about this?

Похожие вопросы

Обсуждают сегодня

Hey everyone! I won’t focus too much on what this person said (it’s clear they don’t understand the scope of what TF and TELOSX are achieving), but I’ll put it simply for thos...
Ana Ojeda
3
Hi did any of you experience a file error when download hex file for Windows?
Valya
17
как правильно удалить сддм? прописал в etc/portage.use/plasma-meta -sddm , но при обновлении юзов мне предлагает поставить lightdm (ещё лучше 😡), добавил туда - display-manage...
REDis
25
Коллеги, я тут для личных нужд пошел ставить MQTT сервер, пощупал mosquitto, но ужаснулся отсутствию такой банальности, как HTTP API для посмотреть список топиков. А тут что,...
Maksim Lapshin
13
How will they work it out?
Max
14
Could the new Norse labs apps have just been called "VPN" instead of DVPN?
HDGVII
14
Всем привет! Имеется функция: function IsValidChar(ch: UTF8Char): Boolean; var i: Integer; ValidChars: AnsiString; begin ValidChars := 'abcdefghijklmnopqrstuvwxyzABCDE...
Евгений
44
Hello team, I have a question regarding next text from an article and if Energyweb is still working on EW-DOS or what the plans are for the future regarding EW-DOS? Can an...
MichelLWD
4
Ready for some fun AND a chance to win TKO Tokens? Join us for exciting minigames in our Telegram group! 🕒 Don’t miss out—games start on today 25 October 2024, at 8 PM! Ge...
Milkyway | Tokocrypto
255
#include <stdio.h> #include <stdlib.h> #include <time.h> void mass_first_generate(int mass[5][7]) {     for (int N = 0; N < 5; N++) {         for (int A = 0; A < 7; A++) {   ...
Чувак
6
Карта сайта