Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 05/20/2017 in all areas

  1. Seriously not in the mood for people today. Take a couple days of not being able to post to think over your response.
    2 points
  2. 1 point
  3. ParamStruct is defining char pointers while the struct you create in Autoit is declaring char arrays. Perhaps ParamStruct should look more like: struct ParamStruct { char const test1[128]; char const test2[128]; char const test3[128]; int size; };
    1 point
  4. Hi Your problem is not your code or AutoIt. The problem occurs because of a fundamental flaw inside the Windows operating system. All dates are presented in "Regional" format, to make your life easy. It does make any type of DATE TIME coding over time zones, or even computers on the same LAN runnign different Regional Settings, a nightmare. Microsoft does not support a single, universal, uniform "TODAY" macro to support date and time functions like SQL does. You either need to get the computers to work the same way, almost always impossible if you cannot directly control those machines. The only alternative is to use something like DTC by Melba. Link ==> https://www.autoitscript.com/forum/topic/154684-date_time_convert-bugfix-version-27-may-15/ Skysnake
    1 point
  5. Well you get what you ask for so AutoIt3 does exactly follow the requested formats. The Win10 system has : g.aa.yyyy so you only get 1 digit when the day (g) is one digit. The Win7 system has : gg.aa.yyyy so you always get 2 digits for day (gg), even when it's only is one digit. Make the format the same on both systems and you will see that AutoIt3 will provide the same output. Jos
    1 point
  6. Simple example: #include <IE.au3> Local $sURL = "https://www.autoitscript.com/forum/topic/188551-close-all-ie-except-the-one-that-is-attached/" $oIE = _IECreate($sURL, 1) ;~ Begin Adding Example Tabs $oIE.Navigate("https://www.google.com", 0x0800) $oIE.Navigate("https://www.youtube.com", 0x0800) Sleep(5000) ;~ End Adding Example Tabs Local $i = 1, $oIETab While 1 $oIETab = _IEAttach("", "instance", $i) If @error = $_IEStatus_NoMatch Then ExitLoop If Not StringInStr(_IEPropertyGet($oIETab, "locationurl"), $sURL) Then _IEQuit($oIETab) ContinueLoop EndIf $i += 1 WEnd
    1 point
  7. Subz

    Mouseclick in if statement

    You can use something like: #include <Misc.au3> HotKeySet("{ESC}", "_ExitScript") While 1 If _IsPressed("01") Then MsgBox(0, "Message", "Mouse Clicked") WEnd Func _ExitScript() Exit EndFunc
    1 point
  8. Hi, @youtuber! I found several issues on your code... Your first PHP code requires a file input named "file"; your second PHP code requires "datei", whereas your AutoIt script gives a file input named "uploadinput" Your second PHP code requires a post variable named "filename", whereas your AutoIt script gives it named "str" Your second PHP code requries a post variable named "password" to be "Pass123", whereas your AutoIt script doesn't give it. Both the PHP codes are vulnerable, as anyone can upload malicious PHP files onto it. Here's a short example (warning: I didn't test it): _HTTP_Upload("http://test/postscript.php", "myFile.txt", "uploadinput", "pwd=123&filename=" & URLEncode("test.txt") ) <?php define('PASSWORD', '123'); // put pwd here $pwd = isset($_REQUEST['pwd']) ? $_REQUEST['pwd'] : null; if ($pwd!=PASSWORD) { header("HTTP/1.0 403 Forbidden"); echo "403 Forbidden"; exit; } $allowed_extensions = ['txt', 'doc', 'docx']; // set it if ($_FILES['uploadinput']['tmp_name']) { $file_extension = strtolower(end($tmp = explode(".", $_POST['filename']))); // $tmp to avoid "should be passed as ref" notice if(in_array($file_extension, $allowed_extensions)) { move_uploaded_file($_FILES['uploadinput']['tmp_name'], 'uploads/'.$_POST['filename']); } } echo 'ok';
    1 point
×
×
  • Create New...