rss

Running Dedicated XServer applications on your Windows

Today I came across the problem that I had to run a Linux X-Server application on a Server, which has no X-Server installed.

Since I didn't want to mess around with the installation (by installing a fullblown xserver and all it's friends), I thought using XForward configuration should do it.

As extra challenge, I ran the X-Server on a windows machine.

First of all, download + install cygwin. When installing, be sure to select xauth package (it's not enabled by default, but important for the XForward process).

You may have to do some changes to your server configuration like the Cygwin FAQ says, but on the remote ubuntu machine XForwardTrusted was already set to yes.

Now open your cygwin console and type:

1
startx

Now open yet another cygwin console and type:

1
ssh -Y name@example.org -p12345

where name is your username, example.org is your server name (or ip) and 12345 is the servers ssh port (default is 22, though).
The -Y (the capital Y is important) tries to connect with ForwardXTrusted, thats what we enabled some lines earlier.

You'll be right on the ssh server and can type xterm or whatever application you want to run. No extra configuration!

The best about all that, you don't have forward router ports or anything!

In Linux & Cygwin By DracoBlue @ 13:34 31.10.2009

Mootools Youtube Chromeless Player

de en

Today I finished the release for YtMooPlayer.js - the chromeless youtube player for mootools.

The plain youtube chromeless player does not run in an own namespace and makes using multiple players on the same site ugly. Since the chromeless player has a swf as "real" player, one needs to wait until its loaded.

That and some useful events are encapsulated in this class. So have fun using youtube with mootools on your site! I am currently using it successfully for 6 month at my koala search engine for youtube player and a custom javascript playlist.

Beside the YtMooPlayer.js-Download, there is also a Demo and Api-Docs (generated with the excellent jsdoc toolkit).

In open source, JavaScript & Mootools By DracoBlue @ 21:43 20.10.2009

Finished first version of Video Playlist for Koala

de en

Today I finished the first version of the video playlist for koala (a search engine interface for google, located at http://erstmal.com).

You have a small icon next to every youtube video, which enables you to add the video to the playlist. The playlist is capable of playing all videos in list order but also has a shuffle-button.

Since koala is "AJAX" driven, you are able to continue searching without any interruption in the video playback.

In Koala By DracoBlue @ 23:56 10.10.2009

Koala Search Engine updated with "Search more"

de en

Today I added some new features to the search engine interface at http://erstmal.com (the current home of the koala search engine).

  • "Search More"-button
  • Autofocus on search-input field
  • Info if no result was found
  • "Did you mean?"-Spellchecking feature

Bug-Reports and Comments appriciated as usual ;).

In Koala By DracoBlue @ 20:56 10.10.2009

Cache-Control revalidate

If you want to revalidate the contents of some kind of image, without delivering the entire image, on each call: no-cache-Header won't be the right choice.

You may workaround this issue, by setting:

1
Cache-Control: max-age=3600, must-revalidate
By DracoBlue @ 14:54 30.09.2009

Simple php task to run commandline in phing

In phing there is a task called exec. Even though it provides a "passthru"-property it's not really possible to directly get the response from the output.

Since I wanted to have direct output of all data, I created an adhock-task called "run". You can add it to your phing build file, by adding this tag right before the usage.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
<adhoc-task name="run"><![CDATA[
class RunTest extends Task {
private $dir;
private $command;

function setCommand($command) {
$this->command = $command;
}

function setDir($dir) {
$this->dir = $dir;
}

function main() {
$this->log("Changing to: " . $this->dir);
chdir($this->dir);
$this->log("Executing: " . $this->command);
system($this->command);
}
}
]]></adhoc-task>

Remember, that this task does not check wether the directory exists and always requires it to be set. If you want to extend the task for your needs and mind to share it, feel free to post a reply!

In php & Phing By DracoBlue @ 22:47 22.09.2009