By LeeMcL on
I'm administering a bunch of small sites on different locations and also playing in my sandbox with the 4.7 beta. It would really help me avoid getting lost if I could see the Drupal version somewhere. On the admin page at least and also in the html of the generated page.
I've had a good wander through the source, and these forums, and I cannot see any easy way of doing this. In fact there doesn't seem to be any variables/constants/functions that return the current Drupal version details.
If I am missing how to do this could someone point out how, please? Or is there some reason why the Drupal version number isn't available?
Thanks
Lee
Comments
chagelog
If you open up the changelog.txt file in your Drupal root folder you can tell which version is being used. Although, it's probably a good idea to have something in the ADMINISTER -> SETTINGS page maybe that says "you are using Drupal version x.x".
Especially if you are working on various Drupal sites and forget sometimes which is which.
Site Admins putting something subtle in the footer maybe a temp workaround...
Dub
Currently in Switzerland working as an Application Developer with UBS Investment Bank...using Drupal 7 and lots of swiss chocolate
version
[root@warship drupal47]# grep -r "4.7" * | grep VERSION
modules/drupal.module:define(VERSION, '4.7.0');
[root@warship drupal47]#
enable the drupal module, and try that:
and you'll be all set.
--
got pwned today ?
http://www.gotpwned.com/
VERSION in 4.7.0-beta3
Thanks for the information that the version string is available in 4.7.0-beta3. Sadly it is not available in any earlier versions. Well I guess thats why text editors exist!
Somewhat annoying that the version string in 4.7.0-beta3 doesnt mention it is beta3. Shame too that you have to enable another module to get it. I guess I am just surprised that it isn't more readily available.
Thanks
Lee
I agree with you
that the drupal version should be more explicit (but that's not a concern, since the core is now coming with that). What do you need, exactly ? You may try to test the existance or abstence of a drupal core function to determine the version (not the best way, but works).
--
got pwned today ?
http://www.gotpwned.com/
Version information for various things
I wanted version info' mainly to help remind me which Drupal I was now using. I have a test 4.6.4 and another test site using 4.7.0-beta3 (and I just remembered I have another running CVS!). It would be helpful to just see a version number. Clearly this isn't necessary, in particular between 4.6 and 4.7 there are major differences in some of the admin menu bits, but I find it a useful reminder.
I also wanted to share some code between the versions and it would make it very clear what was going on if the code checked the Drupal version details before using features that differ between the releases. Yes, you can achieve the same effect by looking at which functions are defined (unless you are using the legacy.inc module!). But I think version checking is clearer.
Lee
handbook link here
To additional information.
http://drupal.org/node/27362
-sp
---------
Test site, always start with a test site.
Drupal Best Practices Guide -|- Black Mountain
-Steven Peck
---------
Test site, always start with a test site.
Drupal Best Practices Guide
I made the same point /request to the core
Funny that I have made a point/request to the core for Administrators
not just the core version but modules as well
http://drupal.org/node/44611
Yet another way..
First line will look like:
// $Id: system.module,v 1.204.2.1 2005/04/12 19:00:39 dries Exp $Now notice the revision here, 1.204.2.1 and write it down.
That helped me because in the drupal installation I was dealing with, there was no CHANGELOG file.
Thanks
Tnaks to this clue, I knew what version we were using on a site.
thanks.
Drupal 4.6.x version
The version number for 4.6.x versions can be found under the drupal root/fantversion.php file
ahijado
Fantastico
Only when installed and upgraded with fantastico.
--
The Manual | Troubleshooting FAQ | Tips for posting | Make Backups! | Consider creating a Test site.