Page 1 of 1

calling a function problems

Posted: Mon Jun 29, 2009 7:20 am
by jodi
I am calling a function and it works okay in on most of my pages but they are in an includes folder, and it works.

I then have an index file on the root and go to call it using.

<?php sidebarlogin(); ?>

but the function is located in the includes/wordpress/ folder.

how do I link the two?

Re: calling a function problems

Posted: Mon Jun 29, 2009 7:51 am
by Eric!
As long as your php file with the sidebarlogin function just contains functions you can use include without any extra code executing. Or you can just put that function in its own file and include it.

Code: Select all

include("/path/phpcode.php");

Re: calling a function problems

Posted: Mon Jun 29, 2009 8:14 am
by jodi
thank you, going to have to do it as it own file I think as I call other links again in that folder.