Support

Account

Home Forums ACF PRO a value retrieved via 'acf/validate_value' is double-backslashed.

Solved

a value retrieved via 'acf/validate_value' is double-backslashed.

  • Hi to support team.

    I found this strange behavior.

    On the condition of a existing text field with “(backslash)n” inputted,
    When I get a value of the field above via get_field() or get_post_meta(),
    the value is “(backslash)n” as inputted.
    But when I get a value of the field via ‘acf/validate_value’,
    the value is “(backslash)(backslash)n”.

    I am using ACF PRO v5.6.10.

    Is it designed or bug?

    Thanks in advance.

    Regards

  • Does it happen to me only…?

  • When validating values you need to take the backslashes into account. No it is not happening only to you, but is the way that the values are passed. This can be caused by your php installation and the “Magic Quotes” setting.

  • Thanks for your reply @hube2

    You cleared my mind!

    (I should have read core of ACF first…)

    Regards

Viewing 4 posts - 1 through 4 (of 4 total)

The topic ‘a value retrieved via 'acf/validate_value' is double-backslashed.’ is closed to new replies.