purchase html template with extending license and convert it into php

can i sell my script on codecanyon if i purchase some template with extended license from codecanyon and convert into to php script

no license (regular/extended) will give you permit to do that. But you can make author collaboration (partnership) to make version product as like html to wordpress, psd to html etc.

But you can use any script/plugin as your main product bundle as like wordpress theme bundle plugin. In this case you have to purchase extended license and have to take permission from the original script/plugin author to add into your main item.