Auto add link to contact page if contact.php exist

This commit is contained in:
Knah Tsaeb 2018-02-13 14:46:06 +01:00
parent 7a4ff2cd78
commit c111704f8c
2 changed files with 14 additions and 0 deletions

3
.gitignore vendored
View file

@ -37,3 +37,6 @@ tpl/*
!tpl/default
!tpl/vintage
!tpl/myShaarli
contact.php
formStyle.css

View file

@ -61,6 +61,17 @@ function hook_myShaarli_render_linklist($data,$conf)
return $data;
}
/**
* Hook render_footer.
*/
function hook_myShaarli_render_footer($data)
{
if(file_exists('contact.php')){
$data['text'][] = '<br><a href="https://forge.leslibres.org/Knah-Tsaeb/MyShaarli">MyShaarli</a> is a fork of Shaarli.<a href="contact.php">Contact</a>';
}
return $data;
}
/**
* NOT WORKING
* To poor performance