Join us in Outworldz at www.outworldz.com:9000 or follow us:

Search dozens of selected web sites for OpenSim and LSL script

New! Script Meta-Search will search thousands of scripts here and at other sites for LSL or Opensim scripts.
Loading

Want to add a script or a project? Upload it and a half million people will see it and your name here this year.

Home   Show All
Category: Contributor: Creator
HTML HTML_in_a_prim_with_no_server  

HTML_in_a_prim_with_no_server

I've written an LSL script which "serves...

Category: HTML
By : Jacek Antonelli
Created: 2010-01-10 Edited: 2010-01-10
Worlds: Second Life

the Zip file

Download all files for HTML_in_a_prim_with_no_server
Contents are in zip format, with .LSL (text) source code and LSLEdit (text + Solution) formats.
Get file # 1. HTML_in_a_prim_with_no_server_1.lsl
1
2 // VERY SIMPLE HTML SERVER
3 // by Jacek Antonelli, 2008-11-24.
4 //
5 // Description: When an avatar touches the object, it sets the
6 // avatar's media URL to a custom-generated HTML string,
7 // effectively serving HTML from an LSL script.
8 //
9 // However, this method is limited by the maximum allowed
10 // URL length of 254 characters. Thus it's only possible to
11 // serve very simple HTML with this method.
12 //
13 // This script has been released to the PUBLIC DOMAIN
14 // by its author.
15
16 default
17 {
19 {
20 string html = \
21 "<html><body>"+
22 "<p style=\"font-family:sans-serif;font-size:30px;\">"+
23 "Your name is "+ llDetectedName(0)+".<br/>"+
24 "Your position is "+ (string)llDetectedPos(0)+ ".<br/>"+
25 "This HTML is generated by the LSL script.<br/>"+
26 "Have a nice day. :)"+
27 "</p></body></html>";
28
31 "8b5fec65-8d8d-9dc5-cda8-8fdf2716e361",
33 "data:text/html,"+html,
35 "text/html",
37 600, 300,
38 PARCEL_MEDIA_COMMAND_AGENT,
41 ]);
42 }
43 }

Back to the Best Free Tools in Second Life and OpenSim.