User Tools

Site Tools


wiki:components:x2goplugin

This is an old revision of the document!


x2goplugin

x2goplugin is a Firefox plugin. It can be used to access a x2go session via a Webbrowser instead of using x2goclient.

Installation of x2goplugin

Inserting x2goplugin into a webpage

This is a short tutorial how to integrate the x2go plugin into a website.

create a properties file

First of all you'll need a porperties file. This file should be stored accessible by the website, for example inside the same directory. You can choose a name by yourself, but in this tutorial the file will be called x2go.server. Please us a suitable file editor like vi for editing:

session=phoca
server=localhost
user=verstandk
sshport=22
command=KDE
rootless=false

You can choose the value “session” to whatever you like - it is just the name of the session. The value “server” should be the hostname or the IP-address of the x2goserver which should be contacted by the plugin. The value “user” can be left blank, otherwise this username will be used as login for the x2go session. The value “sshport” should be set to 22 - you should only change this if you've previously changed the sshd config of the x2goserver. You can choose the used Desktop Environment or application by changing the value “command”. You can use KDE, Gnome or any application which can be excecuted by the previosly entered user. The value “rootless” should be false for the use with whole Desktop Environments and Window Manager. If you plan to use single applications you can use this feature to use the local running window manager.

building a minimal website

You'll need a Website to carry the plugin. Please feel free to use your own Website code. This is just a example which should be used to get started:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <title>x2go Plugin</title>
  </head>
  <body>
    <div id="x2goplugin">
        <--x2goplugin //--> 
    </div>
  </body>
</html>

Inserting the <object> code

    <object src="location" 
	type="application/x2go" 
	pluginspage="http://plugin.x2go.org/index.html" 
	pluginurl="http://plugin.x2go.org/download/x2goplugin_linux32.xpi" 
	data="server.x2go" 
	hidden="false" 
	name="x2goplugin" 
	palette="background" 
	height="100%" 
	hspace="0" 
	vspace="0" 
	width="100%">
        <--x2goplugin //-->
    </object>    

As long as you wan't to use the automatical update service (recommended), please don't change the urls used in the options “pluginspage” and “pluginurl”. The option “data” is the name of a properties file.

wiki/components/x2goplugin.1266529809.txt.gz · Last modified: 2013/03/08 13:31 (external edit)