Jump to content

Search the Community

Showing results for tags 'php7'.

More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • The latest WHMCS Release
  • WHMCS Beta Program
    • WHMCS Mobile App Technical Preview Feedback
  • The Latest from the WHMCS Team
    • News, Announcements & Blogs from WHMCS
  • WHMCS.Community
    • Community Announcements
    • Introduce Yourself
  • Using WHMCS
    • Pre-Sales Questions
    • Admin & Configuration Questions
    • Installation, Upgrade, and Import Support
    • Using WHMCS
    • Troubleshooting Issues
    • Vendor Discussions
  • WHMCS Showcase
    • Showcase Your Site
    • Share Your Best Practices & Tips
  • Developing & Extending WHMCS
    • Third Party Add-ons
    • Service Offers & Requests
    • Developer Corner
    • Building Modules
    • Share Ideas for WHMCS Modules
  • Community Competitions
    • Competitions
  • General Discussions
    • General Discussion
  • General Feedback & Assistance
    • Feedback
    • WHMCS.Community Tips & Tricks
  • Third Party Developers's Topics
  • Turkish International Discussions's Topics
  • Russian International Discussions's Topics
  • Spanish International Discussions's Topics
  • Portuguese International Discussions's Topics
  • French International Discussions's Topics
  • Italian International Discussions's Topics
  • German International Discussions's Topics
  • WHMCS Brasil's Topics
  • WHMCS Brasil's Tópicos
  • ModulesGarden Club's Topics
  • Hungarian International Discussions's Segítség
  • ThemeMetro Club's Topics
  • WHMCS Services Club's Topics
  • SwiftModders Club's Topics
  • WHMCS Global Services Club's Topics
  • Zomex Club's Topics

WHMCS Version

  • V7.10.x Hotfixes
  • V7.9.x Hotfixes
  • V7.8.x Hotfixes

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start



About Me

Found 3 results

  1. I've been trying this for a couple days and stuck. I am trying to add a custom function in WHMCS, by creating a file `addstripecard.php`, the idea is based on a given customer token (something like `cus_1GPkTFJEegxX3y3c123456`) and then try to attach it to a card. The custom function is accessed from an API. First, I'm trying to access the Stripe library, by using these commands : ``` $gateway = new \WHMCS\Module\Gateway(); $gateway->load("stripe") ``` PS: the codes were taken from `https://github.com/WHMCSCare/WHMCS-7.8.0-decoded/blob/e7446479de49a28c8801d4c0c95f4cae22dcff33/modules/gateways/stripe/lib/StripeController.php` But, after running the above commands, I got this error message : ``` FastCGI sent in stderr: "PHP message: [WHMCS Application] ERROR: TypeError: Argument 2 passed to WHMCS\Api\ApplicationSupport\Http\ResponseFactory::factory() must be of the type array, string given, called in /www/xxxxxx.xxx/billing/vendor/whmcs/whmcs-foundation/lib/Api/ApplicationSupport/Route/Middleware/HandleProcessor.php on line 0 and defined in /www/xxxxxx.xxx/billing/vendor/whmcs/whmcs-foundation/lib/Api/ApplicationSupport/Http/ResponseFactory.php:0 Stack trace: #0 /www/xxxxxx.xxx/billing/vendor/whmcs/whmcs-foundation/lib/Api/ApplicationSupport/Route/Middleware/HandleProcessor.php(0): WHMCS\Api\ApplicationSupport\Http\ResponseFactory::factory(Object(WHMCS\Api\ApplicationSupport\Http\ServerRequest), '{"legacyGateway...') #1 /www/xxxxxx.xxx/billing/vendor/whmcs/whmcs-foundation/lib/Route/Middleware/Strategy/DelegatingMiddlewareTrait.php(0): WHMCS\Api\ApplicationSupport\Route\Middleware\HandleProcessor->_process(Object(WHMCS\Api\ApplicationSupport\Http\ServerRequest), Object(Middlewares\Utils\Delegate)) #2 /www/dat" while reading response header from upstream, client:, server: xxxxxx.xxx, request: "POST /billing/includes/api.php HTTP/1.1", upstream: "fastcgi://unix:/run/php/php7.0-fpm.sock:", host: "xxxxxx.xxx.net" ``` Full codes: ``` <?php if (!defined("WHMCS")) { die("This file cannot be access directly!"); } function addStripeCard() { // card parameters $cardNumber = $_POST['cardnumber']; $cardExpiryDate = $_POST['cardexpirydate']; $remoteToken = $_POST['remotetoken']; $billingContactId = $_POST['billingcontactid']; $description = $_POST['description']; $cardType = $_POST['cardtype']; $cardStartDate = $_POST['cardstartdate']; $cardIssueNumber = $_POST['cardissuenumber']; $clientId = $_POST['clientid']; try { $gateway = new \WHMCS\Module\Gateway(); $gateway->load("stripe") return json_encode($gateway); } catch (Exception $e) { $error = [ 'result' => 'error', 'message' => $e->getMessage(), 'file' => $e->getFile(), 'line' => $e->getLine(), ]; return $error; } } try { $data = addStripeCard(); $apiresults = $data; } catch (Exception $e) { $error = [ 'result' => 'error', 'message' => $e->getMessage(), 'file' => $e->getFile(), 'line' => $e->getLine(), ]; $apiresults = $error; } ``` Does anyone have a clue on what's going on? I've tried googling many times, but couldn't find any answers.
  2. Getting error 500 when trying to access todo lists. Seems to be happening after the update to 7.5.1. ./admin/todolist.php was encoded by the ionCube Encoder for PHP 5.6 and cannot run under PHP 7.1 or later." Host: CentOS6.9 nginx + FPM php 7.1.16 + ionCube Loader 10.1.0 The original installation 7.2.x was running on php5.6.35 + iCL6.0.7, and I think this is where the issue is coming from. Is it possible ./admin/todolist.php wasn't updated with 7.5.1?
  3. Hello We are running shortly our WHMCS installation 7.2.3 with Nginx, php-fpm 7.0 and almost all is running well. but we had a problem with the knowledgebase which was not reachable anymore over https://whmcsurl/knowledgebase after installing some nginx rules like here posted we can again open the knowledgebase like https://whmcsurl/knowledgebase. but now the search is not working ( 404 not found). the question is now if someone has working nginx rules or can help with the problem? # Announcements rewrite ^/announcements/([0-9]+)/[a-zA-Z0-9-]+.html$ /./announcements.php?id=$1 last; rewrite ^/announcements$ /./announcements.php last; # Downloads rewrite ^/downloads/([0-9]+)/([^/]*)$ /./downloads.php?action=displaycat&catid=$1 last; rewrite ^/downloads$ /./downloads.php last; # Knowledgebase rewrite ^/knowledgebase/([0-9]+)/[a-zA-Z0-9-]+.html$ /./knowledgebase.php?action=displayarticle&id=$1 last; rewrite ^/knowledgebase/([0-9]+)/([^/]*)$ /./knowledgebase.php?action=displaycat&catid=$1 last; rewrite ^/knowledgebase$ /./knowledgebase.php last; best regards chris
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated