Flicker block problem

Permalink
I downloaded the flicker block and unzip into the root block folder, but when i to to add functionality, i get a screen of code, like something is missing? any pointers?

wizardontherun
 
wizardontherun replied on at Permalink Reply
wizardontherun
same type of error with Google Maps Prem, unziped to the block folder and code fills the screen when try to access add functionality.
Tony replied on at Permalink Reply
Tony
Can you provide a little more information on the "code". Is it throwing an error? What does the code look like?
wizardontherun replied on at Permalink Reply
wizardontherun
first part, but much more dumps...

'G_NORMAL_MAP','Hybrid'=>'G_HYBRID_

and an error message after it is:

An unexpected error occurred.
PremiumGoogleMapBlockController not found. Please check that the block controller file contains the correct class name.

same error for both flicker and google maps

also this is a windows box, themes work fine.
andrew replied on at Permalink Reply
andrew
It's weird...haven't seen much like this before.

Could you try zipping up controller.php exactly as you have it and posting it here?
Tony replied on at Permalink Reply
Tony
so you have got your premium google map block controller in /blocks/premium_google_map/controller.php?

And then if you open that file, does it have a class definition of:
class PremiumGoogleMapBlockController extends BlockController {....

?
wizardontherun replied on at Permalink Reply
wizardontherun
Yes i have that file with the class def

error seems to be right after the => op

public $map_types=array('Normal'=>'G_NORMAL_MAP'
Tony replied on at Permalink Reply 1 Attachment
Tony
Well I can't seem to replicate this locally. We've made a few change to how the blocks are being loaded recently. That's my best guess as to where a problem's happening. I've attached a version of my working loader.php file. Save a backup of your existing version, and copy this new one into /concrete/libraries/. Hopefully this'll work for you. If not, add some debugging echos to the block() function, like on line 84 of loader.php let me know what this prints:

echo DIR_FILES_BLOCK_TYPES . '/' . $bl . '/' . FILENAME_BLOCK_CONTROLLER;
die;

It really should be caught by the first IF statement there, provided you've got your folders named correctly. Hope that helps.
wizardontherun replied on at Permalink Reply 1 Attachment
wizardontherun
ok i replace the loader with the one you sent. but the site does not load anything now, i put back the old one and added the echo line as noted, screen attacht for your review.
wizardontherun replied on at Permalink Reply
wizardontherun
line 25 of the controller.php for the block seems to be the problem right after the => comand:
public $map_types=array('Normal' => 'aG_NORMAL_MAP','Hy...

as the code dumps starts at the 'aG_NORMAL_MAP'. this also happens on other blocks that I downloaded and try to use.
wizardontherun replied on at Permalink Reply
wizardontherun
seems that on line 25 the reading of the controller.php fails at the '=>' array pointer on the first entry, then the rest of the file is dump to the browser, happens on the google map and flicker blocks. any ideal from anywone what would cause this?
andrew replied on at Permalink Reply
andrew
Could you zip up both controller.php files from both blocks, as you have them, and post them here?
andrew replied on at Permalink Reply
andrew
We run c5 through a processor that converts all short open tags ("<?") to regular PHP open tags ("<?php") but we haven't done that for the blocks and themes. That's why you're getting this error.

We will try and do this and repost the blocks and themes... however in the meantime to get this to work either enable short_open_tags on your server or go through the block and change all instances of <? to <?php and all instances of <?= to <?php echo