I was wondering how I can get the URL of a page that I am moving. I need to have the URL before and after i move a page so I can update a search Index.
Currently I am hooking into the ContentService.Moving event but the current page and it's child pages have a URL of '#'.
On ContentService.Moved the page has a URL so that bit iss fine - I just need the Moving "Old" URL.
Have you tried fetching the content from the Cache in the moving event? I would guess that the cache has not yet refreshed and therefor the content would have the old URL.
Then when you have finished what you need to finish, the cache refresher event would fire, and you can get the new URL of your content and reindex it.
Not sure whether it is possible, as I am not 100% sure that the events would fire in the right order, but worth a try. :-)
Get Page URL in ContentService.Moving Event
Hi,
I was wondering how I can get the URL of a page that I am moving. I need to have the URL before and after i move a page so I can update a search Index.
Currently I am hooking into the ContentService.Moving event but the current page and it's child pages have a URL of '#'.
On ContentService.Moved the page has a URL so that bit iss fine - I just need the Moving "Old" URL.
Any ideas?
Thanks
Hi Jon.
Have you tried fetching the content from the Cache in the moving event? I would guess that the cache has not yet refreshed and therefor the content would have the old URL.
Then when you have finished what you need to finish, the cache refresher event would fire, and you can get the new URL of your content and reindex it.
Not sure whether it is possible, as I am not 100% sure that the events would fire in the right order, but worth a try. :-)
is working on a reply...