<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.secondlife.com/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Techplex+Engineer</id>
	<title>Second Life Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.secondlife.com/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Techplex+Engineer"/>
	<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/wiki/Special:Contributions/Techplex_Engineer"/>
	<updated>2026-07-27T03:19:13Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.42.1</generator>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=Importprimscript&amp;diff=1196781</id>
		<title>Importprimscript</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=Importprimscript&amp;diff=1196781"/>
		<updated>2015-06-19T01:36:41Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: /* Source */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Introduction==&lt;br /&gt;
&lt;br /&gt;
importprimscript is a complement to Qarl Linden&#039;s [[Advanced_Sculptie_Exporter_From_Maya]]. Once you&#039;ve exported a folder of files using his script, this program will log in to Second Life using an account of your choice, upload all of the textures, and rez the entire sculptie structure. Sculpt maps are compressed with a single layer lossless JPEG2000 encoding while textures use the traditional five layer lossy JPEG2000 encoding.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&lt;br /&gt;
* [http://abbloch.com/importprimscript/importprimscript-1.4.2-libomv-0.6r2334-x64.zip 1.4.2(x64)] (Works with 64-bit Windows Vista; More secure than previous versions (objects now rez with Allow Anyone To Copy/Move turned off by default instead of on); Functionality that had been broken by SL server 1.20 is restored)&lt;br /&gt;
* [http://abbloch.com/importprimscript/importprimscript-1.4.2-libomv-0.6r2334.zip 1.4.2(x86)] (Works with 32-bit Windows Vista and XP; More secure than previous versions (objects now rez with Allow Anyone To Copy/Move turned off by default instead of on); Functionality that had been broken by SL server 1.20 is restored)&lt;br /&gt;
* [http://abbloch.com/importprimscript/importprimscript-1.4.0-libsl-0.3.2.3-x64.zip 1.4.0(x64)]  (Compatibility added for 64-bit Vista; Functionality that had been broken by SL server 1.20 is restored)&lt;br /&gt;
* [http://www.jhurliman.org/download/importprimscript-1.3.0.zip 1.3.0] (Uploads go in to an inventory folder, more reliable file uploads)&lt;br /&gt;
* [http://www.jhurliman.org/download/importprimscript-1.0.2.zip 1.0.2]&lt;br /&gt;
&lt;br /&gt;
== Source ==&lt;br /&gt;
&lt;br /&gt;
* https://github.com/openmetaversefoundation/libopenmetaverse/tree/master/Programs/importprimscript&lt;br /&gt;
* http://openmv.org/svn/libsl/libopenmetaverse/branches/modularized/Programs/importprimscript/&lt;br /&gt;
* http://openmv.org/svn/libsl/libopenmetaverse/branches/simd/Programs/importprimscript/&lt;br /&gt;
&lt;br /&gt;
==Requirements==&lt;br /&gt;
&lt;br /&gt;
If you are on Windows you will need the [http://www.microsoft.com/downloads/details.aspx?FamilyID=0856EACB-4362-4B0D-8EDD-AAB15C5E04F5&amp;amp;displaylang=en .NET 2.0 framework]. On other platforms, a current version of [http://www.monoproject.org/ Mono] is required.&lt;br /&gt;
&lt;br /&gt;
===Linux/OSX Users===&lt;br /&gt;
&lt;br /&gt;
The current version does not ship with a binary of the openjpeg-libsl library. You will need a current copy of [http://www.libsecondlife.org/ libsecondlife], and to run &amp;quot;make&amp;quot; (or &amp;quot;make osx&amp;quot; on OSX) in the openjpeg-libsl directory and copy the resulting .so or .dylib file to the importprimscript directory. A future release will contain openjpeg-libsl binaries for 32/64-bit Linux and Intel OSX.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Usage==&lt;br /&gt;
&lt;br /&gt;
This program is meant to be run from the command line. All input is fed through command line parameters and the program runs and periodically outputs status information to the console. Eight parameters must be passed in (multiple word parameters must be enclosed in quotes), using this order: FirstName LastName Password Simulator X Y Z Primscript.&lt;br /&gt;
&lt;br /&gt;
* FirstName: The first name of the avatar you are going to use to import the structure. This avatar will be listed as the creator, although the object will have full permissions so you can copy it with another avatar. This avatar cannot be logged in before you run the program, so if you are already logged in to Second Life this must be an alt account.&lt;br /&gt;
&lt;br /&gt;
* LastName: The last name of the avatar that is going to import the structure.&lt;br /&gt;
&lt;br /&gt;
* Password: The account password. This password is hashed before being sent to the login server and is never sent to any other sources, running this program is as safe as running the official Second Life client.&lt;br /&gt;
&lt;br /&gt;
* Simulator: The name of the simulator you want the bot to log in to and create the import in. Examples are Hooper or &amp;quot;My Region&amp;quot; (notice the quotes).&lt;br /&gt;
&lt;br /&gt;
* X, Y, Z: Coordinates to log the bot in to the simulator and rez the structure at. These are whole numbers between 0 and 255.&lt;br /&gt;
&lt;br /&gt;
* Primscript: The path to the primscript file to import. Lets say you installed this program to c:\importprimscript\ and exported a folder of textures and the primscript file from Maya in to c:\importprimscript\myexport, and the primscript file is named myexport1.primscript. The command line argument could be either the relative path myexport/myexport1.primscript or the absolute c:\importprimscript\myexport\myexport1.primscript.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Optional GUI==&lt;br /&gt;
&lt;br /&gt;
To make things a little more user friendly, there is an [http://www.fileden.com/files/2006/10/8/271989/sculptgui.zip optional GUI] for controlling the upload utility.  Basically, just move sculptgui.exe to the folder with importprimscript.exe in it, and then double click the GUI to use it.&lt;br /&gt;
&lt;br /&gt;
The GUI is Windows only.  It could be compiled for Mac with little trouble, only the developer&#039;s Mac is broken.&lt;br /&gt;
[[Category:Sculpted_Prims]]&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=Talk:LlSetContentType&amp;diff=1179952</id>
		<title>Talk:LlSetContentType</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=Talk:LlSetContentType&amp;diff=1179952"/>
		<updated>2013-07-12T17:20:53Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: /* Too many Questions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Too many Questions ==&lt;br /&gt;
we (will) have a pretty new function, but zero information about it...&lt;br /&gt;
only works for LL&#039;s browser / MOAP? (seems like a strange limitation.)&lt;br /&gt;
only works for the prim owner? (hows that going to work with the internal browser / MOAP, user key/name isn&#039;t sent except from llHTTPRequest)&lt;br /&gt;
I can assume it only works for the script that received the request (since normally other scripts can&#039;t respond)&lt;br /&gt;
&lt;br /&gt;
if someone has some better info, it&#039;d be really helpful... if all the above are true, it has zero value, since html from llHTTPRequest can&#039;t be displayed as such. if it&#039;s just limited to html within SL, it has no use for exporting interface of inworld to the web, but more use for things like huds and distrubuted inworld networks.&amp;lt;br/&amp;gt;-- &#039;&#039;&#039;[[User:Void_Singer|Void]]&#039;&#039;&#039; &amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;([[User_talk:Void_Singer|talk]]|[[Special:Contributions/Void_Singer|contribs]])&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; 15:29, 5 August 2011 (PDT)&lt;br /&gt;
&lt;br /&gt;
:&amp;quot;for things like huds and distrubuted inworld networks&amp;quot; I think this is exactly the intended use. The exact wording in the release notes was &amp;lt;code&amp;gt;CONTENT_TYPE_HTML &amp;quot;text/html&amp;quot;, only valid for embedded browsers on content owned by the person viewing. Falls back to &amp;quot;text/plain&amp;quot; otherwise.&amp;lt;/code&amp;gt; The implication is that this is to be used with {{LSLGC|Prim Media}}; which should be made clear (and isn&#039;t) in the caveat or description. -- &#039;&#039;&#039;[[User:Strife_Onizuka|Strife]]&#039;&#039;&#039; &amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;([[User talk:Strife_Onizuka|talk]]|[[Special:Contributions/Strife_Onizuka|contribs]])&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; 10:20, 6 August 2011 (PDT)&lt;br /&gt;
&lt;br /&gt;
The intended use is to enable HTML based HUDs. I have created an [[HTML_HUD_Demo]].&lt;br /&gt;
&amp;lt;br&amp;gt;For the technical nitty gritty:&lt;br /&gt;
* The server will check if the user-agent string contains Second Life and revert to text/plain if it doesn&#039;t.&lt;br /&gt;
* The server will check the incoming IP of the request against the IP of the object owner and revert to text/plain if they don&#039;t match.&lt;br /&gt;
&lt;br /&gt;
For HUDs this will work as expected. Non-HUD content may have weird behavior:&lt;br /&gt;
* You may set a custom user-agent string to include Second Life in a non-SL browser to view these urls while logged into the region with the content.&lt;br /&gt;
* If you run multiple clients from the same IP and logged into the same region you may be able to see HTML rendered content cross-account.&lt;br /&gt;
* Poxy and IP anonymizing services are unlikely to work well with this.&lt;br /&gt;
&lt;br /&gt;
In general these are rare and unreliable enough to sufficiently reduce the concern for hosting webpages under the Linden Lab domain name. This feature is *not* meant to enable serving general purpose web pages from LSL scripts.&lt;br /&gt;
&lt;br /&gt;
: [[User:Kelly Linden|Kelly Linden]] 14:25, 26 August 2011 (PDT)&lt;br /&gt;
&lt;br /&gt;
:: any hope of opening this up to any browser with the secondlife user-agent string? that&#039;d still keep it out of the wider internet and the association clean, while enabling wider use cases within SL. &amp;lt;br/&amp;gt;-- &#039;&#039;&#039;[[User:Void_Singer|Void]]&#039;&#039;&#039; &amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;([[User_talk:Void_Singer|talk]]|[[Special:Contributions/Void_Singer|contribs]])&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; 12:46, 30 August 2011 (PDT)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
I wonder if the Caveats is applicable to the new content types: &lt;br /&gt;
* CONTENT_TYPE_XML application/xml&lt;br /&gt;
* CONTENT_TYPE_XHTML application/xhtml+xml&lt;br /&gt;
* CONTENT_TYPE_ATOM application/atom+xml&lt;br /&gt;
* CONTENT_TYPE_JSON application/json&lt;br /&gt;
* CONTENT_TYPE_LLSD application/llsd+xml&lt;br /&gt;
* CONTENT_TYPE_FORM application/x-www-form-urlencoded&lt;br /&gt;
* CONTENT_TYPE_RSS application/rss+xml&lt;br /&gt;
[[User:Techplex Engineer|Techplex Engineer]] 10:20, 12 July 2013 (PDT)&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests.svg&amp;diff=1175597</id>
		<title>File:VW HTTP requests.svg</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests.svg&amp;diff=1175597"/>
		<updated>2012-12-26T04:32:15Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: uploaded a new version of &amp;quot;File:VW HTTP requests.svg&amp;quot;:&amp;amp;#32;Trying to fix svg render problem&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Simple diagram that illustrates the difference between http_response and http_request.&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests.svg&amp;diff=1175596</id>
		<title>File:VW HTTP requests.svg</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests.svg&amp;diff=1175596"/>
		<updated>2012-12-26T04:29:51Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: Simple diagram that illustrates the difference between http_response and http_request.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Simple diagram that illustrates the difference between http_response and http_request.&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=Category:LSL_HTTP&amp;diff=1175595</id>
		<title>Category:LSL HTTP</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=Category:LSL_HTTP&amp;diff=1175595"/>
		<updated>2012-12-26T04:19:13Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: /* Understanding LSL HTTP Communications */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{LSL Header|ml=*}}&lt;br /&gt;
&lt;br /&gt;
== HTTP ==&lt;br /&gt;
&lt;br /&gt;
[[LSL]] includes functions that utilize HTTP, the HyperText Transfer Protocol, for communicating with other scripts in-world or web servers on the outside internet. HTTP requests incur no speed penalty, but there is a limit on how many requests per [[object]] can be made.&lt;br /&gt;
&lt;br /&gt;
=== Functions ===&lt;br /&gt;
;[[llEscapeURL]]: 	Returns the UTF-8 encoded escape codes for selected characters.&lt;br /&gt;
;[[llHTTPRequest]]: 	Requests information from an HTTP server.&lt;br /&gt;
;[[llLoadURL]]:		Loads a web page in an external browser.&lt;br /&gt;
;[[llUnescapeURL]]: 	Returns the UTF-8 characters without escape codes.&lt;br /&gt;
;[[llHTTPResponse]]: 	Responds to an HTTP request made to the script.&lt;br /&gt;
;[[llGetFreeURLs]]: 	Returns the number of URLs that the script can request for HTTP-In.&lt;br /&gt;
;[[llGetHTTPHeader]]: 	Returns the value of the requested header for a given HTTP request made to the script.&lt;br /&gt;
;[[llReleaseURL]]: 	Releases a given URL so it may not be used further.&lt;br /&gt;
;[[llRequestURL]]: 	Requests a non-secure URL to be used with HTTP-In.&lt;br /&gt;
;[[llRequestSecureURL]]: 	Same as [[llRequestURL]] but requests a secure url &amp;lt;nowiki&amp;gt;(https://)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Events ===&lt;br /&gt;
;[[http_request]]: 	Called when the script receives an HTTP request.&lt;br /&gt;
;[[http_response]]: 	Called when an HTTP request is complete.&lt;br /&gt;
&lt;br /&gt;
{{LSLC|}}{{LSLC|Communications}}&lt;br /&gt;
&lt;br /&gt;
=== Understanding LSL HTTP Communications ===&lt;br /&gt;
&lt;br /&gt;
[[File:VW_http.png|500px]]&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=File:VW_http.png&amp;diff=1175594</id>
		<title>File:VW http.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=File:VW_http.png&amp;diff=1175594"/>
		<updated>2012-12-26T04:18:35Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: Simple diagram that illustrates the difference between http_response and http_request.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Simple diagram that illustrates the difference between http_response and http_request.&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=Category:LSL_HTTP&amp;diff=1175593</id>
		<title>Category:LSL HTTP</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=Category:LSL_HTTP&amp;diff=1175593"/>
		<updated>2012-12-26T04:18:05Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: /* Understanding LSL HTTP Communications */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{LSL Header|ml=*}}&lt;br /&gt;
&lt;br /&gt;
== HTTP ==&lt;br /&gt;
&lt;br /&gt;
[[LSL]] includes functions that utilize HTTP, the HyperText Transfer Protocol, for communicating with other scripts in-world or web servers on the outside internet. HTTP requests incur no speed penalty, but there is a limit on how many requests per [[object]] can be made.&lt;br /&gt;
&lt;br /&gt;
=== Functions ===&lt;br /&gt;
;[[llEscapeURL]]: 	Returns the UTF-8 encoded escape codes for selected characters.&lt;br /&gt;
;[[llHTTPRequest]]: 	Requests information from an HTTP server.&lt;br /&gt;
;[[llLoadURL]]:		Loads a web page in an external browser.&lt;br /&gt;
;[[llUnescapeURL]]: 	Returns the UTF-8 characters without escape codes.&lt;br /&gt;
;[[llHTTPResponse]]: 	Responds to an HTTP request made to the script.&lt;br /&gt;
;[[llGetFreeURLs]]: 	Returns the number of URLs that the script can request for HTTP-In.&lt;br /&gt;
;[[llGetHTTPHeader]]: 	Returns the value of the requested header for a given HTTP request made to the script.&lt;br /&gt;
;[[llReleaseURL]]: 	Releases a given URL so it may not be used further.&lt;br /&gt;
;[[llRequestURL]]: 	Requests a non-secure URL to be used with HTTP-In.&lt;br /&gt;
;[[llRequestSecureURL]]: 	Same as [[llRequestURL]] but requests a secure url &amp;lt;nowiki&amp;gt;(https://)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Events ===&lt;br /&gt;
;[[http_request]]: 	Called when the script receives an HTTP request.&lt;br /&gt;
;[[http_response]]: 	Called when an HTTP request is complete.&lt;br /&gt;
&lt;br /&gt;
{{LSLC|}}{{LSLC|Communications}}&lt;br /&gt;
&lt;br /&gt;
=== Understanding LSL HTTP Communications ===&lt;br /&gt;
&lt;br /&gt;
[[File:VW_HTTP_requests2.jpg|500px]]&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests2.jpg&amp;diff=1175592</id>
		<title>File:VW HTTP requests2.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests2.jpg&amp;diff=1175592"/>
		<updated>2012-12-26T04:17:47Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: Simple diagram that illustrates the difference between http_response and http_request.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Simple diagram that illustrates the difference between http_response and http_request.&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests.jpg&amp;diff=1175591</id>
		<title>File:VW HTTP requests.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests.jpg&amp;diff=1175591"/>
		<updated>2012-12-26T04:12:19Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: uploaded a new version of &amp;quot;File:VW HTTP requests.jpg&amp;quot;:&amp;amp;#32;Updated to fix some semantic errors.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Simple diagram that illustrates the difference between http_response and http_request.&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=Talk:Mesh_and_LOD&amp;diff=1170802</id>
		<title>Talk:Mesh and LOD</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=Talk:Mesh_and_LOD&amp;diff=1170802"/>
		<updated>2012-07-20T17:20:19Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: Created page with &amp;quot;Has anyone done any testing on what is a good polygon count at the different LODs? --TE&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Has anyone done any testing on what is a good polygon count at the different LODs? --TE&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=Good_Building_Practices&amp;diff=1170801</id>
		<title>Good Building Practices</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=Good_Building_Practices&amp;diff=1170801"/>
		<updated>2012-07-20T17:03:52Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: /* Scripting */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Welcome to Good Building Practices ==&lt;br /&gt;
This page is all about how to be creative and efficient at the same time!&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|valign=&amp;quot;top&amp;quot;|&lt;br /&gt;
&amp;lt;div id=&amp;quot;box&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Animation ==&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0.5em&amp;quot;&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;[[Animation Streamlined]]&#039;&#039;&#039; - Make your creations move without dragging Second Life to a crawl!&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;box&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Mesh ==&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0.5em&amp;quot;&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;[[Making Mesh Physics]]&#039;&#039;&#039; - Why and How.&lt;br /&gt;
* &#039;&#039;&#039;[[Making Mesh for Pathfinding]]&#039;&#039;&#039; - Pathfinding friendly mesh.&lt;br /&gt;
* &#039;&#039;&#039;[[Mesh and LOD]]&#039;&#039;&#039; - Mesh objects that don&#039;t crash your friends&#039; old computer.&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;box&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Pathfinding ==&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0.5em&amp;quot;&amp;gt;&lt;br /&gt;
*&#039;&#039;&#039;[[Pathfinding_Overview]]&#039;&#039;&#039; - Pathfinding explained.&lt;br /&gt;
*&#039;&#039;&#039;[[Pathfinding_Tools_in_the_Second_Life_Viewer]]&#039;&#039;&#039; - The Pathfinding tools.&lt;br /&gt;
*&#039;&#039;&#039;[[Pathfinding_Quick_Start_Guide]]&#039;&#039;&#039; - The best way to get up and running with Pathfinding.&lt;br /&gt;
*&#039;&#039;&#039;[[Visual_Guide_to_Pathfinding|A Visual Guide]]&#039;&#039;&#039; - Watch how easy it is!&lt;br /&gt;
*&#039;&#039;&#039;[[Walkability_Coefficients]]&#039;&#039;&#039; - Control the speed of your Walkable areas.&lt;br /&gt;
*&#039;&#039;&#039;[[Material_Volumes]]&#039;&#039;&#039; - Control the speed of your characters.&lt;br /&gt;
*&#039;&#039;&#039;[[Universal_Attribute_Changes_for_Pathfinding]]&#039;&#039;&#039; Configure objects for pathfinding in bulk&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;box&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Physics ==&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0.5em&amp;quot;&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;[[Physics Optimization]]&#039;&#039;&#039; - Not everything needs physics, learn how to add the least load necessary to the physics engine.&lt;br /&gt;
* &#039;&#039;&#039;[[PRIM_PHYSICS_SHAPE_NONE]]&#039;&#039;&#039; - Additional information on this important attribute.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
|valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot;|&lt;br /&gt;
&amp;lt;div id=&amp;quot;box&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Scripting ==&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0.5em&amp;quot;&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;[[Debugging Tips]]&#039;&#039;&#039; - how to work out what your code is doing without a conventional development toolkit&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Pathfinding&#039;&#039;&#039;&lt;br /&gt;
** &#039;&#039;&#039;[[Pathfinding LSL Functions]]&#039;&#039;&#039; - standard reference for all of the pathfinding functions.&lt;br /&gt;
** &#039;&#039;&#039;[[Modular Pathfinding Kit]]&#039;&#039;&#039; - code snippets designed to be plugged together to quickly build unique behaviors.&lt;br /&gt;
** &#039;&#039;&#039;[[Pathfinding Cookbook]]&#039;&#039;&#039; - ready made solutions for some critters.&lt;br /&gt;
** &#039;&#039;&#039;[[Holistic Pathfinding Management]]&#039;&#039;&#039; - Strategies for managing large numbers of pathfinding objects.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Vehicles&#039;&#039;&#039;&lt;br /&gt;
** &#039;&#039;&#039;[[Linden Vehicle Tutorial]]&#039;&#039;&#039; - Vehicle scripting best practices.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;box&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0.5em&amp;quot;&amp;gt;&lt;br /&gt;
Tips for adding sound effects to your builds.&lt;br /&gt;
* [[Environment_Sounds|Environment Sounds]]&lt;br /&gt;
* [[Event_Driven_Sounds|Event Driven Sounds]]&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;box&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Sculpted Prims ==&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0.5em&amp;quot;&amp;gt;&lt;br /&gt;
*&#039;&#039;&#039;[[Sculpted Prim Usage]]&#039;&#039;&#039; - What you need to know about how sculpted prims effect Second Life.&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;box&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Textures ==&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 0.5em&amp;quot;&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;[[Texture Usage]]&#039;&#039;&#039; - What size to use, and what to avoid.&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
__NOTOC__&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=User:Techplex_Engineer&amp;diff=1170712</id>
		<title>User:Techplex Engineer</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=User:Techplex_Engineer&amp;diff=1170712"/>
		<updated>2012-07-18T18:09:46Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: Initially Created&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Hey&lt;br /&gt;
&lt;br /&gt;
Nice to meet ya!&lt;br /&gt;
I&#039;m an avid scripter and builder, let me know if there is something I can help with.&lt;br /&gt;
&lt;br /&gt;
I have submitted a couple of patches to opensim and written a php texture manager.&lt;br /&gt;
&lt;br /&gt;
I enjoy Virtual worlds and the potential they have for profiteering and education. I work with a number of educators in Maine to spread the use of Virtual Worlds.&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests.jpg&amp;diff=1170711</id>
		<title>File:VW HTTP requests.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests.jpg&amp;diff=1170711"/>
		<updated>2012-07-18T18:06:12Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: uploaded a new version of &amp;quot;File:VW HTTP requests.jpg&amp;quot;:&amp;amp;#32;Added Details to help make the diagram Clearer.

Fixed arrows to make them point the right way.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Simple diagram that illustrates the difference between http_response and http_request.&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests.jpg&amp;diff=1170433</id>
		<title>File:VW HTTP requests.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests.jpg&amp;diff=1170433"/>
		<updated>2012-07-10T00:44:42Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: uploaded a new version of &amp;quot;File:VW HTTP requests.jpg&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Simple diagram that illustrates the difference between http_response and http_request.&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=Category:LSL_HTTP&amp;diff=1170432</id>
		<title>Category:LSL HTTP</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=Category:LSL_HTTP&amp;diff=1170432"/>
		<updated>2012-07-10T00:43:52Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: /* Events */ added image to help newcommers&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{LSL Header|ml=*}}&lt;br /&gt;
&lt;br /&gt;
== HTTP ==&lt;br /&gt;
&lt;br /&gt;
[[LSL]] includes functions that utilize HTTP, the HyperText Transfer Protocol, for communicating with other scripts in-world or web servers on the outside internet. HTTP requests incur no speed penalty, but there is a limit on how many requests per [[object]] can be made.&lt;br /&gt;
&lt;br /&gt;
=== Functions ===&lt;br /&gt;
;[[llEscapeURL]]: 	Returns the UTF-8 encoded escape codes for selected characters.&lt;br /&gt;
;[[llHTTPRequest]]: 	Requests information from an HTTP server.&lt;br /&gt;
;[[llLoadURL]]:		Loads a web page in an external browser.&lt;br /&gt;
;[[llUnescapeURL]]: 	Returns the UTF-8 characters without escape codes.&lt;br /&gt;
;[[llHTTPResponse]]: 	Responds to an HTTP request made to the script.&lt;br /&gt;
;[[llGetFreeURLs]]: 	Returns the number of URLs that the script can request for HTTP-In.&lt;br /&gt;
;[[llGetHTTPHeader]]: 	Returns the value of the requested header for a given HTTP request made to the script.&lt;br /&gt;
;[[llReleaseURL]]: 	Releases a given URL so it may not be used further.&lt;br /&gt;
;[[llRequestURL]]: 	Requests a non-secure URL to be used with HTTP-In.&lt;br /&gt;
;[[llRequestSecureURL]]: 	Same as [[llRequestURL]] but requests a secure url &amp;lt;nowiki&amp;gt;(https://)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Events ===&lt;br /&gt;
;[[http_request]]: 	Called when the script receives an HTTP request.&lt;br /&gt;
;[[http_response]]: 	Called when an HTTP request is complete.&lt;br /&gt;
&lt;br /&gt;
{{LSLC|}}{{LSLC|Communications}}&lt;br /&gt;
&lt;br /&gt;
=== Understanding LSL HTTP Communications ===&lt;br /&gt;
&lt;br /&gt;
[[File:VW_HTTP_requests.jpg|500px]]&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests.jpg&amp;diff=1170431</id>
		<title>File:VW HTTP requests.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests.jpg&amp;diff=1170431"/>
		<updated>2012-07-10T00:43:12Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: uploaded a new version of &amp;quot;File:VW HTTP requests.jpg&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Simple diagram that illustrates the difference between http_response and http_request.&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests.jpg&amp;diff=1170430</id>
		<title>File:VW HTTP requests.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests.jpg&amp;diff=1170430"/>
		<updated>2012-07-10T00:38:02Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: uploaded a new version of &amp;quot;File:VW HTTP requests.jpg&amp;quot;:&amp;amp;#32;Removed the Gliffy banner&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Simple diagram that illustrates the difference between http_response and http_request.&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests.jpg&amp;diff=1170429</id>
		<title>File:VW HTTP requests.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=File:VW_HTTP_requests.jpg&amp;diff=1170429"/>
		<updated>2012-07-10T00:36:21Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: Simple diagram that illustrates the difference between http_response and http_request.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Simple diagram that illustrates the difference between http_response and http_request.&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=LSL_HTTP_server/examples&amp;diff=1169113</id>
		<title>LSL HTTP server/examples</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=LSL_HTTP_server/examples&amp;diff=1169113"/>
		<updated>2012-06-14T00:03:54Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: /* Echo World */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{LSL Header|ml=*}}&lt;br /&gt;
=== Utility Script ===&lt;br /&gt;
A script intended as a &#039;fill in the blank&#039; exercise for very, very simple HTTP servers is here: [[LSL_http_server/examples/utility_script | Utility Script]]&lt;br /&gt;
=== Hello World! ===&lt;br /&gt;
Classic example, the smallest http_request script possible.&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
    state_entry()&lt;br /&gt;
    {&lt;br /&gt;
        llRequestURL();&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    http_request(key id, string method, string body)&lt;br /&gt;
    {&lt;br /&gt;
        if (method == URL_REQUEST_GRANTED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0,&amp;quot;URL: &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == &amp;quot;GET&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            llHTTPResponse(id,200,&amp;quot;Hello World!&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
A slightly more robust version:&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
    state_entry()&lt;br /&gt;
    {&lt;br /&gt;
        llRequestURL();&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    http_request(key id, string method, string body)&lt;br /&gt;
    {&lt;br /&gt;
        if (method == URL_REQUEST_GRANTED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0,&amp;quot;URL: &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == URL_REQUEST_DENIED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0, &amp;quot;Something went wrong, no url. &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == &amp;quot;GET&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            llHTTPResponse(id,200,&amp;quot;Hello World!&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
        else&lt;br /&gt;
        {&lt;br /&gt;
            llHTTPResponse(id,405,&amp;quot;Unsupported Method&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Echo World ===&lt;br /&gt;
&amp;quot;Echo World ([[User:Byrd Sciavo|Byrd Sciavo]] 04:19, 7 October 2009 (UTC))&amp;quot; is a slightly more useful &amp;quot;Hello World&amp;quot;, demonstrating a basic server that echos back dynamic data fed. Echo World shows how http_request receives GET variables. To receive this &amp;quot;dynamic echo&amp;quot;, append your cap url with a query string, such as https://sim3015.aditi.lindenlab.com:12043/cap/a7717681-2c04-e4ac-35e3-1f01c9861322/foo/bar?arg=gra&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
string url;&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
    state_entry()&lt;br /&gt;
    {&lt;br /&gt;
        llRequestURL();&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    http_request(key id, string method, string body)&lt;br /&gt;
    {    &lt;br /&gt;
        if (method == URL_REQUEST_GRANTED) &lt;br /&gt;
        {&lt;br /&gt;
            url=body;&lt;br /&gt;
            llOwnerSay(url);&lt;br /&gt;
        }&lt;br /&gt;
        else if(method==&amp;quot;GET&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
              if(llGetHTTPHeader(id,&amp;quot;x-query-string&amp;quot;)==&amp;quot;&amp;quot;) &lt;br /&gt;
                  llHTTPResponse(id,200,&amp;quot;I ECHO when you append some GET variables to me, e.g., /?var=foo&amp;quot;);&lt;br /&gt;
              else &lt;br /&gt;
                  llHTTPResponse(id,200,llGetHTTPHeader(id,&amp;quot;x-query-string&amp;quot;));&lt;br /&gt;
        }        &lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Visitor List ===&lt;br /&gt;
A list of residents within sensor range of the server.&lt;br /&gt;
&amp;lt;br&amp;gt;Notes:&lt;br /&gt;
* This includes a method for handling multiple requests while waiting for asynchronous data requests to come back.&lt;br /&gt;
&amp;lt;lsl&amp;gt;integer scanning = FALSE;&lt;br /&gt;
&lt;br /&gt;
list requests;&lt;br /&gt;
&lt;br /&gt;
send_response(string body)&lt;br /&gt;
{&lt;br /&gt;
    integer j;&lt;br /&gt;
    for (j = 0; j &amp;lt; llGetListLength(requests); ++j)&lt;br /&gt;
    {&lt;br /&gt;
        llHTTPResponse(llList2Key(requests,j), 200, body);&lt;br /&gt;
    }&lt;br /&gt;
    requests = [];&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
    state_entry()&lt;br /&gt;
    {&lt;br /&gt;
        llRequestURL();&lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    http_request(key id, string method, string body)&lt;br /&gt;
    {&lt;br /&gt;
        if (method == URL_REQUEST_GRANTED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0,&amp;quot;URL: &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == URL_REQUEST_DENIED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0, &amp;quot;Something went wrong, no url. &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == &amp;quot;GET&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            if (!scanning)&lt;br /&gt;
            {&lt;br /&gt;
                llSensor(&amp;quot;&amp;quot;,NULL_KEY,AGENT,96,PI);&lt;br /&gt;
                scanning = TRUE;&lt;br /&gt;
            }&lt;br /&gt;
            &lt;br /&gt;
            requests += [id];&lt;br /&gt;
        }&lt;br /&gt;
        else&lt;br /&gt;
        {&lt;br /&gt;
            llHTTPResponse(id,405,&amp;quot;Unsupported method.&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    no_sensor()&lt;br /&gt;
    {&lt;br /&gt;
        send_response(&amp;quot;There is no one here.&amp;quot;);&lt;br /&gt;
        scanning = FALSE;&lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    sensor(integer n)&lt;br /&gt;
    {&lt;br /&gt;
        string output;&lt;br /&gt;
        if (n &amp;lt; 16) output = &amp;quot;There are &amp;quot; + (string)n + &amp;quot; avatars nearby:&amp;quot;;&lt;br /&gt;
        else output = &amp;quot;There are at least 16 avatars nearby:&amp;quot;;&lt;br /&gt;
        &lt;br /&gt;
        integer i;&lt;br /&gt;
        for (i = 0;i&amp;lt;n;++i)&lt;br /&gt;
        {&lt;br /&gt;
            output += &amp;quot;\n\t&amp;quot; + llDetectedName(i);&lt;br /&gt;
        }&lt;br /&gt;
        &lt;br /&gt;
        send_response(output);&lt;br /&gt;
&lt;br /&gt;
        scanning = FALSE;&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Url Persistence / Visitor Counter ===&lt;br /&gt;
A more complete &#039;hello world&#039;, always has an url and keeps a visitor counter.&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
string url;&lt;br /&gt;
integer hits;&lt;br /&gt;
&lt;br /&gt;
setup()&lt;br /&gt;
{&lt;br /&gt;
    llSetObjectName(&amp;quot;HTTP Server&amp;quot;);&lt;br /&gt;
    url = &amp;quot;&amp;quot;;&lt;br /&gt;
    llRequestURL();&lt;br /&gt;
    hits = (integer)llGetObjectDesc();&lt;br /&gt;
    llSetText((string)hits + &amp;quot; visitors.&amp;quot;,&amp;lt;1,1,0&amp;gt;,1);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
    state_entry() { setup(); }&lt;br /&gt;
    on_rez(integer n) { setup(); }&lt;br /&gt;
    &lt;br /&gt;
    changed(integer c)&lt;br /&gt;
    {&lt;br /&gt;
        if (c &amp;amp; (CHANGED_REGION | CHANGED_REGION_START | CHANGED_TELEPORT) )&lt;br /&gt;
        {&lt;br /&gt;
            setup();&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    touch_start(integer n)&lt;br /&gt;
    {&lt;br /&gt;
        llSay(0,&amp;quot;My url is: &amp;quot; + url);&lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    http_request(key id, string method, string body)&lt;br /&gt;
    {&lt;br /&gt;
        if (method == URL_REQUEST_GRANTED)&lt;br /&gt;
        {&lt;br /&gt;
            url = body;&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == URL_REQUEST_DENIED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0, &amp;quot;Something went wrong, no url. &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == &amp;quot;GET&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            ++hits;&lt;br /&gt;
            llSetObjectDesc((string)hits);&lt;br /&gt;
            llSetText((string)hits + &amp;quot; visitors.&amp;quot;,&amp;lt;1,1,0&amp;gt;,1);&lt;br /&gt;
            llHTTPResponse(id,200,&amp;quot;Hello!  You are visitor &amp;quot; + (string)hits + &amp;quot;.&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
        else&lt;br /&gt;
        {&lt;br /&gt;
            llHTTPResponse(id,405,&amp;quot;Method unsupported&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Perl/Python Examples Using POST ===&lt;br /&gt;
Here are a set of scripts to provide another example using POST. The first script is the LSL code to receive the information on the grid. The second script is a Perl script that is used on the outside server to contact the code on the grid. The third script is a Python script that is also used on the outside server to contact the code on the grid.  ([[User:Grandma Bates|Grandma Bates]] 12:42, 27 May 2009 (UTC))&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
key requestURL;&lt;br /&gt;
&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
    state_entry() &lt;br /&gt;
    {&lt;br /&gt;
        requestURL = llRequestURL();     // Request that an URL be assigned to me.&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
     http_request(key id, string method, string body) &lt;br /&gt;
     {&lt;br /&gt;
        if ((method == URL_REQUEST_GRANTED) &amp;amp;&amp;amp; (id == requestURL) )&lt;br /&gt;
        {&lt;br /&gt;
            // An URL has been assigned to me.&lt;br /&gt;
            llOwnerSay(&amp;quot;Obtained URL: &amp;quot; + body);&lt;br /&gt;
            requestURL = NULL_KEY;&lt;br /&gt;
        }&lt;br /&gt;
        else if ((method == URL_REQUEST_DENIED) &amp;amp;&amp;amp; (id == requestURL)) &lt;br /&gt;
        {&lt;br /&gt;
            // I could not obtain a URL&lt;br /&gt;
            llOwnerSay(&amp;quot;There was a problem, and an URL was not assigned: &amp;quot; + body);&lt;br /&gt;
            requestURL = NULL_KEY;&lt;br /&gt;
        }&lt;br /&gt;
&lt;br /&gt;
        else if (method == &amp;quot;POST&amp;quot;) &lt;br /&gt;
        {&lt;br /&gt;
            // An incoming message was received.&lt;br /&gt;
            llOwnerSay(&amp;quot;Received information from the outside: &amp;quot; + body);&lt;br /&gt;
            llHTTPResponse(id,200,&amp;quot;Thank you for calling. All of our operators are busy.&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
        else &lt;br /&gt;
        {&lt;br /&gt;
            // An incoming message has come in using a method that has not been anticipated.&lt;br /&gt;
            llHTTPResponse(id,405,&amp;quot;Unsupported Method&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Here is the Perl script to contact the prim on the grid.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;perl&amp;gt;&lt;br /&gt;
#!/usr/bin/perl&lt;br /&gt;
# Routine to contact a script on the SL Grid using http server&lt;br /&gt;
use strict;&lt;br /&gt;
use warnings;&lt;br /&gt;
use LWP;&lt;br /&gt;
&lt;br /&gt;
my $browser = LWP::UserAgent-&amp;gt;new;&lt;br /&gt;
&lt;br /&gt;
sub submitInformation) {&lt;br /&gt;
    my( $url, $params ) = @_;&lt;br /&gt;
    return $browser-&amp;gt;post( $url, $params )-&amp;gt;content;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# Set the URL manually....&lt;br /&gt;
my $url = &#039;http://sim3015.aditi.lindenlab.com:12046/cap/d57a7c8b-3ace-3186-730a-f22fde870d48&#039;;&lt;br /&gt;
&lt;br /&gt;
my $info = submitInformation( $url, {&lt;br /&gt;
    id   =&amp;gt; &#039;244195d6-c9b7-4fd6-9229-c3a8b2e60e81&#039;,&lt;br /&gt;
    name =&amp;gt; &#039;M Linden&#039;,&lt;br /&gt;
} );&lt;br /&gt;
&lt;br /&gt;
print $info,&amp;quot;\n&amp;quot;;&lt;br /&gt;
&amp;lt;/perl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Here is the Python code that does the same thing as the PERL code above.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;python&amp;gt;&lt;br /&gt;
#!/usr/bin/python&lt;br /&gt;
&lt;br /&gt;
import urllib&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
# #################################################&lt;br /&gt;
# Routine to send the information to the prim&lt;br /&gt;
#     submitInformation(url,information)&lt;br /&gt;
#&lt;br /&gt;
def submitInformation(url,parameters) :&lt;br /&gt;
    # Set the parameters to be sent.&lt;br /&gt;
    encodedParams =  urllib.urlencode(parameters);&lt;br /&gt;
&lt;br /&gt;
    # Post the data.&lt;br /&gt;
    net = urllib.urlopen(url,encodedParams);&lt;br /&gt;
&lt;br /&gt;
    # return the result.&lt;br /&gt;
    return(net.read());&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
if __name__ == &amp;quot;__main__&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
    # Set the URL manually&lt;br /&gt;
    url = &#039;http://sim3015.aditi.lindenlab.com:12046/cap/d57a7c8b-3ace-3186-730a-f22fde870d48&#039;;&lt;br /&gt;
&lt;br /&gt;
    # Define the parameters&lt;br /&gt;
    parameters = {&#039;id&#039;:&#039;244195d6-c9b7-4fd6-9229-c3a8b2e60e81&#039;,&lt;br /&gt;
                  &#039;name&#039;:&#039;M Linden&#039;}&lt;br /&gt;
&lt;br /&gt;
    # Pass the information along to the prim&lt;br /&gt;
    info = submitInformation(url,parameters);&lt;br /&gt;
    print(info);&lt;br /&gt;
&amp;lt;/python&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Perl/Python Examples Using POST With Argument Parsing ===&lt;br /&gt;
Here are a set of scripts to provide another example using POST. In this example the scripts are adapted to handle the parsing of the arguments that are passed. The first script is the LSL code to receive the information on the grid. The second script is a PERL script that is used on the outside server to contact the code on the grid. The third script is a Python script that is also used on the outside server to contact the code on the grid. ([[User:Grandma Bates|Grandma Bates]] 12:42, 27 May 2009 (UTC))&lt;br /&gt;
&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
key requestURL;&lt;br /&gt;
&lt;br /&gt;
// ###############################################&lt;br /&gt;
// Routine to parse a string sent through the &lt;br /&gt;
// http server via post.&lt;br /&gt;
//       parsePostData(theMessage)&lt;br /&gt;
// Returns a strided list with stride length 2.&lt;br /&gt;
// Each set has the key and then its value.&lt;br /&gt;
list parsePostData(string message) {&lt;br /&gt;
    list postData = [];         // The list with the data that was passed in.&lt;br /&gt;
    list parsedMessage = llParseString2List(message,[&amp;quot;&amp;amp;&amp;quot;],[]);    // The key/value pairs parsed into one list.&lt;br /&gt;
    integer len = ~llGetListLength(parsedMessage);&lt;br /&gt;
&lt;br /&gt;
    while(++len) {          &lt;br /&gt;
        string currentField = llList2String(parsedMessage, len); // Current key/value pair as a string.&lt;br /&gt;
&lt;br /&gt;
        integer split = llSubStringIndex(currentField,&amp;quot;=&amp;quot;);     // Find the &amp;quot;=&amp;quot; sign&lt;br /&gt;
        if(split == -1) { // There is only one field in this part of the message.&lt;br /&gt;
            postData += [llUnescapeURL(currentField),&amp;quot;&amp;quot;];  &lt;br /&gt;
        } else {&lt;br /&gt;
            postData += [llUnescapeURL(llDeleteSubString(currentField,split,-1)), llUnescapeURL(llDeleteSubString(currentField,0,split))];&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
    // Return the strided list.&lt;br /&gt;
    return postData ;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
default {&lt;br /&gt;
&lt;br /&gt;
    state_entry() {&lt;br /&gt;
        requestURL = llRequestURL(); // Request that an URL be assigned to me.&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    http_request(key id, string method, string body) {&lt;br /&gt;
         list incomingMessage;&lt;br /&gt;
        &lt;br /&gt;
        if ((method == URL_REQUEST_GRANTED) &amp;amp;&amp;amp; (id == requestURL) ){&lt;br /&gt;
            // An URL has been assigned to me.&lt;br /&gt;
            llOwnerSay(&amp;quot;Obtained URL: &amp;quot; + body);&lt;br /&gt;
            requestURL = NULL_KEY;&lt;br /&gt;
        }&lt;br /&gt;
        else if ((method == URL_REQUEST_DENIED) &amp;amp;&amp;amp; (id == requestURL)) {&lt;br /&gt;
            // I could not obtain a URL&lt;br /&gt;
            llOwnerSay(&amp;quot;There was a problem, and an URL was not assigned: &amp;quot; + &lt;br /&gt;
                       body);&lt;br /&gt;
            requestURL = NULL_KEY;&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == &amp;quot;POST&amp;quot;) {&lt;br /&gt;
            // An incoming message was received.&lt;br /&gt;
            llOwnerSay(&amp;quot;Received information form the outside: &amp;quot; + body);&lt;br /&gt;
            incomingMessage = parsePostData(body);&lt;br /&gt;
            llOwnerSay(llDumpList2String(incomingMessage,&amp;quot;\n&amp;quot;));&lt;br /&gt;
&lt;br /&gt;
            llHTTPResponse(id,200,&amp;quot;You passed the following:\n&amp;quot; + &lt;br /&gt;
                           llDumpList2String(incomingMessage,&amp;quot;\n&amp;quot;));&lt;br /&gt;
&lt;br /&gt;
        }&lt;br /&gt;
        else {&lt;br /&gt;
            // An incoming message has come in using a method that has&lt;br /&gt;
            // not been anticipated.&lt;br /&gt;
            llHTTPResponse(id,405,&amp;quot;Unsupported Method&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Here is the coresponding PERL script for contacting the LSL script on the grid.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;perl&amp;gt;&lt;br /&gt;
#!/usr/bin/perl&lt;br /&gt;
# Routine to contact a script on the SL Grid using http server&lt;br /&gt;
use strict;&lt;br /&gt;
use warnings;&lt;br /&gt;
&lt;br /&gt;
use LWP;&lt;br /&gt;
&lt;br /&gt;
my $browser = LWP::UserAgent-&amp;gt;new;&lt;br /&gt;
&lt;br /&gt;
sub submitInformation) {&lt;br /&gt;
    my( $url, $params ) = @_;&lt;br /&gt;
    return $browser-&amp;gt;post( $url, $params )-&amp;gt;content;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# Set the URL manually....&lt;br /&gt;
my $url = &#039;http://sim3015.aditi.lindenlab.com:12046/cap/5a1b89cd-e681-8110-7245-fb98969f32a0&#039;;&lt;br /&gt;
&lt;br /&gt;
my $info = submitInformation( $url, {&lt;br /&gt;
    &#039;action&#039; =&amp;gt; &#039;send message&#039;,&lt;br /&gt;
    &#039;value&#039;  =&amp;gt; &#039;Hi there chief!&#039;,&lt;br /&gt;
    &#039;id&#039;     =&amp;gt; &#039;244195d6-c9b7-4fd6-9229-c3a8b2e60e81&#039;,&lt;br /&gt;
    &#039;name&#039;   =&amp;gt; &#039;M Linden&#039;,&lt;br /&gt;
});&lt;br /&gt;
&lt;br /&gt;
print($info,&amp;quot;\n&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/perl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here is the coresponding Python script. It does the same thing as the Perl script above.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;python&amp;gt;&lt;br /&gt;
#!/usr/bin/python&lt;br /&gt;
&lt;br /&gt;
import urllib&lt;br /&gt;
import re&lt;br /&gt;
&lt;br /&gt;
# #################################################&lt;br /&gt;
# Routine to send the information to the prim&lt;br /&gt;
#     submitInformation(url,information)&lt;br /&gt;
#&lt;br /&gt;
def submitInformation(url,parameters) :&lt;br /&gt;
    &lt;br /&gt;
#    encodedParams =  urllib.urlencode(parameters);  # encode the parameters&lt;br /&gt;
    encodedParams  = dictionary2URI(parameters);    # encode the parameters&lt;br /&gt;
    net = urllib.urlopen(url,encodedParams);        # Post the data.&lt;br /&gt;
    return(net.read());                             # return the result.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
# ################################################&lt;br /&gt;
# Routine to encode a dictionary without using &lt;br /&gt;
# &amp;quot;+&amp;quot; for spaces.&lt;br /&gt;
#       dictionary2URI(theDictionary)&lt;br /&gt;
def dictionary2URI(theDictionary) : &lt;br /&gt;
&lt;br /&gt;
    encoded = &#039;&#039;;           # Initialize the string to return&lt;br /&gt;
    for key, value in theDictionary.iteritems():&lt;br /&gt;
        # Encode each item in the dictionary.&lt;br /&gt;
        encoded += urllib.quote(key)+&amp;quot;=&amp;quot;+urllib.quote(value)+&amp;quot;&amp;amp;&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
    remove = re.compile(&#039;&amp;amp;$&#039;)             # Remove the trailing ampersand.&lt;br /&gt;
    encoded = remove.sub(&#039;&#039;,encoded);&lt;br /&gt;
&lt;br /&gt;
    return(encoded);&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
if __name__ == &amp;quot;__main__&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
    # Set the URL manually&lt;br /&gt;
    url = &#039;http://sim3015.aditi.lindenlab.com:12046/cap/5a1b89cd-e681-8110-7245-fb98969f32a0&#039;;&lt;br /&gt;
&lt;br /&gt;
    # Define the parameters&lt;br /&gt;
    parameters = {&#039;id&#039;:&#039;244195d6-c9b7-4fd6-9229-c3a8b2e60e81&#039;,&lt;br /&gt;
                  &#039;name&#039;:&#039;M Linden&#039;,&lt;br /&gt;
                  &#039;action&#039;:&#039;send message&#039;,&lt;br /&gt;
                  &#039;value&#039;:&#039;Hey there, hi there, ho there!&#039;};&lt;br /&gt;
&lt;br /&gt;
    # Pass the information along to the prim&lt;br /&gt;
    info = submitInformation(url,parameters);&lt;br /&gt;
    print(info);&lt;br /&gt;
&amp;lt;/python&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;display:none;&amp;quot;&amp;gt;&amp;lt;lsl&amp;gt;&amp;lt;/lsl&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Simple script for sending data to an LSL via PHP ===&lt;br /&gt;
This example by Simba Fuhr &#039;&#039;&#039;UPDATE April 16, 2011&#039;&#039;&#039;&lt;br /&gt;
{{Warning|Some hosting providers only allow fsockopen on the standard 80 and 443 ports.  This script will not work on those providers. If your provider is willing to open some ports for you, HTTP-in uses port 12046, and HTTPS-in uses port 12043.}}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039;&lt;br /&gt;
To use SSL encrypted sockets, you need to have SSL activated on your server. If you run your own server, you need to import the ssl support to your server (apache =&amp;gt; apache.conf  +&amp;quot;LoadModule ssl_module modules/mod_ssl.so&amp;quot;)(normaly based on openssl).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Secure URL Request with LSL.&lt;br /&gt;
Script returns the URL to the chat. Please put the URL into the PHP below.&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
 state_entry()&lt;br /&gt;
 {&lt;br /&gt;
  llRequestSecureURL();&lt;br /&gt;
 }&lt;br /&gt;
 http_request(key id, string method, string body)&lt;br /&gt;
 {&lt;br /&gt;
  if ((method == URL_REQUEST_GRANTED))&lt;br /&gt;
  {&lt;br /&gt;
   llOwnerSay(&amp;quot;URL: &amp;quot; + body);&lt;br /&gt;
  }&lt;br /&gt;
  else if (method == &amp;quot;POST&amp;quot;)&lt;br /&gt;
  {&lt;br /&gt;
   llOwnerSay(&amp;quot;PHP script sent: {&amp;quot; + body + &amp;quot;}&amp;quot;);&lt;br /&gt;
   llHTTPResponse(id, 200, &amp;quot;PHP script sent: {&amp;quot; + body + &amp;quot;}&amp;quot;);&lt;br /&gt;
  }&lt;br /&gt;
 }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Here the PHP.&lt;br /&gt;
A more advanced php function which supports complete url structures and automatical GET and POST types.&lt;br /&gt;
Just don&#039;t submit any post Data to make a GET request.&lt;br /&gt;
The Function supports any kind of url as secure and not secure (https and http).&lt;br /&gt;
If you dont submit a port in the url, the default port for http (80) and https (443) will be used.&lt;br /&gt;
(An example is shown on the top of the script.)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;php&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
echo &amp;quot;LSL Script answered:&amp;lt;br&amp;gt;&amp;quot;;&lt;br /&gt;
echo Advanced_HTTP_Request(&amp;quot;https://sim20557.agni.lindenlab.com:12043/cap/5851e666-b0c6-f0a0-758a-9e8156765215&amp;quot;, &amp;quot;Hello script, how are you ?&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
function Advanced_HTTP_Request($Host, $PostData = &amp;quot;&amp;quot;)&lt;br /&gt;
{&lt;br /&gt;
 $Method = &amp;quot;POST&amp;quot;;&lt;br /&gt;
 if (empty($PostData))&lt;br /&gt;
  {$Method = &amp;quot;GET&amp;quot;;}&lt;br /&gt;
 $Port = 80;&lt;br /&gt;
 if (strtolower(substr($Host, 0, 5)) == &amp;quot;https&amp;quot;)&lt;br /&gt;
  {$Port = 443;}&lt;br /&gt;
 $Host = explode(&amp;quot;//&amp;quot;, $Host, 2);&lt;br /&gt;
 if (count($Host) &amp;lt; 2)&lt;br /&gt;
  {$Host[1] = $Host[0];}&lt;br /&gt;
 $Host = explode(&amp;quot;/&amp;quot;, $Host[1], 2);&lt;br /&gt;
 if ($Port == 443)&lt;br /&gt;
  {$SSLAdd = &amp;quot;ssl://&amp;quot;;}&lt;br /&gt;
 $Host[0] = explode(&amp;quot;:&amp;quot;, $Host[0]);&lt;br /&gt;
 if (count($Host[0]) &amp;gt; 1)&lt;br /&gt;
 {&lt;br /&gt;
  $Port = $Host[0][1];&lt;br /&gt;
  $Host[0] = $Host[0][0];&lt;br /&gt;
 }&lt;br /&gt;
 else&lt;br /&gt;
  {$Host[0] = $Host[0][0];}&lt;br /&gt;
 $Socket = fsockopen($SSLAdd.$Host[0], $Port, $Dummy1, $Dummy2, 10);&lt;br /&gt;
 if ($Socket)&lt;br /&gt;
 {&lt;br /&gt;
  fputs($Socket, &amp;quot;$Method /$Host[1] HTTP/1.1\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Host: $Host[0]\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Content-type: application/x-www-form-urlencoded\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;User-Agent: Opera/9.01 (Windows NT 5.1; U; en)\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Accept-Language: de-DE,de;q=0.9,en;q=0.8\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Accept-Charset: iso-8859-1, utf-8, utf-16, *;q=0.1\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Content-length: &amp;quot;.strlen($PostData).&amp;quot;\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Connection: close\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;\r\n&amp;quot;.&lt;br /&gt;
				 $PostData);&lt;br /&gt;
  $Tme = time();&lt;br /&gt;
  while(!feof($Socket) &amp;amp;&amp;amp; $Tme + 30 &amp;gt; time())&lt;br /&gt;
   {$Res = $Res.fgets($Socket, 256);}&lt;br /&gt;
  fclose($Socket);&lt;br /&gt;
 }&lt;br /&gt;
 $Res = explode(&amp;quot;\r\n\r\n&amp;quot;, $Res, 2);&lt;br /&gt;
 return $Res[1];&lt;br /&gt;
}&lt;br /&gt;
?&amp;gt;&lt;br /&gt;
&amp;lt;/php&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Kelly&#039;s Stupid Web Status Updater ===&lt;br /&gt;
Is actually on its own page: [[LSL_http_server/examples/kellys_stupid_web_status_updater | Kelly&#039;s Stupid Web Status Updater]]&amp;lt;br&amp;gt;&lt;br /&gt;
Kurai&#039;s mod from Kelly&#039;s stupid thing: [[LSL_http_server/examples/kurais_stupid_web_status_updater| Kurai&#039;s Stupid Web Status Updater Mod]]&lt;br /&gt;
{{LSLC|HTTP}}{{LSLC|Examples}}&lt;br /&gt;
&lt;br /&gt;
=== Web-based dynamic buildings ===&lt;br /&gt;
HTTP-in may be used to easily send commands from a web page to an in-world object, so that web users can control and interact with buildings. The interactive installation &#039;&#039;Chromutate&#039;&#039; is based upon this idea: see its [[User:Opensource_Obscure/Chromutate|documentation page]] for free scripts and more details.&lt;br /&gt;
&lt;br /&gt;
=== PHP/SQL Object DNS ===&lt;br /&gt;
Simple DNS server written in PHP to facilitate a DNS service for LSL scripts&lt;br /&gt;
[[LSL_http_server/examples/phpdns|PHPDNS]]&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=LSL_HTTP_server/examples&amp;diff=1169112</id>
		<title>LSL HTTP server/examples</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=LSL_HTTP_server/examples&amp;diff=1169112"/>
		<updated>2012-06-14T00:02:11Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: /* Echo World */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{LSL Header|ml=*}}&lt;br /&gt;
=== Utility Script ===&lt;br /&gt;
A script intended as a &#039;fill in the blank&#039; exercise for very, very simple HTTP servers is here: [[LSL_http_server/examples/utility_script | Utility Script]]&lt;br /&gt;
=== Hello World! ===&lt;br /&gt;
Classic example, the smallest http_request script possible.&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
    state_entry()&lt;br /&gt;
    {&lt;br /&gt;
        llRequestURL();&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    http_request(key id, string method, string body)&lt;br /&gt;
    {&lt;br /&gt;
        if (method == URL_REQUEST_GRANTED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0,&amp;quot;URL: &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == &amp;quot;GET&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            llHTTPResponse(id,200,&amp;quot;Hello World!&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
A slightly more robust version:&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
    state_entry()&lt;br /&gt;
    {&lt;br /&gt;
        llRequestURL();&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    http_request(key id, string method, string body)&lt;br /&gt;
    {&lt;br /&gt;
        if (method == URL_REQUEST_GRANTED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0,&amp;quot;URL: &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == URL_REQUEST_DENIED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0, &amp;quot;Something went wrong, no url. &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == &amp;quot;GET&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            llHTTPResponse(id,200,&amp;quot;Hello World!&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
        else&lt;br /&gt;
        {&lt;br /&gt;
            llHTTPResponse(id,405,&amp;quot;Unsupported Method&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Echo World ===&lt;br /&gt;
&amp;quot;Echo World ([[User:Byrd Sciavo|Byrd Sciavo]] 04:19, 7 October 2009 (UTC))&amp;quot; is a slightly more useful &amp;quot;Hello World&amp;quot;, demonstrating a basic server that echos back dynamic data fed. Echo World shows how http_request receives GET variables. To receive this &amp;quot;dynamic echo&amp;quot;, append your cap url with a query string, such as https://sim3015.aditi.lindenlab.com:12043/cap/a7717681-2c04-e4ac-35e3-1f01c9861322/foo/bar?arg=gra&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
string url;&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
    state_entry()&lt;br /&gt;
    {&lt;br /&gt;
        llRequestURL();&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    http_request(key id, string method, string body)&lt;br /&gt;
    {    &lt;br /&gt;
        if (method == URL_REQUEST_GRANTED) &lt;br /&gt;
        {&lt;br /&gt;
            url=body;llOwnerSay(url);&lt;br /&gt;
        }&lt;br /&gt;
        else if(method==&amp;quot;GET&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
              if(llGetHTTPHeader(id,&amp;quot;x-query-string&amp;quot;)==&amp;quot;&amp;quot;) &lt;br /&gt;
                  llHTTPResponse(id,200,&amp;quot;I ECHO when you append some GET variables to me, e.g., /?var=foo&amp;quot;);&lt;br /&gt;
              else &lt;br /&gt;
                  llHTTPResponse(id,200,llGetHTTPHeader(id,&amp;quot;x-query-string&amp;quot;));&lt;br /&gt;
        }        &lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Visitor List ===&lt;br /&gt;
A list of residents within sensor range of the server.&lt;br /&gt;
&amp;lt;br&amp;gt;Notes:&lt;br /&gt;
* This includes a method for handling multiple requests while waiting for asynchronous data requests to come back.&lt;br /&gt;
&amp;lt;lsl&amp;gt;integer scanning = FALSE;&lt;br /&gt;
&lt;br /&gt;
list requests;&lt;br /&gt;
&lt;br /&gt;
send_response(string body)&lt;br /&gt;
{&lt;br /&gt;
    integer j;&lt;br /&gt;
    for (j = 0; j &amp;lt; llGetListLength(requests); ++j)&lt;br /&gt;
    {&lt;br /&gt;
        llHTTPResponse(llList2Key(requests,j), 200, body);&lt;br /&gt;
    }&lt;br /&gt;
    requests = [];&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
    state_entry()&lt;br /&gt;
    {&lt;br /&gt;
        llRequestURL();&lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    http_request(key id, string method, string body)&lt;br /&gt;
    {&lt;br /&gt;
        if (method == URL_REQUEST_GRANTED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0,&amp;quot;URL: &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == URL_REQUEST_DENIED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0, &amp;quot;Something went wrong, no url. &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == &amp;quot;GET&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            if (!scanning)&lt;br /&gt;
            {&lt;br /&gt;
                llSensor(&amp;quot;&amp;quot;,NULL_KEY,AGENT,96,PI);&lt;br /&gt;
                scanning = TRUE;&lt;br /&gt;
            }&lt;br /&gt;
            &lt;br /&gt;
            requests += [id];&lt;br /&gt;
        }&lt;br /&gt;
        else&lt;br /&gt;
        {&lt;br /&gt;
            llHTTPResponse(id,405,&amp;quot;Unsupported method.&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    no_sensor()&lt;br /&gt;
    {&lt;br /&gt;
        send_response(&amp;quot;There is no one here.&amp;quot;);&lt;br /&gt;
        scanning = FALSE;&lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    sensor(integer n)&lt;br /&gt;
    {&lt;br /&gt;
        string output;&lt;br /&gt;
        if (n &amp;lt; 16) output = &amp;quot;There are &amp;quot; + (string)n + &amp;quot; avatars nearby:&amp;quot;;&lt;br /&gt;
        else output = &amp;quot;There are at least 16 avatars nearby:&amp;quot;;&lt;br /&gt;
        &lt;br /&gt;
        integer i;&lt;br /&gt;
        for (i = 0;i&amp;lt;n;++i)&lt;br /&gt;
        {&lt;br /&gt;
            output += &amp;quot;\n\t&amp;quot; + llDetectedName(i);&lt;br /&gt;
        }&lt;br /&gt;
        &lt;br /&gt;
        send_response(output);&lt;br /&gt;
&lt;br /&gt;
        scanning = FALSE;&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Url Persistence / Visitor Counter ===&lt;br /&gt;
A more complete &#039;hello world&#039;, always has an url and keeps a visitor counter.&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
string url;&lt;br /&gt;
integer hits;&lt;br /&gt;
&lt;br /&gt;
setup()&lt;br /&gt;
{&lt;br /&gt;
    llSetObjectName(&amp;quot;HTTP Server&amp;quot;);&lt;br /&gt;
    url = &amp;quot;&amp;quot;;&lt;br /&gt;
    llRequestURL();&lt;br /&gt;
    hits = (integer)llGetObjectDesc();&lt;br /&gt;
    llSetText((string)hits + &amp;quot; visitors.&amp;quot;,&amp;lt;1,1,0&amp;gt;,1);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
    state_entry() { setup(); }&lt;br /&gt;
    on_rez(integer n) { setup(); }&lt;br /&gt;
    &lt;br /&gt;
    changed(integer c)&lt;br /&gt;
    {&lt;br /&gt;
        if (c &amp;amp; (CHANGED_REGION | CHANGED_REGION_START | CHANGED_TELEPORT) )&lt;br /&gt;
        {&lt;br /&gt;
            setup();&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    touch_start(integer n)&lt;br /&gt;
    {&lt;br /&gt;
        llSay(0,&amp;quot;My url is: &amp;quot; + url);&lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    http_request(key id, string method, string body)&lt;br /&gt;
    {&lt;br /&gt;
        if (method == URL_REQUEST_GRANTED)&lt;br /&gt;
        {&lt;br /&gt;
            url = body;&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == URL_REQUEST_DENIED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0, &amp;quot;Something went wrong, no url. &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == &amp;quot;GET&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            ++hits;&lt;br /&gt;
            llSetObjectDesc((string)hits);&lt;br /&gt;
            llSetText((string)hits + &amp;quot; visitors.&amp;quot;,&amp;lt;1,1,0&amp;gt;,1);&lt;br /&gt;
            llHTTPResponse(id,200,&amp;quot;Hello!  You are visitor &amp;quot; + (string)hits + &amp;quot;.&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
        else&lt;br /&gt;
        {&lt;br /&gt;
            llHTTPResponse(id,405,&amp;quot;Method unsupported&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Perl/Python Examples Using POST ===&lt;br /&gt;
Here are a set of scripts to provide another example using POST. The first script is the LSL code to receive the information on the grid. The second script is a Perl script that is used on the outside server to contact the code on the grid. The third script is a Python script that is also used on the outside server to contact the code on the grid.  ([[User:Grandma Bates|Grandma Bates]] 12:42, 27 May 2009 (UTC))&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
key requestURL;&lt;br /&gt;
&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
    state_entry() &lt;br /&gt;
    {&lt;br /&gt;
        requestURL = llRequestURL();     // Request that an URL be assigned to me.&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
     http_request(key id, string method, string body) &lt;br /&gt;
     {&lt;br /&gt;
        if ((method == URL_REQUEST_GRANTED) &amp;amp;&amp;amp; (id == requestURL) )&lt;br /&gt;
        {&lt;br /&gt;
            // An URL has been assigned to me.&lt;br /&gt;
            llOwnerSay(&amp;quot;Obtained URL: &amp;quot; + body);&lt;br /&gt;
            requestURL = NULL_KEY;&lt;br /&gt;
        }&lt;br /&gt;
        else if ((method == URL_REQUEST_DENIED) &amp;amp;&amp;amp; (id == requestURL)) &lt;br /&gt;
        {&lt;br /&gt;
            // I could not obtain a URL&lt;br /&gt;
            llOwnerSay(&amp;quot;There was a problem, and an URL was not assigned: &amp;quot; + body);&lt;br /&gt;
            requestURL = NULL_KEY;&lt;br /&gt;
        }&lt;br /&gt;
&lt;br /&gt;
        else if (method == &amp;quot;POST&amp;quot;) &lt;br /&gt;
        {&lt;br /&gt;
            // An incoming message was received.&lt;br /&gt;
            llOwnerSay(&amp;quot;Received information from the outside: &amp;quot; + body);&lt;br /&gt;
            llHTTPResponse(id,200,&amp;quot;Thank you for calling. All of our operators are busy.&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
        else &lt;br /&gt;
        {&lt;br /&gt;
            // An incoming message has come in using a method that has not been anticipated.&lt;br /&gt;
            llHTTPResponse(id,405,&amp;quot;Unsupported Method&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Here is the Perl script to contact the prim on the grid.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;perl&amp;gt;&lt;br /&gt;
#!/usr/bin/perl&lt;br /&gt;
# Routine to contact a script on the SL Grid using http server&lt;br /&gt;
use strict;&lt;br /&gt;
use warnings;&lt;br /&gt;
use LWP;&lt;br /&gt;
&lt;br /&gt;
my $browser = LWP::UserAgent-&amp;gt;new;&lt;br /&gt;
&lt;br /&gt;
sub submitInformation) {&lt;br /&gt;
    my( $url, $params ) = @_;&lt;br /&gt;
    return $browser-&amp;gt;post( $url, $params )-&amp;gt;content;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# Set the URL manually....&lt;br /&gt;
my $url = &#039;http://sim3015.aditi.lindenlab.com:12046/cap/d57a7c8b-3ace-3186-730a-f22fde870d48&#039;;&lt;br /&gt;
&lt;br /&gt;
my $info = submitInformation( $url, {&lt;br /&gt;
    id   =&amp;gt; &#039;244195d6-c9b7-4fd6-9229-c3a8b2e60e81&#039;,&lt;br /&gt;
    name =&amp;gt; &#039;M Linden&#039;,&lt;br /&gt;
} );&lt;br /&gt;
&lt;br /&gt;
print $info,&amp;quot;\n&amp;quot;;&lt;br /&gt;
&amp;lt;/perl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Here is the Python code that does the same thing as the PERL code above.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;python&amp;gt;&lt;br /&gt;
#!/usr/bin/python&lt;br /&gt;
&lt;br /&gt;
import urllib&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
# #################################################&lt;br /&gt;
# Routine to send the information to the prim&lt;br /&gt;
#     submitInformation(url,information)&lt;br /&gt;
#&lt;br /&gt;
def submitInformation(url,parameters) :&lt;br /&gt;
    # Set the parameters to be sent.&lt;br /&gt;
    encodedParams =  urllib.urlencode(parameters);&lt;br /&gt;
&lt;br /&gt;
    # Post the data.&lt;br /&gt;
    net = urllib.urlopen(url,encodedParams);&lt;br /&gt;
&lt;br /&gt;
    # return the result.&lt;br /&gt;
    return(net.read());&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
if __name__ == &amp;quot;__main__&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
    # Set the URL manually&lt;br /&gt;
    url = &#039;http://sim3015.aditi.lindenlab.com:12046/cap/d57a7c8b-3ace-3186-730a-f22fde870d48&#039;;&lt;br /&gt;
&lt;br /&gt;
    # Define the parameters&lt;br /&gt;
    parameters = {&#039;id&#039;:&#039;244195d6-c9b7-4fd6-9229-c3a8b2e60e81&#039;,&lt;br /&gt;
                  &#039;name&#039;:&#039;M Linden&#039;}&lt;br /&gt;
&lt;br /&gt;
    # Pass the information along to the prim&lt;br /&gt;
    info = submitInformation(url,parameters);&lt;br /&gt;
    print(info);&lt;br /&gt;
&amp;lt;/python&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Perl/Python Examples Using POST With Argument Parsing ===&lt;br /&gt;
Here are a set of scripts to provide another example using POST. In this example the scripts are adapted to handle the parsing of the arguments that are passed. The first script is the LSL code to receive the information on the grid. The second script is a PERL script that is used on the outside server to contact the code on the grid. The third script is a Python script that is also used on the outside server to contact the code on the grid. ([[User:Grandma Bates|Grandma Bates]] 12:42, 27 May 2009 (UTC))&lt;br /&gt;
&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
key requestURL;&lt;br /&gt;
&lt;br /&gt;
// ###############################################&lt;br /&gt;
// Routine to parse a string sent through the &lt;br /&gt;
// http server via post.&lt;br /&gt;
//       parsePostData(theMessage)&lt;br /&gt;
// Returns a strided list with stride length 2.&lt;br /&gt;
// Each set has the key and then its value.&lt;br /&gt;
list parsePostData(string message) {&lt;br /&gt;
    list postData = [];         // The list with the data that was passed in.&lt;br /&gt;
    list parsedMessage = llParseString2List(message,[&amp;quot;&amp;amp;&amp;quot;],[]);    // The key/value pairs parsed into one list.&lt;br /&gt;
    integer len = ~llGetListLength(parsedMessage);&lt;br /&gt;
&lt;br /&gt;
    while(++len) {          &lt;br /&gt;
        string currentField = llList2String(parsedMessage, len); // Current key/value pair as a string.&lt;br /&gt;
&lt;br /&gt;
        integer split = llSubStringIndex(currentField,&amp;quot;=&amp;quot;);     // Find the &amp;quot;=&amp;quot; sign&lt;br /&gt;
        if(split == -1) { // There is only one field in this part of the message.&lt;br /&gt;
            postData += [llUnescapeURL(currentField),&amp;quot;&amp;quot;];  &lt;br /&gt;
        } else {&lt;br /&gt;
            postData += [llUnescapeURL(llDeleteSubString(currentField,split,-1)), llUnescapeURL(llDeleteSubString(currentField,0,split))];&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
    // Return the strided list.&lt;br /&gt;
    return postData ;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
default {&lt;br /&gt;
&lt;br /&gt;
    state_entry() {&lt;br /&gt;
        requestURL = llRequestURL(); // Request that an URL be assigned to me.&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    http_request(key id, string method, string body) {&lt;br /&gt;
         list incomingMessage;&lt;br /&gt;
        &lt;br /&gt;
        if ((method == URL_REQUEST_GRANTED) &amp;amp;&amp;amp; (id == requestURL) ){&lt;br /&gt;
            // An URL has been assigned to me.&lt;br /&gt;
            llOwnerSay(&amp;quot;Obtained URL: &amp;quot; + body);&lt;br /&gt;
            requestURL = NULL_KEY;&lt;br /&gt;
        }&lt;br /&gt;
        else if ((method == URL_REQUEST_DENIED) &amp;amp;&amp;amp; (id == requestURL)) {&lt;br /&gt;
            // I could not obtain a URL&lt;br /&gt;
            llOwnerSay(&amp;quot;There was a problem, and an URL was not assigned: &amp;quot; + &lt;br /&gt;
                       body);&lt;br /&gt;
            requestURL = NULL_KEY;&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == &amp;quot;POST&amp;quot;) {&lt;br /&gt;
            // An incoming message was received.&lt;br /&gt;
            llOwnerSay(&amp;quot;Received information form the outside: &amp;quot; + body);&lt;br /&gt;
            incomingMessage = parsePostData(body);&lt;br /&gt;
            llOwnerSay(llDumpList2String(incomingMessage,&amp;quot;\n&amp;quot;));&lt;br /&gt;
&lt;br /&gt;
            llHTTPResponse(id,200,&amp;quot;You passed the following:\n&amp;quot; + &lt;br /&gt;
                           llDumpList2String(incomingMessage,&amp;quot;\n&amp;quot;));&lt;br /&gt;
&lt;br /&gt;
        }&lt;br /&gt;
        else {&lt;br /&gt;
            // An incoming message has come in using a method that has&lt;br /&gt;
            // not been anticipated.&lt;br /&gt;
            llHTTPResponse(id,405,&amp;quot;Unsupported Method&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Here is the coresponding PERL script for contacting the LSL script on the grid.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;perl&amp;gt;&lt;br /&gt;
#!/usr/bin/perl&lt;br /&gt;
# Routine to contact a script on the SL Grid using http server&lt;br /&gt;
use strict;&lt;br /&gt;
use warnings;&lt;br /&gt;
&lt;br /&gt;
use LWP;&lt;br /&gt;
&lt;br /&gt;
my $browser = LWP::UserAgent-&amp;gt;new;&lt;br /&gt;
&lt;br /&gt;
sub submitInformation) {&lt;br /&gt;
    my( $url, $params ) = @_;&lt;br /&gt;
    return $browser-&amp;gt;post( $url, $params )-&amp;gt;content;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# Set the URL manually....&lt;br /&gt;
my $url = &#039;http://sim3015.aditi.lindenlab.com:12046/cap/5a1b89cd-e681-8110-7245-fb98969f32a0&#039;;&lt;br /&gt;
&lt;br /&gt;
my $info = submitInformation( $url, {&lt;br /&gt;
    &#039;action&#039; =&amp;gt; &#039;send message&#039;,&lt;br /&gt;
    &#039;value&#039;  =&amp;gt; &#039;Hi there chief!&#039;,&lt;br /&gt;
    &#039;id&#039;     =&amp;gt; &#039;244195d6-c9b7-4fd6-9229-c3a8b2e60e81&#039;,&lt;br /&gt;
    &#039;name&#039;   =&amp;gt; &#039;M Linden&#039;,&lt;br /&gt;
});&lt;br /&gt;
&lt;br /&gt;
print($info,&amp;quot;\n&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/perl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here is the coresponding Python script. It does the same thing as the Perl script above.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;python&amp;gt;&lt;br /&gt;
#!/usr/bin/python&lt;br /&gt;
&lt;br /&gt;
import urllib&lt;br /&gt;
import re&lt;br /&gt;
&lt;br /&gt;
# #################################################&lt;br /&gt;
# Routine to send the information to the prim&lt;br /&gt;
#     submitInformation(url,information)&lt;br /&gt;
#&lt;br /&gt;
def submitInformation(url,parameters) :&lt;br /&gt;
    &lt;br /&gt;
#    encodedParams =  urllib.urlencode(parameters);  # encode the parameters&lt;br /&gt;
    encodedParams  = dictionary2URI(parameters);    # encode the parameters&lt;br /&gt;
    net = urllib.urlopen(url,encodedParams);        # Post the data.&lt;br /&gt;
    return(net.read());                             # return the result.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
# ################################################&lt;br /&gt;
# Routine to encode a dictionary without using &lt;br /&gt;
# &amp;quot;+&amp;quot; for spaces.&lt;br /&gt;
#       dictionary2URI(theDictionary)&lt;br /&gt;
def dictionary2URI(theDictionary) : &lt;br /&gt;
&lt;br /&gt;
    encoded = &#039;&#039;;           # Initialize the string to return&lt;br /&gt;
    for key, value in theDictionary.iteritems():&lt;br /&gt;
        # Encode each item in the dictionary.&lt;br /&gt;
        encoded += urllib.quote(key)+&amp;quot;=&amp;quot;+urllib.quote(value)+&amp;quot;&amp;amp;&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
    remove = re.compile(&#039;&amp;amp;$&#039;)             # Remove the trailing ampersand.&lt;br /&gt;
    encoded = remove.sub(&#039;&#039;,encoded);&lt;br /&gt;
&lt;br /&gt;
    return(encoded);&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
if __name__ == &amp;quot;__main__&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
    # Set the URL manually&lt;br /&gt;
    url = &#039;http://sim3015.aditi.lindenlab.com:12046/cap/5a1b89cd-e681-8110-7245-fb98969f32a0&#039;;&lt;br /&gt;
&lt;br /&gt;
    # Define the parameters&lt;br /&gt;
    parameters = {&#039;id&#039;:&#039;244195d6-c9b7-4fd6-9229-c3a8b2e60e81&#039;,&lt;br /&gt;
                  &#039;name&#039;:&#039;M Linden&#039;,&lt;br /&gt;
                  &#039;action&#039;:&#039;send message&#039;,&lt;br /&gt;
                  &#039;value&#039;:&#039;Hey there, hi there, ho there!&#039;};&lt;br /&gt;
&lt;br /&gt;
    # Pass the information along to the prim&lt;br /&gt;
    info = submitInformation(url,parameters);&lt;br /&gt;
    print(info);&lt;br /&gt;
&amp;lt;/python&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;display:none;&amp;quot;&amp;gt;&amp;lt;lsl&amp;gt;&amp;lt;/lsl&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Simple script for sending data to an LSL via PHP ===&lt;br /&gt;
This example by Simba Fuhr &#039;&#039;&#039;UPDATE April 16, 2011&#039;&#039;&#039;&lt;br /&gt;
{{Warning|Some hosting providers only allow fsockopen on the standard 80 and 443 ports.  This script will not work on those providers. If your provider is willing to open some ports for you, HTTP-in uses port 12046, and HTTPS-in uses port 12043.}}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039;&lt;br /&gt;
To use SSL encrypted sockets, you need to have SSL activated on your server. If you run your own server, you need to import the ssl support to your server (apache =&amp;gt; apache.conf  +&amp;quot;LoadModule ssl_module modules/mod_ssl.so&amp;quot;)(normaly based on openssl).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Secure URL Request with LSL.&lt;br /&gt;
Script returns the URL to the chat. Please put the URL into the PHP below.&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
 state_entry()&lt;br /&gt;
 {&lt;br /&gt;
  llRequestSecureURL();&lt;br /&gt;
 }&lt;br /&gt;
 http_request(key id, string method, string body)&lt;br /&gt;
 {&lt;br /&gt;
  if ((method == URL_REQUEST_GRANTED))&lt;br /&gt;
  {&lt;br /&gt;
   llOwnerSay(&amp;quot;URL: &amp;quot; + body);&lt;br /&gt;
  }&lt;br /&gt;
  else if (method == &amp;quot;POST&amp;quot;)&lt;br /&gt;
  {&lt;br /&gt;
   llOwnerSay(&amp;quot;PHP script sent: {&amp;quot; + body + &amp;quot;}&amp;quot;);&lt;br /&gt;
   llHTTPResponse(id, 200, &amp;quot;PHP script sent: {&amp;quot; + body + &amp;quot;}&amp;quot;);&lt;br /&gt;
  }&lt;br /&gt;
 }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Here the PHP.&lt;br /&gt;
A more advanced php function which supports complete url structures and automatical GET and POST types.&lt;br /&gt;
Just don&#039;t submit any post Data to make a GET request.&lt;br /&gt;
The Function supports any kind of url as secure and not secure (https and http).&lt;br /&gt;
If you dont submit a port in the url, the default port for http (80) and https (443) will be used.&lt;br /&gt;
(An example is shown on the top of the script.)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;php&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
echo &amp;quot;LSL Script answered:&amp;lt;br&amp;gt;&amp;quot;;&lt;br /&gt;
echo Advanced_HTTP_Request(&amp;quot;https://sim20557.agni.lindenlab.com:12043/cap/5851e666-b0c6-f0a0-758a-9e8156765215&amp;quot;, &amp;quot;Hello script, how are you ?&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
function Advanced_HTTP_Request($Host, $PostData = &amp;quot;&amp;quot;)&lt;br /&gt;
{&lt;br /&gt;
 $Method = &amp;quot;POST&amp;quot;;&lt;br /&gt;
 if (empty($PostData))&lt;br /&gt;
  {$Method = &amp;quot;GET&amp;quot;;}&lt;br /&gt;
 $Port = 80;&lt;br /&gt;
 if (strtolower(substr($Host, 0, 5)) == &amp;quot;https&amp;quot;)&lt;br /&gt;
  {$Port = 443;}&lt;br /&gt;
 $Host = explode(&amp;quot;//&amp;quot;, $Host, 2);&lt;br /&gt;
 if (count($Host) &amp;lt; 2)&lt;br /&gt;
  {$Host[1] = $Host[0];}&lt;br /&gt;
 $Host = explode(&amp;quot;/&amp;quot;, $Host[1], 2);&lt;br /&gt;
 if ($Port == 443)&lt;br /&gt;
  {$SSLAdd = &amp;quot;ssl://&amp;quot;;}&lt;br /&gt;
 $Host[0] = explode(&amp;quot;:&amp;quot;, $Host[0]);&lt;br /&gt;
 if (count($Host[0]) &amp;gt; 1)&lt;br /&gt;
 {&lt;br /&gt;
  $Port = $Host[0][1];&lt;br /&gt;
  $Host[0] = $Host[0][0];&lt;br /&gt;
 }&lt;br /&gt;
 else&lt;br /&gt;
  {$Host[0] = $Host[0][0];}&lt;br /&gt;
 $Socket = fsockopen($SSLAdd.$Host[0], $Port, $Dummy1, $Dummy2, 10);&lt;br /&gt;
 if ($Socket)&lt;br /&gt;
 {&lt;br /&gt;
  fputs($Socket, &amp;quot;$Method /$Host[1] HTTP/1.1\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Host: $Host[0]\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Content-type: application/x-www-form-urlencoded\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;User-Agent: Opera/9.01 (Windows NT 5.1; U; en)\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Accept-Language: de-DE,de;q=0.9,en;q=0.8\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Accept-Charset: iso-8859-1, utf-8, utf-16, *;q=0.1\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Content-length: &amp;quot;.strlen($PostData).&amp;quot;\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Connection: close\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;\r\n&amp;quot;.&lt;br /&gt;
				 $PostData);&lt;br /&gt;
  $Tme = time();&lt;br /&gt;
  while(!feof($Socket) &amp;amp;&amp;amp; $Tme + 30 &amp;gt; time())&lt;br /&gt;
   {$Res = $Res.fgets($Socket, 256);}&lt;br /&gt;
  fclose($Socket);&lt;br /&gt;
 }&lt;br /&gt;
 $Res = explode(&amp;quot;\r\n\r\n&amp;quot;, $Res, 2);&lt;br /&gt;
 return $Res[1];&lt;br /&gt;
}&lt;br /&gt;
?&amp;gt;&lt;br /&gt;
&amp;lt;/php&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Kelly&#039;s Stupid Web Status Updater ===&lt;br /&gt;
Is actually on its own page: [[LSL_http_server/examples/kellys_stupid_web_status_updater | Kelly&#039;s Stupid Web Status Updater]]&amp;lt;br&amp;gt;&lt;br /&gt;
Kurai&#039;s mod from Kelly&#039;s stupid thing: [[LSL_http_server/examples/kurais_stupid_web_status_updater| Kurai&#039;s Stupid Web Status Updater Mod]]&lt;br /&gt;
{{LSLC|HTTP}}{{LSLC|Examples}}&lt;br /&gt;
&lt;br /&gt;
=== Web-based dynamic buildings ===&lt;br /&gt;
HTTP-in may be used to easily send commands from a web page to an in-world object, so that web users can control and interact with buildings. The interactive installation &#039;&#039;Chromutate&#039;&#039; is based upon this idea: see its [[User:Opensource_Obscure/Chromutate|documentation page]] for free scripts and more details.&lt;br /&gt;
&lt;br /&gt;
=== PHP/SQL Object DNS ===&lt;br /&gt;
Simple DNS server written in PHP to facilitate a DNS service for LSL scripts&lt;br /&gt;
[[LSL_http_server/examples/phpdns|PHPDNS]]&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=LSL_HTTP_server/examples&amp;diff=1169111</id>
		<title>LSL HTTP server/examples</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=LSL_HTTP_server/examples&amp;diff=1169111"/>
		<updated>2012-06-13T23:48:34Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: /* Perl/Python Examples Using POST */  Fixed some formatting&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{LSL Header|ml=*}}&lt;br /&gt;
=== Utility Script ===&lt;br /&gt;
A script intended as a &#039;fill in the blank&#039; exercise for very, very simple HTTP servers is here: [[LSL_http_server/examples/utility_script | Utility Script]]&lt;br /&gt;
=== Hello World! ===&lt;br /&gt;
Classic example, the smallest http_request script possible.&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
    state_entry()&lt;br /&gt;
    {&lt;br /&gt;
        llRequestURL();&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    http_request(key id, string method, string body)&lt;br /&gt;
    {&lt;br /&gt;
        if (method == URL_REQUEST_GRANTED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0,&amp;quot;URL: &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == &amp;quot;GET&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            llHTTPResponse(id,200,&amp;quot;Hello World!&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
A slightly more robust version:&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
    state_entry()&lt;br /&gt;
    {&lt;br /&gt;
        llRequestURL();&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    http_request(key id, string method, string body)&lt;br /&gt;
    {&lt;br /&gt;
        if (method == URL_REQUEST_GRANTED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0,&amp;quot;URL: &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == URL_REQUEST_DENIED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0, &amp;quot;Something went wrong, no url. &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == &amp;quot;GET&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            llHTTPResponse(id,200,&amp;quot;Hello World!&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
        else&lt;br /&gt;
        {&lt;br /&gt;
            llHTTPResponse(id,405,&amp;quot;Unsupported Method&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Echo World ===&lt;br /&gt;
&amp;quot;Echo World ([[User:Byrd Sciavo|Byrd Sciavo]] 04:19, 7 October 2009 (UTC))&amp;quot; is a slightly more useful &amp;quot;Hello World&amp;quot;, demonstrating a basic server that echos back dynamic data fed. Echo World shows how http_request receives GET variables. To receive this &amp;quot;dynamic echo&amp;quot;, append your cap url with a query string, such as https://sim3015.aditi.lindenlab.com:12043/cap/a7717681-2c04-e4ac-35e3-1f01c9861322/foo/bar?arg=gra&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
string url;&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
    state_entry(){&lt;br /&gt;
        llRequestURL();&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    http_request(key id, string method, string body){    &lt;br /&gt;
        if (method == URL_REQUEST_GRANTED) {&lt;br /&gt;
            url=body;llOwnerSay(url);&lt;br /&gt;
        }else if(method==&amp;quot;GET&amp;quot;){&lt;br /&gt;
              if(llGetHTTPHeader(id,&amp;quot;x-query-string&amp;quot;)==&amp;quot;&amp;quot;) llHTTPResponse(id,200,&amp;quot;I ECHO when you append some GET variables to me, e.g., /?var=foo&amp;quot;);&lt;br /&gt;
              else llHTTPResponse(id,200,llGetHTTPHeader(id,&amp;quot;x-query-string&amp;quot;));&lt;br /&gt;
        }        &lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Visitor List ===&lt;br /&gt;
A list of residents within sensor range of the server.&lt;br /&gt;
&amp;lt;br&amp;gt;Notes:&lt;br /&gt;
* This includes a method for handling multiple requests while waiting for asynchronous data requests to come back.&lt;br /&gt;
&amp;lt;lsl&amp;gt;integer scanning = FALSE;&lt;br /&gt;
&lt;br /&gt;
list requests;&lt;br /&gt;
&lt;br /&gt;
send_response(string body)&lt;br /&gt;
{&lt;br /&gt;
    integer j;&lt;br /&gt;
    for (j = 0; j &amp;lt; llGetListLength(requests); ++j)&lt;br /&gt;
    {&lt;br /&gt;
        llHTTPResponse(llList2Key(requests,j), 200, body);&lt;br /&gt;
    }&lt;br /&gt;
    requests = [];&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
    state_entry()&lt;br /&gt;
    {&lt;br /&gt;
        llRequestURL();&lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    http_request(key id, string method, string body)&lt;br /&gt;
    {&lt;br /&gt;
        if (method == URL_REQUEST_GRANTED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0,&amp;quot;URL: &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == URL_REQUEST_DENIED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0, &amp;quot;Something went wrong, no url. &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == &amp;quot;GET&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            if (!scanning)&lt;br /&gt;
            {&lt;br /&gt;
                llSensor(&amp;quot;&amp;quot;,NULL_KEY,AGENT,96,PI);&lt;br /&gt;
                scanning = TRUE;&lt;br /&gt;
            }&lt;br /&gt;
            &lt;br /&gt;
            requests += [id];&lt;br /&gt;
        }&lt;br /&gt;
        else&lt;br /&gt;
        {&lt;br /&gt;
            llHTTPResponse(id,405,&amp;quot;Unsupported method.&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    no_sensor()&lt;br /&gt;
    {&lt;br /&gt;
        send_response(&amp;quot;There is no one here.&amp;quot;);&lt;br /&gt;
        scanning = FALSE;&lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    sensor(integer n)&lt;br /&gt;
    {&lt;br /&gt;
        string output;&lt;br /&gt;
        if (n &amp;lt; 16) output = &amp;quot;There are &amp;quot; + (string)n + &amp;quot; avatars nearby:&amp;quot;;&lt;br /&gt;
        else output = &amp;quot;There are at least 16 avatars nearby:&amp;quot;;&lt;br /&gt;
        &lt;br /&gt;
        integer i;&lt;br /&gt;
        for (i = 0;i&amp;lt;n;++i)&lt;br /&gt;
        {&lt;br /&gt;
            output += &amp;quot;\n\t&amp;quot; + llDetectedName(i);&lt;br /&gt;
        }&lt;br /&gt;
        &lt;br /&gt;
        send_response(output);&lt;br /&gt;
&lt;br /&gt;
        scanning = FALSE;&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Url Persistence / Visitor Counter ===&lt;br /&gt;
A more complete &#039;hello world&#039;, always has an url and keeps a visitor counter.&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
string url;&lt;br /&gt;
integer hits;&lt;br /&gt;
&lt;br /&gt;
setup()&lt;br /&gt;
{&lt;br /&gt;
    llSetObjectName(&amp;quot;HTTP Server&amp;quot;);&lt;br /&gt;
    url = &amp;quot;&amp;quot;;&lt;br /&gt;
    llRequestURL();&lt;br /&gt;
    hits = (integer)llGetObjectDesc();&lt;br /&gt;
    llSetText((string)hits + &amp;quot; visitors.&amp;quot;,&amp;lt;1,1,0&amp;gt;,1);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
    state_entry() { setup(); }&lt;br /&gt;
    on_rez(integer n) { setup(); }&lt;br /&gt;
    &lt;br /&gt;
    changed(integer c)&lt;br /&gt;
    {&lt;br /&gt;
        if (c &amp;amp; (CHANGED_REGION | CHANGED_REGION_START | CHANGED_TELEPORT) )&lt;br /&gt;
        {&lt;br /&gt;
            setup();&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    touch_start(integer n)&lt;br /&gt;
    {&lt;br /&gt;
        llSay(0,&amp;quot;My url is: &amp;quot; + url);&lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    http_request(key id, string method, string body)&lt;br /&gt;
    {&lt;br /&gt;
        if (method == URL_REQUEST_GRANTED)&lt;br /&gt;
        {&lt;br /&gt;
            url = body;&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == URL_REQUEST_DENIED)&lt;br /&gt;
        {&lt;br /&gt;
            llSay(0, &amp;quot;Something went wrong, no url. &amp;quot; + body);&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == &amp;quot;GET&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            ++hits;&lt;br /&gt;
            llSetObjectDesc((string)hits);&lt;br /&gt;
            llSetText((string)hits + &amp;quot; visitors.&amp;quot;,&amp;lt;1,1,0&amp;gt;,1);&lt;br /&gt;
            llHTTPResponse(id,200,&amp;quot;Hello!  You are visitor &amp;quot; + (string)hits + &amp;quot;.&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
        else&lt;br /&gt;
        {&lt;br /&gt;
            llHTTPResponse(id,405,&amp;quot;Method unsupported&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Perl/Python Examples Using POST ===&lt;br /&gt;
Here are a set of scripts to provide another example using POST. The first script is the LSL code to receive the information on the grid. The second script is a Perl script that is used on the outside server to contact the code on the grid. The third script is a Python script that is also used on the outside server to contact the code on the grid.  ([[User:Grandma Bates|Grandma Bates]] 12:42, 27 May 2009 (UTC))&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
key requestURL;&lt;br /&gt;
&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
    state_entry() &lt;br /&gt;
    {&lt;br /&gt;
        requestURL = llRequestURL();     // Request that an URL be assigned to me.&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
     http_request(key id, string method, string body) &lt;br /&gt;
     {&lt;br /&gt;
        if ((method == URL_REQUEST_GRANTED) &amp;amp;&amp;amp; (id == requestURL) )&lt;br /&gt;
        {&lt;br /&gt;
            // An URL has been assigned to me.&lt;br /&gt;
            llOwnerSay(&amp;quot;Obtained URL: &amp;quot; + body);&lt;br /&gt;
            requestURL = NULL_KEY;&lt;br /&gt;
        }&lt;br /&gt;
        else if ((method == URL_REQUEST_DENIED) &amp;amp;&amp;amp; (id == requestURL)) &lt;br /&gt;
        {&lt;br /&gt;
            // I could not obtain a URL&lt;br /&gt;
            llOwnerSay(&amp;quot;There was a problem, and an URL was not assigned: &amp;quot; + body);&lt;br /&gt;
            requestURL = NULL_KEY;&lt;br /&gt;
        }&lt;br /&gt;
&lt;br /&gt;
        else if (method == &amp;quot;POST&amp;quot;) &lt;br /&gt;
        {&lt;br /&gt;
            // An incoming message was received.&lt;br /&gt;
            llOwnerSay(&amp;quot;Received information from the outside: &amp;quot; + body);&lt;br /&gt;
            llHTTPResponse(id,200,&amp;quot;Thank you for calling. All of our operators are busy.&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
        else &lt;br /&gt;
        {&lt;br /&gt;
            // An incoming message has come in using a method that has not been anticipated.&lt;br /&gt;
            llHTTPResponse(id,405,&amp;quot;Unsupported Method&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Here is the Perl script to contact the prim on the grid.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;perl&amp;gt;&lt;br /&gt;
#!/usr/bin/perl&lt;br /&gt;
# Routine to contact a script on the SL Grid using http server&lt;br /&gt;
use strict;&lt;br /&gt;
use warnings;&lt;br /&gt;
use LWP;&lt;br /&gt;
&lt;br /&gt;
my $browser = LWP::UserAgent-&amp;gt;new;&lt;br /&gt;
&lt;br /&gt;
sub submitInformation) {&lt;br /&gt;
    my( $url, $params ) = @_;&lt;br /&gt;
    return $browser-&amp;gt;post( $url, $params )-&amp;gt;content;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# Set the URL manually....&lt;br /&gt;
my $url = &#039;http://sim3015.aditi.lindenlab.com:12046/cap/d57a7c8b-3ace-3186-730a-f22fde870d48&#039;;&lt;br /&gt;
&lt;br /&gt;
my $info = submitInformation( $url, {&lt;br /&gt;
    id   =&amp;gt; &#039;244195d6-c9b7-4fd6-9229-c3a8b2e60e81&#039;,&lt;br /&gt;
    name =&amp;gt; &#039;M Linden&#039;,&lt;br /&gt;
} );&lt;br /&gt;
&lt;br /&gt;
print $info,&amp;quot;\n&amp;quot;;&lt;br /&gt;
&amp;lt;/perl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Here is the Python code that does the same thing as the PERL code above.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;python&amp;gt;&lt;br /&gt;
#!/usr/bin/python&lt;br /&gt;
&lt;br /&gt;
import urllib&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
# #################################################&lt;br /&gt;
# Routine to send the information to the prim&lt;br /&gt;
#     submitInformation(url,information)&lt;br /&gt;
#&lt;br /&gt;
def submitInformation(url,parameters) :&lt;br /&gt;
    # Set the parameters to be sent.&lt;br /&gt;
    encodedParams =  urllib.urlencode(parameters);&lt;br /&gt;
&lt;br /&gt;
    # Post the data.&lt;br /&gt;
    net = urllib.urlopen(url,encodedParams);&lt;br /&gt;
&lt;br /&gt;
    # return the result.&lt;br /&gt;
    return(net.read());&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
if __name__ == &amp;quot;__main__&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
    # Set the URL manually&lt;br /&gt;
    url = &#039;http://sim3015.aditi.lindenlab.com:12046/cap/d57a7c8b-3ace-3186-730a-f22fde870d48&#039;;&lt;br /&gt;
&lt;br /&gt;
    # Define the parameters&lt;br /&gt;
    parameters = {&#039;id&#039;:&#039;244195d6-c9b7-4fd6-9229-c3a8b2e60e81&#039;,&lt;br /&gt;
                  &#039;name&#039;:&#039;M Linden&#039;}&lt;br /&gt;
&lt;br /&gt;
    # Pass the information along to the prim&lt;br /&gt;
    info = submitInformation(url,parameters);&lt;br /&gt;
    print(info);&lt;br /&gt;
&amp;lt;/python&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Perl/Python Examples Using POST With Argument Parsing ===&lt;br /&gt;
Here are a set of scripts to provide another example using POST. In this example the scripts are adapted to handle the parsing of the arguments that are passed. The first script is the LSL code to receive the information on the grid. The second script is a PERL script that is used on the outside server to contact the code on the grid. The third script is a Python script that is also used on the outside server to contact the code on the grid. ([[User:Grandma Bates|Grandma Bates]] 12:42, 27 May 2009 (UTC))&lt;br /&gt;
&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
key requestURL;&lt;br /&gt;
&lt;br /&gt;
// ###############################################&lt;br /&gt;
// Routine to parse a string sent through the &lt;br /&gt;
// http server via post.&lt;br /&gt;
//       parsePostData(theMessage)&lt;br /&gt;
// Returns a strided list with stride length 2.&lt;br /&gt;
// Each set has the key and then its value.&lt;br /&gt;
list parsePostData(string message) {&lt;br /&gt;
    list postData = [];         // The list with the data that was passed in.&lt;br /&gt;
    list parsedMessage = llParseString2List(message,[&amp;quot;&amp;amp;&amp;quot;],[]);    // The key/value pairs parsed into one list.&lt;br /&gt;
    integer len = ~llGetListLength(parsedMessage);&lt;br /&gt;
&lt;br /&gt;
    while(++len) {          &lt;br /&gt;
        string currentField = llList2String(parsedMessage, len); // Current key/value pair as a string.&lt;br /&gt;
&lt;br /&gt;
        integer split = llSubStringIndex(currentField,&amp;quot;=&amp;quot;);     // Find the &amp;quot;=&amp;quot; sign&lt;br /&gt;
        if(split == -1) { // There is only one field in this part of the message.&lt;br /&gt;
            postData += [llUnescapeURL(currentField),&amp;quot;&amp;quot;];  &lt;br /&gt;
        } else {&lt;br /&gt;
            postData += [llUnescapeURL(llDeleteSubString(currentField,split,-1)), llUnescapeURL(llDeleteSubString(currentField,0,split))];&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
    // Return the strided list.&lt;br /&gt;
    return postData ;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
default {&lt;br /&gt;
&lt;br /&gt;
    state_entry() {&lt;br /&gt;
        requestURL = llRequestURL(); // Request that an URL be assigned to me.&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    http_request(key id, string method, string body) {&lt;br /&gt;
         list incomingMessage;&lt;br /&gt;
        &lt;br /&gt;
        if ((method == URL_REQUEST_GRANTED) &amp;amp;&amp;amp; (id == requestURL) ){&lt;br /&gt;
            // An URL has been assigned to me.&lt;br /&gt;
            llOwnerSay(&amp;quot;Obtained URL: &amp;quot; + body);&lt;br /&gt;
            requestURL = NULL_KEY;&lt;br /&gt;
        }&lt;br /&gt;
        else if ((method == URL_REQUEST_DENIED) &amp;amp;&amp;amp; (id == requestURL)) {&lt;br /&gt;
            // I could not obtain a URL&lt;br /&gt;
            llOwnerSay(&amp;quot;There was a problem, and an URL was not assigned: &amp;quot; + &lt;br /&gt;
                       body);&lt;br /&gt;
            requestURL = NULL_KEY;&lt;br /&gt;
        }&lt;br /&gt;
        else if (method == &amp;quot;POST&amp;quot;) {&lt;br /&gt;
            // An incoming message was received.&lt;br /&gt;
            llOwnerSay(&amp;quot;Received information form the outside: &amp;quot; + body);&lt;br /&gt;
            incomingMessage = parsePostData(body);&lt;br /&gt;
            llOwnerSay(llDumpList2String(incomingMessage,&amp;quot;\n&amp;quot;));&lt;br /&gt;
&lt;br /&gt;
            llHTTPResponse(id,200,&amp;quot;You passed the following:\n&amp;quot; + &lt;br /&gt;
                           llDumpList2String(incomingMessage,&amp;quot;\n&amp;quot;));&lt;br /&gt;
&lt;br /&gt;
        }&lt;br /&gt;
        else {&lt;br /&gt;
            // An incoming message has come in using a method that has&lt;br /&gt;
            // not been anticipated.&lt;br /&gt;
            llHTTPResponse(id,405,&amp;quot;Unsupported Method&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Here is the coresponding PERL script for contacting the LSL script on the grid.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;perl&amp;gt;&lt;br /&gt;
#!/usr/bin/perl&lt;br /&gt;
# Routine to contact a script on the SL Grid using http server&lt;br /&gt;
use strict;&lt;br /&gt;
use warnings;&lt;br /&gt;
&lt;br /&gt;
use LWP;&lt;br /&gt;
&lt;br /&gt;
my $browser = LWP::UserAgent-&amp;gt;new;&lt;br /&gt;
&lt;br /&gt;
sub submitInformation) {&lt;br /&gt;
    my( $url, $params ) = @_;&lt;br /&gt;
    return $browser-&amp;gt;post( $url, $params )-&amp;gt;content;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# Set the URL manually....&lt;br /&gt;
my $url = &#039;http://sim3015.aditi.lindenlab.com:12046/cap/5a1b89cd-e681-8110-7245-fb98969f32a0&#039;;&lt;br /&gt;
&lt;br /&gt;
my $info = submitInformation( $url, {&lt;br /&gt;
    &#039;action&#039; =&amp;gt; &#039;send message&#039;,&lt;br /&gt;
    &#039;value&#039;  =&amp;gt; &#039;Hi there chief!&#039;,&lt;br /&gt;
    &#039;id&#039;     =&amp;gt; &#039;244195d6-c9b7-4fd6-9229-c3a8b2e60e81&#039;,&lt;br /&gt;
    &#039;name&#039;   =&amp;gt; &#039;M Linden&#039;,&lt;br /&gt;
});&lt;br /&gt;
&lt;br /&gt;
print($info,&amp;quot;\n&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/perl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here is the coresponding Python script. It does the same thing as the Perl script above.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;python&amp;gt;&lt;br /&gt;
#!/usr/bin/python&lt;br /&gt;
&lt;br /&gt;
import urllib&lt;br /&gt;
import re&lt;br /&gt;
&lt;br /&gt;
# #################################################&lt;br /&gt;
# Routine to send the information to the prim&lt;br /&gt;
#     submitInformation(url,information)&lt;br /&gt;
#&lt;br /&gt;
def submitInformation(url,parameters) :&lt;br /&gt;
    &lt;br /&gt;
#    encodedParams =  urllib.urlencode(parameters);  # encode the parameters&lt;br /&gt;
    encodedParams  = dictionary2URI(parameters);    # encode the parameters&lt;br /&gt;
    net = urllib.urlopen(url,encodedParams);        # Post the data.&lt;br /&gt;
    return(net.read());                             # return the result.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
# ################################################&lt;br /&gt;
# Routine to encode a dictionary without using &lt;br /&gt;
# &amp;quot;+&amp;quot; for spaces.&lt;br /&gt;
#       dictionary2URI(theDictionary)&lt;br /&gt;
def dictionary2URI(theDictionary) : &lt;br /&gt;
&lt;br /&gt;
    encoded = &#039;&#039;;           # Initialize the string to return&lt;br /&gt;
    for key, value in theDictionary.iteritems():&lt;br /&gt;
        # Encode each item in the dictionary.&lt;br /&gt;
        encoded += urllib.quote(key)+&amp;quot;=&amp;quot;+urllib.quote(value)+&amp;quot;&amp;amp;&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
    remove = re.compile(&#039;&amp;amp;$&#039;)             # Remove the trailing ampersand.&lt;br /&gt;
    encoded = remove.sub(&#039;&#039;,encoded);&lt;br /&gt;
&lt;br /&gt;
    return(encoded);&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
if __name__ == &amp;quot;__main__&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
    # Set the URL manually&lt;br /&gt;
    url = &#039;http://sim3015.aditi.lindenlab.com:12046/cap/5a1b89cd-e681-8110-7245-fb98969f32a0&#039;;&lt;br /&gt;
&lt;br /&gt;
    # Define the parameters&lt;br /&gt;
    parameters = {&#039;id&#039;:&#039;244195d6-c9b7-4fd6-9229-c3a8b2e60e81&#039;,&lt;br /&gt;
                  &#039;name&#039;:&#039;M Linden&#039;,&lt;br /&gt;
                  &#039;action&#039;:&#039;send message&#039;,&lt;br /&gt;
                  &#039;value&#039;:&#039;Hey there, hi there, ho there!&#039;};&lt;br /&gt;
&lt;br /&gt;
    # Pass the information along to the prim&lt;br /&gt;
    info = submitInformation(url,parameters);&lt;br /&gt;
    print(info);&lt;br /&gt;
&amp;lt;/python&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;display:none;&amp;quot;&amp;gt;&amp;lt;lsl&amp;gt;&amp;lt;/lsl&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Simple script for sending data to an LSL via PHP ===&lt;br /&gt;
This example by Simba Fuhr &#039;&#039;&#039;UPDATE April 16, 2011&#039;&#039;&#039;&lt;br /&gt;
{{Warning|Some hosting providers only allow fsockopen on the standard 80 and 443 ports.  This script will not work on those providers. If your provider is willing to open some ports for you, HTTP-in uses port 12046, and HTTPS-in uses port 12043.}}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039;&lt;br /&gt;
To use SSL encrypted sockets, you need to have SSL activated on your server. If you run your own server, you need to import the ssl support to your server (apache =&amp;gt; apache.conf  +&amp;quot;LoadModule ssl_module modules/mod_ssl.so&amp;quot;)(normaly based on openssl).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Secure URL Request with LSL.&lt;br /&gt;
Script returns the URL to the chat. Please put the URL into the PHP below.&lt;br /&gt;
&amp;lt;lsl&amp;gt;&lt;br /&gt;
default&lt;br /&gt;
{&lt;br /&gt;
 state_entry()&lt;br /&gt;
 {&lt;br /&gt;
  llRequestSecureURL();&lt;br /&gt;
 }&lt;br /&gt;
 http_request(key id, string method, string body)&lt;br /&gt;
 {&lt;br /&gt;
  if ((method == URL_REQUEST_GRANTED))&lt;br /&gt;
  {&lt;br /&gt;
   llOwnerSay(&amp;quot;URL: &amp;quot; + body);&lt;br /&gt;
  }&lt;br /&gt;
  else if (method == &amp;quot;POST&amp;quot;)&lt;br /&gt;
  {&lt;br /&gt;
   llOwnerSay(&amp;quot;PHP script sent: {&amp;quot; + body + &amp;quot;}&amp;quot;);&lt;br /&gt;
   llHTTPResponse(id, 200, &amp;quot;PHP script sent: {&amp;quot; + body + &amp;quot;}&amp;quot;);&lt;br /&gt;
  }&lt;br /&gt;
 }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/lsl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Here the PHP.&lt;br /&gt;
A more advanced php function which supports complete url structures and automatical GET and POST types.&lt;br /&gt;
Just don&#039;t submit any post Data to make a GET request.&lt;br /&gt;
The Function supports any kind of url as secure and not secure (https and http).&lt;br /&gt;
If you dont submit a port in the url, the default port for http (80) and https (443) will be used.&lt;br /&gt;
(An example is shown on the top of the script.)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;php&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
echo &amp;quot;LSL Script answered:&amp;lt;br&amp;gt;&amp;quot;;&lt;br /&gt;
echo Advanced_HTTP_Request(&amp;quot;https://sim20557.agni.lindenlab.com:12043/cap/5851e666-b0c6-f0a0-758a-9e8156765215&amp;quot;, &amp;quot;Hello script, how are you ?&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
function Advanced_HTTP_Request($Host, $PostData = &amp;quot;&amp;quot;)&lt;br /&gt;
{&lt;br /&gt;
 $Method = &amp;quot;POST&amp;quot;;&lt;br /&gt;
 if (empty($PostData))&lt;br /&gt;
  {$Method = &amp;quot;GET&amp;quot;;}&lt;br /&gt;
 $Port = 80;&lt;br /&gt;
 if (strtolower(substr($Host, 0, 5)) == &amp;quot;https&amp;quot;)&lt;br /&gt;
  {$Port = 443;}&lt;br /&gt;
 $Host = explode(&amp;quot;//&amp;quot;, $Host, 2);&lt;br /&gt;
 if (count($Host) &amp;lt; 2)&lt;br /&gt;
  {$Host[1] = $Host[0];}&lt;br /&gt;
 $Host = explode(&amp;quot;/&amp;quot;, $Host[1], 2);&lt;br /&gt;
 if ($Port == 443)&lt;br /&gt;
  {$SSLAdd = &amp;quot;ssl://&amp;quot;;}&lt;br /&gt;
 $Host[0] = explode(&amp;quot;:&amp;quot;, $Host[0]);&lt;br /&gt;
 if (count($Host[0]) &amp;gt; 1)&lt;br /&gt;
 {&lt;br /&gt;
  $Port = $Host[0][1];&lt;br /&gt;
  $Host[0] = $Host[0][0];&lt;br /&gt;
 }&lt;br /&gt;
 else&lt;br /&gt;
  {$Host[0] = $Host[0][0];}&lt;br /&gt;
 $Socket = fsockopen($SSLAdd.$Host[0], $Port, $Dummy1, $Dummy2, 10);&lt;br /&gt;
 if ($Socket)&lt;br /&gt;
 {&lt;br /&gt;
  fputs($Socket, &amp;quot;$Method /$Host[1] HTTP/1.1\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Host: $Host[0]\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Content-type: application/x-www-form-urlencoded\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;User-Agent: Opera/9.01 (Windows NT 5.1; U; en)\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Accept-Language: de-DE,de;q=0.9,en;q=0.8\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Accept-Charset: iso-8859-1, utf-8, utf-16, *;q=0.1\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Content-length: &amp;quot;.strlen($PostData).&amp;quot;\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;Connection: close\r\n&amp;quot;.&lt;br /&gt;
				 &amp;quot;\r\n&amp;quot;.&lt;br /&gt;
				 $PostData);&lt;br /&gt;
  $Tme = time();&lt;br /&gt;
  while(!feof($Socket) &amp;amp;&amp;amp; $Tme + 30 &amp;gt; time())&lt;br /&gt;
   {$Res = $Res.fgets($Socket, 256);}&lt;br /&gt;
  fclose($Socket);&lt;br /&gt;
 }&lt;br /&gt;
 $Res = explode(&amp;quot;\r\n\r\n&amp;quot;, $Res, 2);&lt;br /&gt;
 return $Res[1];&lt;br /&gt;
}&lt;br /&gt;
?&amp;gt;&lt;br /&gt;
&amp;lt;/php&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Kelly&#039;s Stupid Web Status Updater ===&lt;br /&gt;
Is actually on its own page: [[LSL_http_server/examples/kellys_stupid_web_status_updater | Kelly&#039;s Stupid Web Status Updater]]&amp;lt;br&amp;gt;&lt;br /&gt;
Kurai&#039;s mod from Kelly&#039;s stupid thing: [[LSL_http_server/examples/kurais_stupid_web_status_updater| Kurai&#039;s Stupid Web Status Updater Mod]]&lt;br /&gt;
{{LSLC|HTTP}}{{LSLC|Examples}}&lt;br /&gt;
&lt;br /&gt;
=== Web-based dynamic buildings ===&lt;br /&gt;
HTTP-in may be used to easily send commands from a web page to an in-world object, so that web users can control and interact with buildings. The interactive installation &#039;&#039;Chromutate&#039;&#039; is based upon this idea: see its [[User:Opensource_Obscure/Chromutate|documentation page]] for free scripts and more details.&lt;br /&gt;
&lt;br /&gt;
=== PHP/SQL Object DNS ===&lt;br /&gt;
Simple DNS server written in PHP to facilitate a DNS service for LSL scripts&lt;br /&gt;
[[LSL_http_server/examples/phpdns|PHPDNS]]&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
	<entry>
		<id>https://wiki.secondlife.com/w/index.php?title=Limits&amp;diff=1164167</id>
		<title>Limits</title>
		<link rel="alternate" type="text/html" href="https://wiki.secondlife.com/w/index.php?title=Limits&amp;diff=1164167"/>
		<updated>2012-03-18T04:16:25Z</updated>

		<summary type="html">&lt;p&gt;Techplex Engineer: /* All Viewers */ added a note about bytes and characters&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;noinclude&amp;gt;{{KBmaster}}&amp;lt;/noinclude&amp;gt;&lt;br /&gt;
== Summary ==&lt;br /&gt;
{{RightToc}}&lt;br /&gt;
The Second Life Viewer and simulators have a division of labor, keeping track of the data that makes Second Life run. The Viewer&#039;s job is to:&lt;br /&gt;
&lt;br /&gt;
* Handle locations of objects.&lt;br /&gt;
* Get velocities and other physics information, and does simple physics to keep track of what is moving where.&lt;br /&gt;
&lt;br /&gt;
The simulator&#039;s job is to:&lt;br /&gt;
&lt;br /&gt;
* Run the physics engine.&lt;br /&gt;
* Detect collisions.&lt;br /&gt;
* Keep track of where everything is&lt;br /&gt;
* Send locations of content to the Viewer along with updates when certain changes occur.&lt;br /&gt;
&lt;br /&gt;
Limits are necessary for all of these components to work together. The list below outlines many of the &#039;&#039;&#039;Second Life numerical limits that affect your inworld experience&#039;&#039;&#039;. Some of these will likely change over time, so if you spot something incorrect/outdated, please take a moment to update it.&lt;br /&gt;
&lt;br /&gt;
{{KBcaution|1=The scope of this page is focused on Linden Lab&#039;s official Viewers, keeping in mind [[Third_Party_Viewer_Directory|3rd-party viewers may differ]]. Cite sources and provide substantiation for limits that aren&#039;t provided by Linden Lab. Also, unconfirmed speculation [[Talk:Limits|goes on this discussion page]]. Don&#039;t add data without a hard limit, and don&#039;t add obscure trivia that doesn&#039;t practically affect the general inworld experience.}}&lt;br /&gt;
&lt;br /&gt;
== [[Avatar]] ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Max. # of attachment points&#039;&#039;&#039; - 30 for avatar, 8 for [[HUD]].&lt;br /&gt;
** They can be viewed by right-clicking your avatar and choosing &#039;&#039;&#039;Take Off&#039;&#039;&#039; &amp;gt; &#039;&#039;&#039;HUD&#039;&#039;&#039; or &#039;&#039;&#039;Detach&#039;&#039;&#039;.&lt;br /&gt;
** With the formal introduction of [[multiple attachments|multiple attachments to a single point]] in Viewer 2.4, you can attach up to 38 total objects, and they can all be attached to a single point. &lt;br /&gt;
* &#039;&#039;&#039;Max. unassisted fly height&#039;&#039;&#039; - Stable hover almost 150m above the ground (terrain mesh).&lt;br /&gt;
** You can easily acquire a flight attachment to fly high. Also see [[flight limit]] and [[Limits#Navigation|the Navigation section]] below.&lt;br /&gt;
* &#039;&#039;&#039;Common shoe sizes&#039;&#039;&#039; - Most women&#039;s shoes are designed for a size 0 (zero) foot. Men&#039;s generally scale up to 14.&lt;br /&gt;
** You can check this by going to Edit menu &amp;gt; Appearance and clicking on the Shape &amp;gt; Legs tab.&lt;br /&gt;
&amp;lt;!--Can someone verify the following?&lt;br /&gt;
* &#039;&#039;&#039;Min. length of avatar name&#039;&#039;&#039; - 2 for first name, 2 for last name, 5 in total (including the space).--&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;Max. length of avatar name&#039;&#039;&#039; - 31 for first name, 31 for last name, 63 in total (including the space).&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Max. length of {{LSLGC|Username}}&#039;&#039;&#039; - All lower case and a maximum of 63 including the &#039;.&#039;(eg; firstname.lastname)&lt;br /&gt;
**Older account user names are a combination of the First and last name in lower case separated by a period(.)(eg; lilmix.pixelmaid)&lt;br /&gt;
**Modern user names are a single name(no period)(eg; john1234) - &#039;&#039;&#039;Max.&#039;&#039;&#039; length is 31 characters&lt;br /&gt;
**The {{LSLGC|Legacy Name}}s for modern user names always shows Resident as the last name. So the Max is 40 characters in total for a new avatar&#039;s legacy name(including the space and last name &#039;Resident&#039;)&lt;br /&gt;
*&#039;&#039;&#039;Min. length of [[Display_Names]]&#039;&#039;&#039; - At least one script character&lt;br /&gt;
*&#039;&#039;&#039;Max. length of Display Names&#039;&#039;&#039; - 31 characters&lt;br /&gt;
**Display Names can include most Unicode script characters, spaces, and some punctuation.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Max. avatar speed&#039;&#039;&#039; - 250m/s (with only attachments to assist)&lt;br /&gt;
* &#039;&#039;&#039;Max. teleport speed&#039;&#039;&#039;&amp;lt;!-- - 3 teleports per 15 seconds (server 1.27.0) and 10 teleports per 15 seconds (server 1.27.1)--&amp;gt;&lt;br /&gt;
** &#039;&#039;&#039;Server 1.27.1&#039;&#039;&#039; - 10 teleports per 15 seconds&lt;br /&gt;
** &#039;&#039;&#039;Server 1.27.0&#039;&#039;&#039; - 3 teleports per 15 seconds&lt;br /&gt;
&lt;br /&gt;
== [[Animation]] ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Max. length of animation:&#039;&#039;&#039; 30.0 seconds&lt;br /&gt;
* &#039;&#039;&#039;Min. animation priority:&#039;&#039;&#039; 0&lt;br /&gt;
* &#039;&#039;&#039;Max. animation priority:&#039;&#039;&#039; 4&lt;br /&gt;
&lt;br /&gt;
== Building ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Max. [[prim]] dimensions (non-[[megaprim]])&#039;&#039;&#039; - 64&amp;amp;times;64&amp;amp;times;64m&lt;br /&gt;
** it was 10&amp;amp;times;10&amp;amp;times;10m before SL Server 3.0.0 (238864) &lt;br /&gt;
* &#039;&#039;&#039;Min. prim dimensions&#039;&#039;&#039; - 0.01&amp;amp;times;0.01&amp;amp;times;0.01m&lt;br /&gt;
* &#039;&#039;&#039;Max. # of prims in a linkset&#039;&#039;&#039; - 256 &lt;br /&gt;
** It was 255 before SL Server 1.26.&lt;br /&gt;
* &#039;&#039;&#039;Max. link distance&#039;&#039;&#039; - See [[Linkability Rules]].&lt;br /&gt;
* &#039;&#039;&#039;Max. # of prims in a physical object&#039;&#039;&#039; - 32&lt;br /&gt;
** If you try to link more, it&#039;ll either say &amp;quot;Can&#039;t enable physics for objects with more than 32 primitives&amp;quot; or &amp;quot;Object has too many primitives -- its dynamics have been disabled.&amp;quot;.&lt;br /&gt;
** On server versions 1.38 and below, each sitting avatar counted as 1 prim. From 1.40.2 the limit is only on actual prims.&lt;br /&gt;
* &#039;&#039;&#039;Max. build or rez height&#039;&#039;&#039; - 4,096m&lt;br /&gt;
** This is 768m for Viewers prior to SL 1.20&lt;br /&gt;
* &#039;&#039;&#039;Max. prim name length&#039;&#039;&#039; - 63 bytes UTF-8 [[string]]&lt;br /&gt;
** Note: This is the same total character limit as avatar names.&lt;br /&gt;
* &#039;&#039;&#039;Max. prim description length&#039;&#039;&#039; - 127 bytes UTF-8 [[string]]&lt;br /&gt;
** Note: &lt;br /&gt;
* &#039;&#039;&#039;Temporary prim lifetime&#039;&#039;&#039; - around 60 seconds&lt;br /&gt;
* &#039;&#039;&#039;Max. number of temporary prims&#039;&#039;&#039; - regular_prim_limit - current_regular_prims + minimum(0.5 * regular_prim_limit + 400, 1000)&lt;br /&gt;
** From [http://forums-archive.secondlife.com/8/cd/305651/1.html Andrew Linden&#039;s February 2009 discussion])&lt;br /&gt;
* &#039;&#039;&#039;Max. length of hovertext (via [[llSetText]] or [[PRIM_TEXT]])&#039;&#039;&#039; - 254 bytes UTF-8 [[string]]&lt;br /&gt;
&lt;br /&gt;
== Chat (text) ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Whisper distance&#039;&#039;&#039; - 10 m&lt;br /&gt;
* &#039;&#039;&#039;Chat distance&#039;&#039;&#039; - 20 m&lt;br /&gt;
* &#039;&#039;&#039;Shout distance&#039;&#039;&#039; - 100 m&lt;br /&gt;
** &#039;&#039;Rule of thumb:&#039;&#039; when you&#039;re at default zoom (&#039;&#039;&#039;View&#039;&#039;&#039; &amp;gt; &#039;&#039;&#039;Reset View&#039;&#039;&#039;), if you can see another person&#039;s nametag, they can see your chat. If they&#039;re far enough away that you don&#039;t see a nametag, they won&#039;t &amp;quot;hear&amp;quot; you unless you shout.&lt;br /&gt;
** Text spoken as a &amp;quot;Chat&amp;quot; step in a gesture cannot be shouted or whispered&lt;br /&gt;
** Text spoken as &amp;quot;Replace with&amp;quot; text in a gesture can be whispered or shouted in Viewer 2 either by putting &amp;lt;code&amp;gt;/whisper&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;/shout&amp;lt;/code&amp;gt; at the start of the &amp;quot;Replace with&amp;quot; text or by typing &amp;lt;code&amp;gt;/whisper&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;/shout&amp;lt;/code&amp;gt; at the beginning of the nearby chat input bar, followed by the gesture&#039;s trigger text. (Though, if you do both, or if a gesture with built-in &amp;lt;code&amp;gt;/whisper&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;/shout&amp;lt;/code&amp;gt; is used mid-sentence, the &amp;quot;/whisper&amp;quot; or &amp;quot;/shout&amp;quot; will appear literally.) Viewer 1 does not honor &amp;lt;code&amp;gt;/whisper&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;/shout&amp;lt;/code&amp;gt; and will always send them literally.&lt;br /&gt;
* &#039;&#039;&#039;Max. length of a chat message&#039;&#039;&#039; - 1023 bytes/single-byte characters&lt;br /&gt;
** The same holds true for an IM &amp;lt;-&amp;gt; email replies.&lt;br /&gt;
*** When the receiver is offline, if they set an IM to Email feature (&#039;&#039;&#039;Edit&#039;&#039;&#039; &amp;gt; &#039;&#039;&#039;Preferences&#039;&#039;&#039; (or press {{K|Ctrl|P}}), go to the &#039;&#039;&#039;Communication&#039;&#039;&#039; tab and check the &#039;&#039;&#039;Send IM to Email&#039;&#039;&#039; checkbox), it will send offline messages directly to the mailbox connected to your account. When an offline message is received via Email, this message can also be answered via Email again. The length of properly delivered Email replies is limited to 1023 bytes/single-byte characters.&lt;br /&gt;
* &#039;&#039;&#039;Capped&#039;&#039;&#039; - Maximum number of offline messages (involving [[IM]]s, inventory offers, group notices and group invitations) received before messages get capped is 25.&lt;br /&gt;
** Senders can&#039;t know whether their messages were capped or not.&lt;br /&gt;
* &#039;&#039;&#039;Email -&amp;gt; IM&#039;&#039;&#039; replies can be sent up to 5 days after receiving the offline IM the email is meant to answer.&amp;lt;sup&amp;gt;[&amp;lt;span class=&amp;quot;plainlinks&amp;quot;&amp;gt;[https://blogs.secondlife.com/community/features/blog/2007/02/06/im-to-e-mail-return-addresses-changing blog]&amp;lt;/span&amp;gt;]&amp;lt;/sup&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;IMs&#039;&#039;&#039; are retained on Linden Lab&#039;s servers for up to 31 days before being discarded. For example, if someone sends you an Instant Message and the next time you login is 33 days later, you won&#039;t get it.&lt;br /&gt;
** Torley confirmed this with Kelly Linden.&lt;br /&gt;
* The number of &#039;&#039;&#039;IMs&#039;&#039;&#039; an object can send in one hour is 5000.&lt;br /&gt;
&lt;br /&gt;
== [[Gesture]]s ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Shortcut key mapping:&#039;&#039;&#039; 33 unique combinations, since {{K|F2}}&amp;amp;ndash;{{K|F12}} can be used with the {{K|Ctrl}} or {{K|Shift}} modifiers.&lt;br /&gt;
* &#039;&#039;&#039;Maximum Chat step length:&#039;&#039;&#039; 127 single-byte characters.&lt;br /&gt;
* &#039;&#039;&#039;Maximum Wait time:&#039;&#039;&#039; 3600 seconds (one hour).&lt;br /&gt;
&lt;br /&gt;
== [[Group]]s ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Maximum number of groups you can belong to:&#039;&#039;&#039; 42&lt;br /&gt;
** Roles within groups are sort of like sub-groups. In many cases, you can use them instead of creating new groups.&lt;br /&gt;
* &#039;&#039;&#039;Minimum number of members in a group:&#039;&#039;&#039; 2&lt;br /&gt;
** A group with only 1 person for 48 hours will be disbanded (cancelled). Unless the group owns land.&lt;br /&gt;
* &#039;&#039;&#039;Maximum number of roles allowed in a group:&#039;&#039;&#039; 10 (including &amp;quot;Owners&amp;quot; and &amp;quot;Everyone&amp;quot;, which cannot be deleted)&lt;br /&gt;
* &#039;&#039;&#039;Maximum Group Name:&#039;&#039;&#039; 35 single-byte characters.&lt;br /&gt;
* &#039;&#039;&#039;Maximum Group Title:&#039;&#039;&#039; 20 single-byte characters.&lt;br /&gt;
* &#039;&#039;&#039;Maximum Length of a Group Notice:&#039;&#039;&#039; 512 single-byte characters.&lt;br /&gt;
&lt;br /&gt;
== [[Inventory]] ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Maximum number of inventory items that can be sent in a folder:&#039;&#039;&#039; 42&lt;br /&gt;
** Folders count as items too. This has more to do with packet size limits than cheeky Douglas Adams references.&lt;br /&gt;
* &#039;&#039;&#039;Maximum notecard line:&#039;&#039;&#039; None, but scripts can only read the first 255 bytes.&lt;br /&gt;
* &#039;&#039;&#039;Maximum notecard size:&#039;&#039;&#039; 65,536 bytes&lt;br /&gt;
* &#039;&#039;&#039;Number of items in the Library:&#039;&#039;&#039; 1,248 as of 2010-06-17&lt;br /&gt;
** Verified by [[How_does_the_Library_work|hiding the Library]] and counting the difference.&lt;br /&gt;
&lt;br /&gt;
== [[Land]] ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Maximum [[Land#Parcel|parcel]] size:&#039;&#039;&#039; 65,536 meters²&lt;br /&gt;
** Covering a whole region, or square on the World Map.&lt;br /&gt;
* &#039;&#039;&#039;Minimum parcel size:&#039;&#039;&#039; 16 meters²&lt;br /&gt;
* &#039;&#039;&#039;Maximum parcel name length:&#039;&#039;&#039; 63 single-byte characters&lt;br /&gt;
* &#039;&#039;&#039;Maximum parcel description length:&#039;&#039;&#039; 255 characters&lt;br /&gt;
* &#039;&#039;&#039;Region name length:&#039;&#039;&#039; Under Linden Concierge policy, minimum of 3 characters, and a maximum of 25 characters (including spaces). See [[Linden Lab Official:Guidelines for Private Region Naming|Guidelines for Private Region Naming]].&lt;br /&gt;
** Rare exceptions exist, like [http://slurl.com/secondlife/Q/128/128/24 Q].&lt;br /&gt;
* &#039;&#039;&#039;Maximum &amp;quot;NO ENTRY&amp;quot; ban line height:&#039;&#039;&#039; 768 meters above the terrain mesh.&lt;br /&gt;
** This is if you are explicitly banned from a parcel. If the parcel is simply not public access or restricted to certain Residents or a group, then the access lines go up to 50 meters above the terrain mesh.&lt;br /&gt;
* &#039;&#039;&#039;Maximum prims in a [[Land#Region|region]]:&#039;&#039;&#039;&lt;br /&gt;
** Full region: 15,000&lt;br /&gt;
** [[Land#Homestead|Homestead]]: 3,750&lt;br /&gt;
** [[Land#Openspace|Openspace]]: 750&lt;br /&gt;
* &#039;&#039;&#039;Maximum auto return value&#039;&#039;&#039;: Besides &amp;quot;0&amp;quot; (which means &#039;&#039;never&#039;&#039;), {{HoverText|999,999|Almost 23 months}} minutes is the highest auto return value.&lt;br /&gt;
* &#039;&#039;&#039;Terraforming limits:&#039;&#039;&#039;&lt;br /&gt;
** Most mainland can be raised/lowered by 4 meters (+/-).&lt;br /&gt;
** Some mainland cannot be terraformed, including: Bay City Regions, Blumfield, Boardman, Brown, De Haro, Nautilus City Regions, Nova Albion Regions, Shermerville Regions, and West Haven.&lt;br /&gt;
** A few, very old mainland Regions like Da Boom have a terraform range of 40 meters (+/-).&lt;br /&gt;
** Estate (private island) terraformability is settable to a maximum of 100 meters (+/-) by the estate owner or managers.&lt;br /&gt;
* &#039;&#039;&#039;Maximum water height:&#039;&#039;&#039; 100 meters using inworld controls (mainland limit), 255 meters by using a *.raw file upload.&lt;br /&gt;
** Region water height is usually 20 meters, and adjacent regions should have the same water height, or else they will look discontinuous.&lt;br /&gt;
* &#039;&#039;&#039;Maximum terrain height:&#039;&#039;&#039; 255 meters using inworld controls (mainland limit), 510 meters by using a *.raw file upload.&lt;br /&gt;
* &#039;&#039;&#039;Miscellaneous estate limits:&#039;&#039;&#039; You can have a maximum of 10 estate managers, 500 allowed Residents, 63 allowed groups, and 500 banned Residents.&lt;br /&gt;
** See World menu &amp;gt; Region/Estate &amp;gt; Estate tab.&lt;br /&gt;
* &#039;&#039;&#039;Mainland maximum number of agents&#039;&#039;&#039;&lt;br /&gt;
** Full region: 100 (Historically set to 40 by LL but this does vary. Some meeting areas have this set to 60 and higher.)&lt;br /&gt;
*** Recent server performance improvements make regions with 60 agents in them perform quite well excepting the issue described in {{JIRA|SVC-3895}}.&lt;br /&gt;
** [[Land#Homestead|Homestead]]: 20&lt;br /&gt;
** [[Land#Openspace|Openspace]]: 10&lt;br /&gt;
* &#039;&#039;&#039;Island maximum number of agents:&#039;&#039;&#039;&lt;br /&gt;
** Full region: 100&lt;br /&gt;
** [[Land#Homestead|Homestead]]: 20&lt;br /&gt;
** [[Land#Openspace|Openspace]]: 10&lt;br /&gt;
* &#039;&#039;&#039;Freeze Time:&#039;&#039;&#039; Land owners can [[freeze]] other Residents for up to 30 seconds.  Members of land owning groups can also be granted this ability.&lt;br /&gt;
* &#039;&#039;&#039;Minimum parcel that can be listed in Places or All search:&#039;&#039;&#039; 144 meters² &amp;lt;!-- 128 and under are disabled --&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;Minimum parcel that can be listed in Events:&#039;&#039;&#039; 512 meters²&lt;br /&gt;
* &#039;&#039;&#039;Maximum altitude for event listings:&#039;&#039;&#039;  768 meters ({{JIRA|WEB-814}})&lt;br /&gt;
* &#039;&#039;&#039;Maximum heights that objects can be seen on the [[World Map]]:&#039;&#039;&#039; 400.005m&lt;br /&gt;
* &#039;&#039;&#039;[[Classic clouds]] layer:&#039;&#039;&#039; Approximately 150-225 meters, although the edges of particles can appear to exceed that.&lt;br /&gt;
&lt;br /&gt;
== Misc. ==&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;[https://secondlife.com/currency/describe-limits.php Billing and Trading Limits]&#039;&#039;&#039; - Includes [https://secondlife.com/whatis/economy-market.php LindeX] currency exchange limits.&lt;br /&gt;
*&#039;&#039;&#039;Contacts in Communication &amp;gt; Friends tab &#039;&#039;&#039; - A maximum of 20 simultaneous contacts can be selected to change permissions, remove, or invite for a conference chat.&lt;br /&gt;
&lt;br /&gt;
== Navigation ==&lt;br /&gt;
&lt;br /&gt;
[[File:Max Alt.jpg|thumb|right|435px|&#039;&#039;&#039;Height counter error above 2147483647 meters&#039;&#039;&#039;]]&lt;br /&gt;
* &#039;&#039;&#039;Absolute height limit:&#039;&#039;&#039; [http://en.wikipedia.org/wiki/2147483647#2147483647_in_computing 2147483647]&amp;amp;nbsp;=&amp;amp;nbsp;2&amp;lt;sup&amp;gt;31&amp;lt;/sup&amp;gt;&amp;amp;nbsp;−&amp;amp;nbsp;1 meters, which causes the altitude counter to roll over. Altitudes well below this cause graphics errors probably due to limited floating point number precision.&lt;br /&gt;
* &#039;&#039;&#039;Highest z-value of an [[SLurl]], that will still teleport you to a positive altitude:&#039;&#039;&#039; 2147483583&lt;br /&gt;
** This is lower than the &#039;&#039;Absolute height limit&#039;&#039; above probably because of precision issues. Any value higher than 2147483583 would be rounded up to something beyond 2147483647 and thus cause an [http://en.wikipedia.org/wiki/Arithmetic_overflow overflow], while 2147483583 will still be rounded down to 2147483520 (see below).&lt;br /&gt;
* &#039;&#039;&#039;Highest altitude you can teleport to with an SLurl:&#039;&#039;&#039; 2147483520 meters&lt;br /&gt;
&lt;br /&gt;
== [[Profile]] ==&lt;br /&gt;
&lt;br /&gt;
Each 7-bit ASCII character is encoded in one byte. International characters might need more bytes. When pasting text instead of typing, you can get in one byte more into each of the below.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;2nd Life tab&#039;s About field&#039;&#039;&#039; - 510 bytes&lt;br /&gt;
* &#039;&#039;&#039;Picks tab&#039;&#039;&#039; - 10 picks with 1022 bytes each&lt;br /&gt;
* &#039;&#039;&#039;1st Life tab&#039;s Info field&#039;&#039;&#039; - 253 bytes&lt;br /&gt;
* &#039;&#039;&#039;Classified tab&#039;&#039;&#039; - 100 listings with x bytes each&lt;br /&gt;
* &#039;&#039;&#039;My Notes&#039;&#039;&#039; - 1022 bytes&lt;br /&gt;
&lt;br /&gt;
== Performance ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Healthy Viewer FPS&#039;&#039;&#039; - Generally, FPS above 15 is good. The higher it gets, the smoother. You can check via Help menu &amp;gt; Lag Meter, or for more advanced usage, see View menu &amp;gt; Statistics Bar.&lt;br /&gt;
* &#039;&#039;&#039;Avatar Rendering Cost scores&#039;&#039;&#039; - [[Avatar Rendering Cost|Learn all about it!]]&lt;br /&gt;
&lt;br /&gt;
== [[Scripting]] ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Height at which scripts reactivate on a no-script parcel&#039;&#039;&#039; - 50 m above terrain mesh. Scripted objects that take controls continue to remain active when you fly down or enter a no-script parcel.&lt;br /&gt;
* &#039;&#039;&#039;Maximum height where scripts can run&#039;&#039;&#039; - none, as long as the object remains rezzed or attached.&lt;br /&gt;
* &#039;&#039;&#039;Maximum script source code size&#039;&#039;&#039; - 65536 single byte characters.&lt;br /&gt;
* For specific scripting limits, lookup calls in the &#039;&#039;&#039;[[LSL Portal]]&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
== [[Textures]] ==&lt;br /&gt;
* &#039;&#039;&#039;[http://en.wikipedia.org/wiki/Aspect_ratio Aspect ratios]&#039;&#039;&#039; of profile, place, etc. pictures — all of these were measured at UI size (Edit menu &amp;gt; Preferences &amp;gt; General tab &amp;gt; UI Size) = 1.000:&lt;br /&gt;
&lt;br /&gt;
=== 1.x Series Viewers ===&lt;br /&gt;
&lt;br /&gt;
(official Viewer up to 1.23.5, most [[Alternate viewers|Third Party Viewers]])&lt;br /&gt;
* &#039;&#039;&#039;Search &amp;gt; All for &amp;quot;Classifieds&amp;quot;, &amp;quot;People&amp;quot;, and &amp;quot;Places&amp;quot;&#039;&#039;&#039; - 4:3 (256&amp;amp;times;192 pi&amp;amp;times;els)&lt;br /&gt;
* &#039;&#039;&#039;Search &amp;gt; Places and Classified tabs&#039;&#039;&#039; - ~7:5 (398&amp;amp;times;282 pixels)&lt;br /&gt;
* &#039;&#039;&#039;Search &amp;gt; Land tab&#039;&#039;&#039; - ~7:5 (358&amp;amp;times;252 pixels)&lt;br /&gt;
* &#039;&#039;&#039;Profile &amp;gt; 2nd Life tab&#039;&#039;&#039; - ~4:3 (178&amp;amp;times;133 pixels)&lt;br /&gt;
* &#039;&#039;&#039;Profile &amp;gt; Picks tab&#039;&#039;&#039; - 16:9 (288&amp;amp;times;162 pixels)&lt;br /&gt;
* &#039;&#039;&#039;Profile &amp;gt; 1st Life tab&#039;&#039;&#039; - 1:1 (133&amp;amp;times;133 pixels)&lt;br /&gt;
* &#039;&#039;&#039;Profile &amp;gt; Classifieds tab&#039;&#039;&#039; - ~3:2 (206&amp;amp;times;137 pixels)&lt;br /&gt;
* &#039;&#039;&#039;Profile &amp;gt; Web tab&#039;&#039;&#039; - 1:1 (400&amp;amp;times;400 pixels)&lt;br /&gt;
** A scrollbar uses 15 pixels on the right-hand side.&lt;br /&gt;
* &#039;&#039;&#039;About Land &amp;gt; Options tab&#039;&#039;&#039; - ~3:2 (178&amp;amp;times;117 pixels)&lt;br /&gt;
* &#039;&#039;&#039;Group Information &amp;gt; General tab&#039;s &amp;quot;Group Insignia&amp;quot;&#039;&#039;&#039; - 1:1 (126&amp;amp;times;126 pixels)&lt;br /&gt;
** Some of these textures are shared (for example, Search &amp;gt; All place pages, Search &amp;gt; Places, and About Land &amp;gt; Options use the same image), so you should pick a well-balanced ratio and size.&lt;br /&gt;
** [[Texture_aspect_ratios|Learn how to get correct texture aspect ratios when editing images.]]&lt;br /&gt;
&lt;br /&gt;
=== 2.x Series Viewers ===&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Search &amp;gt; Classifieds thumbnail&#039;&#039;&#039; - 4:3 (60&amp;amp;times;45 pixels)&lt;br /&gt;
* &#039;&#039;&#039;Search &amp;gt; Classifieds expanded&#039;&#039;&#039; - ~4:3 (252&amp;amp;times;188 pixels)&lt;br /&gt;
* &#039;&#039;&#039;Search &amp;gt; Classifieds expanded &amp;gt; Details&#039;&#039;&#039; - 17:7 (272&amp;amp;times;112 pixels)&lt;br /&gt;
* &#039;&#039;&#039;Search &amp;gt; People&#039;&#039;&#039; - 4:3 (188&amp;amp;times;141 pixels)&lt;br /&gt;
* &#039;&#039;&#039;Search &amp;gt; Destination Guide thumbnail&#039;&#039;&#039; - ~4:3 (45&amp;amp;times;34 pixels)&lt;br /&gt;
* &#039;&#039;&#039;Search &amp;gt; Destination Guide expanded&#039;&#039;&#039; - 5:3 (250&amp;amp;times;150 pixels)&lt;br /&gt;
* &#039;&#039;&#039;Profile &amp;gt; 2nd Life tab&#039;&#039;&#039; - ~1:1 (100&amp;amp;times;99 pixels)&lt;br /&gt;
* &#039;&#039;&#039;Profile &amp;gt; Picks thumbnail&#039;&#039;&#039; - 8:5 (88&amp;amp;times;55 pixels)&lt;br /&gt;
* &#039;&#039;&#039;Profile &amp;gt; Pick expanded&#039;&#039;&#039; - ~5:3 (285&amp;amp;times;172 pixels)&lt;br /&gt;
* &#039;&#039;&#039;About Land &amp;gt; Options tab&#039;&#039;&#039; - ~20:13 (193&amp;amp;times;125 pixels)&lt;br /&gt;
* &#039;&#039;&#039;Places &amp;gt; More information&#039;&#039;&#039; - ~11:7 (272&amp;amp;times;173 pixels)&lt;br /&gt;
&lt;br /&gt;
=== All Viewers ===&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Maximum texture size&#039;&#039;&#039; - 1024&amp;amp;times;1024 pixels&lt;br /&gt;
** All Second Life textures are constrained to [http://en.wikipedia.org/wiki/Power_of_2 powers of 2] (e.g., 128, 256, 512).&lt;br /&gt;
** Some textures inworld have a resolution as high as 2048&amp;amp;times;2048; this is due to a previous limit that was higher.&lt;br /&gt;
** We strongly recommend you use as small textures as possible because larger ones consume more memory and take substantially longer to load.&lt;br /&gt;
** Where large textures are being forced by import to only 512&amp;amp;times;512, lower your ...&amp;gt; Preferences &amp;gt;...&amp;gt; UI Size under 1.0, to increase import size to the max 1024&amp;amp;times;1024.&lt;br /&gt;
&lt;br /&gt;
[[Category:Creation]] [[Category:Tutorials]] [[Category:Lists]]&lt;br /&gt;
&lt;br /&gt;
=== Notes ===&lt;br /&gt;
In general 1 byte is enough to contain one character.&lt;/div&gt;</summary>
		<author><name>Techplex Engineer</name></author>
	</entry>
</feed>