• 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

How do I refresh a DIV content?

Sentry + Laravel: how to log an already catched Exception?

How to display MySQL table using php and edit it in a web browser

Shopify password update using Shopify API

Component install error: JInstaller: :Install: File does not exist

dompdf and img tag, image wont show

Redirect to previous page with php

Uncaught TypeError: Cannot read property 'length' of null when retrieving tags from wp

Issue saving card for customer

PHP: Print caught exception like Xdebug

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

google content api for shopping

How to run or debug php on Visual Studio Code (VSCode)

Custom Button next to “ADD TO CART” button of WooCommerce based on Product Type

The difference when using if statement true === something() vs something() === true [duplicate]

About Contact Privacy policy Terms and conditions