Custom Content Type Manager
custom field MultiSelect (list of link) (3 posts)

  1. yukiko-kawa
    Posted 2 years ago #

    I looked at the website guide of your plugin, but I have not found a solution.
    So I ask here.

    I have to create a "multiselect" checkbox to select a series of external sites.
    The key elements: site name, site address.
    What the user sees in admin: Site Name.
    What the user sees in front: a link with the name of the site, pointing at the url of site.

    eg: SiteA -> http://www.sitoA.net

    Tests carried out:
    1) fill in the "Options" the name of the site, and in "Stored Values" the url.
    problems: filling in the template do not know how to retrieve the value of Options.

    eg Site link </ strong>
    <? php print_custom_field ('fansub: formatted_list', ',');?>

    2) impost "Alternate Input" with SiteA || SiteA </ a>
    but does not allow me to load the link code and not even see where these changes valor.


    I think it's just the right code in the template that calls both "Stored Values​​" and "Options", but I do not know what value or variable to call "Options". and then are blocked.

    Please, help me,
    thank you very much


  2. fireproofsocks
    Plugin Author

    Posted 2 years ago #

    I think you're on the right track... I'm not sure what you mean for some of that -- I think you didn't format your code correctly. I would avoid putting HTML into your field options, however. Print those only in the template. So define your multiselect field to use unique options/values like this screenshot:


    Then in your template, you would have to iterate over the values and make them into links. E.g. using the "formatted_list" output filter:

            array('<li><a href="[+value+]">[+value+]</a></li>',
             '<ul>[+content+]</ul>') );

    There might be a bug here, though... I can't recall off the top of my head if the multi-select field is supposed to store the options and values, or just the values. I think it's just the options, so you'd have to do more work if you wanted to print out the same text that users saw in the manager, or put the link it its entirety as the value to begin with.

  3. yukiko-kawa
    Posted 2 years ago #


Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Custom Content Type Manager
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic