This tips is a part of my session in XCDM#1.
You can hook renderer of XCL2.1 entirely just putting a preload.
First, read the source code of a preload named "HdXoopsTplHook.class.php".
A directory "XOOPS_TRUST_PATH/libs/smartyplugins" is inserted into the top of an array $xoopsTpl->plugins_dir.
This looks like ryusSmartyPluginsEx.
http://ryus.co.jp/modules/wordpress/index.php?p=57
But you should notice the different between addition and insertion.
By insertion, you can also hook almost smarty plugins.
The most important target is resource.db.php.
(I'll show a god sample to hook resource.db.php in the next time)
And the method of hook() also sets the selected theme as "compile_id".
This allows you to select themes with templates for the theme.
Certainly, this looks the same way as the core from xoops.org.
But you should know such a strong hooking is achieved just by adding an extra file. There are no core files overwritten. (Then you can update the core casually)
This is another proof which XCL2.1 has been well-designed definitely.
Yesterday, I took part in XCDM#1.
In the meeting, minahito tried to wash our brain."What does the project give us"
"What do we give the project".
Certainly, both XOOPS projects don't look like common OpenSource Projects.
We should think "what is OSS", again.
# Marijuna gave me "XOOPS Cube Legacy Developer's bible"
# I'll read it soon.
Here is the specs of pico's form processing system.
Of course, you can change default behaviors by adding parameters.
eg) add a parameter of to="" inside <{command}>
Any parameters can be missed. Default values are defined in language files.
I've just released d3forum-0.77.
You can use fckxoops with this version.
Perhaps, you've already known forum modules can use WYSIWYG Editors.
But d3forum is far differnt from them because of the security.
If you turn "Enable HTML" on, your post will be filtered HTMLPurifier automatically.
Then, all of JavaScripts will be removed from the post.
I've opened "HTML allowd FORUM" for my experments.
http://xoops.peak.ne.jp/md/d3forum/index.php?forum_id=12
Only with the forum, you can use fckxoops and allow HTML.
Of couse, you can control such detailed settings by forum's option.
Now, I show a practical examples how to use pico's formmail system.
Case 1:
"Implant forms after product presentation pages"
You can easily achive it using pico's smarty plugisn "pico" and "formmail".
Make a content like this. (Turn "Smarty" filter on)
(products introducing section)
<{capture}>
<{pico id="(content ID describing the form)"}>
<{/capture}>
<{formmail4fleamarket mail_body_pre="A query from visitor exists\nContact him/her soon as possible\n\n" from_name="Product manager" cc_field_name="youremail" cc_mail_subject="A confirmation for your query" cc_mail_body_pre="Thank you for querying us.\nThis is the content you have queried\n"}>
<form>
name: <input type="text" name="name" class="required" /><br />
email: <input type="text" name="youremail" class="email" />
<input type="submit" />
</form>