Wordpress Header in Moodle

Wordpress Header in Moodle

על ידי Liam Knight בתאריך
מספר תגובות: 5

Hello I am trying to use the wordpress header inside Moodle instead of using the menu in the theme we are using (Essential)

I have tried adding it using this php code below in the header.php file of the theme but that didn't work and caused the site only to load the background, I also tried adding it in the "additional HTML" area but that didn't make any difference.

Does anyone know how this can be done as it will be really useful to make the site seamless and we don't want to use iframes as they are no good to us.

Any help is greatly appreciated, thank you.

<?php require('/XXX/public_html/wp-blog-header.php'); ?>
<?php require('/XXX/wp-content/themes/ourtheme/wp-blog-header.php'); ?>
ממוצע דרוגים: -
בתגובה ל: Liam Knight

Re: Wordpress Header in Moodle

על ידי Mary Evans בתאריך
תמונה של Core developers תמונה של Documentation writers תמונה של Peer reviewers תמונה של Plugin developers תמונה של Testers

You need to add the file into the layout folder of your theme and link from the page header of your theme's layout file general.php or whatever it's name using this method...

<?php include('wp-blog-header.php'); ?>

Read: http://www.w3schools.com/php/php_includes.asp

Cheers

Mary

בתגובה ל: Mary Evans

Re: Wordpress Header in Moodle

על ידי Liam Knight בתאריך

Hello Mary,

Thanks for your reply, I have tried this but when I add this to the header.php file it only loads the background of the page. I have also tried putting hte wp-blog-header.php into the layout folder and get the same result. 


I would really like to get this working as it would make the site a lot better, thank you for your reply.

בתגובה ל: Liam Knight

Re: Wordpress Header in Moodle

על ידי Liam Knight בתאריך

Nobody had any idea about this? It would be really useful.

בתגובה ל: Liam Knight

Re: Wordpress Header in Moodle

על ידי Mary Evans בתאריך
תמונה של Core developers תמונה של Documentation writers תמונה של Peer reviewers תמונה של Plugin developers תמונה של Testers

This all depends on what is in those PHP files. What does the header do. I don't use Wordpress and as far as I recall it is not really that compatible with Moodle. So the WP php would need to be modified for it to work.

Some links or images to the kind of header would be good.

Thanks

Mary