I made a website with WordPress and Codeigniter. I create 4 pages on Codeigniter then one more blog page in WordPress. I get the footer data dynamically on the Codeigniter based site.

I need to take the same footer data dynamically on my WordPress pages.

  • yes thats my question – Aniket Meshram Jan 27 '17 at 7:16
  • okey.....well, I have to include footer.php file into wp file but for that I have to give path of footer file.....how?? – Aniket Meshram Jan 27 '17 at 11:57

If your footer file name is abc.php inside Codeigniter pages and you want to run that file in the WordPress directory. In the footer.php file in WordPress include your abc.php file. Otherwise, you can make your own functions to call or manage the content.

<?php include 'abc.php'; ?>
  • well, before include abc.php whether i need to connect mysql with db name??from where I want to retrieve data – Aniket Meshram Jan 27 '17 at 7:19
  • I think you don't need to reconnect db. But give it a try fist without db connection. – Umer Shoukat Jan 27 '17 at 8:51
  • so I just need to mention db name of CI site from where I need to take data dynamically in my WP site – Aniket Meshram Jan 27 '17 at 8:55
  • just include that file no need to add database connection etc. – Umer Shoukat Jan 27 '17 at 9:01
  • bro let me clear you one thing my WP db is diff and my CI db is diff...okey! if I include CI db file in WP db site,, so obviously I have to mention CI db name , as I want to take data from CI into WP..!! – Aniket Meshram Jan 27 '17 at 9:09

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.