January 20, 201016 yr Hi there, Could someone please help me with this PHP command please... <?php echo str_replace("265", "160", $row["video"])?> This is for a client who is inserting the YouTube embed code into a field that gets updated on the site. The values above basically are saying that to replace 265 with 160 (if that value is found in the code - this refers to the height of the video object). However, I ALSO want it to replace the width value from 320 to 198, but I don't know how to add more than one string replace into the above code. I'm good at using PHP but not creating it in some cases! Could someone please help me with this one. Many thanks.
January 20, 201016 yr <?php echo str_replace(array("265", "320"), array("160", "198"), $row["video"])?>
Create an account or sign in to comment