Get page_url value before update it in db
Posted: Wed Jun 27, 2012 1:27 pm
Hello,
how can I get the alternate url field value (page's option tab) just before save it in db?
My goal is to make a UDT that, in conjunction with the ContentEditPre event, does:
1) queries the cms_content table and stores in a variable the value of the page_url field
2) gets the new Page URL value (alternate url in option tab)
2) queries a custom db table to see if there are duplicates entries for that url
3) if there are not, inserts the url in the custom table and update the .htaccess file with a 301 status, redirecting the old url to the new one
I'm using cmsms 1.10.3
thanks
how can I get the alternate url field value (page's option tab) just before save it in db?
My goal is to make a UDT that, in conjunction with the ContentEditPre event, does:
1) queries the cms_content table and stores in a variable the value of the page_url field
2) gets the new Page URL value (alternate url in option tab)
2) queries a custom db table to see if there are duplicates entries for that url
3) if there are not, inserts the url in the custom table and update the .htaccess file with a 301 status, redirecting the old url to the new one
I'm using cmsms 1.10.3
thanks