Remove before import with php

Hi!
Anyone know how to code this:
i have in a value inside ( value ) in some of my posts in excel and i want to remove everything before it imports " included ( and ) and of course the value it self"
example:
I got a ( red ) car!

should be after import

I got a car!

Anyone got an idéa

PHP has a great function ereg_replace that will search for a pattern (using Regular Expressions) and replace it.
In your case, replace it with NOTHING.

Hi!
can you show me how tofix that its replace everything included the () problem is that the value is different in all the files.
here is my import query:


     if (($handle = $source_file) !== FALSE) { 
        $columns = fgetcsv($handle, 10000, ";"); 
        foreach ($columns as &$column) { 
            $column = str_replace(".","",$column); 
        } 
        $insert_query_prefix = "INSERT INTO test (".join(",",$columns).")\
VALUES";
         while (($data = fgetcsv($handle, 10000, ";")) !== FALSE) { 
            while (count($data)<count($columns)) 
                array_push($data, NULL); 
            $query = "$insert_query_prefix (".join(",",quote_all_array($data)).");";
			 mysql_query($query); 
        } 

ereg_replace has been deprecated as of php 5.3.0. You can use preg_replace to do the replacement. Take a look at the following example.

$s = "I got a ( red ) car!";
$pattern = '#\\([^)]+\\)#';
$s = preg_replace($pattern, "", $s);
$s = preg_replace('#\\s{2,}#', " ", $s);
echo $s;

yes i saw that when i read the tread he posted
one more question:
is it possible to narrow it down to the pattern =
( Gå till … … … . . … . ) " i would like to remove every pattern that starts with ( Gå till
so it keeps rows like this:
( Drunk )

if you understand what i mean

Try the following pattern

$pattern = '#\\(\\s*Gå till[^)]+\\)#';

were in my code should i try to put this so it insert after this is done?

Or can i put this as a function?