Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/adrianbj/processcodetester
A ProcessWire admin module to quickly test code without needing to edit templates
https://github.com/adrianbj/processcodetester
code processwire tester
Last synced: 4 days ago
JSON representation
A ProcessWire admin module to quickly test code without needing to edit templates
- Host: GitHub
- URL: https://github.com/adrianbj/processcodetester
- Owner: adrianbj
- License: gpl-2.0
- Created: 2013-10-09T00:19:38.000Z (about 11 years ago)
- Default Branch: master
- Last Pushed: 2017-07-31T20:35:51.000Z (over 7 years ago)
- Last Synced: 2024-05-02T00:35:00.937Z (7 months ago)
- Topics: code, processwire, tester
- Language: PHP
- Size: 17.6 KB
- Stars: 3
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
ProcessCodeTester
=================#### This module is obsolete - please use the [Console panel from the Tracy Debugger module](https://processwire.com/blog/posts/introducing-tracy-debugger/#console-panel)
A ProcessWire admin module to quickly test code without needing to edit templates
Ok, this is really not very fancy, but I think it will come in quite handy - for me at least :)
It provides an admin page where you can test code without the need to edit template files.
It runs from a new page under Setup called "Code Tester"
You are presented with a simple text area. Enter your code, including an opening find(selector) as $page) $out .= "
```
```
$getpage = $pages->get(selector); //This will populate the results frame with the page returned by the selector. You must use $getpage as the variable!
```
```
foreach($pages->find(selector) as $p) $p->delete(); // Bulk delete pages matching the selector
```
So really it is more than a code tester - it can also be used as a way to test selectors and return the resulting page and also as a way of running admin maintenance scripts.
### Forum
http://processwire.com/talk/topic/4689-code-tester-module/
## License
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
(See included LICENSE file for full license text.)