1
Will_H
Heres an interesting query....
  • 2005/6/21 21:50

  • Will_H

  • Friend of XOOPS

  • Posts: 1786

  • Since: 2004/10/10


Ok so i am building a clan site and I stumbled upon this snippet of code that allowed a user to simply enter a username into a field and login to our TeamSpeak channel. here's that code.








To use this simply place your TS ip into the area where the x's have replaced my own. Then copy the entire code into a custom block... Voila! alot easier than the TS module for xoops.


This works great... It opens up the TeamSpeak(if available) on the users machine. and automatically logs them in with the guest name they entered.

Heres my question:

So after using this and loving it, I would like to port this concept into launching different applications... for example... the clan is an Enemy Territory clan, and I would love for users on the site to be able to launch enemy territory and log into our server from the site. Obviously an added bonus would be to automatically have the user cookie input their callsign into these fields... because having to repeat this process would certainly be very annoying. I would really appreciatte any input on this topic, and please feel free to use this code on your own sites.

2
Will_H
Re: Heres an interesting query....
  • 2005/6/21 21:59

  • Will_H

  • Friend of XOOPS

  • Posts: 1786

  • Since: 2004/10/10


Sorry for the double post....

Essentially I am looking to direct the user to their local machine... the default directory for the exec file is ""C:\Program Files\Wolfenstein - Enemy Territory\ET.exe""

3
script_fu
Re: Heres an interesting query....

Bump

What you want to do is start the game on your computer from your website. Not sure if this can be done maybe someone else would know.

4
McNaz
Re: Heres an interesting query....
  • 2005/6/22 13:53

  • McNaz

  • Just can't stay away

  • Posts: 574

  • Since: 2003/4/21


It can be done via javascript but with lots of limitations:

1. It only works on IE on Window$ machines
2. IE must be configured to include the site that has the script to be in the trusted area under IR security.

Here is a javascript sample.

<script type="text/javascript">
  function 
LaunchApp()
   {if (!
document.all)
     {
alert ('Available only with Internet Explorer.');return;}
    var 
ws = new  ActiveXObject("WScript.Shell");
    
ws.Run('c:winntsystem32calc.exe');}
script>

<
a href="#" onclick="LaunchApp()">Click herea>(Internet Explorer Only)

5
Will_H
Re: Heres an interesting query....
  • 2005/6/23 4:53

  • Will_H

  • Friend of XOOPS

  • Posts: 1786

  • Since: 2004/10/10


lol wow, so what you are saying is that I must create a secure page (https://)and post the script in a custom block on it, and launch it from there? Yet even then it will only work if each individual user adds the site to their trusted zone? Also, by default this java will work in a custom block, correct? Will i need to install any run-time enviroment or any special features of that nature into my XOOPS core? Forgive me for the latter, but I am clueless when it comes to java.


Also, is that definitely the only possibility... What is the difference between launching the teamspeak application with the snippet of code I provided, and trying to launch a different app with it?

6
Will_H
Re: Heres an interesting query....
  • 2005/6/24 19:32

  • Will_H

  • Friend of XOOPS

  • Posts: 1786

  • Since: 2004/10/10


bump

7
Herko
Re: Heres an interesting query....
  • 2005/6/24 21:39

  • Herko

  • XOOPS is my life!

  • Posts: 4238

  • Since: 2002/2/4 1


teamspeak (and SKype as well, for instance) register a 'protocol' on install, where you can start the app by calling on that protocol. eDonkey links work the same way. So it heavily depends on the apps you want to start, if they support this feature. Not many do, unless they're intended to be started from a webbrowser.

The other snippet is the closest you can get, but due to security measures that are now quite common (I hope), they're more likely to be blocked then not.

Herko

8
Will_H
Re: Heres an interesting query....
  • 2005/6/29 20:27

  • Will_H

  • Friend of XOOPS

  • Posts: 1786

  • Since: 2004/10/10


lol, nothing like a dead end... thanks for all the help.

Login

Who's Online

458 user(s) are online (377 user(s) are browsing Support Forums)


Members: 0


Guests: 458


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits