Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Register Script and Gump
Author Message
larmc20
Journeyman
*

Posts: 67
Likes Given: 0
Likes Received: 1 in 1 posts
Joined: May 2013
Reputation: 0



Post: #1
Register Script and Gump
Hello Guys, I have made a gump register menu but I have a doubt. How can I make the OKAY button to, when pressed, record the lines and save in a SCP file on Accounts folder? To save a list like
login
Password
Full Name (Nome Completo)
E-mail
Rg (Personal Brazilian Id)

Can you Help me doing that?

Have a look [Image: menucadastro.png]

PHP Code:
// Created 01/06/2013 15:48:03, with Gump Studio.
// Exported with with SphereExporter ver 1.1.
// Script for 0.56/Revisions

[DIALOG d_cadastros]
99,51
NOCLOSE
NOMOVE
NODISPOSE
page 0
resizepic 93 52 9200 354 388
gumppic 197 70 100
text 235 84 0 0
text 218 125 0 1
gumppic 90 27 52
htmlgump 175 184 200 100 2 1 1
gumppic 102 296 2430
textentry 120 301 308 20 0 1 3
textentry 117 332 308 20 0 2 4
textentry 120 362 304 20 0 3 5
button 235 411 247 248 1 0 0

[DIALOG d_cadastros text]
Bem-Vindo
Conamidia Shard
Boa tarde
Seja bem vindo ao Conamíia ShardAqui você encontrará aventuras e diversão com outros jogadoresRespeite os jogadores assim como o servidorO intuito do servidor e proporcionar diversão a todosCaso encontre algum bugfavor contatar os resposáveis pelos servidor.

Nome Completo
E
-mail
RG

[DIALOG d_cadastros button]
ON=0
// Button 1
// 


[EOF

I was thinking doing like
PHP Code:
[DIALOG d_cadastros button]
ON=0
// Button 1
// 
Writefile contas/<tag.newbmenu.defname>.scp
 SYSMESSAGE 
@044,,1 Cadastro [<TAG.src.name>] successfully saved

But How can I do to the button take the words which fill those TEXT ENTRIES and save in the file?
(This post was last modified: 06-02-2013 06:12 AM by larmc20.)
06-02-2013 05:00 AM
Find all posts by this user Like Post Quote this message in a reply
Mordaunt
Super Moderator
****

Posts: 1,237
Likes Given: 26
Likes Received: 55 in 43 posts
Joined: Mar 2012
Reputation: 35



Post: #2
RE: Register Script and Gump
Your text entries are recorded as:

<ARGTXT[0]>
<ARGTXT[1]>
<ARGTXT[2]>

[Image: 2nis46r.jpg]
06-02-2013 06:18 AM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
larmc20
Journeyman
*

Posts: 67
Likes Given: 0
Likes Received: 1 in 1 posts
Joined: May 2013
Reputation: 0



Post: #3
RE: Register Script and Gump
Well, so let me try, see if its correct please.
PHP Code:
[DIALOG d_cadastros button]
ON=0 3  
// Button 1
TAG.NAME <ARGTXT[1]> 
TAG.EMAIL <ARGTXT[2]>           
TAG.RG <ARGTXT[3]>
WRITEFILE CONTAS/<TAG.CONTAS>.scp NAME=<TAG.NAME>
WRITEFILE CONTAS/<TAG.CONTAS>.scp EMAIL=<TAG.EMAIL>
WRITEFILE CONTAS/<TAG.CONTAS>.scp RG=<TAG.RG
(This post was last modified: 06-02-2013 06:36 AM by larmc20.)
06-02-2013 06:35 AM
Find all posts by this user Like Post Quote this message in a reply
Mordaunt
Super Moderator
****

Posts: 1,237
Likes Given: 26
Likes Received: 55 in 43 posts
Joined: Mar 2012
Reputation: 35



Post: #4
RE: Register Script and Gump
You shouldn't need to tag them honestly

Code:
WRITEFILE CONTAS/<TAG.CONTAS>.scp NAME=<ARGTXT[1]>
WRITEFILE CONTAS/<TAG.CONTAS>.scp EMAIL=<ARGTXT[2]>
WRITEFILE CONTAS/<TAG.CONTAS>.scp RG=<ARGTXT[3]>

should work fine.

[Image: 2nis46r.jpg]
06-02-2013 12:15 PM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
larmc20
Journeyman
*

Posts: 67
Likes Given: 0
Likes Received: 1 in 1 posts
Joined: May 2013
Reputation: 0



Post: #5
RE: Register Script and Gump
Still not working =//... It is not creating the file in the folder contas. I tried to change the name of the file.scp but still not working =//!
[DIALOG d_cadastros button]
ON=0
// Button 1
//

wRITEFILE CONTAS/cadastros.scp NAME=<ARGTXT[1]>
WRITEFILE CONTAS/Cadastros.scp EMAIL=<ARGTXT[2]>
WRITEFILE CONTAS/Cadastros.scp RG=<ARGTXT[3]>
06-02-2013 03:40 PM
Find all posts by this user Like Post Quote this message in a reply
Rattlehead
Master
**

Posts: 290
Likes Given: 3
Likes Received: 8 in 6 posts
Joined: Jun 2012
Reputation: 8



Post: #6
RE: Register Script and Gump
first of all, the folder has to exist, if there is no folder, then u will get an error

second, why keep the name of the folder in a tag?? seems like to me the folder name will always be the same anyway, correct me if i am wrong.

third, are you sure you have the correct folder name saved in 'tag.contas' ?

you should try;

WRITEFILE cadastros.scp NAME=<ARGTXT[1]>
WRITEFILE Cadastros.scp EMAIL=<ARGTXT[2]>
WRITEFILE Cadastros.scp RG=<ARGTXT[3]>

just to see if it works, this will end up in ur main sphere folder, if it does, then you have folder naming issues.

[Image: matts_siggy.gif]
06-02-2013 06:23 PM
Find all posts by this user Like Post Quote this message in a reply
larmc20
Journeyman
*

Posts: 67
Likes Given: 0
Likes Received: 1 in 1 posts
Joined: May 2013
Reputation: 0



Post: #7
RE: Register Script and Gump
Hey mates, It worked really fine...
Thank you so much.
I have done like

[DIALOG d_cadastros button]
ON=0
WRITEFILE cadastros.scp Conta=<src.account>
wRITEFILE cadastros.scp NAME=<ARGTXT[1]>
WRITEFILE Cadastros.scp EMAIL=<ARGTXT[2]>
WRITEFILE Cadastros.scp RG=<ARGTXT[3]>

Now I can see the account; NAME; E-MAIL; RG(PERSONAL ID) in a file...

Thank you both
06-03-2013 01:22 AM
Find all posts by this user Like Post Quote this message in a reply
babazar
Journeyman
*

Posts: 189
Likes Given: 2
Likes Received: 10 in 9 posts
Joined: Jun 2013
Reputation: 0



Post: #8
RE: Register Script and Gump
do u have an english version?
07-17-2013 11:46 PM
Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)