Closed (fixed)
Project:
Theme developer
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
26 Feb 2011 at 18:17 UTC
Updated:
17 Aug 2011 at 21:11 UTC
Jump to comment: Most recent file
Comments
Comment #1
JeremyFrench commentedI have noticed this sporadically, some servers seem ok with it others not.
Comment #2
ultimikeI'm seeing this as well (consistently) on my dev machine - using MAMP with PHP 5.2.5.
The variable list in the "Drupal Themer Information" box always appears to display the same set of variable. For example, when looking at a node.tpl.php, no CCK fiels (nor the title or body) are displayed in the variable list.
-mike
Comment #3
ultimikeI believe that I found and fixed the bug. Patch attached.
-mike
Comment #4
ultimikeWhoops - forgot to set the status to "needs review".
-mike
Comment #5
ultimikeHow about I upload the patch and set to "needs review" at the same time.
(sorry)
-mike
Comment #6
JeremyFrench commentedThanks for the patch. I haven't had a chance to test it yet. Was there a collision with the id variable name?
Comment #7
ultimikeYep, there was an "id" collision. Also, the uri was being set twice with identical code, so I fixed that as well.
-mike
Comment #8
deadairwaves commentedMike,
I tried the patch and it's working, for the most part. I'm having an issue when I try to view the variables available to node.tpl.php. Each time I try, I get a pop up that says:
An AJAX error has occured.
HTTP Result Code: 502
Debugging information follows.
Path:
/devel_themer/variables/277760777284d7fba4064faa/thmr_74
StatusText: Bad Gateway
ResponseText:
502 Bad Gateway
502 Bad Gateway
nginx
It's only happening with node.tpl.php. Other template files (page.tpl.php, block.tpl.php) are showing the correct variables without any error.
Comment #9
ultimikedeadairwaves,
That sounds like it could be a caching issue between your web server and nginx. Are you running this on a production server?
You may want to try using a dev server without nginx running.
-mike
Comment #10
deadairwaves commentedYup, it's running on a production server. I'm on a shared hosting plan, so I'm not able to add/remove server features. Unfortunately, I don't have access to a devel server right now, but maybe it's time to build one myself.
Comment #11
ultimikedeadairwaves,
Try WAMP (Windows) or MAMP (Mac) - if you can get a copy of the code and DB from your site, it shouldn't take too much time to get it running locally. If the problem still persists, reopen this case.
Good luck,
-mike
Comment #12
ultimikeRats - I didn't mean to "postpone" this issue. I just reset it to "needs review".
-mike
Comment #13
cyprien2 commentedHave the same problem on wampserver with apache and apply the patch, worked for me...
Edit : Sorry, i made an error, it doesn't work for me either under Wampserver and LAMP on Linux Ubuntu with drupal 7.0...
Comment #14
Ankabout commentedHad the same problem on my server, patch fixed it for me.
Comment #15
cyprien2 commentedPatch is working for me too with new version of Drupal
Comment #16
effulgentsia commentedThanks for the fix. Committed #5 to master branch.
Yes. Local variable scope in JavaScript is at the function level only, so "var" statements in loops and inline closures can collide with the same named variables declared anywhere else in the top-level function scope.
Comment #17
effulgentsia commented