Skip to content

Commit

Permalink
Merge pull request #23 from mambax7/master
Browse files Browse the repository at this point in the history
2.1.0 Beta 2
  • Loading branch information
mambax7 authored Apr 20, 2023
2 parents ac9a191 + 5cd4aa3 commit e11ae02
Show file tree
Hide file tree
Showing 229 changed files with 2,865 additions and 10,734 deletions.
10 changes: 6 additions & 4 deletions .scrutinizer.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# language: php
build:
environment:
php: 8.0.11
nodes:
tests: true
analysis:
Expand All @@ -14,9 +16,9 @@ build:
override: true
tests:
override:
- php-scrutinizer-run --enable-security-analysis
- php-scrutinizer-run --enable-security-analysis
filter:
dependency_paths:
- XoopsCore25/*
- tag/*
- newbb/*
- XoopsCore25/*
- tag/*
- newbb/*
8 changes: 4 additions & 4 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
![alt XOOPS CMS](https://xoops.org/images/logoXoops4GithubRepository.png)
![alt XOOPS CMS](https://xoops.org/images/logoXoopsPhp81.png)
# Contributing to [XOOPS CMS](https://xoops.org)
[![XOOPS CMS Module](https://img.shields.io/badge/XOOPS%20CMS-Module-blue.svg)](https://xoops.org)
[![Software License](https://img.shields.io/badge/license-GPL-brightgreen.svg?style=flat)](https://www.gnu.org/licenses/gpl-2.0.html)

Contributions are **welcome** and will be fully **credited**.

We accept contributions via Pull Requests on [Github](https://github.com/XoopsModules25x/xoopspoll).
We accept contributions via Pull Requests on [GitHub](https://github.com/XoopsModules25x/xoopspoll).

## Pull Requests

- **[PSR-2 Coding Standard](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md)** - The easiest way to apply the conventions is to install [PHP Code Sniffer](http://pear.php.net/package/PHP_CodeSniffer).
- **[PSR-12 Coding Standard](https://www.php-fig.org/psr/psr-12/)** - The easiest way to apply the conventions is to install [PHP Code Sniffer](http://pear.php.net/package/PHP_CodeSniffer).
- **Add tests!** - We encourage providing tests for your contributions.
- **Document any change in behavior** - Make sure the `/docs/changelog.txt` and any other relevant documentation are up-to-date.
- **Consider our release cycle** - We try to follow [Semantic Versioning v2.0.0](http://semver.org/). Randomly breaking public APIs is not an option.
- **Create feature branches** - Don't ask us to pull from your master branch.
- **One pull request per feature** - If you want to do more than one thing, send multiple pull requests.
- **Send coherent history** - Make sure each individual commit in your pull request is meaningful. If you had to make multiple intermediate commits while developing, please squash them before submitting.

**Happy coding, and _May the Source be with You_!**
Happy coding, and **_May the Source be with You_**!
5 changes: 2 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
![alt XOOPS CMS](https://xoops.org/images/logoXoops4GithubRepository.png)
![alt XOOPS CMS](https://xoops.org/images/logoXoopsPhp81.png)
## XoopsPoll module for [XOOPS CMS 2.5.9+](https://xoops.org)

[![XOOPS CMS Module](https://img.shields.io/badge/XOOPS%20CMS-Module-blue.svg)](https://xoops.org)
Expand All @@ -7,8 +7,7 @@
[![Scrutinizer Code Quality](https://img.shields.io/scrutinizer/g/mambax7/xoopspoll.svg?style=flat)](https://scrutinizer-ci.com/g/XoopsModules25x/xoopspoll/?branch=master)
[![Codacy Badge](https://api.codacy.com/project/badge/grade/85a08057185d440e9ca996303d3e3c26)](https://www.codacy.com/app/mambax7/xoopspoll_2)
[![Code Climate](https://img.shields.io/codeclimate/github/mambax7/xoopspoll.svg?style=flat)](https://codeclimate.com/github/XoopsModules25x/xoopspoll)
[![SensioLabsInsight](https://insight.sensiolabs.com/projects/62de8735-2c10-41b8-9faa-d4cfac041975/mini.png)](https://insight.sensiolabs.com/projects/62de8735-2c10-41b8-9faa-d4cfac041975)
[![Latest Pre-Resease](https://img.shields.io/github/tag/XoopsModules25x/xoopspoll.svg?style=flat)](https://github.com/XoopsModules25x/xoopspoll/tags/)
[![Latest Pre-Release](https://img.shields.io/github/tag/XoopsModules25x/xoopspoll.svg?style=flat)](https://github.com/XoopsModules25x/xoopspoll/tags/)
[![Latest Version](https://img.shields.io/github/release/XoopsModules25x/xoopspoll.svg?style=flat)](https://github.com/XoopsModules25x/xoopspoll/releases/)

**XoopsPolls** module for [XOOPS CMS](https://xoops.org) can be used to display interactive survey forms on your site. Each poll can display a question on which visitors can ‘vote’.
Expand Down
7 changes: 3 additions & 4 deletions admin/about.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?php
<?php declare(strict_types=1);
/*
You may not change or alter any portion of this comment or credits
of supporting developers from this source code or any supporting source code
Expand All @@ -13,8 +13,7 @@
* Display module 'About' page in administration interface
*
* @copyright :: {@link https://xoops.org/ XOOPS Project}
* @license :: {@link http://www.fsf.org/copyleft/gpl.html GNU public license}
* @package :: xoopspoll
* @license :: {@link https://www.gnu.org/licenses/gpl-2.0.html GNU GPL 2.0 or later}
* @subpackage:: admin
* @since :: 1.40
* @author :: Mage, Mamba
Expand All @@ -31,7 +30,7 @@

/** @var Admin $adminObject */
$adminObject->displayNavigation(basename(__FILE__));
$adminObject::setPaypal('[email protected]');
Admin::setPaypal('[email protected]');
$adminObject->displayAbout(false);

require_once __DIR__ . '/admin_footer.php';
15 changes: 4 additions & 11 deletions admin/admin_footer.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?php
<?php declare(strict_types=1);
/*
You may not change or alter any portion of this comment or credits
Expand All @@ -13,8 +13,7 @@
* XOOPS Poll module
*
* @copyright :: {@link https://xoops.org/ XOOPS Project}
* @license :: {@link http://www.fsf.org/copyleft/gpl.html GNU public license}
* @package :: xoopspoll
* @license :: {@link https://www.gnu.org/licenses/gpl-2.0.html GNU GPL 2.0 or later}
* @subpackage:: admin
* @since :: 1.32
* @author :: XOOPS Module Team
Expand All @@ -23,14 +22,8 @@
* @uses xoops_getHandler() used to load information about the module
* @uses XoopsModule::getByDirname() to load information if module info not currently present
*/
$pathIcon32 = Xmf\Module\Admin::iconUrl('', 32);
$pathIcon32 = Xmf\Module\Admin::iconUrl('', '32');

echo "<div class='adminfooter'>\n"
. " <div style='text-align: center;'>\n"
. " <a href='https://xoops.org' rel='external'><img src='{$pathIcon32}/xoopsmicrobutton.gif' alt='XOOPS' title='XOOPS'></a>\n"
. " </div>\n"
. ' ' . _AM_MODULEADMIN_ADMIN_FOOTER . "\n"
. '</div>';
echo "<div class='adminfooter'>\n" . " <div style='text-align: center;'>\n" . " <a href='https://xoops.org' rel='external'><img src='$pathIcon32/xoopsmicrobutton.gif' alt='XOOPS' title='XOOPS'></a>\n" . " </div>\n" . ' ' . _AM_MODULEADMIN_ADMIN_FOOTER . "\n" . '</div>';

xoops_cp_footer();

19 changes: 9 additions & 10 deletions admin/admin_header.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?php
<?php declare(strict_types=1);
/*
You may not change or alter any portion of this comment or credits
of supporting developers from this source code or any supporting source code
Expand All @@ -12,8 +12,7 @@
* XOOPS Poll module
*
* @copyright :: {@link https://xoops.org/ XOOPS Project}
* @license :: {@link http://www.fsf.org/copyleft/gpl.html GNU public license}
* @package :: xoopspoll
* @license :: {@link https://www.gnu.org/licenses/gpl-2.0.html GNU GPL 2.0 or later}
* @subpackage:: admin
* @since :: 1.32
* @author :: XOOPS Module Team
Expand All @@ -35,28 +34,28 @@
Helper
};

include dirname(__DIR__) . '/preloads/autoloader.php';
include \dirname(__DIR__) . '/preloads/autoloader.php';

require_once dirname(__DIR__, 3) . '/include/cp_header.php';
require dirname(__DIR__) . '/include/common.php';
require \dirname(__DIR__, 3) . '/include/cp_header.php';
require \dirname(__DIR__) . '/include/common.php';

$moduleDirName = basename(dirname(__DIR__));
$moduleDirName = \basename(\dirname(__DIR__));

/** @var Helper $helper */
$helper = Helper::getInstance();

/** @var Admin $adminObject */
$adminObject = Admin::getInstance();

$pathIcon16 = \Xmf\Module\Admin::iconUrl('', 16);
$pathIcon32 = \Xmf\Module\Admin::iconUrl('', 32);
$pathIcon16 = \Xmf\Module\Admin::iconUrl('', '16');
$pathIcon32 = \Xmf\Module\Admin::iconUrl('', '32');
$pathModIcon32 = $helper->getModule()->getInfo('modicons32');

// Load language files
$helper->loadLanguage('admin');
$helper->loadLanguage('modinfo');
$helper->loadLanguage('main');
$helper->loadLanguage('common');
$helper->loadLanguage('blocksadmin');

$myts = \MyTextSanitizer::getInstance();

Expand Down
129 changes: 0 additions & 129 deletions admin/blockform.php

This file was deleted.

Loading

0 comments on commit e11ae02

Please sign in to comment.