To any one who can help out, many thanks ahead of time...
Here is my question: I insert the variable $item into my database, which you can see below... Then, on an edit form, I need to get just the name of the graphic to a varible by itself utilizing the ereg_replace function, but I can't seem to get it to work. Below the $item variable, you will see what I am currently using...
$item = "<TABLE ALIGN=\"left\" WIDTH=\"$graphic_width\" CELLSPACING=2 CELLPADDING=0 BORDER=0><TR><TD ALIGN=\"center\">\n<!-- graphic --><IMG SRC=\"http://www.tfid.org/pictures/$graphic_name\" WIDTH=\"$graphic_width\" HEIGHT=\"$graphic_height\" ><!-- graphic -->\n</TD></TR>\n<TR><TD ALIGN=\"center\"><FONT FACE=\"arial\" SIZE=2>\n<B><!-- graphic_caption -->".ereg_replace("\"",""",$HTTP_POST_VARS[graphic_caption])."<!-- graphic_caption --></B>\n</FONT></TD></TR></TABLE>\n";
Here is my ereg_replace function:
$existing_graphic = ereg_replace(".<!-- graphic --><IMG SRC=\"http://www.tfid.org/pictures/([\"])\"><!-- graphic -->.*$","\1",$rowarray[item]);
I am trying to get just the name of the graphic when I echo my $existing_graphic. Again, thanks for any assistance given. CJ