Upgrade EXT:ajaxselectlist

Upgrading from EXT:ajaxseleclist 1.0 or 2.x to 3.x

As Version 3.x provides several new features, it’s mandatory that you perform the following tasks:

  1. Add the new field for image zoom (see 1. Update database below)
  2. Adapt your templates (see 2. Adapt your templates below)
  3. Add ‘Click-enlarge (image_zoom)’ permission for your editors (in Backend usergroup’s Access Lists)
  4. If you want to use a lightbox within your option records, you’ll have to extend the Ajax call. See Using a lightbox within option records

Although EXT:ajaxselectlist now supports new media types (such as videos), your already used images are still properly linked in your option records.

1. Update database

You’ll have to add the new field for image zoom. This can be achieved by any of these three options:

  1. This extension provides a convenient update script that you can start within the Extension Manager. One click - done.
  2. Open the Install Tool and use the Database analyzer
  3. Uninstall and reinstall this extension

2. Adapt your templates

Formerly used if-clause:

<f:if condition="{optionRecord.image}">
    <f:image src="{optionRecord.image.originalResource.uid}"
             treatIdAsReference="1"
             alt="{optionRecord.image.originalResource.altText}"
             title="{optionRecord.image.originalResource.title}"
             width="50"/>
</f:if>

New iteration of media:

<f:for each="{optionRecord.image}" as="falmedia">
    <f:image src="{falmedia.originalResource.uid}"
             treatIdAsReference="1"
             alt="{falmedia.originalResource.altText}"
             title="{falmedia.originalResource.title}"
             maxHeight="{settings.media.image.maxHeight}"
             maxWidth="{settings.media.image.maxWidth}"/>
</f:for>

Tip

To benefit from all new features, you should adopt the enhancements from the new Partial Media.html, which is based on fluid_styled_content.