Last active
April 27, 2017 10:53
-
-
Save mootari/ffef1d6b0a1a3dddbe1c3ce9f6887618 to your computer and use it in GitHub Desktop.
Drupal 7: Regenerate pathauto aliases for existing nodes (per type).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$type = 'my_node_type'; $nids = db_query('select nid from node where type = :type', array(':type' => $type))->fetchCol(); pathauto_node_update_alias_multiple($nids, 'bulkupdate', array('message' => TRUE)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment