I'm not sure whether this is an issue with node_clone, url_alias, or pathauto but at the moment as soon as you click 'clone' a url alias is created in the style clone_of_page_title.
Is there any way of not letting this happen until I commit the clone as I foresee a lot of clone_ urls in my url alias table!

Cheers

PS: Cheers for releasing this module, you saved me quite a bit of time!

Comments

pwolanin’s picture

This must be a pthautho issue. My module wipes out any existing path.

fronbow’s picture

Would it be possible then, to have the 'new' path to come up as something like clone/oldpath just so that I can edit the old path?

Also, would it be possible/viable to hook into pathauto's settings so that either it doesn't automagically create a path, or that there's some control on pathauto's settings page like there is for nodes, pages, content types, etc?

Cheers

pwolanin’s picture

I don't know anything about how pathauto works internally, so I think these things are possible, but you'd have to do some research yourself. I'd assume you can still set the path manually, or that the pathauto path gets changed when you edit the node title?

fronbow’s picture

I'll have a look into pathauto when I get a spare minute!

Yes, I can manually set the path. And the new path gets set when I submit the new version, but occasionally (I'm not sure why/how and in what circumstances) a clone_of_page_title alias stays in the url alias table.

Cheers

pwolanin’s picture

I suppose one could take a totally different approach and just try to populate the node add form. Thus, no node would be created until submitting the form. However, it seems like this would only work for simple node types. The advantage of the method used with this module is that most of the data in the original node object (including taxonomy, etc) gets saved for the clone without having to do any extra work.

pwolanin’s picture

Also, I'm like to commit this patch soon: http://drupal.org/node/81882

which will make "Clone of" translatable via the local module into some else if you prefer.

fronbow’s picture

regarding #5, this is fine; on further investigation it looks like a path only gets created in extreme circumstances where it's of the clone_of_title form. Today I probably cloned about 30 pages, and I expected 30 aliases to be in the db, but there was only one!

Oh, and I like the idea of #6!

pwolanin’s picture

Status: Active » Closed (fixed)

ok, seems like there's not really an issue

doublejosh’s picture