• Categories
    • PHP
    • phpMyAdmin
    • PHPMailer
    • FFMpeg
    • PHPEXcel
    • PHPDoc
    • PHPUnit
    • CakePHP
    • CakePHP 2.0
    • Cake PHP 2.1
    • CakePHP Model
    • Facebook PHP SDK
    • composer-php
    • PHP 7
    • PHP GD
    All Categories
  • About

How to use functions that are declared in snippets in Evolution CMS (Modx) in an external PHP Script?

phpmodxevolution-cms


PHP Snippet 1:

// Modx init
require_once 'config.core.php';
require_once MODX_CORE_PATH.'model/modx/modx.class.php';
$modx = new modX();
$modx->initialize('mgr');

// Run snippet
$modx->runSnippet('functions_main');

// Run your functions here

Related Snippets

PHP header location absolute URL

shell errors running php exec

how to see if database exists with PDO [duplicate]

Any AWS EB Laravel route getting 404 Not Found nginx/1.16.1

How to create a video stream from a single dynamic image in PHP

Why do I have invalid argument supply for foreach in Laravel for json response? [duplicate]

How to remove from a multidimensional array all duplicate elements including the original?

Webscraping Symfony/Panther: Can't get HTML

Pagekite error: FAIL: localhost:8080 is down

How to fix bootstrap multiselect search data using ajax

PHP function Not Working As Expected From functions.php Include File

Unable to Edit config.inc.php

Adding one microsecond to Datetime object in PHP

Laravel Passport - Not able to get token string in response?

mysql slow on updates for a well optimized query

About Contact Privacy policy Terms and conditions