For our canvas lets use the Enhanced Text Widget plugin, it will let us type Javascript, Flash and even Php directly into the text box..

After you install put this widget box on your sidebar or wherever you insert the following at the top of your code.

require( '/home/my/absolute/path/wp-load.php' );

Here is a simple example which would output something along the lines of : “Hello World Mr facade”.

IMPORTANT: Remember to change the absolute path to the one for YOUR server.

require( '/home/my/absolute/path/wp-load.php' );
echo "hello world Mr ";
$current_user = wp_get_current_user();
echo $current_user->display_name;


WordPress Codex (get current user) :

Categories: CMS

1 Comment

How to get buddypress Avatar in Wordpress | DEVGET.NET · August 14, 2013 at 10:35 am

[…] So with the same canvas setup in the last post: […]

Leave a Reply

%d bloggers like this: