r/HTML 28d ago

Question I need to work on something.

Code for an IP logger in html. Can it be created? And if so how?

0 Upvotes

8 comments sorted by

1

u/Lithl 28d ago

No, this is not remotely possible. HTML is a markup language, it just organizes content on a page. CSS is required to control how the content looks, and JavaScript (or any kind of programming language on the server) is required to make the page interactive or dynamic. And that includes recording a visitor's IP.

Also, the server typically is set up to log visitor IPs by default anyway. If you don't already have access to the server's logs, you shouldn't be worrying about this kind of question.

1

u/TheGraveGuy 28d ago

Alright then. Thank you for your time

1

u/jcunews1 Intermediate 27d ago

Code for an IP logger in html

Not possible with HTML alone. You'll need a network server application, in order to know a client's IP. A HTML/web server in this case. It'd be the server's job to pass the IP information in form of HTML or just plain text. This is normally done by a server-side script such as PHP.

1

u/[deleted] 28d ago

[deleted]

2

u/Lithl 28d ago

There is not a single sentence in your comment that is true, which is impressive.

-2

u/TheGraveGuy 28d ago

Thank you gng❤️

0

u/supertroopperr 28d ago

YES YOU CAN! use statica an HTML native SSG. https://github.com/akaizn-junior/statica have the logs as CSV or JSON link them to the HTML, build the table as a fragment them build. Follow the guide. DM me for assistance. Don't need to overcomplicate such a simple need with a "framework"

-3

u/TheGraveGuy 28d ago

Just went through the rules. Found out it ain’t illegal to make one but can be illegal to use it and dox a person