SitePoint Sponsor

User Tag List

Results 1 to 7 of 7
  1. #1
    SitePoint Enthusiast
    Join Date
    Jun 2003
    Location
    Mermaid beach 4218
    Posts
    37
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    accessing windows login username w/JS

    Is it possible to access a users username in Windows with JS?

    Can JS access this sort of system INFO??

    If i can get the windows username, i can automatically validate users with active directory. I am using PHP server side, so using .net is not desiralble.

    Any links, intelligent suggestions appriciated

    Cheers

  2. #2
    SitePoint Guru Vincent Puglia's Avatar
    Join Date
    Feb 2000
    Location
    where the World once stood
    Posts
    700
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi,

    I say no. But, what the hay...run the following and see what you get:

    Code:
    var obj2test = window;  //also try document, etc.
    for ( property in obj2test)
    document.write( property + " = " + obj2test[property] + "<br>")
    Vinny
    Where the World Once Stood
    the blades of grass
    cut me still

  3. #3
    SitePoint Enthusiast
    Join Date
    Jun 2003
    Location
    Mermaid beach 4218
    Posts
    37
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Are there any VBScript experts around. i can see that JS would not be able to access this info, but surely VBScript would???

  4. #4
    Web-coding NINJA! silver trophy beetle's Avatar
    Join Date
    Jul 2002
    Location
    Dallas, TX
    Posts
    2,900
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Actually, neither can, but ActiveX might.

    Both JScript and VBScript can create ActiveX objects, so this could be possible.
    beetle a.k.a. Peter Bailey
    blogs: php | prophp | security | design | zen | software
    refs: dhtml | gecko | prototype | phpdocs | unicode | charsets
    tools: ide | ftp | regex | ffdev




  5. #5
    SitePoint Enthusiast
    Join Date
    Jun 2003
    Location
    Mermaid beach 4218
    Posts
    37
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    cheers and Good call. i could create an activeX object to retrieve the info i need and install that on the client machines , then get js or vbs to call it.

    hmm, don;t think i need it that much, but maybe if i get some spare time.

  6. #6
    SitePoint Guru Vincent Puglia's Avatar
    Join Date
    Feb 2000
    Location
    where the World once stood
    Posts
    700
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    mermaid beach?? as in coney?
    Where the World Once Stood
    the blades of grass
    cut me still

  7. #7
    SitePoint Enthusiast
    Join Date
    Jun 2003
    Location
    Mermaid beach 4218
    Posts
    37
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Nah, I come from a land Down Under.

    Gold Coast Australia, Mate.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •