• Let me first introduce myself as a novice WordPress user. I have coded in PHP and HTML before, so I have some background in creating web applications. However my knowledge of using WordPress has been pretty limited to adding plugins, changing themes, slightly modifying theme/plugin files, and creating very basic plugins (such as a custom poll).

    I have been assigned by my employer to migrate an existing site of theirs to a WordPress installation they created. Most of the site was basic HTML and easily moved, but there is one section that relies on a lot of PHP and JS to function. My initial thought was to design a plugin that could import the functionality of those pages, but that has proven to be more difficult than I thought.

    So far I know I can create a shortcode to call on a new page within WordPress that builds some of the HTML, but linking their existing PHP, CSS, and JS files to that page have been evading me. I understand the use of wp_register_ and wp_enqueue_ and how add_action('wp_enqueue_scripts','$handle') is supposed to work for importing JS and CSS. I have not successfully been able to import any existing CSS or JS files. Nor do I have any idea about how to bring in the few thousand (seriously) PHP files that run some of the backend to this site.

    http://redridgewhitetails.com/pedigrees/ — That is the existing site.

    http://redridgewhitetails.com/2014site/pedigrees/buck-pedigrees/ — Is the new site. You can see by using an iframe they can do a little hack around WordPress, but that is not the solution they want.

    Sorry for the wall of text, I tried to be as detailed as possible. I would appreciate any feedback or suggestions possible. I have poured over documentation and other forum posts to no avail.

Viewing 2 replies - 1 through 2 (of 2 total)
  • I would try to take all those PHP and JS files and put in a sub-folder of root. Then in a Page Template of WP site (then assigned to a page), I would include the ‘index’ (of sub), then apply CSS to get the content on these pages looking as much like the rest of the site as possible.

    Thread Starter Shaazaam

    (@shaazaam)

    Ok I will try that as an option. I think I will try to track down whomever created the original site. There is a possibility I don’t need all of it. Perhaps if that is the case whatever we do need I can strip down into a plugin.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Migrating existing PHP’ is closed to new replies.