User Tag List

Results 1 to 2 of 2

Thread: Lacewing Web Server

  1. #1
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleSWF Export ModuleInstall Creator ProPatch Maker
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Fusion 2.5+ DLC (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    DJFuego's Avatar
    Join Date
    Jul 2006
    Location
    UK
    Posts
    1,410
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)

    Lacewing Web Server

    Well this object is pretty neat. I just made a simple wallboard app. The webserver reads a text file and renders the rest of the page with a set template and a refresh script is incorporated into the html.
    Has anyone actually made a Lacewing webserver app with forms to post back to your lacewing server yet?

  2. #2
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export Module
    Kimera's Avatar
    Join Date
    Feb 2007
    Location
    Houston, TX
    Posts
    718
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Re: Lacewing Web Server

    um, yea, I do it now just in plain HTML against lacewing...

    Right now I am not using the form, I took that down but you will get the idea here...

    Form Page... Just use the form rather than the onload statement...
    <body onload="javascript:sendData();">

    <script>
    var data = new Array();
    data[0] = "this is the data that gets passed";
    data[1] = "you have to pack all the lines together and use a backslash for the special chars.";
    data[2] = "a slash: \\";
    data[3] = "quotes: \"I forget what four was for\"";

    function sendData()
    {
    // Initialize packed or we get the word 'undefined'
    var packed = "";
    for (i = 0; (i < data.length); i++) {
    if (i > 0) {
    packed += ",";
    }
    packed += escape(data[i]);
    }
    window.location = "b.htm?" + packed;
    }
    </script>


    This is the page that gets the data...

    <script>
    var query = window.location.search;
    // Skip the leading ?, which should always be there,
    // but be careful anyway
    if (query.substring(0, 1) == '?') {
    query = query.substring(1);
    }
    var data = query.split(',');
    for (i = 0; (i < data.length); i++) {
    data[i] = unescape(data[i]);
    }
    </script>
    <h1>This is what the array contains:</h1>
    <ul>
    <script>
    for (i = 0; (i < data.length); i++) {
    document.write("<li>" + data[i] + "</li>\n");
    }
    </script>
    </ul>


    I wrote my one code within the server to save the data to a sqlite3 database as needed and the code above to pass and display. Hope that helps.

    K

Similar Threads

  1. Basic Lacewing server/Serveur Lacewing basique
    By samcool_129 in forum File Archive
    Replies: 4
    Last Post: 24th April 2013, 05:50 AM
  2. Create a lacewing server?
    By Unknowner in forum Lacewing
    Replies: 4
    Last Post: 4th October 2011, 05:43 AM
  3. How would I set up a Lacewing chat server?
    By RGBreality in forum Lacewing
    Replies: 5
    Last Post: 27th December 2010, 01:15 AM
  4. Lacewing server? Just a little help.
    By Gibbon in forum Lacewing
    Replies: 12
    Last Post: 16th December 2010, 06:22 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •