![]() |
STRREPLACE - Printable Version +- SphereCommunity (https://forum.spherecommunity.net) +-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d) +--- Forum: Script Submissions (/Forum-Script-Submissions) +--- Thread: STRREPLACE (/Thread-STRREPLACE--3734) |
STRREPLACE - Crusader - 09-04-2014 06:07 PM oh no another one! yes, that's mine. takes into account commas too....but ofc might be improved, feel free to post improvements below =) Code: [FUNCTION STRREPLACE] edit oh right, commas, thx mordy. RE: STRREPLACE - Mordaunt - 09-05-2014 04:28 AM comas huh... interesting.. not sure how one would type while in a coma but still..... Oh I'm sorry did you mean commas? ![]() RE: STRREPLACE - Extreme - 09-05-2014 06:08 AM Hahhahahahha don't fuck mordaunt.. RE: STRREPLACE - Extreme - 09-05-2014 12:11 PM Here is my STR custom functions. STRSTR WORD,PHRASE RETURN the position of the first WORD found on PHRASE, -1 if don't find. PHP Code: [FUNCTION STRSTR] STRREPLACE OLDWORD,NEWWORD,PHRASE RETURN PHRASE with ALL found OLDWORD's changed to NEWWORLD's PHP Code: [FUNCTION STRREPLACE] STRREPLACEONCE OLDWORD,NEWWORD,PHRASE RETURN PHRASE with only one OLDWORD changed to NEWWORD PHP Code: [FUNCTION STRREPLACEONCE] PS: both STRREPLACE and STRREPLACEONCE needs the function STRSTR! RE: STRREPLACE - Extreme - 09-06-2014 05:35 AM Well... [FUNCTION ISPAIR] RETURN <QVAL <EVAL <ARGS>%2>?0:1> RE: STRREPLACE - kn4tseb - 09-06-2014 05:47 AM never tried the qval operarator... ;] nice btw, ty whats the "%" for? is it too long to explain? RE: STRREPLACE - XuN - 09-06-2014 11:05 PM http://en.wikipedia.org/wiki/Modulo_operation RE: STRREPLACE - kn4tseb - 09-07-2014 03:03 AM ohhh .. understood, thanks XuN |