Skip to main content
Topic: Guide for Addon Development for ElkArte (Read 2498 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Guide for Addon Development for ElkArte

Guide for Addon Development for ElkArte mainly if you are coming from SMF?

In the creation of some of my addons I noticed a couple things that have changed. And thinking it would be helpful to a list/start guide on the conversion process.

Re: Guide for Addon Development for ElkArte

Reply #1

I think there is no specific guide for the time being but they are basically the same with most important aspects of it have been discussed and posted here and there in this forum.

All addon package will need one package-info.xml file. Hooks to EA can be put directly inside that file or otherwise use a separate file. Manual modification, though not encouraged, when necessary can still be used.

For the directory, the main ones are redefined like BOARDDIR and SOURCEDIR instead of the ones previously used like $boarddir and $sourcedir. Specially for source files, they are divided to admin, controller, subs, etc instead of lumping everything together in one source directory.

And for database, we use $db = database(); $dbtbl = db_table(); instead of using $smcFunc.

I can't think of everything else for the time being, mainly because I myself am not so good with any of them. I only manage to do few simple addons migration or creation when I really focus and put my mind unto it but, most of the time, I tend to get confused or forget and start researching about them all over again whenever I have time to look back into them.

I really like to see more and more smf mods and themes authors coming and thus wish them all with very good luck!
Last Edit: January 30, 2017, 06:10:03 am by ahrasis

Re: Guide for Addon Development for ElkArte

Reply #2

You mean something like
Quoteinstead of $smcFunc['db_query'] use:
Code: [Select]
$db = database();
$db->query('', 'query');
and things like that?

Time, time, time... xD
Bugs creator.
Features destroyer.
Template killer.

Re: Guide for Addon Development for ElkArte

Reply #3

Yeah if not I was going to write something up.

Re: Guide for Addon Development for ElkArte

Reply #4

If you want to, feel free!!
That's actually the spirit. ;)
Bugs creator.
Features destroyer.
Template killer.