Hello I need to convert this VB6 function into a php function. When I input "loffkkcgjnaeokqdqgmj" into the function it should output "[url removed, login to view]:17478". Thanks
Public Function LW2IP(sLWKey As String) As String
On Error GoTo err
Dim key As String
Dim Ip As String
Dim ippointer As Long
Dim keypointer As Long
Dim LWKey As String
LWKey = sLWKey
key = "TYXUYZUVXWSTZSWSZSVRT"
ippointer = 12
keypointer = 1
Ip = ""
Do Until ippointer = Len(LWKey) - 13
Ip = Ip & Chr$(Asc(Mid$(LWKey, ippointer, 1)) - Asc(Mid$(key, keypointer, 1)) + 32)
ippointer = ippointer + 1
keypointer = keypointer + 1
LW2IP = Replace(Ip, " ", vbNullString)
LW2IP = "invalid ip"
dont include the " while you input into function
oops ignore the last additional information submitted, this site shows & quot; insted of "