- Where Developers Learn, Share, & Build Careers


In setting parameters for my component, I want one of them to be an article ID that opens and uses is done. According to, text is the only option.

Can the integers be specified, or is there any way to validate the input?

As far as I know, text is your only standard solution Joomla, however, allows for custom parameter types. You can imagine that for an integer, but if this is for article selection only, then what can you do for Joomla for the com_content component?

  1. Create a new folder in your admin component called: admin \ component \ com_mycomponent \ elements
  2. Copy admin \ components \ com_content \ elements \ article.php in your new folder (and for index.html security)
  3. You can now add "Articles" to your component as shown below You can specify a parameter type, and component configuration will have a dropdown of your articles.
  4. Be sure to include the adapter in your Elements folder in your "Parameters".

    & lt; Parameter addpath = "/ admin / components / com_mycomponent / elements" />

    & lt; Ultimate type = "article" name = "article_id" default = "0" label = "choose paragraph" />

Comments

Popular posts from this blog

Python SQLAlchemy:AttributeError: Neither 'Column' object nor 'Comparator' object has an attribute 'schema' -

java - How not to audit a join table and related entities using Hibernate Envers? -

mongodb - CakePHP paginator ignoring order, but only for certain values -