I upgraded to the latest version yesterday (not sure if it's related though), and when I today needed to change some alias settings and update all nodes of a certain type, this happens:
* I select all nodes I want to update (on admin/content/node). I select Update URL alias in the Operations dropdown, and save. Result -> Alias is deleted on all selected nodes, setting them back to node/nid!
* I select all nodes again, thinking that this time new aliases will be created, since they at this time don't have an alias. Hit save, and nothing happens. All nodes still have no alias.
When I go and edit each one of these nodes, I have to select Automatic Alias, which is unchecked, after which a new alias is created when saved.
How do I bulk update a bunch of nodes aliases? I'd really hate to go in and edit 1200 nodes manually...
| Comment | File | Size | Author |
|---|---|---|---|
| #4 | pathauto.module.patch | 554 bytes | anon |
Comments
Comment #1
jmlane commentedWhat if you go to admin/build/path/pathauto and under "Node path settings" check the "Bulk generate aliases for nodes that are not aliased" checkbox? Be sure to check the alias patterns are correct for your various content types before you hit save configuration.
That is how I've been doing my bulk alias updates, which is working fine in both 6.x-1.2 and 6.x-2.x.
Comment #2
blackdog commentedNope, no aliases created that way either...
Comment #3
univac commentedsubscribe
bulk update does not work with my installation either. got a blank page...
am running D6.14 + i18n-6.x-1.1 + cck-6.x-2.5 + Token-6.x-1.12 +...
Comment #4
anonThe problem is that the node language isnt passed to the "pathauto_create_alias" function when do a bulk update path alias.
6.x-1.1 has the same problem.
Here is a patch that resolves the issue (for 6.x-1.2)
Comment #5
anonComment #6
gregglesWill this also work on sites that do not use locales? Is this a duplicate of any other issues in the queue?
Comment #7
univac commentedHi anon and greggles,
thanks for the quick patch.
Unfortunately it does not work in my case. The behavior is very much the same and I get a blank page after waiting several seconds.
Thanks again,
univac
Comment #8
gregglesBlank page means you ran out of memory. Try increasing your php.ini memory_limit value (search for details on how to do this - it is called a WSOD).
Comment #9
blackdog commented@greggles - I don't see how this would affect sites without i18n needs, but I haven't tried it. This issue solves the bulk updating to work for i18n enabled sites, I can't see any other issues that does that.
The patch in #4 solves the issue I had, because without
$node->language, pathauto_create_alias() will always resolve to using no language dependent patterns. See this snippet from pathauto_create_alias():Comment #10
univac commented@greggles
thanks for you prompt reply.
I use 128M as php memory limit, which is quite a lot. I have even raised to 512M for testing purpose, but with no luck.
Moreover I have really a few nodes in my testing environment.
By the way, the creation of single aliases works fine.
Thanks again,
univac
UPDATE: I have the very same problem with Path module. I have created an issue under the latter project.
Comment #11
mindaugasd commentedI deleted all users aliases and I want to bulk generate new aliases. But it do not work. It says "Bulk generation of users completed, 0 aliases generated." now none users have one.
Comment #12
LaurenH commented#11 describes my problem exactly. I was trying to change the way that paths were auto-generated for users, and so I deleted all existing aliases. Creating the new aliases does not work.
Comment #13
PieWie commentedhi
i have the same problem
I downgrade to 6.x.-1.1 end this problem dose exist
Comment #14
IbnDrupal commentedI've moved this back to work as it isn't fixed and downgrading to a previous version is not a fix, although I can confirm that even downgrading doesn't fix the problem.
Just to confirm this is the issue.
I deleted all my taxonomy aliases (about 1200).
I then tried to use the bulk setting feature to recreated them. I am doing 200 at a time so memory is not a problem.
I get the following message
I tried the patch and it does not fix the problem. I even checked the database table url_alias and nothing.
And I maybe wrong about this, but it isn't an internationalisation problem as its all in English.
Comment #15
izmeez commentedsubscribe
Comment #16
IbnDrupal commentedOK guys, I've solved this problem for me. (#14, #11 and several others including parent)
Go to
admin/build/path/pathauto-> "automated alias settings" -> "General Settings"and change the "Update Actions:" settings to "Create a new alias. Delete the old alias." (Mine was set to "Do nothing. Leave the old alias intact")
Then when I use the bulk update it worked.
I'm moving this to fixed as the following issues deal with the problem of the "Do nothing...." setting:
#478718: Update action "do nothing" should do more...
#285042: "Do Nothing" Should Still create aliases for unaliased items
Comment #17
IbnDrupal commentedComment #18
hass commented#639512: Massgeneration of aliases creates only 50 links!? What's about the other 120.000 aliases? seems to be a follow up. I haven't found any batch API/cron stuff in the module so I expect that this bulk update doesn't work reliable. Aside - I need to update 120.000-180.000 aliases.
Comment #19
blackdog commentedOk, we have several different issues here. My post (#1) was regarding updating aliases on a multilingual site.
My issue is fixed with the patch in #4. That patch has nothing to do with some of the other issues here.
Other people here has taken over the issue with other problems with bulk updating etc.
@hass (#18) - use the Views bulk operations module if you can. It uses the Batch API.
Comment #20
hass commentedOT: This bug have nothing to do with Views.
Comment #21
blackdog commented@hass - I know. I was just suggesting a solution if you need it right now.
Comment #22
ressaI also have the problem of URL aliases not being generated on a multilingual web site, after deletion of aliases.
The patch in #4, does not solve the problem, sadly...
Comment #23
AlanAtLarge commentedHi
The original post in this thread says the problem begins with 1200 Nodes that have, "Automatic Alias, which is unchecked." If they are unchecked I would not expect any updates to those records no matter what the settings are.
ISSUE:
I think the question being asked is, "how do I change 1200 nodes to have Automatic Alias *checked* without having to go into each node and manually checking the box 1200 times.
Since I'm in the same boat, I'm very very interested too. I've Drupal'd and Googled my fingers raw. This isn't an isolated problem, but I haven't come across an answer yet.
I have the issue on both a multilingual site and a basic installation.
Thanks
Alan
Comment #24
dave reidTagging all the bulk alias issues for #713238: RFC: Pathauto Bulk module.
Comment #25
dave reidCommitted #4 to all three CVS branches. Doesn't make sense that this is the only place we're calling pathauto_create_alias() with a node and not providing $node->language.
http://drupal.org/cvs?commit=330262
http://drupal.org/cvs?commit=330264
http://drupal.org/cvs?commit=330266
Comment #27
Marko B commented#4 patch is in 1.3 version but id doesnt help with big problem with languages and aliases when bulk updating. :-(
Comment #28
pfournier commentedIn reply to #22, I noticed that bulk update only updates node in the current language (fr/admin/build/path/pathauto will only update nodes in french).
Use admin/content/node/overview to update nodes in all languages (but only 50 at a time...)