PHPackages                             iu-webtech/wcms-generic-tool - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. iu-webtech/wcms-generic-tool

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

iu-webtech/wcms-generic-tool
============================

A generic tool to operation assets in WCMS

0178[4 issues](https://github.com/zhuqiwen/hannonhill-cascade-webservice-generic-tool/issues)PHP

Since Oct 29Pushed 1mo ago1 watchersCompare

[ Source](https://github.com/zhuqiwen/hannonhill-cascade-webservice-generic-tool)[ Packagist](https://packagist.org/packages/iu-webtech/wcms-generic-tool)[ RSS](/packages/iu-webtech-wcms-generic-tool/feed)WikiDiscussions main Synced today

READMEChangelogDependenciesVersions (2)Used By (0)

Generic WCMS WebService Tool
============================

[](#generic-wcms-webservice-tool)

This tool simplifies user's work on using WCMS WebService to manipulate assets.

Asset types supported
---------------------

[](#asset-types-supported)

Before operating any asset, a WCMS SOAP client should initiated with url to WSDL, site name, and api key:

```
$wcms = new WCMSClient($wsdl, $sitename);
$wcms->setAuthByKey($apikey);
```

### Block: Data Definition

[](#block-data-definition)

#### Read

[](#read)

```
$pathToBlock = "/Settings";
$block = new BlockXHTML($wcms, $pathToBlock);
var_dump($block->oldAsset);
```

#### Update

[](#update)

#### Create

[](#create)

```
$assetPayload = [];
//required
$assetPayload['structuredData'] = [
    'definitionPath' => 'path-to-data-definition',
    // OR
    //'definitionId' => 'data definition id'
];
//OR required
//$assetPayload['xhtml'] = '';
//required
$assetPayload['parentFolderPath'] = "path-to-parent-folder";
//OR required
//$assetPayload['parentFolderId'] = "parent-folder-id";
$assetPayload['name'] = "asset-name";
$assetPayload = (object) $assetPayload;
$block = new BlockXHTML($wcms);
$block->setNewAsset($assetPayload);
$block->createAsset();
```

#### Delete

[](#delete)

### Block: Index

[](#block-index)

### Block: Feed

[](#block-feed)

### Block: Text

[](#block-text)

### File

[](#file)

### Page

[](#page)

### Folder

[](#folder)

### Content Type

[](#content-type)

### Asset Factory

[](#asset-factory)

### Data Definition

[](#data-definition)

### Format: Velocity

[](#format-velocity)

### Symlink

[](#symlink)

### Template

[](#template)

How-To
------

[](#how-to)

### When creating new asset, how to check if new asset is created or the asset already exists?

[](#when-creating-new-asset-how-to-check-if-new-asset-is-created-or-the-asset-already-exists)

By checking if $asset-&gt;oldAsset attribute is set and $asset-&gt;newAsset has a $id key set

1. if $asset-&gt;getOldAsset() returns `null`, or $asset-&gt;getNewAsset()-&gt;id is set, a new asset has been created by createAsset()
2. if $asset-&gt;getOldAsset() returns asset data or $asset-&gt;getNewAsset()-&gt;id is Not set, the asset meant to be created has already existed.

###  Health Score

25

—

LowBetter than 35% of packages

Maintenance58

Moderate activity, may be stable

Popularity11

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity19

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/66307533c75b16d8f643ca832c6f7c01db15dab1ac7f03dcb3ef678c486c8cfa?d=identicon)[zhuqiwen](/maintainers/zhuqiwen)

---

Top Contributors

[![zhuqiweniu](https://avatars.githubusercontent.com/u/48067881?v=4)](https://github.com/zhuqiweniu "zhuqiweniu (187 commits)")

### Embed Badge

![Health badge](/badges/iu-webtech-wcms-generic-tool/health.svg)

```
[![Health](https://phpackages.com/badges/iu-webtech-wcms-generic-tool/health.svg)](https://phpackages.com/packages/iu-webtech-wcms-generic-tool)
```

###  Alternatives

[jalle19/php-whitelist-check

Provides a simple way to check whether an address or domain is on a whitelist

45796.8k4](/packages/jalle19-php-whitelist-check)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
