PHP Classes

Ascoos OS - CiC (Cross-Interpreter Communication): combine WordPress and Joomla in a shared runtime

Recommend this page to a friend!
     
  Info   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Last Updated Ratings Unique User Downloads Download Rankings
2025-11-30 (1 month ago) RSS 2.0 feedNot yet rated by the usersTotal: Not yet counted Not yet ranked
Version License PHP version Categories
aos-sec00080-wp_joom 1.0Custom (specified...8.2Libraries, Content management, Blogs, P...
Description 

Author

This package can combine WordPress and Joomla in a shared runtime within Ascoos OS.

It provides an case study that shows how to integrate WordPress and Joomla in Ascoos OS and executing, translating, and exchanging logic in real time.

It shows how uses Ascoos OS for:

- Implement WordPress action hooks

- Access Joomla user details using an API bridge

Innovation Award
PHP Programming Innovation award nominee
December 2025
Nominee
Vote
WordPress and Joomla are two popular content management systems written in PHP that are implement using software development approaches.

This package demonstrates how a developer can combine the two content management systems using Ascoos Os classes to integrate them and take advantage of the benefits of each system in the same PHP application.

Manuel Lemos
Picture of Christos Drogidis
  Performance   Level  
Name: Christos Drogidis <contact>
Classes: 32 packages by
Country: Greece Greece
Age: ???
All time rank: 379423 in Greece Greece
Week rank: 5 Up1 in Greece Greece Up
Innovation award
Innovation award
Nominee: 19x

Winner: 2x

Instructions

Please read this document learn how to integrate WordPress and Joomla using Ascoos Os.

Details

Cross-Interpreter Communication (CiC) ? WordPress & Joomla Case Study

This case study demonstrates how Ascoos OS implements the CiC (Cross?Interpreter Communication) standard to combine WordPress and Joomla in a shared runtime. Instead of simple integration, each CMS acts as an autonomous interpreter capable of executing, translating, and exchanging logic in real time, paving the way for Web5 and WebAI interoperability.

Purpose

  • Interpret WordPress hooks in a common interpreter
  • Translate hooks into conditional macros
  • Execute Joomla API calls via bridge
  • Combine results into a unified render
  • Demonstrate Web5 interoperability through CiC

Main Classes of Ascoos OS

  • TWordpressInterpreterHandler Interprets WordPress hooks into logic objects
  • TWordpressHookTranslatorHandler Translates hooks into conditional macros
  • TJoomlaApiBridgeHandler Executes Joomla API calls and returns data
  • TMacroHandler Unifies and executes conditional macros from multiple CMSs
  • TErrorMessageHandler Handles errors and execution messages

File Structure

The implementation resides in a single PHP file: - wp_joomla_in_aos.php

It contains the full logic: WordPress hook interpretation, translation into macros, Joomla API execution, and result combination.

Prerequisites

  1. PHP ? 8.2
  2. Installed Ascoos OS or AWES 26
  3. Available autoloaders for WordPress and Joomla cores

Execution Flow

  1. Load the WordPress and Joomla cores via autoloaders.
  2. The WordPress hook `add_action('wp_head', 'my_custom_head', 10, 1)` is interpreted by `TWordpressInterpreterHandler`.
  3. The hook is translated into a macro via `TWordpressHookTranslatorHandler`.
  4. The macro is inserted into `TMacroHandler` with conditional execution.
  5. `TJoomlaApiBridgeHandler` calls the API `JFactory::getUser`.
  6. `TMacroHandler` executes all conditional macros.
  7. Results are combined and displayed in a unified render.

Code Example

$wpInterpreter = new TWordpressInterpreterHandler(['cms' => ['cmsType' => 'wordpress']]);
$wpHook = $wpInterpreter->interpretHooks("add_action('wp_head', 'my_custom_head', 10, 1)");

$wpTranslator = new TWordpressHookTranslatorHandler();
$wpMacro = $wpTranslator->translate($wpHook, ['hook' => 'wp_head']);

$macroEngine->addConditionalMacro(
    $wpMacro->condition->condition,
    fn(...$p) => $wpMacro->executeIfTrue(...$p)
);

$joomlaApiBridge = new TJoomlaApiBridgeHandler();
$userData = $joomlaApiBridge->bridge('JFactory::getUser', []);

$macroEngine->runAllConditional();
echo "@render_combined({$userData['name']})";

Expected Result

@render_combined(Ascoos user)

Resources

Contribution

You can extend CiC with more interpreters (e.g., Drupal, Python APIs) or improve translators for more complex hooks. See CONTRIBUTING.md for guidelines.

License

This case study is covered by the Ascoos General License (AGL). See LICENSE.md.


  Files folder image Files (5)  
File Role Description
Accessible without login Plain text file aos-SEC00080-wp_joomla_in_aos.php Example Example script
Accessible without login Plain text file LICENSE-GR.md Lic. License text
Accessible without login Plain text file LICENSE.md Lic. License text
Accessible without login Plain text file README-EL.md Doc. Documentation
Accessible without login Plain text file README.md Doc. Documentation

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
Downloadaos-sec00080-wp_joom-2025-11-30.zip 5KB
Downloadaos-sec00080-wp_joom-2025-11-30.tar.gz 4KB
Install with ComposerInstall with Composer
Needed packages  
Class DownloadWhy it is needed Dependency
Ascoos OS Download .zip .tar.gz requires the Ascoos OS kernel Required
 Version Control Unique User Downloads  
 100%
Total:0
This week:0