Home arrow Forum Problem in Subs.php line 871 using JSMF Recent Topics and Virtuemart
  Welcome, Guest. Please login or register.
Did you miss your activation email?
December 01, 2008, 11:18:39 PM
Home New Posts Search Calendar


Login with username, password and session length
+  Joomla Forum
|-+  Joomla Hacks
| |-+  Joomla-SMF Forum Support
| | |-+  Joomla-SMF 2.0.x (Moderators: -Wolverine, kai920)
| | | |-+  Problem in Subs.php line 871 using JSMF Recent Topics and Virtuemart
0 Members and 1 Guest are viewing this topic. « previous next »
Pages: [1] Go Down Print
Author Topic: Problem in Subs.php line 871 using JSMF Recent Topics and Virtuemart  (Read 2405 times)
SteveO
Joomla Newbie
*

Karma: +1/-0
Offline Offline

Posts: 15


View Profile
Problem in Subs.php line 871 using JSMF Recent Topics and Virtuemart
« on: December 27, 2006, 06:33:16 PM »

Hi all,

Not sure where to put this topic because it touches on so many things, but here goes.

I have come across a persistent PHP error using Joomla, JSMF Bridge and Virtuemart on my site.

versions-
Joomla: 1.0.11 (but also 1.0.10 previously)
JSMF: 2.0 RC3
Recent Topics: 2.0.2 (but also 1.7.1 previously)
SMF: 1.1 RC3
Virtuemart: 1.0.7


Error -

With all of the above except the Virtuemart module published everything works fine.

If I publish the VM module the site breaks; the web site page displays the left-hand module/menus, the top banner and nothing else.

The server logs also show the following PHP error -

PHP Fatal error:  Call to undefined function:  () in blah_blah/community/Sources/Subs.php on line 871


If I log out then the site index display reverts to normal.

If I unpublish the VM module the site works fine.

I have kludged my way around a fix that seems to me to solve my problem, but I've no idea if I'm breaking anything else -

If I comment out lines 868 -to - 873 in Subs.php then everything works, JSMF Bridge, JSMFRecent Topics and Virtuemart.


I'm posting this in case someone else has this problem and also because I recognise my workaround is a complete kludge and should be "fixed" by someone who knows what they're doing.

Cheers
Logged
-Wolverine
Moderator
Joomla Guru
*****

Karma: +376/-34
Offline Offline

Posts: 3393


Lead Developer


View Profile WWW
Re: Problem in Subs.php line 871 using JSMF Recent Topics and Virtuemart
« Reply #1 on: December 28, 2006, 12:03:11 PM »

You should at least upgrade to JSMF 2.0 Final. 

Try this just for debugging, it may help me find the real problem.  On line 870 change these two lines to be this:

Code:
if (strpos($str, $token) !== false) {
    die("FUNC is:<br />".print_r($func));
    $str = str_replace($token, $func['ucwords'](strftime($token, $time)), $str);
}

When SMF loads it creates this array, $func, and for whatever reason it doesn't appear to be set when this function is executed.  It should be set because JSMF includes SSI.php.

Let me know what the result is.
Logged

Need help?  Check Here First!
Get the JSMF User Guide
SEARCH this forum.
SteveO
Joomla Newbie
*

Karma: +1/-0
Offline Offline

Posts: 15


View Profile
Re: Problem in Subs.php line 871 using JSMF Recent Topics and Virtuemart
« Reply #2 on: December 28, 2006, 06:50:42 PM »

Hi, I upgraded to JSMF v2 Final and:

a.) first of all the result was the same (broken as above)

b.) I then made the edits to Subs.php as you described and:

- no page at all loads (blank/white screen)
- server php error logs show:
Code:
PHP Parse error:  syntax error, unexpected $end in blah_blah/community/Sources/Subs.php on line 3570

I then commented out the same lines in Subs.php as I described above and the site works as it should now.

Is that any help?

Cheers.

Logged
-Wolverine
Moderator
Joomla Guru
*****

Karma: +376/-34
Offline Offline

Posts: 3393


Lead Developer


View Profile WWW
Re: Problem in Subs.php line 871 using JSMF Recent Topics and Virtuemart
« Reply #3 on: December 28, 2006, 11:09:56 PM »

not really, the code I put is to output a bunch of debug information.  It is scenario where you put the code in, refresh the page, copy the error, and then take the code out.  Then paste the error here.  You might need to check if you have Joomla error reporting set to maximum.  You can find this in Joomla admin->global config->server tab

Sounds like you missed the closing curly brace(}) and that is why you got the error you did.  Try again for me if you would, make sure you get the whole piece of code.
Logged

Need help?  Check Here First!
Get the JSMF User Guide
SEARCH this forum.
SteveO
Joomla Newbie
*

Karma: +1/-0
Offline Offline

Posts: 15


View Profile
Re: Problem in Subs.php line 871 using JSMF Recent Topics and Virtuemart
« Reply #4 on: December 30, 2006, 04:16:18 PM »

Hmm, sorry about that, I had grabbed the whole piece of code but hadn't inserted it correctly.

I've repeated the process and this is the error message:

Code:
Array ( [entity_fix] => lambda_335 [substr] => lambda_336 [strlen] => lambda_337 [strpos] => lambda_338 [htmlspecialchars] => lambda_339 [htmltrim] => lambda_340 [truncate] => lambda_341 [strtolower] => strtolower [strtoupper] => strtoupper [ucfirst] => ucfirst [ucwords] => ucwords ) FUNC is:
1

Hope that's a little more use than the first one  Wink
Logged
icho tolot
Joomla Newbie
*

Karma: +0/-0
Offline Offline

Posts: 2


View Profile
Re: Problem in Subs.php line 871 using JSMF Recent Topics and Virtuemart
« Reply #5 on: January 01, 2007, 05:32:20 AM »

hi,

i had the same problem with easybook.
my solution:
easybook use also the $func variable, so the system crashes.
i have changed the $func variable in easybook to $funceas -
now i have no problems

icho.tolot
« Last Edit: January 01, 2007, 02:03:09 PM by icho tolot » Logged
-Wolverine
Moderator
Joomla Guru
*****

Karma: +376/-34
Offline Offline

Posts: 3393


Lead Developer


View Profile WWW
Re: Problem in Subs.php line 871 using JSMF Recent Topics and Virtuemart
« Reply #6 on: January 01, 2007, 01:52:24 PM »

that very well could be the problem
Logged

Need help?  Check Here First!
Get the JSMF User Guide
SEARCH this forum.
SteveO
Joomla Newbie
*

Karma: +1/-0
Offline Offline

Posts: 15


View Profile
Re: Problem in Subs.php line 871 using JSMF Recent Topics and Virtuemart
« Reply #7 on: January 01, 2007, 06:14:23 PM »

That sounds cool, is there a solution for me, or somethingelse you want me to try?

Ste
Logged
Robert C. Pack
Joomla Newbie
*

Karma: +0/-0
Offline Offline

Posts: 2


View Profile
Re: Problem in Subs.php line 871 using JSMF Recent Topics and Virtuemart
« Reply #8 on: January 05, 2007, 10:16:55 PM »

I'm having the *exact* same problem at Subs.php line 871 when using the recent topic module.  I don't have Virtuemart installed though. 

Bob
Logged
FidelGonzales
Joomla Newbie
*

Karma: +0/-6
Offline Offline

Posts: 35


View Profile
Re: Problem in Subs.php line 871 using JSMF Recent Topics and Virtuemart
« Reply #9 on: September 10, 2008, 04:17:56 PM »

I am also having this issue and have yet to find a fix. Any suggestions? Thank you.

Joomla version is: 1.0.13
SMF version is: 1.1
Joomla-SMF version: 2.0.2.1
Virtuemart version: 1.0.13
Logged
Pages: [1] Go Up Print 
« previous next »
Jump to:  



Login with username, password and session length

Powered by MySQL Powered by PHP Joomla Forum | Powered by SMF 1.1 RC1.
© 2001-2005, Lewis Media. All Rights Reserved.
Joomla Bridge by JoomlaHacks.com
Valid XHTML 1.0! Valid CSS!

Joomla Hacks is a Joomla Components, Joomla Modules, Joomla Templates, & Joomla Mambots resource portal. None of the text or images in this public website may be copied without the expressed written consent of the authors. Copyright 2005 by JoomlaHacks.com. Powered by Joomla. All rights reserved.
Terms of Use
Joomla Hacks



Joomla Hacks
German Lang French Lang Italian Lang Spanish Lang Japanese Lang Chinese Lang
MamboBuzz.com
Search Contact About Advertise Blogs Topsites Submit News Register Login