How to make this:
from this:Code:SELECT%20name%20FROM%20items%20WHERE%20id%20=%201
How to convert spaces to %20? I need this for connecting with my database because else it won't work.Code:SELECT name FROM items WHERE id = 1![]()
How to make this:
from this:Code:SELECT%20name%20FROM%20items%20WHERE%20id%20=%201
How to convert spaces to %20? I need this for connecting with my database because else it won't work.Code:SELECT name FROM items WHERE id = 1![]()
ctrl+r -> add a space char to the first textbox -> add %20 to second text box -> replace all
get a string of whatever you will send to your database, and before you send it, use the replace(); function (or replaceWrap(); )
Can you please give an example, I try it but I don't understand the last thing you have to put in....
Simba Code:program New;
{$i SRL\SRL.simba} // includes all main functions
var
Q,R : string;
F : TReplaceFlags;
begin
SetupSRL; // essential function to make bots work
Q := 'Test Test Test Test';
//R := Replace(Q,' ','20',F);
R := ReplaceWrap(Q,' ','%20',F);
writeln(R);
end.
it only replaces it once... :S
Simba Code:program new;
{$I SRL/SRL.simba}
var
Q,R,D : string;
F : TReplaceFlags;
begin
setupsrl;
Q := 'Test Test Test Test';
D := ReplaceWrap(Q,' ','%20',F);
while(D<>R)do
begin
R:= D;
D := ReplaceWrap(D,' ','%20',F);
end;
writeln(R);
end.
No need for all that.
Simba Code:ReplaceRegExpr('%20', 'SELECT%20name%20FROM%20items%20WHERE%20id%20=%201', ' ', True)
I'll finish my RegEx tutorial eventually. 20 Lines turns into 1.
I am Ggzz..
Hackintosher
There are currently 1 users browsing this thread. (0 members and 1 guests)