Link to home
Start Free TrialLog in
Avatar of solsticeint
solsticeint

asked on

PHP in wordpress

I have a PHP part generator that was created and now they are moving the site to wordpress.  How do I go about moving the generator to the wordpress site?  I moved the folder and the database.  The generator is currently at http://sagemetering.com/applicationsdata/ .  Currently I am having no luck getting this to work.  ANy help is greatly appreciated.

Thank you
Avatar of Dave Baldwin
Dave Baldwin
Flag of United States of America image

Although that's not nearly enough info, I suspect that you won't get it to work as part of Wordpress.  At the very least, you would have to redesign the theme where the display code is and find some way to resolve the differences between your CSS and javascript and that used by Wordpress.
Avatar of solsticeint
solsticeint

ASKER

I was afraid of that.  Any suggestions would be most helpful.
There's no real magic to porting over PHP code to WordPress.  Most of the time you just need to make custom page templates and copy the code over to the template.  You can add custom CSS or JavaScript required to make things work in a number of different ways.
Unless you convert your website design as Wp themes & features into WP functions. there is no easy way to do
ASKER CERTIFIED SOLUTION
Avatar of Jason C. Levine
Jason C. Levine
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
>>The generator is currently at http://sagemetering.com/applicationsdata/
If I understand you correctly, the link above is from "Site A" (the soon to be old site) and you copied over the applicationdata folder to "Site B" (the WP site).

If that is the case, I would expect it to work if you access it as:
http://thenewsite.com/applicationsdata/index.php

Does it?  If yes, then try routing the requests for "/applicationdata/" to "/applicationdata/index.php" via the .htaccess file:

RewriteEngine On
RewriteBase /

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^/applicationsdata/?$ applicationsdata/index.php [NC,QSA,L]

# the rest of your rules follow

Open in new window

Hello,

You shouldn't need to change anything. Wordpress is just a content management system. As along as the Part Generator worked as a standalone item previously you should be able to create a directory in the root of your site called part-generator or something similar, place all of the code for the part generator into that folder, and then include the part generator in any page you want using an iframe.