• http.Post help with manipulating buttons
    30 replies, posted
So I want to make a !group command to make the user automatically join a group, yet I have no idea how to. There is literally no examples on how to use the http library. this is all i have: http.Post("http://steamcommunity.com/groups/gmod",{["join_group_form"] = "javascript:document.forms['join_group_form'].submit();"}) (Not the actual group I'm going to use, just set it to a group I'm not in to test the code.) And if you cringe at how it's coded, blame the lack of http library examples, as I have no idea what I'm doing. Also some other examples on how to use this would be nice.
Here's a simple http.Post example. Lua: [lua] http.Post("http://localhost/post.php", { p = "Gmod", a = "Test" }, function(result) if result then print("Done!") end end, function(failed) print(failed) end) [/lua] PHP: [php] <?php $p = $_POST["p"]; $a = $_POST["a"]; $f = fopen("write.html", "w"); fwrite($f, "This is atest. $p $a\n"); fclose($f); ?> [/php]
[QUOTE=Its Pawsative;51198286]Here's a simple http.Post example. Lua: [lua] http.Post("http://localhost/post.php", { p = "Gmod", a = "Test" }, function(result) if result then print("Done!") end end, function(failed) print(failed) end) [/lua] PHP: [php] <?php $p = $_POST["p"]; $a = $_POST["a"]; $f = fopen("write.html", "w"); fwrite($f, "This is atest. $p $a\n"); fclose($f); ?> [/php][/QUOTE] Thanks, but again, I have no idea what I'm doing, and I also need help with steam buttons.
To do what you want you will need to probably login first, which will be kinda impossible to make for you. Or if player is already logged in then this is a nice way to force everyone on your server to group without their confirmation.
[QUOTE=SteppuFIN;51198421]To do what you want you will need to probably login first, which will be kinda impossible to make for you. Or if player is already logged in then this is a nice way to force everyone on your server to group without their confirmation.[/QUOTE] [QUOTE=GbrosMC;51198141]So I want to make a !group command to make the user automatically join a group[/QUOTE]
[QUOTE=GbrosMC;51198461][/QUOTE] And im saying, there can be problem that the client will not be logged in in steam or you could just abuse it and force everyone to join the group even if they dont want to.
[QUOTE=SteppuFIN;51198481]And im saying, there can be problem that the client will not be logged in in steam or you could just abuse it and force everyone to join the group even if they dont want to.[/QUOTE] If they aren't logged into steam I'm sure they wouldn't be on my server.
[QUOTE=GbrosMC;51198543]If they aren't logged into steam I'm sure they wouldn't be on my server.[/QUOTE] :/ Have you noticed that you are not always logged in on browser but are in steam? So when you try even posting, you may not even have the join btn because you are not logged in on the http.Post, which would be a problem because you would need to ask login credentials to login with the http.Post.
[quote]So I want to make a !group command to make the user automatically join a group[/quote] Are you serious? That's not how does it works, and i hope nobody get a way to make auto join into a group because that's really evil Just open the group page and let them to join, but never make something like this automatic, because people just might think that they run !group to open group page so they can join, that doesn't happen always, you're just bruteforcing it So no...Don't even think about that
[QUOTE=GbrosMC;51198141]So I want to make a !group command to make the user automatically join a group.[/QUOTE] :nope:
Why do you guys think I'm not going to tell the player what the command does? I swear to god if you say what I think you're gunna say. :^)
[QUOTE=gonzalolog;51198870]Are you serious? That's not how does it works, and i hope nobody get a way to make auto join into a group because that's really evil [B]Just open the group page and let them to join[/B], but never make something like this automatic, because people just might think that they run !group to open group page so they can join, that doesn't happen always, you're just bruteforcing it So no...Don't even think about that[/QUOTE] I've seen a post sometime ago about someone asking how they can load a client file bypassing sv_allowcslua because he wanted to use it for building Okay...He might be saying the truth, but you still have the problem that you're bypassing a protection system that's highly abusable, doesn't matter the purpose, you're abusing it Asking how can you make autojoin people to your group might be legit...[B]BUT YOU STILL HAVE THE POWER TO FORCE ANYONE TO JOIN IN YOUR GROUP WITHOUT ANY CONCERN[/B]
Even if you put aside the concern about this being abusable as fuck, it's gonna be very impractical to do. You'll have to manually initiate login session, retrieve cookie data that the server sent you, process steamguard shit if required (that includes requesting the confirmation code from the user), and only then try to fiddle with joining groups. It's ridiculously complicated for what it's supposed to do (and gladly so). Just gui.OpenURL() the group homepage so the user can join (or not) by themselves.
Best way: write a steam bot that automatically invites people to your steam group
[QUOTE=meharryp;51199590]Best way: write a steam bot that automatically invites people to your steam group[/QUOTE] Actually it isn't The best way that is actually proven to work is gui.OpenURL EDIT: Why don't you code a steam bot, host it 24/7, pay for a game to make it a premium account, and then on top of all of that, make it tie in with your server to invite people to your group? What was that? You'll just use gui.OpenURL instead? :^) So choosing gui.OpenURL over a steam bot is dumb? Or are you just rating dumb because you're salty?
You are the salty one here, we told you why you shouldnt have this, why it's not practical and why you should look alternatives, and you are like :^) im here not giving a fuck but i get offended by dumb rates Then you are dumb
It's retarded how the people asking for help get salty at the people trying to help. Fuckin asshole
Isn't OP that guy who backdoors addons? Yeah, don't help this kid.
[QUOTE=sannys;51200720]Isn't OP that guy who backdoors addons? Yeah, don't help this kid.[/QUOTE] somewhat [url]https://facepunch.com/showthread.php?t=1536424&p=51173451&viewfull=1#post51173451[/url]
[QUOTE=Lunaversity;51200844]somewhat [url]https://facepunch.com/showthread.php?t=1536424&p=51173451&viewfull=1#post51173451[/url][/QUOTE] Well, "somewhat" is incorrect, considering OP had multiple past addons with backdoors and three past addons with stolen code ( Both plasmids addons used Magenta's viewbob, while Realbase took code from GDCW. ) Here's a link to my thread on the backdoors: [url]https://facepunch.com/showthread.php?t=1531921[/url] And his reaction: [img]https://feen.us/prp2r5psa62544m4iioj.png[/img] More relevant, he has a history of spamming and generally abusing steam policy, which makes it more suspicious he's asking for autojoin specifically. I took this screenshot back on July 31st: [img]https://feen.us/se9zbifnlgva2ca0f0dt.png[/img] and dating proof: [t]https://feen.us/8i5avjlym63xnwstoz01.png[/t] Of course, the "evidence" simply said "TFA is gey" inside. Here's a link to the pastebin so you do't have to type it: [url]http://pastebin.com/vpLPvP3C[/url]. Note the July 30th date.
What a fag
[QUOTE=TFA;51201068]Well, "somewhat" is incorrect, considering OP had multiple past addons with backdoors and three past addons with stolen code ( Both plasmids addons used Magenta's viewbob, while Realbase took code from GDCW. ) Here's a link to my thread on the backdoors: [url]https://facepunch.com/showthread.php?t=1531921[/url] And his reaction: [img]https://feen.us/prp2r5psa62544m4iioj.png[/img] More relevant, he has a history of spamming and generally abusing steam policy, which makes it more suspicious he's asking for autojoin specifically. I took this screenshot back on July 31st: [img]https://feen.us/se9zbifnlgva2ca0f0dt.png[/img] and dating proof: [t]https://feen.us/8i5avjlym63xnwstoz01.png[/t] Of course, the "evidence" simply said "TFA is gey" inside. Here's a link to the pastebin so you do't have to type it: [url]http://pastebin.com/vpLPvP3C[/url]. Note the July 30th date.[/QUOTE] I didn't see the backdoor part I just knew he minifies his code in the workshop for some reason
[QUOTE=Lunaversity;51201109]I didn't see the backdoor part I just knew he minifies his code in the workshop for some reason[/QUOTE] The reason being that backdoors blend in with the legitimate content. Or, of course, [I]anti-theft[/I], because thieves have never heard of prettyprint. I'm aiming to reformat more of his addons in the future for the purpose of inspecting them and verifying they're actually safe, which should be protected under the DMCA. That aside, I'll abstain from further derailing.
i find this somewhat ironic given his lack of willingness to listen and expectation of magical http powers from facepunch [T]https://feen.us/9ox6.png[/T]
whoops -deleted
[QUOTE=TFA;51201134]The reason being that backdoors blend in with the legitimate content. Or, of course, [I]anti-theft[/I], because thieves have never heard of prettyprint. I'm aiming to reformat more of his addons in the future for the purpose of inspecting them and verifying they're actually safe, which should be protected under the DMCA. That aside, I'll abstain from further derailing.[/QUOTE] lol are you my parent or something? [spoiler]overly attached ex girlfriend:^)[/spoiler] [editline]14th October 2016[/editline] [QUOTE=Tupac;51200636]It's retarded how the people asking for help get salty at the people trying to help. Fuckin asshole[/QUOTE] noone is trying to help, they are the ones getting salty
Up until post #8 everyone was trying to help. There's also this post:[QUOTE=meharryp;51199590]Best way: write a steam bot that automatically invites people to your steam group[/QUOTE] Which, even it was sarcastic (I can't tell), is a plausible solution. And then you declared that you already know the best way - gui.OpenURL - which is actually what I was going to suggest you use. So clearly you don't need any more help. If you think anyone minds clicking the big green [b]Join Group[/b] button when the group page opens for them, you're wrong. There is no need to try to remove this step. Doing so will be a security breach (if you can join groups on behalf of the user, you can do all sorts of other stuff too) and anything like that will hopefully get patched quickly by the devs. Use gui.OpenURL.
[QUOTE=GbrosMC;51203509]lol are you my parent or something? [spoiler]overly attached ex girlfriend:^)[/spoiler][/QUOTE] What was the point of this? To demonstrate that you have mental capacity of a 10 year old once again? [QUOTE=GbrosMC;51203509]noone is trying to help, they are the ones getting salty[/QUOTE] Of course not, because people tried originally but then you disregarded everything that has been said to you without any good reason and claimed that "everybody has been salty". Also why are you even still posting here? You've already claimed that [I]gui.OpenURL()[/I] works for you, so why not mark this thread as solved instead of further embarrassing yourself?
[QUOTE=mijyuoon;51203847]To demonstrate that you have mental capacity of a 10 year old once again?[/QUOTE] that's a bit rude to ten year olds, dontchathink? [T]https://feen.us/01bz.png[/T]
[QUOTE=mijyuoon;51203847]What was the point of this? To demonstrate that you have mental capacity of a 10 year old once again? Of course not, because people tried originally but then you disregarded everything that has been said to you without any good reason and claimed that "everybody has been salty". Also why are you even still posting here? You've already claimed that [I]gui.OpenURL()[/I] works for you, so why not mark this thread as solved instead of further embarrassing yourself?[/QUOTE] already claimed that gui.OpenURL() works better than a whole steam bot* you genius
Sorry, you need to Log In to post a reply to this thread.