0

I need to remove one tr line, with 2x td - 1x "Product code", second random value.

Tried with this query:

$vendorrefenrceremovefi =  mysql_query("
UPDATE ps_product_lang 
SET description = REPLACE
(description,  '<tr><td>Product code</td><td>C%</td></tr><tr class=\"info\" bgcolor=#F3F3F3><td>Original Part Number',  
'<tr class=\"info\" bgcolor=#F3F3F3><td>Original Part Number' );
"  ,$db) or die(mysql_error()) ;    

But it doesn't work.

The original code:

<tr><td>Product code</td><td>CXXX</td></tr><tr class="info" bgcolor=#F3F3F3><td>Original Part Number</td><td>

The xx can be a random value.

alecxe
  • 462,703
  • 120
  • 1,088
  • 1,195
user2421781
  • 399
  • 2
  • 5
  • 16
  • "But the doesn't work." - what does that mean? Do you get an error? Which? Does the query crash? How? Does nothing happen at all? Does the universe implode? – arkascha Jun 02 '15 at 10:47
  • nothing happen at all – user2421781 Jun 02 '15 at 10:48
  • Replace does not work this way. Check http://stackoverflow.com/a/986870/1786423 and http://stackoverflow.com/a/21998359/1786423 for alternatives. – jkavalik Jun 02 '15 at 10:49

0 Answers0