[Solved] remove part of string after a special character September 11, 2022 by Kirat $string = current(explode('*', 'something*10')); As found here : REF Running Example : IDEONE 0 solved remove part of string after a special character