Jump to content

Recommended Posts

Posted (edited)

Ok here is idea.

When user starts programm it sends information about time to txt file on web server.

Something like this

10:00 Programm opened.

11:05 Programm closed.

12:14 Programm opened.

13:18 Programm closed.

But not rewrite info, just add...

How to script this?

Thanks for help.

Edited by Romm
Posted (edited)

Here is a quick example using my server.

Click here to view the contents of the file

#include <IE.au3>

_Example("Somebody tried this example at " & @HOUR & ":" & @MIN & @CRLF)

Func _Example($q = "hello world")
    $oIe = _IECreate("http://www.bloxsoftware.com/example/example.php?q=" & $q, 0, 0)
    _IEQuit($oIe)
EndFunc

You need to make a PHP script that will appen the text to the file.

<?
       $text = $_GET["q"];
       echo("Added text... " .$text);
       $file = fopen("example.txt", "a");
       fwrite($file, $text . "\r\n");
       fclose($file);
   ?>

This probably isn't the best way, but heh, it works.

NOTE: If you do use this method, you might want to take some security measures.

Edited by chris95219

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...