How i get the list of module before load modules? - prism

I want to use moduleinfor as a menu, so I must get the list of the module before load modules.I would check the module if it should be loaded, but I don't know when and how to get the list of the module before load modules.
Please show me some help.Thank you.

You're thinking about this all wrong. You tell Prism what modules you have. So you should already know this information. If you must do it this way, you could ask for the IModuleCatalog and iterate through the Modules. Keep in mind that the ModuleInfo objects do not implement INPC and will not send change notifications.

Related

Need guide on Joomla

Its my first time to work with Joomla and I need to make a plugin that basically stores/updates a name and a City the thing is that I want this functionality only in admin panel not in the front end.
Its a bit confusing to me weather I should create a component or a module or a plugin ?
Does anyone has a good guide on how to create such functionality?
Thanks in advance.
If you don't know when to use a module, a plugin, or a component, then a good starting point would be here.
Typically, a module is essentially used for displaying content on specific pages in a specific location. A plugin usually works in the background (modifies displayed content, computes stuff, alters the database, processes payments, etc...). A component is like the Joomla articles component (com_content), in most cases, a component occupies the biggest part of the page (while a module occupies a smaller part).

Best way to extend CKEDITOR.styles?

I feel like I need to change a couple methods in style.js in order to integrate it into my app. What is a "best practice" for adding methods or even overriding methods in core objects? I plan on doing upgrades in the future, so I don't want to edit the style.js file itself.
The way to extend CKEditor is to create plugins for it.
If you have to modify something inside a closure then a plugin won't work for you and you'll have to get the source code and modify it and from then on keep using that patch.

How to add new component parameters in Joomla on the fly?

usually its done by setting up the config.xml but what to do when my component needs more parameters at run-time ? There is little or zero information about, just 1-2 tutorials about custom parameters which could be used to archive the same thing but only if you're willing to write lots of bloat code for a very simple thing.
In my case my component is rather a little platform in it self, ie: users can add plugins from us. Of course I'd like to expose some options for such plugins in the component's options.
Is there any shortcut because if you look at the built-in component's code, you really don't want to do the same for each plugin...
well, thanks! any thoughts are welcome!
ps: may be there is something more compact like the Redux-Framework for Wordpress. I'd love to know there is library which can server both CMS systems.
update
'component' = Joomla component and by 'plugin' I mean my and non-Joomla plugin, hosted in a Joomla component. Imagine your Joomla component is just a host for external plugins.
You need to create a custom field type, where you'll be able to implement all the logic that's needed.
In case you need to store the values with the component, add a hidden input field, and use javascript to populate the markup on load, and insert the values you want to store on user interaction (you can also store an object encoded in json). Joomla will take care of saving and retrieving it.
the docs

Codeigniter loading a helper without the "_helper" suffix?

I am trying to implement a OrientDB HTTP connection in Code Igniter, but I can't quite decide how to go about it. Basically, I am using the php code found here, and I cannot decide whether to make that file collection into a library or a helper.
Right now, I am leaning towards a helper, because $this->load->library() automatically instantiates the class, where I will need the ability to call static methods as well (as can be seen in the use of BindingParameters::create('http://admin:admin#127.0.0.1:2480/demo');) in the example code.
So, if I make these files into helpers, which should not instantiate the classes, is there a way to load them without adding a "_helper" suffix to the files themselves? I would like to avoid using require/include, but if there is no other way to accomplish this then I have no choice.
Does anyone have any tips or ideas that may help me with this? Thanks beforehand.

Magento: Need information for a setup script

I'm trying to create a setup script to install custom attributes on my DB tables and I'm looking for references on regards to the following. I just need to know what they really do as on some of the examples I listed which I found on another question but I haven't located any information anywhere else. If someone knows where I can read about this, I'd appreciate it.
adminhtml_customer //to make the attribute can be created in backend only
customer_account_create //to make the attribute can be created in registration only
customer_account_edit // to make the attribute can be edited in the frontend only
customer_address_edit
customer_register_address
checkout_register
adminhtml_customer_address
based on the 3 first samples I listed, I can sort of guess what the others do but I do want to be mistaken about my guess and if there are others that I did not list, I'd be happy to get that information as well.
Give a look to the setup script of core code Pools (/app/code/core/Mage) modules, you can find a lot of good hint

Resources