Results 1 to 3 of 3

Thread: Formatting text in combinedvalues ?

  1. #1
    User
    Join Date
    04-01-10.
    Posts
    289

    Default Formatting text in combinedvalues ?

    Hi everyone,

    In my MM, I have 4 attributes : adress1, adress2, zip and city. And a combinedvalues AllAdress.
    In the FE, I need to display : "adresse1, zip city" or "adress1, adress2, zip city" (with commas only when necessary).

    In my combinedvalue, I can add "," after the concerned %s but it is always displayed even if the attribute is empty. And I can't use css ::after as I can't IDentifie each element.

    What is the way to have the adress correctly formatted and displayed ?

    Thanks.

  2. #2
    User zonky's Avatar
    Join Date
    11-29-11.
    Location
    Berlin
    Posts
    159

    Default

    in my minde it´s not possible to use a ternary operator in sprintf :-(

    https://www.google.de/search?client=...k1.EBwmCzrMksc

  3. #3
    User
    Join Date
    04-01-10.
    Posts
    289

    Default

    ok. So I have to create my own template…

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •