Page 1 of 1

[Solved]MissingArg plgContentPhocaDownload::onPrepareContent

Posted: 06 Jan 2010, 14:23
by gosa
Hi,

This is for those who might run into the same problem as I did.
I hope the moderator(Jan?) don't mind me posting a solution instead of a question as my intention is to only help people.

This is the message I got:
Warning: Missing argument 3 for plgContentPhocaDownload::onPrepareContent() in /home/xxxxxx/public_html/cms/plugins/content/phocadownload.php on line 40

After some research I found out that I had to make small modification in a file.
You have to open the file that's located in: /plugins/content/phocadownload.php
You look for the following function on line 39(in the current version)

And you change:

function onPrepareContent( &$article, &$params, $limitstart ) {

into:

function onPrepareContent( &$article, &$params, $limitstart = null ) {

And that's it.
Don't ask me what why you get this message in the first place cause I don't know how this function works but maybe someone can explain why it occurs.

Hope this helps others.

Greets,

Gosa

ps: Keep up the good work Jan and other Phoca staff!!!

Re: [Solved]MissingArg plgContentPhocaDownload::onPrepareContent

Posted: 09 Jan 2010, 17:55
by Jan
Hi, thank you for the information, I will add it into the new release of plugin.

Jan