1
aharon
content 1 module on xoops 2.0.16 - an error on add_content.php
  • 2007/1/16 4:18

  • aharon

  • Not too shy to talk

  • Posts: 172

  • Since: 2004/9/17


Hi,

Attempting to add content using content 1 module on XOOPS 2.0.16 brings the following error message:

Fatal error: Call to a member function on a non-object in /home/path_to/public_html/modules/content/admin/add_content.php on line 254

Line 254 is :
while($file = $folder->read()) {

Hence I give it in context of what seems the whole function:

$address_select = new XoopsFormSelect(_C_SELECTFILE, "address");
$address_select->addOption("", _C_NONE);
$folder = dir("../content/");
while($file = $folder->read()) {
if ($file != "." && $file != "..") {
$address_select->addOption($file, "".$file."");
}


I tried re-installing the module and checked the folders permissions (seemed fine)...

Any ideas how to fix this error..?

Thanks!

Aharon

2
aharon
Re: content 1 module on xoops 2.0.16 - an error on add_content.php
  • 2007/1/16 4:45

  • aharon

  • Not too shy to talk

  • Posts: 172

  • Since: 2004/9/17


Seems that I fixed this problem by adding two folders in the module's folder.
One is "content", the other is "headers"...

So now I can add content, though the fix seems a bit dodgy...

For example, attempting to add content type "link", gives the following errors:
Notice: Undefined index: showerror in file /modules/content/index.php line 40
Notice: Undefined index: cont_permits_advnaced in file /modules/content/index.php line 49
Notice: Undefined variable: crumbsout in file /modules/content/index.php line 167

Line 40 = $header_img = $fileupload_name;

Line 49 = $sqlinsert="INSERT INTO ".$xoopsDB->prefix(_MIC_CONTENT_PREFIX)." (parent_id, ptitle, title, text, visible, homepage, nohtml, nosmiley, nobreaks, nocomments,
link, address, submenu, newwindow, date, assoc_module, header_img) VALUES ('" . intval($parent_id) . "','" . $ptitle . "','" . $title . "','" .

Line 167 = $categoria_select->addOption("", _C_MAINMENU);

Any ideas about these errors..?

Aharon

Login

Who's Online

228 user(s) are online (151 user(s) are browsing Support Forums)


Members: 0


Guests: 228


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: May 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits