WebsiteBaker Community Forum

WebsiteBaker Support (2.10.x) => Modules => Topic started by: thefly on June 12, 2017, 02:59:13 PM

Title: Uncatched exception in Multipart Pages
Post by: thefly on June 12, 2017, 02:59:13 PM
Hi, everyone! Just installed Multipart Pages from Ruud. Super modules, Ruud! I'm looking forward for PageTags :))

But I saw a little problem in MultiPart Pages (Running on last 2.10 WB and PHP7): After trying to create a new PageType I got this:

Quote
There was an uncatched exception
Call to undefined function mysql_insert_id()
in line (62) of (/modules/multipage/addpagetype.php):

I am far from programming myself, but it seems to me that it is an old PHP function? Or I was able to mess something?
Title: Re: Uncatched exception in Multipart Pages
Post by: Ruud on June 12, 2017, 03:17:14 PM
This is a pretty old module ... And yes, the error is about an old function that does not exist since some time.

You can fix it on WB2.10 (actually on WB283-SP3 and newer) by replacing that line 62 with
Code: [Select]
$pagetype = $database->getLastInsertId() ;
Title: Re: Uncatched exception in Multipart Pages
Post by: thefly on June 12, 2017, 03:36:09 PM
Thanks, Ruud! I did it. And new PageType is added smoothly. In fact it was possible to add the new PageTypes, or at least I saw new PageTypes in the dropdown list. When I tried to delete some PageType WB returned error:
Quote
This page isn’t working

nocommentgroup.eu is currently unable to handle this request.
HTTP ERROR 500

Anytime, may be the future PageItems module will be more convenient for my needs. As I understand, it will add some fields to the usual WYSIWYG-pages and it will be possible to list pages with specific content of these fileds. May be it I should be patient for you to finish this module :))
Title: Re: Uncatched exception in Multipart Pages
Post by: Ruud on June 12, 2017, 03:56:40 PM
If I was you I would have a look at the oneforall module first.
https://addon.WebsiteBaker.org/pages/en/browse-add-ons.php?id=04238F62

It does more-or-less the same thing, and a bit more.. :)
It also is in active development and is working fine on the latest WB and PHP versions.
Title: Re: Uncatched exception in Multipart Pages
Post by: thefly on June 12, 2017, 04:24:19 PM
Thanks! You're right!