Add URL Trigger Action


(Andrew Harris) #1

Matrix Version: v5.4.3.1

I’ve almost fully automated the set up of user training in our system, the last step being to assign a URL to a site, based on the trainee’s username, eg: mysite.training.org/username.

Unfortunately, the Add URL Trigger Action only seems to accept a hard coded value, I can’t pass it variables. Is that right?

Add URL
This action adds an additional URL to the asset.
Enter the URL that you want to add into the field provided and tick either HTTP or HTTPS.


(Bart Banda) #2

Unfortunately not, getting released in 5.4.3.0 though https://squizmap.squiz.net/matrix/11300

Could you maybe create it and then use the Set Attribute action (or JS API?) to set the Site’s URL?


(Andrew Harris) #3

Sadly, the Set Attribute action for Site assets only allows Name, and a couple of other obscure attributes (not_found_page_cache_globally, available_conditions), so that’s not an option.

I was so puzzled by your comment about a release in 5.4.3.0, until I realised I’d transposed the 3 and 1 in our Matrix version on my original message - d’oh!

Again, I guess I can wait - just want to keep this trigger small and self contained.


#4

You could use set attribute (url_suffix ) to append query parameter to the end of the URL (e.g. ?user=[username]) and then use that value to handle your custom actions (e.g. create page asset with their name etc.)

Alternatively, you could use create asset action to create the user’s page and then redirect them to that page.


(Andrew Harris) #5

Petri, thanks - all solid ideas, but I really do need to set the URL of a Site Asset.


#6

You do understand that you need to create an asset to have that URL? If you don’t want to have an asset, you need to create entry in remap manager.