Error when trying to install
cghobbs - March 15, 2007 - 18:17
| Project: | Aggregation |
| Version: | 5.x-2.2 |
| Component: | Code |
| Category: | support request |
| Priority: | critical |
| Assigned: | mistknight |
| Status: | closed |
Jump to:
Description
When trying to install the module I get the following module after I enable the module and click submit:
Parse error: parse error, unexpected T_OBJECT_OPERATOR in /var/www/vhosts/imagexmedia.com/subdomains/replenex/httpdocs/sites/all/modules/aggregation/aggregation.install on line 61
#1
What PHP version did you try to install it on?
#2
I am using PHP 4. We have been using this same server for about year without problems related to the version of PHP we a running and haven't experience problems with any other modules. I did take a look at a code and I think it is that it defines an object property like so:
$some_var = (db_fetch_object($query))->property;Perhaps this syntax is supported in later version of PHP. If that is the problem it should be a simple fix to do something more like this:
$obj = db_fetch_object($query);$some_var = $obj->property;
It's an extra line of code for each instance, but then your module will work on versions of PHP that don't support that syntax.
~Chris
#3
I'm afraid this module was created for PHP5 only.
Even if I do change this line, the code is packed with PHP5 syntax that will crash elsewhere. I use advanced constructs like try/catch that is not supported on PHP4 to make this module extremely reliable. I'm afraid I can't help you with this. But I encourage you to upgrade to PHP5 and give it a shot.
#4
I see. I have built sites using PHP 5. Unfortunately, we often have clients where they are on hosting environment where they can't easily upgrade to PHP 5. In the Drupal system requirements it allows for versions of PHP 4.3 and greater. If you are going to build a module that only works on PHP 5. I would suggest that you put that right on the project page so that people running PHP 4 without the option of upgrading won't waste their time trying to get this to work.
#5
It is very clearly stated on the project page :-)
PHP 5 developers seem to be very satisfied with its functionality, but I may consider upgrading it to PHP 4 if I find the time to do so and I find that it won't need extreme changes to the underlying code. But I'm afraid that I can't put the effort into such a custom change without the needed budget to do that.
#6
Totally understand, I don't really expect you too. I would just suggest adding a note to your project overview page that says "NOTE: This module only works with PHP 5", it might just save people some time and confusion.
Thanks,
Chris
#7
Oh wow missed that first line in your last post and on the project page. Don't I feel like an idiot. Sorry.
#8
I also installed the module when using PHP 4...
How to uninstall the module? The drupal administer is no longer available because of the error generated by aggregation.module.
Deleting the aggregation directory in the module directory is not enough i suppose, since the module was activated...
So how to manually deactivate and unistall a module? thanks!
#9
Try
update system set status=0 where name = 'aggregation';
Hope it works :-)
#10
just delete the folder from the server.
#11
Hi
I'm having the same problem, so I just checked and my server is using PHP 4. I may be able to upgrade to PHP 5, but as there are other sites involved, I'd like to ask you about your experience in upgrading PHP4 to PHP5. I'm not a webmaster type, so I don't know anything about the degree of retro-compatibility.
Any suggestions? Thanks in advance for any assistance
--
Albert
#12
Usually updating from PHP 4 to PHP 5 is a clean cut operation with no problems. Yet some modules seem to experience issues on PHP 5. I'm afraid you'll need to do some check on the forums for such modules that you may be using. But do remember to backup your databases and then you can go ahead with the upgrade without any worries. Good luck!
#13
Usually updating from PHP 4 to PHP 5 is a clean cut operation with no problems. Yet some modules seem to experience issues on PHP 5. I'm afraid you'll need to do some check on the forums for such modules that you may be using. But do remember to backup your databases and then you can go ahead with the upgrade without any worries. Good luck!
#14
closing...
#15
I keep trying to delete the folder/files from the server, but it won't work. I have just unistalled it, and the only thing that is still on the server is the default.settings.php file, which somehow cannot be deleted.