Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. getting apache username with php/python

getting apache username with php/python

Scheduled Pinned Locked Moved Web Development
pythonphpapachequestion
3 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • K Offline
    K Offline
    keegan
    wrote on last edited by
    #1

    Hi. I need to get the username of people when they log into a secure area of my website. (I want to do it in php, so i can output each login with an IP, people keep passing out the password, i want to see what logins have multiple IPs). Is there a way to do this in PHP or python? Im using apache with cPanel. Thanks. *.* cin >> knowledge;

    M U 2 Replies Last reply
    0
    • K keegan

      Hi. I need to get the username of people when they log into a secure area of my website. (I want to do it in php, so i can output each login with an IP, people keep passing out the password, i want to see what logins have multiple IPs). Is there a way to do this in PHP or python? Im using apache with cPanel. Thanks. *.* cin >> knowledge;

      M Offline
      M Offline
      markkuk
      wrote on last edited by
      #2

      Yes, you can authenticate users with PHP.

      1 Reply Last reply
      0
      • K keegan

        Hi. I need to get the username of people when they log into a secure area of my website. (I want to do it in php, so i can output each login with an IP, people keep passing out the password, i want to see what logins have multiple IPs). Is there a way to do this in PHP or python? Im using apache with cPanel. Thanks. *.* cin >> knowledge;

        U Offline
        U Offline
        User 1200622
        wrote on last edited by
        #3

        This is pretty simple. once you have verified that your user is logged in, you can find his ip from the $ip=$_SERVER['REMOTE_ADDR']; Now you can store this $ip in a database to keep track of your users. One glitch though, your users may want to access your site contents from different pcs the ip would change in this case. Also modem users get a new ip every time they log in. So dont just ban users who have multiple IPs Any tool is only as good as you can use it!! (http://www.pascalnet.tk)

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups