-
Posts
7,103 -
Joined
-
Days Won
88
Content Type
Forums
Downloads
Forum Articles
Events
Everything posted by TheDcoder
-
(Poll) What features do you wish you had in AutoIt?
TheDcoder replied to TheDcoder's topic in AutoIt Technical Discussion
I think you are referring to the unneeded code which is stripped by AutoIt3Wrapper script written by Jos. I was not talking about that, I was talking about the interpreter program itself, AutoIt for example always includes a full copy of AutoIt3.exe in all compiled programs. My proposal is to only include the required components instead of everything in the compiled program -
create a Word Frequency Counter
TheDcoder replied to vinnyMS's topic in AutoIt General Help and Support
Why not use a program to do the counting? I am sure there are many available. But if you are doing this to learn programming then you should indeed follow JLogan's advice and start learning the language, you can use the help file and maybe some youtube videos -
(Poll) What features do you wish you had in AutoIt?
TheDcoder replied to TheDcoder's topic in AutoIt Technical Discussion
Hmmm... maybe I don't fully understand these reflections you are talking about. Anyway, exposing too much info about the execution will prevent optimizations, like making the function stack publicly accessible. I don't see much benefit anyway, you should stick to parameters for passing around info, keep it simple However a macro with the current function name is reasonable, it can be useful for debugging purposes. Yeah, I guess it could work that way. That's crazy, I didn't know AutoIt converts both datatypes to a number in a mixed comparison... but that won't be the case in ECI, I will make the comparison purely binary, which means an empty string and zero will always be false AND a non-empty string and non-zero will be true. Honestly don't know why it isn't implemented like that in AutoIt, what's the point of an extra step of conversion? -
(Poll) What features do you wish you had in AutoIt?
TheDcoder replied to TheDcoder's topic in AutoIt Technical Discussion
Looks like I have a lot to respond to 😅 I understand advantages of machine code, but can you elaborate on why you think byte code wouldn't make sense? It allows the interpreter to function without parsing the same old code on every execution, aside from the obvious benefit of cutting down on the code required for the parser itself. Byte code would also serve as a good intermediate between pure machine instructions and pure script interpretation, perhaps it can later be used by different compilers which could target different instruction sets This is important in our "smart" "IoT" connected world, where many small devices use ARM or some other instruction-based processor, x86 is very rare outside of personal computers I think. -- About memory management, I am not sure I entirely understand what you mean, do you want to be able to set a hard limit on the amount of memory the process can use? Boost: I looked at it and it is indeed a very good library, but an awful lot of it seems to be very specific to C++, in fact one of their goals is to get these functions integrated into standards... and integrating with it means also following same mindset as C++, which is something I really want to avoid at all costs, I'd say it would be an anti-goal. A large part of the library deals with C++ language features, only a few actually provide useful "end-user features" like dates, filesystem, http etc. So even if we wanted to integrate with boost ignoring the other stuff, the benefit isn't that much... and there are better libraries which can provide support for these kind of things anyway. Even in C++ there is Qt which provides everything a desktop programmer could ever want, and there is already a BASIC language which integrates with it @JockoDundee For sure! This is one of the features I had planned from the start, you will be able to use assignment in expressions I might also add an additional operator, something like python's := to make it more explicit. File scope as in variables which are not shared across includes? This suggestion sounds good on the surface but it has several issues, #include is treated as a "copy-and-paste" inside the scanner/tokenizer, so it is completely transparent to the syntax analyzer (the actual parser). We could make the parser more complex by adding the ability to recognize the file boundaries and then implement file scope that way but I am not sure if that is a wise design decision. A more appropriate feature might be namespaces, which you have mentioned in your latest post Objects is an ambigious term, it can be a misnomer, one of the meanings is just a term for any value... but I guess you are talking about them in the context of "Object-oriented programming", I might implement an "object" in the form of a structure (simply a variable which contains a fixed number of elements which can be referred by names, very similar to maps/associate arrays). Reflections if I am recalling correctly are traps for operations on a variable/object, it is an interesting prospect for sure Good one, noted! Another one of the things I had in my mind from the start, I think I made a topic here in the forums requesting the feature. Rest assured this will make its into ECI I am trying to keep whitespace as less significant as possible, some might be opposed to the idea but I would prefer flexibility as it offers a chance to write code in a less awkward way in certain situations while maintaining the usual norms in normal circumstances. Doesn't AutoIt already have this feature? It's simple enough to DIY too: Func Bool($vVar) Return Not Not $vVar EndFunc But yeah, casts are useful. How would this be different than returning an array? In my opinion this is one of the most important features of a high-level scripting language, having the ability to use it everywhere. Not saying that it would be a "Code-once run everywhere" thing, but the fundamentals would stay same and the programmer can handle platform specific stuff with their code. AutoIt is definitely not meant for OOP, some may not agree but I think in spirit it wouldn't be AutoIt if we add OOP to it. Objects are okay, but not a full-fledged inheritance system Sounds like an array, python calls them lists. I think you might be referring to something more than an array, so can you elaborate? GUI is another beast, and of course a visual designer is a hard thing to make. I am not in an hurry to implement this. Eventually I will implement GUI with support for layout-based design, similar to how HTML and GTK work, as opposed to absolute pixel position based design (this would still be possible if needed) Sorry, if we did this it won't be AutoIt Does any BASIC dialect support this feature actually? -- Wow, this might be my longest reply post. -
(Poll) What features do you wish you had in AutoIt?
TheDcoder replied to TheDcoder's topic in AutoIt Technical Discussion
Java is not a fair comparison, it is a cross-platform OS which happens to run on top of other OSes, and the whole OS just runs one program I might be "let's make a programming language" crazy but I am not "let's make an OS" crazy Not really, python for example compiles the code into its own bytes before interpreting it, I am taking a similar approach. If I ever get around making an actual compiler, it would just be a little bit of generated assembly with a lot of pre-compiled stubs to handle high-level stuff Some of the sub-systems might get too heavy (10s of MBs) if I implement all the other features you asked for, so it's a good feature to have, hopefully not too bothersome to implement Those are great recommendations, I already had some of them in my mind, like hooking into crypto functions (OpenSSL in Linux). These features are more related to a standard library though, as opposed to the core language design itself, but I am glad you mentioned them anyway. I have a lot planned for which would go into the standard set of tools available in EasyCodeIt, here are some I can recall on top of my head: cURL integration to support a lot of network protocols Transparent encryption for network sockets (the crypto SSL stuff you mentioned), perhaps implemented via a generic abstract layer so that people can implement their own wrappers over sockets and other IO A lot of wrappers around POSIX, Linux, Windows and other platform specific stuff etc. As you can see, implementing all of this in a single program might make it too heavy, thus my interest making it somewhat modular. Not really sure about chromium though, that might be taking it a bit too far... but we will see, nothing is impossible*! *conditions apply -
Hi everyone, The question is simple, what features do you wish you had in AutoIt? AutoIt is a great language but it comes with limitations, so I am on a mission to write a similar scripting/programming language with many improvements which would make it a very powerful but easy-to-use tool. As some of you already know, the project is already underway and it is called EasyCodeIt. I am interested in seeing what features are the most wanted so that I can focus my attention to them in the near future So please help me by voting for your favorite features!
-
EasyCodeIt - cross-platform AutoIt implementation
TheDcoder replied to TheDcoder's topic in AutoIt Projects and Collaboration
@jpm Oops, thanks, fixed /* Macro or Variable */ [@$][A-Za-z0-9_]+ return *yytext == '$' ? VARIABLE : MACRO; I also removed the limitation of not being able start a variable (or macro) with a digit, seems arbitrary as we already have a special symbol to denote a variable. LOL, indeed, normally it shouldn't be there but it is allowed since C99... patches are cleaner if you change those values because you don't have to add that extra comma at that time. -
Security questions for AutoIT approval
TheDcoder replied to BradBurke's topic in Developer General Discussion
This applies for all code, anything you store in your program can be easily extracted and decrypted... even big companies which specialize in anti-tampering technology fail. This is a fundamental flaw which arises from the fact that you want the machine to know the secret but not the user, in other words, you can't have your cake and eat it too -
EasyCodeIt - cross-platform AutoIt implementation
TheDcoder replied to TheDcoder's topic in AutoIt Projects and Collaboration
I got busy with work again, but luckily I didn't take another month long break I implemented support for #include and #include-once in the lexer, which means the lexer part is more or less done. Here is the new code: // lexer.l %option batch noyywrap nounput nodefault yylineno %{ /* * This file is part of EasyCodeIt. * * Copyright (C) 2021 TheDcoder <[email protected]> * * EasyCodeIt is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see <https://www.gnu.org/licenses/>. */ #include <stdbool.h> #include <stdio.h> #include <stdlib.h> #include <string.h> struct BufferStack { struct BufferStack *prev; char *code; YY_BUFFER_STATE state; size_t line; char *file; } *lex_buffer = NULL; static char *token_str = NULL; static size_t token_len = 0; static size_t comment_level = 0; #define YY_USER_ACTION token_str = yytext; token_len = yyleng; enum { // Token Types UNKNOWN = 420, WS, COMMENT, DIRECTIVE, NUMBER, STRING, BOOL, WORD, MACRO, VARIABLE, OPERATOR, BRACKET, DOT, COMMA, }; #include "parser.h" static source_reader read_file; static bool push_file(char *file); static bool pop_file(void); %} %x INCLUDE %x DIRECTIVE_LINE %x ML_COMMENT WS [ \t\r\n]+ NL \r?\n? DIGIT [0-9] XDIGIT [0-9A-Fa-f] QUOTE [\'\"] %% /* Include File */ /* TODO: #include-once */ ^"#include"{WS}[\"<] BEGIN INCLUDE; <INCLUDE>[^\n\">]+ { int c; while((c = input()) && c != '\n') /* Eat up any leftover junk in the include line */; ++yylineno; push_file(yytext); BEGIN INITIAL; } <INCLUDE>.|\n /* Ignore bad include line */; "#include-once" { /* Add current file to "include once" list*/ read_file(lex_buffer->file, NULL, true); } /* Whitespace */ {WS} ; /* Directive */ "#" {BEGIN DIRECTIVE_LINE; yymore();}; <DIRECTIVE_LINE>.+ {BEGIN INITIAL; return DIRECTIVE;}; /* Comment */ <INITIAL,ML_COMMENT>"#cs"|"#comment-start"{WS} {BEGIN ML_COMMENT; ++comment_level;}; <ML_COMMENT>"#ce"|"#comment-end" if (--comment_level == 0) BEGIN INITIAL; <ML_COMMENT>(?s:.) ; ;[^\r\n]* return COMMENT; /* Number */ {DIGIT}+(\.{DIGIT}+(e{DIGIT}+)?)? return NUMBER; 0[xX]{XDIGIT}+ return NUMBER; /* String */ \"[^\n\"]*\" return STRING; \'[^\n\']*\' return STRING; /* Bool */ (?i:"True"|"False") return BOOL; /* Word */ [A-Za-z][A-Za-z0-9]* return WORD; /* Macro or Variable */ [@$][A-Za-z][A-Za-z0-9]* return *yytext == '$' ? VARIABLE : MACRO; /* Operator */ /* IDEA: Make a parser mode where the character will be returned literally */ [+\-*/^&=<>?:] return OPERATOR; /* Misc */ [[\]()] return BRACKET; \. return DOT; \, return COMMA; /* Pop file and terminate if top-level */ <<EOF>> if(!pop_file()) yyterminate(); /* Catch-all for everything else */ . return UNKNOWN; %% #include <stddef.h> #include <stdio.h> static void print_token(char *str, int type) { puts("---### TOKEN ###---"); char *token_type; switch (type) { case UNKNOWN: token_type = "Unknown"; break; case WS: token_type = "Whitespace"; break; case COMMENT: token_type = "Comment"; break; case DIRECTIVE: token_type = "Directive"; break; case NUMBER: token_type = "Number"; break; case STRING: token_type = "String"; break; case BOOL: token_type = "Boolean"; break; case WORD: token_type = "Word"; break; case MACRO: token_type = "Macro"; break; case VARIABLE: token_type = "Variable"; break; case OPERATOR: token_type = "Operator"; break; case BRACKET: token_type = "Bracket"; break; case DOT: token_type = "Dot"; break; case COMMA: token_type = "Comma"; break; default: token_type = "Unnamed"; break; } fputs("Type: ", stdout); puts(token_type); fputs("Data: ", stdout); puts(str); } static void scan() { int type; for (;;) { type = yylex(); if (!type) break; print_token(token_str, type); } } bool parse(char *file, source_reader read_func) { read_file = read_func; push_file(file); scan(); return true; } static bool push_file(char *file) { size_t code_len; file = strdup(file); if (!file) return false; char *code = read_file(file, &code_len, false); if (!code) { free(file); return false; } struct BufferStack *new_buffer = malloc(sizeof *new_buffer); if (!new_buffer) return false; if (lex_buffer) lex_buffer->line = yylineno; *new_buffer = (struct BufferStack){ .prev = lex_buffer, .code = code, .state = yy_scan_buffer(code, code_len + 2), .file = file, .line = yylineno = 1, }; lex_buffer = new_buffer; yy_switch_to_buffer(lex_buffer->state); return true; } static bool pop_file() { struct BufferStack *prev_buffer = lex_buffer->prev; yy_delete_buffer(lex_buffer->state); free(lex_buffer->code); free(lex_buffer->file); free(lex_buffer); lex_buffer = prev_buffer; if (!lex_buffer) return false; yylineno = lex_buffer->line; yy_switch_to_buffer(lex_buffer->state); return true; } // eci.c /* * This file is part of EasyCodeIt. * * Copyright (C) 2020 TheDcoder <[email protected]> * * EasyCodeIt is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see <https://www.gnu.org/licenses/>. */ static char *provide_code(char *file, size_t *size, bool once) { static char **once_list = NULL; static size_t once_list_len = 0; if (once) { // Add the file to "include once" list if (!once_list) { once_list = malloc(sizeof(char *)); if (!once_list) return NULL; ++once_list_len; } else { char **expanded_list = realloc(once_list, sizeof(char *) * ++once_list_len); if (!expanded_list) { --once_list_len; return NULL; } once_list = expanded_list; } once_list[once_list_len - 1] = strdup(file); return NULL; } else { // Skip if the file is in the "include once" list for (size_t i = 0; i < once_list_len; ++i) { if (strcmp(once_list[i], file) == 0) return NULL; } } // Open the source file char *code; FILE *source_file = fopen(file, "r"); if (source_file) { // Read the source file code = readfile(source_file); fclose(source_file); if (!code) die("Failed to read from source file!"); } else { code = malloc(1); code[0] = '\0'; } // The following is required because the parser needs a string with two null terminators *size = strlen(code); char *code_padded = realloc(code, *size + 2); if (!code_padded) { free(code); die("Failed to expand code buffer"); } code_padded[*size + 1] = '\0'; return code_padded; } int main(int argc, char *argv[]) { if (argc < 2) die("No arguments!"); // Parse the code parse(argv[1], provide_code); return EXIT_SUCCESS; } It was surprisingly easy to write a fully featured scanner/tokenizer in flex, guess I should have used it from the beginning. Now I can start work on the parser, hopefully it will be easy too, surely easier than writing it all manually 🥵 Source: https://forum.dtw.tools/d/28-easycodeit-update-flex-bison-parser/2 -
True, but the thing to note is that GitHub is just a hosting platform, so it depends really. If the project is officially hosted there then the DLLs are trustworthy, if it is some 3rd-party mirror then buyer beware A loose comparison is Wikipedia, you shouldn't trust it, but you should check the sources and if they are trustworthy, then Wikipedia is too.
-
There are many, just search for a particular DLL and you'd get many results. But the thing is they aren't for programmers, they are for end-users who don't know anything about compiling programs. If you are a programmer, just get your DLLs from the SDK or build them from the source if available, one of those options is always available.
-
EasyCodeIt - cross-platform AutoIt implementation
TheDcoder replied to TheDcoder's topic in AutoIt Projects and Collaboration
Hi everyone, I already posted an update yesterday where I mentioned that I have started work on the new parser which uses Flex and Bison to generate C code for parsing. So far the experience has been very nice, I am able to test and develop things very fast compared to doing it all on my own. I have completed the initial version of the tokenizer/scanner/lexer, it should be able to scan all tokens which could possibly occur in a valid script %option noyywrap nodefault %{ #include <stdlib.h> #include <string.h> char *token_str = NULL; size_t token_len = 0; size_t comment_level = 0; //#define YY_USER_ACTION free(token_str); token_str = strndup(yytext, token_len = yyleng); #define YY_USER_ACTION token_str = yytext; token_len = yyleng; enum { // Token Types UNKNOWN = 420, WS, COMMENT, DIRECTIVE, NUMBER, STRING, BOOL, WORD, MACRO, VARIABLE, OPERATOR, BRACKET, DOT, COMMA, }; %} %x ML_COMMENT WS [ \t\r\n]+ NL \r?\n? DIGIT [0-9] XDIGIT [0-9A-Fa-f] QUOTE [\'\"] %% /* Whitespace */ {WS} ; /* Comment */ <INITIAL,ML_COMMENT>"#cs"|"#comment-start"{WS} {BEGIN ML_COMMENT; ++comment_level;}; <ML_COMMENT>"#ce"|"#comment-end" if (--comment_level == 0) BEGIN INITIAL; <ML_COMMENT>(?s:.) ; [;#][^\r\n]* return *yytext == ';' ? COMMENT : DIRECTIVE; /* Number */ {DIGIT}+(\.{DIGIT}+(e{DIGIT}+)?)? return NUMBER; 0[xX]{XDIGIT}+ return NUMBER; /* String */ \"[^\n\"]*\" return STRING; \'[^\n\']*\' return STRING; /* Bool */ (?i:"True"|"False") return BOOL; /* Word */ [A-Za-z][A-Za-z0-9]* return WORD; /* Macro or Variable */ [@$][A-Za-z][A-Za-z0-9]* return *yytext == '@' ? MACRO : VARIABLE; /* Operator */ [+\-*/^&=<>?:] return OPERATOR; /* Misc */ [[\]()] return BRACKET; \. return DOT; \, return COMMA; /* Catch-all for everything else */ . return UNKNOWN; %% #include <stddef.h> #include <stdio.h> static void print_token(char *str, size_t len, int type) { puts("---### TOKEN ###---"); char *token_type; switch (type) { case UNKNOWN: token_type = "Unknown"; break; case WS: token_type = "Whitespace"; break; case COMMENT: token_type = "Comment"; break; case DIRECTIVE: token_type = "Directive"; break; case NUMBER: token_type = "Number"; break; case STRING: token_type = "String"; break; case BOOL: token_type = "Boolean"; break; case WORD: token_type = "Word"; break; case MACRO: token_type = "Macro"; break; case VARIABLE: token_type = "Variable"; break; case OPERATOR: token_type = "Operator"; break; case BRACKET: token_type = "Bracket"; break; case DOT: token_type = "Dot"; break; case COMMA: token_type = "Comma"; break; default: token_type = "Unnamed"; break; } fputs("Type: ", stdout); puts(token_type); fputs("Data: ", stdout); puts(str); } int main(void) { int type; for (;;) { type = yylex(); if (!type) break; print_token(token_str, token_len, type); } return 0; } I passed this "script" as the input: #cs #cs nested comment #ce #ce ; Calm Mints 42 0xDEADBEEF 3.14 6.02214076e23 "Hell'o World" '"To C or not to C"' True true fAlSe False tRUe @TheTruth $TheFact -((1 + 2) / 3) * 4 And here is the output: ---### TOKEN ###--- Type: Comment Data: ; Calm Mints ---### TOKEN ###--- Type: Number Data: 42 ---### TOKEN ###--- Type: Number Data: 0xDEADBEEF ---### TOKEN ###--- Type: Number Data: 3.14 ---### TOKEN ###--- Type: Number Data: 6.02214076e23 ---### TOKEN ###--- Type: String Data: "Hell'o World" ---### TOKEN ###--- Type: String Data: '"To C or not to C"' ---### TOKEN ###--- Type: Boolean Data: True ---### TOKEN ###--- Type: Boolean Data: true ---### TOKEN ###--- Type: Boolean Data: fAlSe ---### TOKEN ###--- Type: Boolean Data: False ---### TOKEN ###--- Type: Boolean Data: tRUe ---### TOKEN ###--- Type: Macro Data: @TheTruth ---### TOKEN ###--- Type: Variable Data: $TheFact ---### TOKEN ###--- Type: Operator Data: - ---### TOKEN ###--- Type: Bracket Data: ( ---### TOKEN ###--- Type: Bracket Data: ( ---### TOKEN ###--- Type: Number Data: 1 ---### TOKEN ###--- Type: Operator Data: + ---### TOKEN ###--- Type: Number Data: 2 ---### TOKEN ###--- Type: Bracket Data: ) ---### TOKEN ###--- Type: Operator Data: / ---### TOKEN ###--- Type: Number Data: 3 ---### TOKEN ###--- Type: Bracket Data: ) ---### TOKEN ###--- Type: Operator Data: * ---### TOKEN ###--- Type: Number Data: 4 Which is very similar if not exactly the same as what our old parser would have produced The next step is to add support for including files (#include <...>) and then I will start work on the syntactic analysis, which is the actual "parsing" to convert list of words into actions. Hopefully I won't get held up by last time due to all the fatigue, using these tools should speed up the process significantly. Stay tuned for more updates this week! Source: https://forum.dtw.tools/d/28-easycodeit-update-flex-bison-parser -
EasyCodeIt - cross-platform AutoIt implementation
TheDcoder replied to TheDcoder's topic in AutoIt Projects and Collaboration
Source: https://forum.dtw.tools/d/26-easycodeit-update-our-hand-written-parser-is-going-away/8 -
@Danp2 Does Postman support WS? I think it only does HTTP requests. I use WebSocket Weasel (available as an addon for Firefox), it works and looks good.
- 24 replies
-
- firefox
- remote control
-
(and 3 more)
Tagged with:
-
I must have forgotten. Did you follow the link where I mentioned usage?: https://firefox-source-docs.mozilla.org/remote/Usage.html You should try using a WebSocket client and manually sending messages, you can use the same source for documentation on the format for communication.
- 24 replies
-
- firefox
- remote control
-
(and 3 more)
Tagged with:
-
@Danp2 What?! Firefox has it's own remote protocol which is based on Chrome's? 😳 The good news is that according to the first ticket you mentioned, they have already implemented addScriptToEvaluateOnNewDocument... but since geckodriver doesn't provide a convenient way to interact with it like chromedriver, we would have to use the interface directly. We could start the driver in both marionette mode and remote debugging mode I think, but we will have to use separate connections for both because of the different interfaces, on top of that, the remote protocol uses WebSockets (has anyone made an UDF yet?) for communication, so the normal WinHTTP won't work. Basically this will be very different from web driver.
- 24 replies
-
- firefox
- remote control
-
(and 3 more)
Tagged with:
-
Indeed, but considering that everything aside from the usual WebDriver interface is non-standard, it is going to be a hard task catering for every kind of web driver. I don't think geckodriver even gives us an interface to interact with marionette like chromedriver's "execute CDP command" command (redundancy again, lol). Does my code not work anymore? It used to work properly with older chrome versions. The code pretty similar, but the difference is that your code uses an arrow function while mine creates a traditional function (it simply clones the default function prototype, which does nothing and returns undefined). There are slight differences between a function created by an arrow expression and a normal function, though I am not sure if the former has any issues, it is better to stick with a normal function just to be safe.
- 24 replies
-
- firefox
- remote control
-
(and 3 more)
Tagged with:
-
The most probable situation is that eBay is detecting the Navigator.webdriver property: It is possible to mask this with some hacks though, here is the JavaScript snippet I used a while ago to mask that in Chrome: Object.defineProperty(Navigator.prototype, "webdriver", {get: Function.prototype.bind()}) You can use this code by injecting it into every page on start like so: ; Inject Navigator Shim Local $sNavShim = 'Object.defineProperty(Navigator.prototype, "webdriver", {get: Function.prototype.bind()})' Local $oParams = Json_ObjCreate() Json_ObjPut($oParams, 'source', $sNavShim) _WD_ExecuteCdpCommand($g_sSession, 'Page.addScriptToEvaluateOnNewDocument', $oParams) But this uses Chrome's non-standard CDP (Chrome DevTools Protocol) protocol (redundant, heh), so obviously it works only in Chrome. Firefox's equivalent is the Marionette protocol, but I am not familiar with it, so someone else would have to help you with that.
- 24 replies
-
- firefox
- remote control
-
(and 3 more)
Tagged with:
-
Shorten Web File Name - path too long
TheDcoder replied to TheSaint's topic in AutoIt Example Scripts
For sure, JavaScript is much better but I will miss all those quirky flash games Such type of games will probably be never made again.