473,569 Members | 2,701 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

UserId - how to find out

Sorry, but I'm a complete newbee!

I need find out under which userid the browser is running.
Is this possible with JavaScript?

Many thanks for a hint,

Helmut Jarausch

Lehrstuhl fuer Numerische Mathematik
RWTH - Aachen University
D 52056 Aachen, Germany
Dec 27 '07 #1
11 2066
Helmut Jarausch said:
Sorry, but I'm a complete newbee!

I need find out under which userid the browser is running.
Is this possible with JavaScript?

Many thanks for a hint,

Helmut Jarausch

Lehrstuhl fuer Numerische Mathematik
RWTH - Aachen University
D 52056 Aachen, Germany
If you mean the system user id, as in their Windows logon, can't be done
with JavaScript.

--
Anthony Levensalor
an*****@mypetpr ogrammer.com
Dec 27 '07 #2
My Pet Programmer said the following on 12/27/2007 7:27 AM:
Helmut Jarausch said:
>Sorry, but I'm a complete newbee!

I need find out under which userid the browser is running.
Is this possible with JavaScript?

Many thanks for a hint,

Helmut Jarausch

Lehrstuhl fuer Numerische Mathematik
RWTH - Aachen University
D 52056 Aachen, Germany
If you mean the system user id, as in their Windows logon, can't be done
with JavaScript.
var userID = prompt('What is your user ID?');

<g>

--
Randy
Chance Favors The Prepared Mind
comp.lang.javas cript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Dec 27 '07 #3
Randy Webb said:
>
var userID = prompt('What is your user ID?');
Ooh, you got me again. I hate it when that happens. :)

~A!

--
Anthony Levensalor
an*****@mypetpr ogrammer.com
Dec 27 '07 #4
Randy Webb wrote:
My Pet Programmer said the following on 12/27/2007 7:27 AM:
>Helmut Jarausch said:
>>Sorry, but I'm a complete newbee!

I need find out under which userid the browser is running.
Is this possible with JavaScript?

Many thanks for a hint,

Helmut Jarausch

Lehrstuhl fuer Numerische Mathematik
RWTH - Aachen University
D 52056 Aachen, Germany
If you mean the system user id, as in their Windows logon, can't be
done with JavaScript.

var userID = prompt('What is your user ID?');
You're joking, aren't you?

Then I need to ask for a password, as well. And for that
I need an ssl connection and I have to keep track of user/password
combinations. Not the solution I was after.

Helmut.


--
Helmut Jarausch

Lehrstuhl fuer Numerische Mathematik
RWTH - Aachen University
D 52056 Aachen, Germany
Dec 27 '07 #5
Helmut Jarausch said the following on 12/27/2007 9:56 AM:
Randy Webb wrote:
>My Pet Programmer said the following on 12/27/2007 7:27 AM:
>>Helmut Jarausch said:
Sorry, but I'm a complete newbee!

I need find out under which userid the browser is running.
Is this possible with JavaScript?

Many thanks for a hint,

Helmut Jarausch

Lehrstuhl fuer Numerische Mathematik
RWTH - Aachen University
D 52056 Aachen, Germany
If you mean the system user id, as in their Windows logon, can't be
done with JavaScript.

var userID = prompt('What is your user ID?');
You're joking, aren't you?
Not near as much as you want me to be.
Then I need to ask for a password, as well.
Why? You didn't want a password, you wanted the user ID.
And for that I need an ssl connection and I have to keep track of
user/password combinations. Not the solution I was after.
What is the user ID going to do for you? And, the username and password
to my desktop won't do anybody any good unless you have access to my
computer. And, that is provided that I even have a username and/or password.

--
Randy
Chance Favors The Prepared Mind
comp.lang.javas cript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Dec 27 '07 #6
Helmut Jarausch said:
Randy Webb wrote:
>My Pet Programmer said the following on 12/27/2007 7:27 AM:
>>Helmut Jarausch said:
Sorry, but I'm a complete newbee!

I need find out under which userid the browser is running.
Is this possible with JavaScript?

Many thanks for a hint,

Helmut Jarausch

Lehrstuhl fuer Numerische Mathematik
RWTH - Aachen University
D 52056 Aachen, Germany
If you mean the system user id, as in their Windows logon, can't be
done with JavaScript.

var userID = prompt('What is your user ID?');
You're joking, aren't you?

Then I need to ask for a password, as well. And for that
I need an ssl connection and I have to keep track of user/password
combinations. Not the solution I was after.

Helmut.

You could help us help you by extrapolating on your need a bit.
Precisely what username and password are you looking for? Is it system
level, on your site, or something I haven't listed?

~A!

--
Anthony Levensalor
an*****@mypetpr ogrammer.com
Dec 27 '07 #7
if you mean the ID of the profile in some dynamic webApplication
(login or nickname) that customizes the output html for each users
(like "Hello Tom, click here to check your account") then there are
basically 2 ways to do it:

1) you can assign the value representing the user while generating the
server response the server-side. Like:

var userId=<%=user. getId() %>;

(that's java jsp the ugly way).
This way, the user's browser will get the code with, say:
var userId=124;

and later on you can use that variable for whatever you please.

2) the never-used-but-theoretically-possible-solution: you can by some
weird way get the user's IP or session ID using javaScript, and query
the server (over ajax, HttpRequest object or something like that) for
the profile corresponding to that data. But no one does it this way,
so I'd suggest (1).

...provided you *do* need some server-side appliaction profile and not
something entirely different
Dec 27 '07 #8
Randy Webb wrote:
Helmut Jarausch said the following on 12/27/2007 9:56 AM:
>Randy Webb wrote:
>>My Pet Programmer said the following on 12/27/2007 7:27 AM:
Helmut Jarausch said:
Sorry, but I'm a complete newbee!
>
I need find out under which userid the browser is running.
Is this possible with JavaScript?
>
Many thanks for a hint,
>
Helmut Jarausch
>
Lehrstuhl fuer Numerische Mathematik
RWTH - Aachen University
D 52056 Aachen, Germany
If you mean the system user id, as in their Windows logon, can't be
done with JavaScript.
var userID = prompt('What is your user ID?');
You're joking, aren't you?

Not near as much as you want me to be.
>Then I need to ask for a password, as well.

Why? You didn't want a password, you wanted the user ID.
>And for that I need an ssl connection and I have to keep track of
user/password combinations. Not the solution I was after.

What is the user ID going to do for you? And, the username and password
to my desktop won't do anybody any good unless you have access to my
computer. And, that is provided that I even have a username and/or
password.
I need authorization for access to something like a database in a strictly
local network. If I could get access to the user's login password (we are
using Linux exclusively), I can be sure that the user's id has been checked
by the system when that user has logged into the system. So, I don't need
to keep track of an additional (user,password) file, secure connection,
means to change a password, initial passwords, lost passwords and so on.

Many thanks for your help,
Helmut.

--
Helmut Jarausch

Lehrstuhl fuer Numerische Mathematik
RWTH - Aachen University
D 52056 Aachen, Germany
Dec 27 '07 #9
Helmut Jarausch wrote:
Randy Webb wrote:
>Helmut Jarausch said the following on 12/27/2007 9:56 AM:
>>Randy Webb wrote:
My Pet Programmer said the following on 12/27/2007 7:27 AM:
Helmut Jarausch said:
>Sorry, but I'm a complete newbee!
>>
>I need find out under which userid the browser is running.
>Is this possible with JavaScript?
>>
>Many thanks for a hint,
>>
>Helmut Jarausch
>>
>Lehrstuh l fuer Numerische Mathematik
>RWTH - Aachen University
>D 52056 Aachen, Germany
If you mean the system user id, as in their Windows logon, can't be
done with JavaScript.
>

var userID = prompt('What is your user ID?');

You're joking, aren't you?

Not near as much as you want me to be.
>>Then I need to ask for a password, as well.

Why? You didn't want a password, you wanted the user ID.
>>And for that I need an ssl connection and I have to keep track of
user/password combinations. Not the solution I was after.

What is the user ID going to do for you? And, the username and
password to my desktop won't do anybody any good unless you have
access to my computer. And, that is provided that I even have a
username and/or password.

I need authorization for access to something like a database in a strictly
local network. If I could get access to the user's login password (we are
using Linux exclusively), I can be sure that the user's id has been checked
by the system when that user has logged into the system. So, I don't need
to keep track of an additional (user,password) file, secure connection,
means to change a password, initial passwords, lost passwords and so on.
Well if they have logged in via samba, you should be able to pick up
their local IP/userid match from samba log files..assuming a Linux
server. But you need server side scripting for that, assuming the
browser is connecting to the same server for webbery as for file sharing.

I simply set up a server side script that make them login again using
the same Id/password.


Many thanks for your help,
Helmut.
Dec 27 '07 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
5835
by: Phillip Wu | last post by:
I have a javascript program that lives in the secure part of a web site. In order to get access to this java program the user needs to log in providing a userid and password. I understand that the userid/password is verified by the web server (Apache in my case). I also understand that any server side program written in php can get the...
0
1470
by: Earl Teigrob | last post by:
I have PW/UserID info as follows and would like to use xpath to find if a userid and pw exists within the xml file. What Xpath query statement do I need and what query command do I need? <users> <user> <userid>joe</userid> <pw>secret</pw> </user> <user>
2
4942
by: Luke Dalessandro | last post by:
I am trying to develop a quick Shopping cart for ASP.NET 2.0. I have added a CartItems table to the AspNetDB access database, that contaings CartItems keyed off of the aspney_Users.UserId key (the automatically generated primary key for the table). I want to bind the current user's CartItems to a GridView, which should be really easy. The...
4
1229
by: Trint Smith | last post by:
I did have UserID as 'Dim UserID As String'. Ok, when I made it 'Public UserID As String', in the Public Area of one program and took out all the 'local' declairations of it, even in the other programs that need to see the same value of UserID, UserID was getting the 'UserID is not declaired' message in the other programs. Do I have to put...
4
7963
by: david.kuczek | last post by:
I got the following error in a javascript I wrote. The script works fine, but why is the error being displayed??? ##### Here comes the little script: function chgMusicLink(userid,userlink,usertype) { var card_music_id = document.getElementsByName(userid).value; ...
0
855
by: marcwentink | last post by:
Somewhere in the code Authorization is set like: ' user id from a login form ...... ...... FormsAuthentication.SetAuthCookie(userid, False) Is there a way to get this information, the userid string back? I have tried myself and looked in google but I just cannot find it. I am trying this NOT WORKING code, that gives me .... Nothing as...
1
6767
by: chaitu | last post by:
Hi, I have an issue. When a developer tries to connect using an USERID and a ped it gives SQL30082N Attempt to establish connection failed with security reason "19" ("USERID DISABLED or RESTRICTED"). SQLSTATE=08001. He is getting this when he tries to connect through QUEST CENTRAL. This is not a DBA userid and pwd. I have tried...
3
2128
by: Jim | last post by:
Using either EW or VSE2008, I want to have a GridView that will: - Insert the logged in user's UserId from either the User table or the membership table when the user inserts a record. - When the user views the GridView, only their records are shown. I don't want to use a query string that uses the UserID for securtiy resons, so I'm thinking...
4
1644
by: sjohnson1984 | last post by:
Hello all, I have a form which is generated using a database query - the recordset is filled with agent details, login time and the like, and there are as many rows in the table as records in the set (plus table header). My problem is that I do not know how to pass the details of each record to an array session variable, once the form is...
0
7924
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
8120
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7672
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
1
5512
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
5219
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3640
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2113
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1212
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
937
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.