hakuren Posted February 3, 2014 Group: Members Topic Count: 120 Topics Per Day: 0.02 Content Count: 295 Reputation: 6 Joined: 12/02/11 Last Seen: November 6, 2023 Share Posted February 3, 2014 (edited) how to disable all the symbol using input only letters and number ex. input @input$; if ( no input symbol == 1) all the symbol will become error sorry bad english Edited February 3, 2014 by hakuren Quote Link to comment Share on other sites More sharing options...
AnnieRuru Posted February 5, 2014 Group: Members Topic Count: 18 Topics Per Day: 0.00 Content Count: 2044 Reputation: 682 Joined: 10/09/12 Last Seen: December 20, 2020 Share Posted February 5, 2014 prontera,155,185,5 script sdkfjhsdkfh2 100,{ input .@test$; query_sql "select '"+ escape_sql( .@test$ )+"' regexp '^[a-z0-9]+$'", .@value; if ( .@value ) dispbottom "pass"; else dispbottom "fail"; end; }------ OR ------ prontera,150,185,5 script sdkfjhsdkfh 100,{ input .@test$; if ( preg_match( "^[a-zA-Z0-9]+$", .@test$ ) ) dispbottom "pass"; else dispbottom "fail"; end; }I still remember last time during eathena times, this preg_match crashed my eathena 12068 test serverI couldn't remember what was the syntax already ... it was 3 years ago I didn't post on the forum because it was just a custom modification release at the time if you guys able to find the bug then file a report then ... because now this is an official script command =/ Quote Link to comment Share on other sites More sharing options...
Kido Posted February 5, 2014 Group: Members Topic Count: 127 Topics Per Day: 0.03 Content Count: 1445 Reputation: 164 Joined: 08/17/13 Last Seen: July 11, 2019 Share Posted February 5, 2014 as far as i know that can't be just thell them to don't use symbols (?) http://rathena.org/wiki/Input have you tryied to search on script_commans.txt D:? i couldn't find something to prevent this Quote Link to comment Share on other sites More sharing options...
hakuren Posted February 5, 2014 Group: Members Topic Count: 120 Topics Per Day: 0.02 Content Count: 295 Reputation: 6 Joined: 12/02/11 Last Seen: November 6, 2023 Author Share Posted February 5, 2014 prontera,155,185,5 script sdkfjhsdkfh2 100,{ input .@test$; query_sql "select '"+ escape_sql( .@test$ )+"' regexp '^[a-z0-9]+$'", .@value; if ( .@value ) dispbottom "pass"; else dispbottom "fail"; end; }------ OR ------ prontera,150,185,5 script sdkfjhsdkfh 100,{ input .@test$; if ( preg_match( "^[a-zA-Z0-9]+$", .@test$ ) ) dispbottom "pass"; else dispbottom "fail"; end; }I still remember last time during eathena times, this preg_match crashed my eathena 12068 test serverI couldn't remember what was the syntax already ... it was 3 years ago I didn't post on the forum because it was just a custom modification release at the time if you guys able to find the bug then file a report then ... because now this is an official script command =/ yes it works! [quote] prontera,155,185,5 script sdkfjhsdkfh2 100,{ input .@test$; query_sql "select '"+ escape_sql( .@test$ )+"' regexp '^[a-z0-9]+", .@value; if ( .@value ) dispbottom "pass"; else dispbottom "fail"; end; } thank you so much Quote Link to comment Share on other sites More sharing options...
Question
hakuren
how to disable all the symbol using input only letters and number
ex. input @input$;
if ( no input symbol == 1)
all the symbol will become error
sorry bad english
Edited by hakurenLink to comment
Share on other sites
3 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.