How to deploy fuelphp website to server - apache

I'm new to fuelPHP, I developed a simple application and when I uploaded the files to my web server I got those errors :
Notice: Use of undefined constant __DIR__ - assumed '__DIR__' in /home1/tdfdf/public_html/site/site/public/index.php on line 22
Fatal error: require() [function.require]: Failed opening required '/bootstrap.php' (include_path='.:/usr/lib64/php:/usr/lib/php:/usr/share/pear') in /home1/tdfdf/public_html/site/site/public/index.php on line 44
I probably miss some configurations here. I also want to remove this "/public" from the url
Can any one help ?

I found the solution. The DIR is not defined for older versions of PHP . I changed my server settings to run on PHP 5.3 and it worked like magic.
Thanks.

Related

how to install Imagic in WAMP server?

I am getting error php_imagick.dll is not working. %1 is not a valid W32 application.
I am using WAMP Server Apaches 2.4.4.6 and PHP 7.4.9. my OS is windows 10 64bit. i think i download php_imagick-3.6.0rc2-7.3-nts-vc15-x64.zip file.
I have installed all DDL file in PHP7.4.9/ext/ and apply all process for install Imagic but still i am getting error
i have add extension in php.ini file.
enter image description here
Warning: PHP Startup: Unable to load dynamic library 'php_imagick' (tried: d:/wamp/bin/php/php7.4.9/ext/php_imagick (%1 is not a valid Win32 application.), d:/wamp/bin/php/php7.4.9/ext/php_php_imagick.dll (The specified module could not be found.)) in Unknown on line 0
i tried to find required file and package form
https://windows.php.net/downloads/pecl/releases/imagick/3.6.0rc2/ also checked
https://www.apachelounge.com/viewtopic.php?t=6359
but nothing helpful for me. that Module is not loading..
please help me....
check that the dll is not blocked:
try downloading the imagick threadsafe for here, version made for your PHP version
also install it from here on top of it all

How do I solve fusionauth php client error 'FusionAuthClient' not found?

when I follow https://github.com/FusionAuth/fusionauth-php-client
I can see error:
PHP Fatal error: Uncaught Error: Class 'FusionAuthClient' not found ... on line 6
My application looks like this:
First application
<?php
require_once 'FusionAuthClient.php';
$apiKey = "7W-yBfeXfniDhu8PR_h0dGkSsPDJlpUYuP9rP2xXd_4";
$client = new FusionAuthClient($apiKey, "http://localhost:9011");
line 6 is last.
composer says all is right
$ composer require fusionauth/fusionauth-client
Using version ^1.6 for fusionauth/fusionauth-client
./composer.json has been created
Loading composer repositories with package information
Updating dependencies (including require-dev)
- Installing fusionauth/fusionauth-client (1.6.1)
Downloading: 100%
Writing lock file
Generating autoload files
FusionAuthClient.php, ClientResponse.php and RESTClient.php are in the same directory as my test script.
Can you point me into the right direction what is cause of this problem?
Have you looked at the first line of the FusionAuthClient.php file? apparently not.
namespace FusionAuth;
Therefore, the class is not in the global namespace, therefore you need to tell php which namespace it's in:
$client = new FusionAuth\FusionAuthClient($apiKey, "http://localhost:9011");
You're welcome.
That looks the require_once function path is invalid
Do have you same bug when using "require" and not "require_once"?

yii creating webapp error

Hi i am trying to create a yii application and i am got this issue tried google but not able to find the solution how can i resolve this,..?
This is my error:
Error: Unsupported VCS specified. Currently only git and hg supported.
And what actually this error is..?
yiic webapp d:\xampp\htdocs should work.
Notice the backslashes.
Or, perhaps better, since the app generator supports relative paths, navigate to d:\xampp and simply run yiic webapp htdocs.
That said: why are you using Yii 1 ?
It is really old, and does not receive any updates.
Yii 2 is so much better :)

Yii 2.0 showing Warning: Module 'mysql' already loaded in Unknown on line 0

I am new to yii 2.0. I installed my first Yii2.o application on my server and configred URL to use user friendly urls. However, I am getting
Warning: Module 'mysql' already loaded in Unknown on line 0
message when I go to the web/about/ URL. I tried to remove the base rout using "defaultRoute" in web.php but that is also not possible.
Please help me to figure out this issue.
That has nothing to do with Yii 2.0. It's a PHP misconfiguration.
Probably, you've enabled mysql extension twice. Search in your php.ini and extensions ini files:
extension=mysql.so
or
extension=mysql.dll
I had the same problem and i fix it by deleting this line in my php.ini:
extension=mysql.so
located in: /etc/php5/apache2/ and restarting apache2 service:
sudo service apache2 restart

Installation failure of Impresspages on Two Servers

I have tried installing Impresspages on my local xampp server, and was successful, but have JS errors and am unable to edit any content on front end. I get the below error in my inspector.
Uncaught TypeError: Cannot read property 'mouse' of undefined localhost/Ip/Internal/Content/assets/management.min.js?1:71
Does anyone know what is causing this?
I then tried to install it on my Cloudserver which runs WHM/Cpanel. I was not able to install at all.. I get the below error:
[03-Jul-2014 19:25:50 UTC] PHP Warning: PHP Startup: Unable to load dynamic library '/usr/local/lib/php/extensions/no-debug-non-zts-20100525/php_openssl.dll' - /usr/local/lib/php/extensions/no-debug-non-zts-20100525/php_openssl.dll: cannot open shared object file: No such file or directory in Unknown on line 0
What is causing this? How can I fix?
Thanks in advance!!
Michael
http://www.digitalworkhorse.com/
First issue shouldn't make any problems with content management. Refresh page, clear browser cache. Content management should work.
The second has nothing to do with ImpressPages. It's your servers problem with PHP installation.