简体   繁体   中英

Dynamic content in Joomla Articles

I have some joomla articles. some values in that article has to be updated by data obtained through a soap call to other site. Is there any plugin available for joomla by which i can embed custom php inside articles?? How can i do this.??

To me, the ideal way is to create a traditional component that gets all the data. This component inserts these values in specified article ids. These articles act as "data containers".

Why create a traditional component? Because you'll be going to use libraries, error corrections and such and a component solution can be more robust. IMHO it's a good idea to avoid php logic in your editor panel.

Then, in the articles that are shown to users in the frontend, using Include Content Item Joomla Plugin , you add {include_content_item 123} , being 123 the id of the article you inserted data you want to show in your component. Doing the {} call outputs the article which id is "123".

There are a lot of such component, they are more or less the same. I use Sourcerer, but pay attention as version of php is crucial sometimes. http://extensions.joomla.org/extensions/core-enhancements/coding-a-scripts-integration/custom-code-in-content/5051

Allows to insert php/js/css code to articles and modules.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM