[3.2.9-3.3.x][RC] Glossary 3.0.20

A place for Extension Authors to post and receive feedback on Extensions still in development. No Extensions within this forum should be used within a live environment!
Suggested Hosts
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

IMPORTANT: Extensions Development rules

IMPORTANT FOR NEEDED EVENTS!!!
If you need an event for your extension please read this for the steps to follow to request the event(s)
Post Reply
User avatar
pierredu
Registered User
Posts: 1255
Joined: Thu Nov 01, 2012 8:04 am
Location: Paris (France)

[3.2.9-3.3.x][RC] Glossary 3.0.20

Post by pierredu »

Extension Name: LMDI Glossary
Author: Pierre Duhem

Extension Description: Glossary for phpBB 3.2.9-3.3.x
Extension Version: 3.0.20


Features:
  • * Glossary static page displaying the content of the phpbb3_glossary table
  • * Glossary edition page reserved for administrator, to edit entries, create new ones, etc.
  • * Glossary term tagging in topics
Extension Download: https://github.com/pierrdu/lmdi_gloss/a ... master.zip

History: this extension was ported from a MOD called Lexicon/Acronym, whose roots are pretty impenetrables. See in particular:
viewtopic.php?f=70&t=584656
viewtopic.php?f=70&t=584656&start=240
In the headers of some files, il seems that the acronym part was a project of the phpBB team, but I could not ascertain anything.

Installation:
1. Download the latest release.
2. Unzip the downloaded release, and change the name of the folder to `gloss`.
3. In the `ext` directory of your phpBB board, create a new directory named `lmdi` (if it does not already exist).
4. Copy the `gloss` folder to `/ext/lmdi/`.
5. Navigate in the ACP to `Customise -> Manage extensions`.
6. Look for `LMDI Glossary` under the Disabled Extensions list, and click its `Enable` link.

Enable the feature in the ACP (Extension tab).
Some users dislike the tagging of terms in the posts. Therefore, there is an option
to disable it individually in the UCP.

Glossary entry edition
By default, only administrators have this permission set in their group. If you want to give the permission to moderators, you should set this permission to Yes in their group. You may also want to create a special group of glossary editors.

Uninstall
1. Navigate in the ACP to `Customise -> Extension Management -> Extensions`.
2. Look for `LMDI Glossary` under the Enabled Extensions list, and click its `Disable` link.
3. To permanently uninstall, click `Delete Data` and then delete the `/ext/lmdi/gloss` folder.
Just drop the extension files in the folder ext/lmdi/gloss, then activate the extension in the ACP.

Testing
Write a topic on a test forum with the terms appearing in the variants column. This column can contain singular and plural forms, etc.

Downloading link:
https://github.com/pierrdu
Last edited by pierredu on Wed Apr 14, 2021 12:21 pm, edited 62 times in total.
John45
Registered User
Posts: 199
Joined: Sat Jun 08, 2013 2:54 am

Re: [DEV] Glossary 1.0.0

Post by John45 »

This is awesome, I'll bump the topic for ya. :D
nya
Registered User
Posts: 157
Joined: Mon Jun 01, 2015 8:31 am

Re: [DEV] Glossary 1.0.0

Post by nya »

You awesome man. Nice ext. Very usable. :D
nya
Registered User
Posts: 157
Joined: Mon Jun 01, 2015 8:31 am

Re: [DEV] Glossary 1.0.0

Post by nya »

Oh. Did anyone try it with non-latin letters? :roll:
User avatar
pierredu
Registered User
Posts: 1255
Joined: Thu Nov 01, 2012 8:04 am
Location: Paris (France)

Re: [DEV] Glossary 1.0.0

Post by pierredu »

The table is coded as UTF-8.
This should work.
I have some greek words in the definitions, but not in the terms themselves.
Holger
Registered User
Posts: 1882
Joined: Tue Mar 12, 2002 3:54 pm
Location: Hannover

Re: [DEV] Glossary 1.0.0

Post by Holger »

Nice!
Demo? Screenshots?
User avatar
pierredu
Registered User
Posts: 1255
Joined: Thu Nov 01, 2012 8:04 am
Location: Paris (France)

Re: [DEV] Glossary 1.0.0

Post by pierredu »

You can download the current version from github. See the link in the first post.
With the two dummy entries, you can see what happens.
nya
Registered User
Posts: 157
Joined: Mon Jun 01, 2015 8:31 am

Re: [DEV] Glossary 1.0.0

Post by nya »

Table '1111_forum.phpbb_glossary' doesn't exist [1146]

SQL

SELECT DISTINCT UPPER(LEFT(TRIM(term),1)) AS a FROM phpbb_glossary ORDER BY a

BACKTRACE

FILE: (not given by php)
LINE: (not given by php)
CALL: msg_handler()

FILE: [ROOT]/phpbb/db/driver/driver.php
LINE: 855
CALL: trigger_error()

FILE: [ROOT]/phpbb/db/driver/mysqli.php
LINE: 193
CALL: phpbb\db\driver\driver->sql_error()

FILE: [ROOT]/phpbb/db/driver/factory.php
LINE: 329
CALL: phpbb\db\driver\mysqli->sql_query()

FILE: [ROOT]/ext/lmdi/gloss/glossaire.php
LINE: 54
CALL: phpbb\db\driver\factory->sql_query()

:cry:
User avatar
mrgoldy
Former Team Member
Posts: 1394
Joined: Tue Oct 06, 2009 7:34 pm
Location: The Netherlands
Name: Gijs
Contact:

Re: [DEV] Glossary 1.0.0

Post by mrgoldy »

He's posted table information in the Readme:
https://github.com/pierrdu/lmdi_gloss/b ... /README.md

@pierredu,
You can add tables and 'dummy files' through you migration file(s) aswell.
You can read more about it here
phpBB Studio / Member of the Studio

Contributing: You can do it too! Including testing Pull Requests (PR).
phpBB Development and Testing made easy.
nya
Registered User
Posts: 157
Joined: Mon Jun 01, 2015 8:31 am

Re: [DEV] Glossary 1.0.0

Post by nya »

Thank you for answer, but i didnt realize how to do this:

CREATE TABLE phpbb3_glossary ( term_id mediumint(9) NOT NULL AUTO_INCREMENT, variants varchar(80) NOT NULL DEFAULT '', term varchar(80) DEFAULT NULL, description varchar(512) NOT NULL DEFAULT '', picture varchar(80) DEFAULT NULL, lang varchar(15) NOT NULL DEFAULT 'fr', PRIMARY KEY (term_id) ) ENGINE=MyISAM DEFAULT CHARSET=utf8;

I havent migration files. :(
User avatar
pierredu
Registered User
Posts: 1255
Joined: Thu Nov 01, 2012 8:04 am
Location: Paris (France)

Re: [DEV] Glossary 1.0.0

Post by pierredu »

This is a SQL command. Use it in phpMyAdmin or in Adminer.
But I'll write a migration file for that.
User avatar
Jessica
Former Team Member
Posts: 4342
Joined: Sun Jul 18, 2010 2:53 pm
Location: Pennsylvania, USA
Name: Jessica
Contact:

Re: [DEV] Glossary 1.0.0

Post by Jessica »

Can you post screenshots please?
Pro-choice, Atheist, Pro-LGBT rights
Everybody is a genius. But if you judge a fish by its ability to climb a tree, it will live its whole life believing that it is stupid. - Albert Einstein
User avatar
pierredu
Registered User
Posts: 1255
Joined: Thu Nov 01, 2012 8:04 am
Location: Paris (France)

Re: [DEV] Glossary 1.0.0

Post by pierredu »

Here are two screenshots from the extenson running on my development server:

Image

This show the static display page of the glossary (feature 1 in the presentation post above).

Image

This shows how terms are tagged in the posts. In this sample, tagged terms are 'tergite', 'tergites', 'sternites' and 'agglomerat'. Note that the singular and plural forms (tergite(s)) is a single entry in the glossary.

When hovering above the terms, the cursor becomes the question mark (not visible on the screenshot). If one clicks on the 'agglomérat' term, one gets the popup on the right, with the term, the explanation and a picture. A classical close box is present. If there is no picture, we use a single white pixel file.

On the other hand, I added the creation of the table and of the dummy entries in the migration file.
Holger
Registered User
Posts: 1882
Joined: Tue Mar 12, 2002 3:54 pm
Location: Hannover

Re: [DEV] Glossary 1.0.0

Post by Holger »

Very nice!
So, when a term is used in a forum-post there will be a link to the item in the glossary?
User avatar
pierredu
Registered User
Posts: 1255
Joined: Thu Nov 01, 2012 8:04 am
Location: Paris (France)

Re: [DEV] Glossary 1.0.0

Post by pierredu »

It is not exactly a link to the item. The content of the item is displayed in a popup window within the topic. The link to the glossary is at the top of the page, in the tool bar.

[Edition: spell checking]
Last edited by pierredu on Tue Dec 01, 2015 12:01 pm, edited 1 time in total.
Post Reply

Return to “Extensions in Development”