0
Welcome Guest! Login
0 items Join Now

Drupal 7 - Crystalline Theme - 500 Error When Adding Block

    • RPC's Avatar
    • RPC
    • Newbie
    • Posts: 7
    • Thanks: 0

    Drupal 7 - Crystalline Theme - 500 Error When Adding Block

    Posted 12 years 9 months ago
    • This is on a Drupal 7 site that started with the RocketLauncher. I haven't made many modifications to the content yet, but I am trying to add a new View called "Our Valued Clients" to the home page in the "Features" region. I can add this block to any other region (at the moment it's placed in Content Top), but for some reason when I try to add it into Features, it takes the whole site down and it displays a 500 error. Any ideas what I could try?

      It's a pretty basic view that I can provide the code for if someone needs it. Not sure why it would cause a 500 error.
  • Re: Drupal 7 - Crystalline Theme - 500 Error When Adding Block

    Posted 12 years 9 months ago
    • I have the same issue, using any view, one i create or one built in.

      The 500 error comes up after a time out period. The issue does not come up with 2 other RT themese I tried.

      I need to use Drush to disable the view in order ot get the site back.
    • RPC's Avatar
    • RPC
    • Newbie
    • Posts: 7
    • Thanks: 0

    Re: Drupal 7 - Crystalline Theme - 500 Error When Adding Block

    Posted 12 years 9 months ago
    • Allan,

      I'm trying to get my shared hosting provider to turn on the MySQL "Slow query log" to see if there's a particular database table that I need to optimize. Maybe it's a views thing? I do see a lot of slow queries in phpmyadmin.

      Hey, a different D7 issue since we're both trying this theme. Do all of your settings for the theme (custom colors, backgrounds, etc.) take effect when you're logged out? For some reason I see them when I'm logged in, but not when I'm logged out.

      Mark W. Jarrell
      This email address is being protected from spambots. You need JavaScript enabled to view it.
      about.me/markjarrell
      fleetthought.com
      Beautiful websites managed by you.
      (931) 494-6065
    • RPC's Avatar
    • RPC
    • Newbie
    • Posts: 7
    • Thanks: 0

    Re: Drupal 7 - Crystalline Theme - 500 Error When Adding Block

    Posted 12 years 9 months ago
    • Just in case anyone else has the same problems I've run into with this theme:

      Looks like the Color Chooser doesn't actually do anything. You have to enter it manually into the Theme settings screen for the end user to see the changes. Looks like the color chooser is just a cookie thing for the currently logged in user. Not permanent for all users. Weird...

      Also, using the "custom" option for controlling colors and images used doesn't work as it's supposed to. If you just choose "custom" from the appearance > Settings screen, everything shows in black & white and you get a bunch of errors in the admin about "Undefined index: custom in crystalline_preprocess() (line 390". You have to create your custom style manually inside of template.php in the main preprocess function (it also has to be mentioned like the other ones in chooser.php, theme-settings.php, and styles.php).
    • RPC's Avatar
    • RPC
    • Newbie
    • Posts: 7
    • Thanks: 0

    Re: Drupal 7 - Crystalline Theme - 500 Error When Adding Block

    Posted 12 years 9 months ago
    • Still not having any luck with 500 errors. It appears any time I try to add a custom views block into either the Sidebar or Features region. Some help from RocketTheme staff would be greatly appreciated.
    • Luke Whitson's Avatar
    • Luke Whitson
    • Elite Rocketeer
    • Posts: 1284
    • Thanks: 0
    • Lead Developer

    Re: Drupal 7 - Crystalline Theme - 500 Error When Adding Block

    Posted 12 years 9 months ago
    • Yes, the color chooser is for demo-ing the changes you can make. To make them permanent, you need to make the changes in the admin. Otherwise, they are only made in cookies for the current user.

      When you choose CUSTOM, it uses the values below in the theme admin.

      For the 500 errors, sometimes you need to re-enable the views module. We've seen it happen a few times. Once the views module is enabled properly and the view is setup, the errors go away.

      If there are still issues, PM me an admin login and your site URL and I will take a look at your setup.

      Cheers.
  • Re: Drupal 7 - Crystalline Theme - 500 Error When Adding Block

    Posted 12 years 9 months ago
    • Hi,
      I had to not just disable but completely uninstall views then re-install/enable. Thigs seem to work - but remember to export any views you want to save before you uninstall views.
      A
    • RPC's Avatar
    • RPC
    • Newbie
    • Posts: 7
    • Thanks: 0

    Re: Drupal 7 - Crystalline Theme - 500 Error When Adding Block

    Posted 12 years 9 months ago
    • Luke, I sent you a PM with the admin login details. Did you receive that? I still could really use some help on this issue.
      Luke Whitson wrote:
      Yes, the color chooser is for demo-ing the changes you can make. To make them permanent, you need to make the changes in the admin. Otherwise, they are only made in cookies for the current user.

      When you choose CUSTOM, it uses the values below in the theme admin.

      For the 500 errors, sometimes you need to re-enable the views module. We've seen it happen a few times. Once the views module is enabled properly and the view is setup, the errors go away.

      If there are still issues, PM me an admin login and your site URL and I will take a look at your setup.

      Cheers.
    • RPC's Avatar
    • RPC
    • Newbie
    • Posts: 7
    • Thanks: 0

    Re: Drupal 7 - Crystalline Theme - 500 Error When Adding Block

    Posted 12 years 9 months ago
    • Just tried it on a localhost install. I've got 128M in php.ini, but PHP reports:

      Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 51 bytes) in /drupal7/sites/raiderpainting.com/themes/rt_crystalline_d7/template.php on line 324
    • RPC's Avatar
    • RPC
    • Newbie
    • Posts: 7
    • Thanks: 0

    Re: Drupal 7 - Crystalline Theme - 500 Error When Adding Block

    Posted 12 years 9 months ago
    • Finally got it on my own. It's the generic crystalline_preprocess() function at the top of template.php. It doesn't take into account the $hook parameter. So... for each view you add into the page, it runs through all of that code in the preprocess function an additional time. So if you have like 20 views fields on the page, it's actually running through a huge function like 20 times. Crazy!

      Here's the fix: go into template.php, change:
      function crystalline_preprocess(&$variables) {
      TO:
      function crystalline_preprocess(&$variables, $hook) {

      Also, wrap everything within that function with an if statement, to figure out which hook is being used. Only page and HTML are necessary. It should now look like this:
      function crystalline_preprocess(&$variables, $hook) {
      if ($hook == 'html' || $hook == 'page') {
      ...BODY OF FUNCTION HERE.
      }
      }

      Then, go to Admin > Configuration > Performance > Clear all caches. That should fix it.

Time to create page: 0.062 seconds