Q:

Combine multiple custom field values into single value

I'm sure this is a fairly basic question but I can't seem to get it right. 
I have multiple custom field values for addresses in my custom post type and I want to save them as a single value or array so I can display them in one call rather than many. I would also like to output the address comma separated, but first need to preg replace any commas entered by the user in the wordpress backend so I don't end up with, for example, '10 high street,, London,, W11 1TT' 
I have this currently:
<?php global $post;
$address_name = get_post_meta( $post->ID, '_mfl_entry_address_name', true );
$address_street = get_post_meta( $post->ID, '_mfl_entry_address_street', true );
$address_line_2 = get_post_meta( $post->ID, '_mfl_entry_address_line_2', true );
$address_line_3 = get_post_meta( $post->ID, '_mfl_entry_address_line_3', true );
$address_postcode = get_post_meta( $post->ID, '_mfl_entry_address_postcode', true );
?>

How would I put these into a single value called 'address', clean out any commas added by the user, then output the address with each value separated by a comma, except the last one?
Thanks for any help

A:

Updated
    <?php global $post;
    $address_name = str_replace(
        ',', 
        '',
         get_post_meta( $post->ID, '_mfl_entry_address_name', true )
    );

    $address_street = str_replace(
        ',', 
        '',
         get_post_meta( $post->ID, '_mfl_entry_address_street', true )
    );

    $address_line_2 = str_replace(
        ',', 
        '',
         get_post_meta( $post->ID, '_mfl_entry_address_line_2', true )
    );

    $address_line_3 = str_replace(
        ',', 
        '',
         get_post_meta( $post->ID, '_mfl_entry_address_line_3', true )
    );

    $address_postcode = str_replace(
        ',', 
        '',
         get_post_meta( $post->ID, '_mfl_entry_address_postcode', true )
    );

    $full_address = array(
        $address_name, 
        $address_street, 
        $address_line_2,
        $address_line_3,
        $address_postcode
    );

    $output = '';
    $glue = ',';
    foreach($full_address as $value){
        if(!empty($value)){
            $output .= $value.$glue;
        }
    }
    $output = trim($output, $glue);

    echo $output;
    ?>

Let me know if that works.

