Reputation: 133
Following example Code given in footer.php:
<footer id="test" role="role">
<div id="test-generator" class="clearfix">
<?php do_action( 'test_open' ); ?>
<div class="copyright">
blabla
</div>
<div class="powered">
blabla
</div>
<?php do_action( 'test_close' ); ?>
</div>
</footer>
</div>
<?php wp_footer(); ?>
the footer.php is part of a wordpress theme. I would like to add some line after "blabla" in div.class copyright. This should be done without modifying the footer.php. Is ther any way to do so?
Thank you for the help!
Upvotes: 0
Views: 138
Reputation: 27599
You need to write a function that is hooked to the "test_close" action and include it in your functions.php
or Custom Functions Plugin:
add_action( 'test_close', 'my_function' );
function my_function(){
echo "<br/>This is on the next line";
}
Upvotes: 1