Remove Assets Scripts

Last Updated: 24 Aug 2018

This chapter outlines the remove asset scripts available within Squiz Matrix.

remove_asset_type.php

The remove_asset_type.php script removes all assets of the specified type, and then removes the asset type itself from your Matrix system. This script is useful when repairing an upgrade or uninstalling a package. Please use with caution, as this script is not aware of asset type inheritance. For example removing the page_asset_builder type, will break any page_account_manager assets you may have set up.

This script is located in the /scripts directory of your Squiz Matrix system and takes the following parameters:

  • the system root
  • the asset type to remove

remove_assets_of_type.php

The remove_assets_of_type.php script removes all assets of the specified type from your Squiz Matrix system. Please note that this script is not aware of asset type inheritance. For example, removing assets of type page_asset_builder will not remove page_account_manager.

This script is located in the /scripts directory of your Squiz Matrix system and takes the following parameters:

  • the system root
  • the asset type of assets to remove

remove_form_submission.php

This script removes form submissions created between two specified dates (does not remove incomplete form submissions).

This script is located in the /scripts directory of your Squiz Matrix system and takes the following parameters:

  • the system root
  • the asset ID of the custom form to remove the submissions from
  • the date from
  • the date until which submissions will be removed (both dates in the format YYYY-MM-DD)

Example

$ php remove_form_submission.php [system_root] 69 2002-01-01 2008-01-11 

Found 2 form submission(s) for 'Custom Form' (#30)
(Date range: 2002-01-01 00:00:00 to 2008-01-01 23:59:59)
 
Removing assets ...
        Updating link table...
        Updating link tree table ...
        Updating attribute value table ...
 
Done

Previous Chapter Next Chapter

The Latest

Let Us Know What You Think

Let us know if you spot any errors or if you have any ideas on how we can improve the Matrix Community Website.

Contact Squiz for Demo

Let us show you the true power of Squiz Matrix by giving you a personalised demonstration.