I’m attempting to migrate thousands of html/php pages into several wordpress installations so the wp insert post help page has been indispensable. But there seems to be one critical parameter missing from the import array: ‘set permalink’.
In my case, I want the permalink set to the file name (e.g. 20100101foster.php) and I’ll also want to use another variable to insert the post title (i.e. go to the “title” div and insert the title).
First, if it is possible to set the permalink on import, how do I do so?
Second, when setting the permalink, if my original URL had a .php or .html extension, will the URL work? If not, how do I make it work.
Third, I’d like to automate the process and use variables to pull in the permalink and title (and possibly tags); where do I start in creating this script?
Any help is much appreciated. Many thanks,