Bitcoin Forum
July 15, 2024, 06:02:12 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1] 2  All
  Print  
Author Topic: popup userscripts suggestion  (Read 670 times)
0x256 (OP)
Sr. Member
****
Offline Offline

Activity: 333
Merit: 335


View Profile
August 17, 2020, 01:34:23 AM
Last edit: August 25, 2020, 06:37:35 PM by 0x256
Merited by OgNasty (1), Yogee (1)
 #1

example


unfortunately, I'm not a good programmer the above example has many mistakes

hacker1001101001
Sr. Member
****
Offline Offline

Activity: 1288
Merit: 415


View Profile
August 17, 2020, 03:01:10 AM
 #2

If you are trying to pop up the user information when clicked on the username, the thread title should be like "pop up user summary when click on the username".

Btw, usually clicking on the username leads to the same details on the profile information page, so can't see any major difference in your script.
Yogee
Sr. Member
****
Offline Offline

Activity: 1554
Merit: 412


View Profile
August 17, 2020, 03:46:48 AM
 #3

....
Btw, usually clicking on the username leads to the same details on the profile information page, so can't see any major difference in your script.
But it looks nicer and I think that's what 0x256 is trying to show us.

I prefer a pop up when viewing someone's profile than being redirected to another page.
SFR10
Legendary
*
Offline Offline

Activity: 3066
Merit: 3476


Crypto Swap Exchange


View Profile WWW
August 17, 2020, 06:01:56 AM
 #4

Based on what "theymos" mentioned before [couldn't find that exact post], making small changes require tweaks in larger scales in order to ensure everything works properly and since this suggestion isn't solving an ongoing issue, I can't see this getting implemented anytime soon...
- Perhaps it's better suited for "New forum software".

But it looks nicer and I think that's what 0x256 is trying to show us.
Visual improvement isn't a necessity.

█▀▀▀











█▄▄▄
▀▀▀▀▀▀▀▀▀▀▀
e
▄▄▄▄▄▄▄▄▄▄▄
█████████████
████████████▄███
██▐███████▄█████▀
█████████▄████▀
███▐████▄███▀
████▐██████▀
█████▀█████
███████████▄
████████████▄
██▄█████▀█████▄
▄█████████▀█████▀
███████████▀██▀
████▀█████████
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
c.h.
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀█











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
AB de Royse777
Legendary
*
Offline Offline

Activity: 2548
Merit: 3964


Hire Bitcointalk Camp. Manager @ r7promotions.com


View Profile WWW
August 17, 2020, 06:15:54 AM
 #5

Nice one! Question is how do I set it in my browser?

- Perhaps it's better suited for "New forum software".
Do you think we will be seeing the forum transferred to the new forum software very soon? Let's say in the next five years :-P

..Stake.com..   ▄████████████████████████████████████▄
   ██ ▄▄▄▄▄▄▄▄▄▄            ▄▄▄▄▄▄▄▄▄▄ ██  ▄████▄
   ██ ▀▀▀▀▀▀▀▀▀▀ ██████████ ▀▀▀▀▀▀▀▀▀▀ ██  ██████
   ██ ██████████ ██      ██ ██████████ ██   ▀██▀
   ██ ██      ██ ██████  ██ ██      ██ ██    ██
   ██ ██████  ██ █████  ███ ██████  ██ ████▄ ██
   ██ █████  ███ ████  ████ █████  ███ ████████
   ██ ████  ████ ██████████ ████  ████ ████▀
   ██ ██████████ ▄▄▄▄▄▄▄▄▄▄ ██████████ ██
   ██            ▀▀▀▀▀▀▀▀▀▀            ██ 
   ▀█████████▀ ▄████████████▄ ▀█████████▀
  ▄▄▄▄▄▄▄▄▄▄▄▄███  ██  ██  ███▄▄▄▄▄▄▄▄▄▄▄▄
 ██████████████████████████████████████████
▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
█  ▄▀▄             █▀▀█▀▄▄
█  █▀█             █  ▐  ▐▌
█       ▄██▄       █  ▌  █
█     ▄██████▄     █  ▌ ▐▌
█    ██████████    █ ▐  █
█   ▐██████████▌   █ ▐ ▐▌
█    ▀▀██████▀▀    █ ▌ █
█     ▄▄▄██▄▄▄     █ ▌▐▌
█                  █▐ █
█                  █▐▐▌
█                  █▐█
▀▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▀█
▄▄█████████▄▄
▄██▀▀▀▀█████▀▀▀▀██▄
▄█▀       ▐█▌       ▀█▄
██         ▐█▌         ██
████▄     ▄█████▄     ▄████
████████▄███████████▄████████
███▀    █████████████    ▀███
██       ███████████       ██
▀█▄       █████████       ▄█▀
▀█▄    ▄██▀▀▀▀▀▀▀██▄  ▄▄▄█▀
▀███████         ███████▀
▀█████▄       ▄█████▀
▀▀▀███▄▄▄███▀▀▀
..PLAY NOW..
Upgrade00
Legendary
*
Offline Offline

Activity: 2100
Merit: 2213


Playgram - The Telegram Casino


View Profile WWW
August 17, 2020, 06:57:40 AM
 #6

Do you think we will be seeing the forum transferred to the new forum software very soon? Let's say in the next five years :-P
I think that is a possible time frame, this is the last message from theymos I have come across regarding the status of the new forum software; it was vaguely optimistic and listed a few limitations which are delaying the transition (mainly security and privacy concerns), you should note that this was close to 20 months ago so it's possible some issues have been solved and new ones may have popped up.

Limited testing was one of the issues listed at that time and is the only one the community can collectively help out with: beta testing thread

▄▄███████▄▄███████
▄███████████████▄▄▄▄▄
▄████████████████████▀░
▄█████████████████████▄░
▄█████████▀▀████████████▄
██████████████▀▀█████████
████████████████████████
██████████████▄▄█████████
▀█████████▄▄████████████▀
▀█████████████████████▀░
▀████████████████████▄░
▀███████████████▀▀▀▀▀
▀▀███████▀▀███████

▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
 
Playgram.io
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀

▄▄▄░░
▀▄







▄▀
▀▀▀░░
▄▄▄███████▄▄▄
▄▄███████████████▄▄
▄███████████████████▄
▄██████████████▀▀█████▄
▄██████████▀▀█████▐████▄
██████▀▀████▄▄▀▀█████████
████▄▄███▄██▀█████▐██████
█████████▀██████████████
▀███████▌▐██████▐██████▀
▀███████▄▄███▄████████▀
▀███████████████████▀
▀▀███████████████▀▀
▀▀▀███████▀▀▀
██████▄▄███████▄▄████████
███▄███████████████▄░░▀█▀
███████████░█████████░░
░█████▀██▄▄░▄▄██▀█████░
█████▄░▄███▄███▄░▄█████
███████████████████████
███████████████████████
██░▄▄▄░██░▄▄▄░██░▄▄▄░██
██░░░░██░░░░██░░░░████
██░░░░██░░░░██░░░░████
██▄▄▄▄▄██▄▄▄▄▄██▄▄▄▄▄████
███████████████████████
███████████████████████
 
PLAY NOW

on Telegram
TheBeardedBaby
Legendary
*
Offline Offline

Activity: 2240
Merit: 3150


₿uy / $ell ..oeleo ;(


View Profile
August 17, 2020, 07:30:25 AM
 #7

Do you think we will be seeing the forum transferred to the new forum software very soon? Let's say in the next five years :-P
I think that is a possible time frame, this is the last message from theymos I have come across regarding the status of the new forum software; it was vaguely optimistic and listed a few limitations which are delaying the transition (mainly security and privacy concerns), you should note that this was close to 20 months ago so it's possible some issues have been solved and new ones may have popped up.

Limited testing was one of the issues listed at that time and is the only one the community can collectively help out with: beta testing thread

The beta site is down for many years now and had not so much success. Instead there are a few more forums using Epochtalk now, and one of them is created by the other admin - Cyrus and his team exactly for the purpose of testing.
You can check it out here: https://coinbistro.com/
The more people testing it, the sooner we'll get the new software implemented.
You can also see the development overview thread here >

Back to the OP. The idea is OK but for me clicking the scroll button on the mouse do almost the same job Smiley

Pffrt
Sr. Member
****
Offline Offline

Activity: 1372
Merit: 322


View Profile
August 17, 2020, 08:38:43 AM
 #8

Based on what "theymos" mentioned before [couldn't find that exact post], making small changes require tweaks in larger scales in order to ensure everything works properly and since this suggestion isn't solving an ongoing issue, I can't see this getting implemented anytime soon...
Someone from the forum can develop such an script easily. Why would forum have to implement this? It's not much of necessary although it would be good to have such option. Mostly it would a benefit for the campaign manager. There are some good users on the forum who play with forum things. I think they can develop a script.
Aveatrex
Sr. Member
****
Offline Offline

Activity: 840
Merit: 375



View Profile
August 17, 2020, 08:47:23 AM
 #9

It can be implemented via an extension without much trouble with javascript



Ofcourse CSS styling can be added to the extension to make it more aesthetic

I might give it more time and release it if there is enough interest because personally I don't see much the utility except saving 5 seconds that it takes to open the user's profile on an other tab...






░░░▄▀█░░░▄░▄▄░▄░░░█▀▄
▄▄▄▀▀██▀░█▐▌█ ▀██▀▀▄▄▄
▐▌░░░▐▀░▄▀░▐▌░▀▄░▀▌░░░▐▌
▐▌░░░█░░▄▀▄▐▌▄▀▄░░█░░░▐▌
▐▌░░░█░░▀▄░▀▀░▄▀░░█░░░▐▌
▐▌░░▄░█▄░▀▄▐▌▄▀░▄█░▄░░▐▌
▐▌░█▄█░░▀▀▀██▀▀▀░░█▄█░▐▌
▐▌░░░░░░░░░░░░░░░░░░░░▐▌
▐█▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀█▌
▀▀▀▀▀▀▀█▀▀▀▀▀▀█▀▀▀▀▀▀▀
░░░░░░░▀▀▀▀▀▀▀▀▀▀
.
░░░░░░░░░░░░░▄█▄░░░░░░░▄█▄
░░░░░░░░░░░░░░░░░▄█▄░░░
░░░░▄▄▄▄▄░░░░░░░░░░░░░
░░█▀▄▄▀▄▄▀█░░░▐▌▐▌
░░░░░░░▐▌▐▌
░░░░░░░░█▄░░░░▄█
█▄█▄▄▄▄▄█▄█░░░░▄▄▀▀▀▄▄
░░░░▄▄▄░░░░░▄▀▄██▀█▌▀▄
░░░██▄██▄▄█▀█▌█▐█▄█▌█▐█
░░░░█▄▄▄▄▄█▄█▌█▐█▄█▌█▐█
░░░░█▄█░░░░░█▄▄█▄█▄█▄█
▀▄▄▄▄▄▄▄▄▄▄▀░░░▀▀▄█▄█▄▀▀
.


░░░██▄▄░░██░██
▄▄░░░░░▀█░█▄▐▌░░░░░▄▄▄
▀▀▀▀▀▀▀█▐▌▄█▐▌░░░░█░▀▀
░░░░░░█▀▄▄▄▄▄▄▀▀▀▀░░▄▄
░░░░░░█░▀▀▀▀▀▀▄█▀▀▀▀▀▀
░░▄▄▄▄▄░▄▄▄▄▄▄▀▄
░░▀▀░░█▄▀▀▀▀▀█▄▀
░░░░░░░█▐▌▀█░█
██▀▀▀▀▀▀▐▌░█░░▀▀▀▀▀▀█
░░░░░░░░██░░▀▀▀▀▀██░██
.
0x256 (OP)
Sr. Member
****
Offline Offline

Activity: 333
Merit: 335


View Profile
August 17, 2020, 11:38:59 AM
Last edit: August 17, 2020, 03:23:24 PM by 0x256
 #10

Nice one! Question is how do I set it in my browser?
as a userscript...

What if we could apply a similar idea for Reply instead of opening a new page to Reply ?
I think maybe it might be more helpful for some user.

if anyone  interested to making similar , maybe he can use Bootstrap’s modal
Bootstrap has great user experience [ https://i.ibb.co/8mBVQkV/image.png ]  [ https://i.ibb.co/8sfsc8H/image.png ]
hd49728
Legendary
*
Offline Offline

Activity: 2156
Merit: 1039



View Profile
August 17, 2020, 01:08:44 PM
 #11

Based on what "theymos" mentioned before [couldn't find that exact post], making small changes require tweaks in larger scales in order to ensure everything works properly and since this suggestion isn't solving an ongoing issue, I can't see this getting implemented anytime soon...
Is it what you can not find?
Sorry for the wait, when I went to implement this it ended up being quite a bit more of a can of worms than I originally thought because of opting out, preventing certain report-count-padding strategies, etc. It's still on my to-do list, but there are several things above it.

I opened my thread last year so I realized I was wrong to ask it.
Yogee
Sr. Member
****
Offline Offline

Activity: 1554
Merit: 412


View Profile
August 17, 2020, 01:21:13 PM
 #12

But it looks nicer and I think that's what 0x256 is trying to show us.
Visual improvement isn't a necessity.
Maybe not but anything that improves interface and user experience should be good right?
0x256 (OP)
Sr. Member
****
Offline Offline

Activity: 333
Merit: 335


View Profile
August 17, 2020, 08:00:59 PM
 #13

pop up post edited history when click on edited date

just another idea more useful came to my (big mind Tongue)
depending on the LoyceV's Topic Details: highlight deleted and edited posts (forum wide)



https://loyce.club/archive/details/topic_5256854.html

post before edited: https://loyce.club/archive/posts/5465/54657219.html
post after edited(currently): https://loyce.club/archive/details/2020-07-13_Mon_18.37h/54657219.html

I don't know if this is possible what do you think?
I hope one of the developers can do this idea
Aveatrex
Sr. Member
****
Offline Offline

Activity: 840
Merit: 375



View Profile
August 17, 2020, 08:20:39 PM
 #14

pop up post edited history when click on edited date

just another idea more useful came to my (big mind Tongue)
depending on the LoyceV's Topic Details: highlight deleted and edited posts (forum wide)



https://loyce.club/archive/details/topic_5256854.html

post before edited: https://loyce.club/archive/posts/5465/54657219.html
post after edited(currently): https://loyce.club/archive/details/2020-07-13_Mon_18.37h/54657219.html

I don't know if this is possible what do you think?
I hope one of the developers can do this idea
Looks do-able via a browser extension too just like the one I showed in the above gif. I might give it a go once I get some free time, LoyceV has to agree to scraping his website (I'm pretty sure he is fine with it though). Nevertheless is it that interesting to see what an user original post was before editing it? I don't know, Need more opinions from the community especially the investigators/Scam buster part of it.






░░░▄▀█░░░▄░▄▄░▄░░░█▀▄
▄▄▄▀▀██▀░█▐▌█ ▀██▀▀▄▄▄
▐▌░░░▐▀░▄▀░▐▌░▀▄░▀▌░░░▐▌
▐▌░░░█░░▄▀▄▐▌▄▀▄░░█░░░▐▌
▐▌░░░█░░▀▄░▀▀░▄▀░░█░░░▐▌
▐▌░░▄░█▄░▀▄▐▌▄▀░▄█░▄░░▐▌
▐▌░█▄█░░▀▀▀██▀▀▀░░█▄█░▐▌
▐▌░░░░░░░░░░░░░░░░░░░░▐▌
▐█▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀█▌
▀▀▀▀▀▀▀█▀▀▀▀▀▀█▀▀▀▀▀▀▀
░░░░░░░▀▀▀▀▀▀▀▀▀▀
.
░░░░░░░░░░░░░▄█▄░░░░░░░▄█▄
░░░░░░░░░░░░░░░░░▄█▄░░░
░░░░▄▄▄▄▄░░░░░░░░░░░░░
░░█▀▄▄▀▄▄▀█░░░▐▌▐▌
░░░░░░░▐▌▐▌
░░░░░░░░█▄░░░░▄█
█▄█▄▄▄▄▄█▄█░░░░▄▄▀▀▀▄▄
░░░░▄▄▄░░░░░▄▀▄██▀█▌▀▄
░░░██▄██▄▄█▀█▌█▐█▄█▌█▐█
░░░░█▄▄▄▄▄█▄█▌█▐█▄█▌█▐█
░░░░█▄█░░░░░█▄▄█▄█▄█▄█
▀▄▄▄▄▄▄▄▄▄▄▀░░░▀▀▄█▄█▄▀▀
.


░░░██▄▄░░██░██
▄▄░░░░░▀█░█▄▐▌░░░░░▄▄▄
▀▀▀▀▀▀▀█▐▌▄█▐▌░░░░█░▀▀
░░░░░░█▀▄▄▄▄▄▄▀▀▀▀░░▄▄
░░░░░░█░▀▀▀▀▀▀▄█▀▀▀▀▀▀
░░▄▄▄▄▄░▄▄▄▄▄▄▀▄
░░▀▀░░█▄▀▀▀▀▀█▄▀
░░░░░░░█▐▌▀█░█
██▀▀▀▀▀▀▐▌░█░░▀▀▀▀▀▀█
░░░░░░░░██░░▀▀▀▀▀██░██
.
hacker1001101001
Sr. Member
****
Offline Offline

Activity: 1288
Merit: 415


View Profile
August 18, 2020, 03:37:14 AM
Merited by AB de Royse777 (5)
 #15

Nice one! Question is how do I set it in my browser?

You can install it by using any userscript manager available for your preferred browser. For example you can use Tampermonkey for Chrome browser. One could easily find userscript manager plugins for most of the browser's out there to manage any script inside the browser itself.




What if we could apply a similar idea for Reply instead of opening a new page to Reply ?

This sounds more fun and user-friendly. I think you should go with a pop up reply option @0x256 ( nice name ).
LoyceV
Legendary
*
Online Online

Activity: 3374
Merit: 17019


Thick-Skinned Gang Leader and Golden Feather 2021


View Profile WWW
August 18, 2020, 11:03:51 AM
Merited by 0x256 (1)
 #16

LoyceV has to agree to scraping his website (I'm pretty sure he is fine with it though).
Fine by me, although if someone wants all archived posts, it's easier if I create a compressed file.
If it's just fetching one post when someone clicks the edit date, it shouldn't produce much server load.

Casdinyard
Hero Member
*****
Offline Offline

Activity: 2128
Merit: 887


Leading Crypto Sports Betting and Casino Platform


View Profile
August 18, 2020, 12:26:30 PM
 #17

I guess what fits in here is both CSS and JavaScript by using some kind of extension that would let a user change both how the forum looks and reacts to certain things. This kind of ideas were been popping recently by the great mind of 0x256 in his css suggestions such as in "custom your bitcointalk header and profile page [css only]".

But I think it would be better if there would be three extensions made with this kind of suggestion. One is for the CSS extension that changes almost how all the forum design looks, one is for the Javascript (userscript) extension that allows users to have helpful features such as merit counters etc, and one is for both design and scripting which would allow users to have a responsive and themed Bitcointalk forum like hovering on one's username and showing a little bubble of any important information about him.

..Stake.com..   ▄████████████████████████████████████▄
   ██ ▄▄▄▄▄▄▄▄▄▄            ▄▄▄▄▄▄▄▄▄▄ ██  ▄████▄
   ██ ▀▀▀▀▀▀▀▀▀▀ ██████████ ▀▀▀▀▀▀▀▀▀▀ ██  ██████
   ██ ██████████ ██      ██ ██████████ ██   ▀██▀
   ██ ██      ██ ██████  ██ ██      ██ ██    ██
   ██ ██████  ██ █████  ███ ██████  ██ ████▄ ██
   ██ █████  ███ ████  ████ █████  ███ ████████
   ██ ████  ████ ██████████ ████  ████ ████▀
   ██ ██████████ ▄▄▄▄▄▄▄▄▄▄ ██████████ ██
   ██            ▀▀▀▀▀▀▀▀▀▀            ██ 
   ▀█████████▀ ▄████████████▄ ▀█████████▀
  ▄▄▄▄▄▄▄▄▄▄▄▄███  ██  ██  ███▄▄▄▄▄▄▄▄▄▄▄▄
 ██████████████████████████████████████████
▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
█  ▄▀▄             █▀▀█▀▄▄
█  █▀█             █  ▐  ▐▌
█       ▄██▄       █  ▌  █
█     ▄██████▄     █  ▌ ▐▌
█    ██████████    █ ▐  █
█   ▐██████████▌   █ ▐ ▐▌
█    ▀▀██████▀▀    █ ▌ █
█     ▄▄▄██▄▄▄     █ ▌▐▌
█                  █▐ █
█                  █▐▐▌
█                  █▐█
▀▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▀█
▄▄█████████▄▄
▄██▀▀▀▀█████▀▀▀▀██▄
▄█▀       ▐█▌       ▀█▄
██         ▐█▌         ██
████▄     ▄█████▄     ▄████
████████▄███████████▄████████
███▀    █████████████    ▀███
██       ███████████       ██
▀█▄       █████████       ▄█▀
▀█▄    ▄██▀▀▀▀▀▀▀██▄  ▄▄▄█▀
▀███████         ███████▀
▀█████▄       ▄█████▀
▀▀▀███▄▄▄███▀▀▀
..PLAY NOW..
0x256 (OP)
Sr. Member
****
Offline Offline

Activity: 333
Merit: 335


View Profile
August 18, 2020, 02:29:49 PM
 #18

This kind of ideas were been popping recently by the great mind of 0x256
my friend my mind it not great Grin believe me..
about (userscript/style manager) userscript(js) and userstyle(css) this ideas exist before I know it and there are available extensions in most browsers

to modifying webpage style you can use "Stylus"‬ extension
to include or modifying javascript for any site/page you are visiting it search about Tampermonkey(for chrome)  or Greasemonkey(for firefox)

I apologize for not explaining in my posts about these additions because they may be harmful to some users..
Thus the user is free to choose the appropriate way to him

see also List of Bitcointalk.org Userscripts/ Add-ons
https://en.wikipedia.org/wiki/Userscript  https://en.wikipedia.org/wiki/Userscript_manager
0x256 (OP)
Sr. Member
****
Offline Offline

Activity: 333
Merit: 335


View Profile
August 22, 2020, 02:27:27 AM
 #19

pop up post edited history when click on edited date

I stopped here, I don't know how to get the loyce data this is just a try
hope someone could complete the idea.. if you find an error please correct it


Code:
// ==UserScript==
// @name         Edit History
// @namespace    https://bitcointalk.org/
// @version      0.1
// @description  bitcointalk edit history pop up
// @author       0x256
// @include      https://bitcointalk.org/index.php?topic=*
// @grant        GM_addStyle

// ==/UserScript==

(function() {
    'use strict';
    /* edit_history_min style (css) */
    GM_addStyle(".modal{background-color:#fff;z-index:10;position:fixed;top:20%;left:16.5%;width:70vw;border-radius:5px}.modal-header{position:relative}.modal-header,.modal-body{padding:10px}.modal-header > h3{margin:0}.modal-close{cursor:pointer;padding:10px 20px;display:inline-block;position:absolute;top:0;right:0;opacity:0.8}.modal-close:hover{opacity:1}.modal-body{background:#ECEDF3}.modal-backdrop{position:fixed;top:0;left:0;width:100vw;height:100vh;background-color:#000;opacity:.3}");


// Get the button that opens the modal
let myBtn = document.querySelectorAll(".edited");

Array.from(myBtn).forEach((element) => {
    element.addEventListener('click', creatModal );
    console.log(element);
});

/** open the modal */
// When the user clicks the date, create and open the modal
function creatModal() {

    /* create modal after myBtn */
    this.insertAdjacentHTML('afterend', `
    <div class="modal">
        <div class="modal-header">
            <h3>edit history</h3>
            <span class="modal-close">&#10006;</span>
        </div>
        <div class="modal-body">
            loyce unedited backup here ${1}
        </div>
    </div>
    <div class="modal-backdrop show"></div>`);

    // Get the modal
    let modal = document.getElementsByClassName("modal")[0];

    // Get the <span> element that closes the modal
    let modalClose = document.getElementsByClassName("modal-close")[0];

    // Get the modal-backdrop
    let modalBackdrop = document.getElementsByClassName("modal-backdrop")[0];


    /** close the modal */
    // When the user clicks on <span> (x), close the modal
    modalClose.onclick = function() {
        modal.remove();
        modalBackdrop.remove();
    }

    // When the user clicks anywhere outside of the modal, close it
    modalBackdrop.onclick = function(event) {
        if (event.target == modalBackdrop) {
            modal.remove();
            modalBackdrop.remove();
        }
    }
}


    
})();
popup edited from: https://www.w3schools.com/howto/tryit.asp?filename=tryhow_css_modal
LoyceV
Legendary
*
Online Online

Activity: 3374
Merit: 17019


Thick-Skinned Gang Leader and Golden Feather 2021


View Profile WWW
August 22, 2020, 07:23:30 AM
 #20

I don't know how to get the loyce data
Aveatrex knows Smiley

Pages: [1] 2  All
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!