Syphilis 0 Light Poster

Ahoy Sailors!

So to simplify this right from the start, When someone connects to my Host script, They first send a string with their PC name attached.

n:JoeyBlowHole-PC

We'll store this into a variable, Along with any others that are being sent. So it may look like this.

JoeyBlowHole-PC:JohnBinBag-PC

Now I'm needing to print to terminal a disconnection message.

<PcName> Has disconnected!

But there's the problem, When someone disconnects how do I know which PC name to print to console?

Thanks Bye!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.