def variable_value(request, field_name):
    """Check field in POST/GET request and return field value

    Depreciated : It will be replaced by getvar
    """
    if request.method == 'GET':
        if field_name in request.GET:
            field_name = request.GET[field_name]
        else:
            field_name = ''
    if request.method == 'POST':
        if field_name in request.POST:
            field_name = request.POST[field_name]
        else:
            field_name = ''
    return field_name
