Welcome, Guest
Username Password: Remember me

[SOLVED] Error
(1 viewing) (1) Guest

TOPIC: [SOLVED] Error

[SOLVED] Error 2 years ago #189

  • Arno
  • OFFLINE
  • Fresh Boarder
  • Posts: 4
Hello,
I've just installed the module and here is the message I have on my browser:

Parse error: syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /homez.323/prothesed/www/plugins/content/faqslider.php on line 24

Can someone tell what I have to do to fix this issue?.
Thanks a lot.

Arno.
Last Edit: 1 year, 11 months ago by mattfaulds.

Re: Error 2 years ago #192

Hi Arno

This is a PHP4 error by the looks of it. What version are you running. You really need PHP5... PHP4 is very old.

Re: Error 1 year, 11 months ago #248

  • Arno
  • OFFLINE
  • Fresh Boarder
  • Posts: 4
Hi Mattfaulds,
I have checked out and the version is PHP5.0 ... I don't know what to do?
Thanks.
Arnaud.

Re:Error 1 year, 11 months ago #252

  • Frost
I'm getting the exact same error when I install the pluggin and my host is using PHP version 5.2.6.

I've uninstalled the pluggin to get back to a working site.

Re:Error 1 year, 11 months ago #253

Ok guys, I'll explain the error message step by step:

1) php tries to parse the code
2) it gets as far as line 24 which is
public function onPrepareContent( &$article, &$params, $limitstart )
in the code snippet below:
class plgContentFaqSlider extends JPlugin
{
public function onPrepareContent( &$article, &$params, $limitstart )
{
$app = &JFactory::getApplication();


3) you have a version of php that cannot understand the "public function" bit of line 24 - it thinks it is a string which is not allowed here - hence "Parse error: syntax error, unexpected T_STRING"

This syntax (public/private) is a feature of php5.


So, although you seem to be using php5 you must have either:

php processing pointed to a php4 installation
or
php4 and 5 co-installed which I believe can cause this sort of problem


How can you sort this out? Well, there are two options:

1) contact your hosts and ask them to test your installation to see if you can successfully run any code which uses the same type of syntax (public/private functions etc)
2) strip the code of any public/private references (which essentially downgrades it to php4)

I really want to hear if you solve this as I'm 100% convinced that this is not an FAQSlider problem. The only other thing that I can think of is some whitespace being processed as a string on your server...

Good luck and Google around on the error if you don't believe me!
Last Edit: 1 year, 11 months ago by mattfaulds.

Re:Error 1 year, 11 months ago #254

Just in case, I've cleaned all the whitespace. Try replacing faqslider.php with the attached file. The file is found in yourJoomlsFolder/plugins/content/

File Attachment:

File Name: faqslider.php
File Size: 13612
Last Edit: 1 year, 11 months ago by mattfaulds.
Time to create page: 0.33 seconds

Login

Make a Donation...

 

© 2009 Content: Trafalgar Design. Template: Afterburner.