Trigger to update webpaths

Matrix 3.18


I'm trying to set a trigger that adds a webpath when an assets metadata field is updated.


  1. User changes MD field A on asset named "cheese" from "brie" to "stilton" - commits changes
  2. Trigger runs (on Metadata changed)
  3. Trigger sets new webpath as follows %asset_metadata_A%__%asset_name%



    I would expect to get the following webpath "stilton__cheese"

    What I get is "brie__cheese"



    If I then change the MD field A to "edam" the webpath changes to "stilton__cheese"



    SO, it runs, but it seems to create the new webpath BEFORE it saves the updated MD value.



    Does anyone know any way around this?





    And while I'm here - Is there a way of adding a remap other than site/assetID ?



    Cheers



    Karl

Try using the "After Asset Metadata Updated" event. Not sure if that is in 3.18 though, that version is getting old.

A-ha!


No, it isn't.



What a shame. Any other ideas anyone?



Cheers