Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
On a fresh 4.5.0 installation, even just selecting the Administer-> Theme menu item breaks the theme stylesheets. For an example see http//hurricane.wagner.nyu.edu
Not sure what is causing this, but I've reinstalled and replicated on several different boxes.
Comment | File | Size | Author |
---|---|---|---|
#1 | Picture 1.pdf | 122.32 KB | Anthony Townsend |
Picture 2.pdf | 62.66 KB | Anthony Townsend |
Comments
Comment #1
Anthony Townsend CreditAttribution: Anthony Townsend commentedweirdly enough, the proper theme is used (and only there) on the Administer -> Theme selection page (see attached)
Comment #2
pildit CreditAttribution: pildit commentedI've got the same symptoms.
Comment #3
Junyor CreditAttribution: Junyor commentedI've debugged the problem a bit. It seems that a null terminator is being inserted in the system table in the middle of the theme path.
See the following for related discussion:
http://drupal.org/node/4567
http://drupal.org/node/11761
http://drupal.org/node/12526
http://drupal.org/node/13005
Comment #4
Junyor CreditAttribution: Junyor commentedHere's the output from devel.module when loading admin/themes. The first query that shows a problem is "0.84 1 DELETE FROM system WHERE filename = 'themes/chameleon/chameleon\0theme' AND type = 'theme'", which comes from system_obtain_theme_info().
1.08 1 SELECT * FROM url_alias
1.37 1 SELECT name, filename, throttle, bootstrap FROM system WHERE type = 'module' AND status = 1
0.8 1 SELECT uid FROM authmap WHERE authname = 'tim'
0.96 1 SELECT u.* FROM users u WHERE u.uid = 18 AND u.status < 3 LIMIT 0, 1
0.84 1 SELECT r.rid, r.name FROM role r INNER JOIN users_roles ur ON ur.rid = r.rid WHERE ur.uid = 18
2.03 1 SELECT DISTINCT(p.perm) FROM role r INNER JOIN permission p ON p.rid = r.rid INNER JOIN users_roles ur ON ur.rid = r.rid WHERE ur.uid = 18
1.65 1 SELECT * FROM system WHERE type = 'theme' ORDER BY name
6.47 1 SELECT data, created, headers FROM cache WHERE cid = 'menu:18'
1.27 1 DELETE FROM system WHERE type = 'theme_engine'
0.85 1 INSERT INTO system (name, type, filename, status, throttle, bootstrap) VALUES ('phptemplate', 'theme_engine', 'themes/engines/phptemplate/phptemplate.engine', 1, 0, 0)
0.75 1 INSERT INTO system (name, type, filename, status, throttle, bootstrap) VALUES ('xtemplate', 'theme_engine', 'themes/engines/xtemplate/xtemplate.engine', 1, 0, 0)
0.76 1 DELETE FROM variable WHERE name = 'phptemplate_extra_templates'
1.13 1 INSERT INTO variable (name, value) VALUES ('phptemplate_extra_templates', 'a:2:{s:14:\"themes/kubrick\";a:3:{s:30:\"themes/kubrick/comment.tpl.php\";O:8:\"stdClass\":2:{s:8:\"filename\";s:30:\"themes/kubrick/comment.tpl.php\";s:4:\"name\";s:11:\"comment.tpl\";}s:27:\"themes/kubrick/node.tpl.php\";O:8:\"stdClass\":2:{s:8:\"filename\";s:27:\"themes/kubrick/node.tpl.php\";s:4:\"name\";s:8:\"node.tpl\";}s:27:\"themes/kubrick/page.tpl.php\";O:8:\"stdClass\":2:{s:8:\"filename\";s:27:\"themes/kubrick/page.tpl.php\";s:4:\"name\";s:8:\"page.tpl\";}}s:12:\"themes/manji\";a:4:{s:24:\"themes/manji/box.tpl.php\";O:8:\"stdClass\":2:{s:8:\"filename\";s:24:\"themes/manji/box.tpl.php\";s:4:\"name\";s:7:\"box.tpl\";}s:28:\"themes/manji/comment.tpl.php\";O:8:\"stdClass\":2:{s:8:\"filename\";s:28:\"themes/manji/comment.tpl.php\";s:4:\"name\";s:11:\"comment.tpl\";}s:25:\"themes/manji/node.tpl.php\";O:8:\"stdClass\":2:{s:8:\"filename\";s:25:\"themes/manji/node.tpl.php\";s:4:\"name\";s:8:\"node.tpl\";}s:25:\"themes/manji/page.tpl.php\";O:8:\"stdClass\":2:{s:8:\"filename\";s:25:\"themes/manji/page.tpl.php\";s:4:\"name\";s:8:\"page.tpl\";}}}')
0.73 2 DELETE FROM cache WHERE cid = 'variables'
0.6 1 DELETE FROM variable WHERE name = 'phptemplate_extra_logic'
0.55 1 INSERT INTO variable (name, value) VALUES ('phptemplate_extra_logic', 'a:0:{}')
0.49 2 DELETE FROM cache WHERE cid = 'variables'
1.27 1 SELECT filename, type, status, throttle FROM system WHERE type = 'theme'
0.84 1 DELETE FROM system WHERE filename = 'themes/chameleon/chameleon\0theme' AND type = 'theme'
0.68 1 INSERT INTO system (name, description, type, filename, status, throttle, bootstrap) VALUES ('chameleon', '', 'theme', 'themes/chameleon/chameleon\0theme', 0, 0, 0)
0.69 1 DELETE FROM system WHERE filename = 'themes/kubrick/page.tpl.php' AND type = 'theme'
0.67 1 INSERT INTO system (name, description, type, filename, status, throttle, bootstrap) VALUES ('kubrick', 'themes/engines/phptemplate/phptemplate.engine', 'theme', 'themes/kubrick/page.tpl.php', 0, 0, 0)
0.68 1 DELETE FROM system WHERE filename = 'themes/manji/page.tpl.php' AND type = 'theme'
0.67 1 INSERT INTO system (name, description, type, filename, status, throttle, bootstrap) VALUES ('manji', 'themes/engines/phptemplate/phptemplate\0engine', 'theme', 'themes/manji/page.tpl.php', 0, 0, 0)
0.67 1 DELETE FROM system WHERE filename = 'themes/bluemarine/xtemplate.xtmpl' AND type = 'theme'
0.66 1 INSERT INTO system (name, description, type, filename, status, throttle, bootstrap) VALUES ('bluemarine', 'themes/engines/xtemplate/xtemplate.engine', 'theme', 'themes/bluemarine/xtemplate.xtmpl', 0, 0, 0)
0.68 1 DELETE FROM system WHERE filename = 'themes/pushbutton/xtemplate.xtmpl' AND type = 'theme'
0.66 1 INSERT INTO system (name, description, type, filename, status, throttle, bootstrap) VALUES ('pushbutton', 'themes/engines/xtemplate/xtemplate\0engine', 'theme', 'themes/pushbutton/xtemplate.xtmpl', 1, 0, 0)
0.68 1 DELETE FROM system WHERE filename = 'themes/pushbutton-new/xtemplate.xtmpl' AND type = 'theme'
0.67 1 INSERT INTO system (name, description, type, filename, status, throttle, bootstrap) VALUES ('pushbutton-new', 'themes/engines/xtemplate/xtemplate\0engine', 'theme', 'themes/pushbutton-new/xtemplate.xtmpl', 0, 0, 0)
0.67 1 DELETE FROM system WHERE filename = 'themes/chameleon/marvin/style.css' AND type = 'theme'
0.65 1 INSERT INTO system (name, description, type, filename, status, throttle, bootstrap) VALUES ('chameleon/marvin', 'chameleon', 'theme', 'themes/chameleon/marvin/style.css', 0, 0, 0)
0.68 1 DELETE FROM system WHERE filename = 'themes/manji/obsidian/style.css' AND type = 'theme'
0.65 1 INSERT INTO system (name, description, type, filename, status, throttle, bootstrap) VALUES ('manji/obsidian', 'manji', 'theme', 'themes/manji/obsidian/style.css', 0, 0, 0)
1 1 SELECT * FROM blocks WHERE (status = 1 OR custom = 1) ORDER BY weight, module
Comment #5
carlmcdade CreditAttribution: carlmcdade commentedThe devel.module works on 4.5.2? or are you using a personally modified version?
Comment #6
Junyor CreditAttribution: Junyor commentedI used the CVS version. Worked fine.
Comment #7
TDobes CreditAttribution: TDobes commentedVery strange... I can't seem to reproduce this. Can sombody clarify the following questions so I might help troubleshoot the problem?
* Does this happen on CVS HEAD Drupal or is it limited to 4.5.x?
* What verion of PHP are you using? This forum topic seems to point to the idea that it might be related to old PHP versions.
Comment #8
Junyor CreditAttribution: Junyor commentedI've only seen this problem in that single installation of Drupal 4.5.2. I'll have to check the PHP version tomorrow. However, if you look at the last comment in that thread, it would appear that someone has the problem with PHP 4.3.9, too.
The problem started when one of the admins changed his account to use a different theme than the site default. I'm pretty sure I've done the exact same thing elsewhere and I haven't run into this problem.
Comment #9
Junyor CreditAttribution: Junyor commentedWe're running 4.1.2.
Is there any way I can debug this?
Comment #10
TDobes CreditAttribution: TDobes commentedJunyor: You mentioned earlier that a null terminator is being placed in the theme path. Can you tell where it's being inserted? Does the null character always appear between the same elements in the path? Perhaps we can determine which function is causing the null character to be inserted and use a different function or a workaround.
Does this same problem occur in CVS HEAD? Drupal 4.6 (a.k.a. CVS HEAD at the moment) will work with the version of PHP you are using as long as you don't try the search.module. I believe the search module's handling of unicode has issues with older PHP versions due to some sort of PHP bug.
Comment #11
Junyor CreditAttribution: Junyor commentedYes, the null character always occurs in place of the full stop in the theme name, i.e. "chameleon\0theme". The first function that outputs a faulty query is system_obtain_theme_info().
I'll do some testing this afternoon to see if the bug still occurs in HEAD.
Comment #12
Junyor CreditAttribution: Junyor commentedI took a database dump and a CVS checkout of the same files we're using for the problem install and I could not reproduce the problem. The server I tested with was using PHP 4.3.9, though.
Is there an easy way I can debug this in the same install that the problem occurs with without upgrading to HEAD?
Comment #13
mpearrow CreditAttribution: mpearrow commentedFWIW, I am running 4.5.2, and PHP 4.1.2 and can consistently replicate the problem described in this thread. I'll be glad to provide whatever additional info would help, and I'd be willing to try a different version for debugging purposes.
mpj
Comment #14
Junyor CreditAttribution: Junyor commentedCan you replicate the problem with the current CVS checkout?
Comment #15
mpearrow CreditAttribution: mpearrow commentedUsing the cvs checkout, the problem does *not* exist. I've tried all of the things that make it break in 4.5.2 and I can't make it break. :)
mjp
Comment #16
Junyor CreditAttribution: Junyor commentedThen I guess we should consider this fixed in CVS until someone reproduces it there.
Comment #17
(not verified) CreditAttribution: commented