Hello!
I am creating a new site on Drupal 6 and needed help on something which might be simple but could not fix it myself by googleing.
I have created a "Footer message" on Administer >> Site Configuration >> Site Information, that displays the copyright info:
© 2009 MyWebsite.com. All rights reserved.
I have changed the date manually but I was wondering if there is any php code that will change the year automatically. I used a php code i found online but the code appeared on the website as text.
Is there any solution to that or I will have to create a custom block and put it on the footer?
I'd prefer using code on the "Footer message" though.
Thank you in advance for your assistance.
Kind regards
Nikolas
Comments
Hi Nikolas, You can't change
Hi Nikolas,
You can't change the "Footer message" with PHP directly. Instead: Enable PHP filter in admin/build/modules, then create a block at build/block/add and paste this code:
Then put this block in your footer.
Cheers
Thank you for your help
Thank you for your help Jeremy!
php code still showing...
Newbie here. I have done exactly what you described - PHP filter enabled, new block created, pasted in the code and moved it into the Footer. It shows exactly as it was pasted - the PHP is not being interpreted.
My site is in very early development, using the pixture_reloaded theme and is running on a localhost under WAMP and Windows. I've restarted the services, logged in and out but can't think of anything else to do.
Any suggestions?
Bill
Make sure the PHP input
Make sure the PHP input filter is enabled in the block settings too.
http://www.learnhow2earn.com/wp-content/uploads/2008/12/phpcode.png
To theme like the original
To theme like the original footer add an ID:
_
... very useful 2 years on - thanks ....
This will work if you enter
This will work if you enter it in page.tpl.php file. However it won't work in the Site Information's footer section at
/admin/settings/site-informationIf you find a code to put it there, please let us know. Thanks!