I am trying to add a blog to a SilverStripe site using the Blog Module.
The package seemed to install fine (via composer require silverstripe/blog) and dev/build returned no errors. The ‘Blog’ page type is also available from the ‘Add page’ menu.
After adding a ‘Blog’ page, the site doesn’t redirect to http://localhost:8888/example/admin/pages/edit/show and simply remains on the http://localhost:8888/example/admin/pages/add/ page.
From what I can tell, the only result from this action is an ‘ARCHIVED’ page being added to the sitetree.
Have ?flush=all etc as per other suggestions to no avail and other page types are still being added fine.
Does anyone have any idea what might be going on here?
Currently using:
"silverstripe/cms": "3.6.1",
"silverstripe/framework": "3.6.1",
"phpunit/PHPUnit": "~3.7#stable"
"silverstripe/blog": "2.4.6"
[Edit 13/09/2017]
While simply adding a 'Blog' page produces no observable errors, adding a generic 'Page' and changing the page type to 'Blog' produces the following error in the php_error.log:
PHP Warning: require_once(/Applications/MAMP/htdocs/example/blog/_config.php): failed to open stream: No such file or directory in /Applications/MAMP/htdocs/example/framework/core/manifest/ConfigManifest.php on line 141
PHP Fatal error: require_once(): Failed opening required '/Applications/MAMP/htdocs/example/blog/_config.php' (include_path='/Applications/MAMP/htdocs/example/vendor/phpunit/phpunit-mock-objects:/Applications/MAMP/htdocs/example/vendor/phpunit/php-token-stream:/Applications/MAMP/htdocs/example/vendor/phpunit/php-code-coverage:/Applications/MAMP/htdocs/example/vendor/phpunit/phpunit:/Applications/MAMP/htdocs/example/vendor/symfony/yaml:.:/Applications/MAMP/htdocs/example/framework:/Applications/MAMP/htdocs/example/framework/parsers:/Applications/MAMP/htdocs/example/framework/thirdparty:.:/Applications/MAMP/bin/php/php5.6.30/lib/php') in /Applications/MAMP/htdocs/example/framework/core/manifest/ConfigManifest.php on line 141
[Edit 13/09/2017]
Trialled the module on a clean install of SilverStripe as well as another project (both using 3.6.1 CMS and 2.4.6 Blog module); both work so far without issue. Perhaps it was an issue with this particular project. Would still be great to get clarification on what the root of this issue might have been.
Related
I upgraded Magento from v 1.4.x to 1.9.2.0. All seems to work OK except the Paypal module.
If I go to System -> Configuration in Admin, or the Checkout page on the front end, I get a blank screen.
The error_log shows this error when I go to System -> Configuration:
PHP Fatal error: Call to undefined method Mage_Paypal_Helper_Data::getConfigurationCountryCode() in /home/mysite/public_html/includes/src/Mage_Paypal_Model_Observer.php on line 130, referer: http://www.mysite.co.uk/index.php/site_admin/dashboard/index/key/7ec25272dd6e12345667015d73b305/
The error_log shows this when I go to the checkout on the front end:
PHP Fatal error: Undefined class constant 'MERCHANT_COUNTRY_CONFIG_PATH' in /home/mysite/public_html/includes/src/Mage_Paypal_Model_Config.php on line 769, referer: http://www.mysite.co.uk/checkout/onepage/
All the files look to be present... specifically the Helper/Data.php file with the class Mage_Paypal_Helper_Data and getConfigurationCountryCode() method. So it seems its just not loading this helper class.
Does anyone have an idea why it would not load?
Thanks
I have solved the issue. There was a Paypal folder with same Mage_Paypal_Helper_Data class in the local/Mage folder, but without the necessary methods. This class was therefore being loaded. The class must have been left over in 1.4.x in which it somehow worked. Removing this folder results in the core/Mage/Paypal class working.
This solved my problem too, though I was getting a different error after upgrading to 1.9.2.2.
When I clicked to checkout with paypal express, it would bring up an error page:
Fatal error: Call to undefined method Mage_Paypal_Model_Express_Checkout::setIsBml() in public_html/app/code/core/Mage/Paypal/Controller/Express/Abstract.php on line 98.
After banging my head against a wall for some time, I finally checked the local/mage folder and discovered a checkout override for paypal that had been done by a previous developer 18 months ago. Makes sense that the error came up after the upgrade, as the override was for an older version of magento's paypal setup.
Delete the override, fixed done and sorted!
Cheers
I am new to the Joomla CMS I would like to say first. The server the website was being hosted on just updated their PHP the 5.4. It worked correctly for a time then the front page stopped displaying anything. I have tried almost everything that's suggested to fix the problem but nothing seems to work. From checking the error_log, exporting the website and re installing it on a new hosting service that still supports PHP 5.2, viewed the PHP errors and made small changes to the file's code that logged as syntax errors so they wouldn't occur and nothing, still blank. Starting from scratch is not on options for me because I need to keep that template intact since I was not the one that created it. If anyone out there has any suggestion it would be appreciated.
When turning on the error reporting in the configuration file I get
Beginning error messages
Strict Standards: Non-static method JLoader::import() should not be called statically in C:\xampp\htdocs\restore\libraries\loader.php on line 186
Strict Standards: Non-static method JLoader::register() should not be called statically in C:\xampp\htdocs\restore\libraries\loader.php on line 71
Strict Standards: Non-static method JFactory::getApplication() should not be called statically in C:\xampp\htdocs\restore\index.php on line 31
Strict Standards: Declaration of JSite::getPathWay() should be compatible with that of JApplication::getPathway() in C:\xampp\htdocs\restore\includes\application.php on line 377
Strict Standards: Non-static method JRegistryFormat::getInstance() should not be called statically, assuming $this from incompatible context in C:\xampp\htdocs\restore\libraries\joomla\registry\registry.php on line 373
Ending error messages
just list a few. I have tried going through and editing them with now luck.
I have found the problem. On if its modules was causing the blank page error in some way.
I was able to find this out by first making a copy of the current site using Akeeba Backup plugin.
Installed is on my localhost.
Installed a fresh version of Joomla 1.5 (with out default data)
Then edited the configuration.php file's database connection settings
/* Database Settings */
var $dbtype = 'mysql';
var $host = 'localhost';
var $user = 'root';
var $password = 'password';
var $db = 'dbname';
var $dbprefix = 'jos_';
to use the database created from the copied version of the website I installed on my localhost.
With that being done the fresh version of joomla I created had all the database information
I needed to recreate a new website with the same content.
I then started copying the components, modules, plugins, template, and modules from the copied
version to the fresh version.
Note: Some of the plugins and modules needed to be re-installed.
I would check to see if the fresh version was still functioning correctly every time I copied a directory over. Then, bam I got a blank front end page on the fresh version after I copies over a certain module.
So I found a version of the module that worked for 1.5 on the W3 and re-installed it.
Solving the mystery of my blank front end page.
It took quite a few hours to pinpoint the problem but I'm thankful for the people that responded to my question on the forums I posted it on. And I hope this can help anyone out there that comes across a mysterious blank front end page.
This issue really isn't a Joomla specific one, but PHP. To learn more about troubleshooting these issues in PHP, there is a good discussion at How to get useful error messages in PHP and What is the recommended error_reporting() setting for development? What about E_STRICT?
I can't get the Bisna doctrine cli to work. It complains about not being able to find the Symfony Console application. Notice it's trying to look for it in a nested directory of Doctrine/Symfony/Console/Symfony/Component/Console. Anybody ever seen this?
PHP Warning: require(/Users/jhicks/workspace/production/application/../library/Doctrine/Symfony/Console/Symfony/Component/Console/Application.php): failed to open stream: No such file or directory in /Users/jhicks/workspace/production/library/Doctrine/Common/ClassLoader.php on line 163
PHP Fatal error: require(): Failed opening required '/Users/jhicks/workspace/production/application/../library/Doctrine/Symfony/Console/Symfony/Component/Console/Application.php' (include_path='/Users/jhicks/workspace/production/library:.:/opt/local/lib/php') in /Users/jhicks/workspace/production/library/Doctrine/Common/ClassLoader.php on line 163
Here's the Github page for the doctrine cli from Bisna: https://github.com/guilhermeblanco/ZendFramework1-Doctrine2/blob/master/bin/doctrine.php
There are many repositories that call themsemves Bisna in Github, it is difficult to find what of them you are using without further information.
The original one is the one created by Guilherme Blanco (Bisna used to be his nickname) called Zend Framework 1 + Doctrine 2 and works like a charm, but it does not bundle the Symfony components necessary to run the CLI tool.
What you have to do is download them from GitHub (search for "Symfony" and you will find the components inside the Organization repository) and put them inside your project's library folder paying attention to the PSR #0 naming conventions.
If you provide the piece of code that generates this error and the repository and version you are using, it will be easier to detect the error and give a better answer. It is naive to try and guess the type of error, but probably you have problems with namespaces and/or how you are calling Symfony's Console component.
If you need some guidance on how this integration can be achieved, you can look at doctrine.php inside Blanco's repository.
Looks like I needed to add these two lines to my existing autoloader bootstrap method:
$symfonyAutoloader = new \Doctrine\Common\ClassLoader('Symfony', 'Doctrine');
$autoloader->pushAutoloader(array($symfonyAutoloader, 'loadClass'), 'Symfony');
I didn't think this would be necessary since I included Symfony in the autoloaderNamespaces array in my application.ini file.
autoloaderNamespaces[] = "Symfony"
I created a website using CodeIgniter Framework 2.1.0 that was originally working well. Yesterday, I integrated this i18n code into the site for multi-language support.
Now, when I upload my site to cpanel and open it, I get this error in my log file:
[21-Nov-2011 10:19:04] PHP Fatal error: Call to undefined method CI_Lang::lang() in XXXX
However, the website is working well on my localhost server (xampp for Windows). What's wrong?
See the thread attached to the library: http://web.archive.org/web/20120112092127/http://codeigniter.com/forums/viewthread/179036. In the first post is attached a modified library that claims to alleviate the buggyness of the original.
There is also a post on the first page there referencing an error similar to yours:
After copying the files as described in the article I get the
following error: Fatal error: Call to undefined method
CI_Lang::CI_Lang() in
/www/websites/audio-machinery/application/core/MY_Lang.php on line 32
Though he seems to be calling CI_Lang, not Lang. His solution appears to have been to use the code attached to the forum thread.
Also, cpanel is a control panel for hosting, not a hosting provider. But your hosting provider may be causing issues (e.g. if using older versions of PHP which do not work with newer version of CI. Often hosting providers will give you the ability to choose which version of PHP you are using--usually found in cPanel).
have you uploaded ALL the new files to your live server? that error implies that the code is not found or available to the script.
I came accross the same problem.... it was working fine on localhost but when loaded on live server it gives me undefined error... the problem appears becuase I created file with name My_Lang.php and My_Config.php as on live server it is case sensitive.... so I changed it to MY_Config.php and MY_Lang.php .... it works fine now.... Hope it will work for you too
I'm trying to implement modular extensions into a codeigniter 2 setup but am having a few problems. I followed the installation instructions on the wiki and everything was working fine. Then I started to play around a bit and try and use it. All I did was create a new module called users with the required folders and added a model class called users_m. I then tried to load this from my welcome module controller. According to the wiki this should be very straightforward. I simply added this line
$this->load->model('users/users_m');
to the constructor of my welcome controller.
Unfortunately at this point I get the white screen of death.
So I tried something else. This time I removed the load model line and added
$this->output->enable_profiler(TRUE);
This time I got the welcome page displayed and I got the profiler, but at the top of the page I got this error:
A PHP Error was encountered
Severity: Notice
Message: Undefined property: CI::$profiler
Filename: MX/Loader.php
Line Number: 145
I don't know if these two tries are related or not, but there's obviously something not right with my setup. Could someone point me in the right direction?
If you accessing the model from the controller in the same module, you can load it using just:
$this->load->model(‘user_m’);
You only have to do $this->load->model(‘module/model_name’); when your cross loading between modules.
Just to make sure, your model is located here right?
application/modules/users/models/users_m.php
As for the profiler error:
1) Have you done installation step 5 and put the Modular Extensions core files into application/core?
2) Do you have the latest version of HMVC? There have been updates to mx/loader.php in the last couple days.
Ps. great tutorial on HMVC: http://net.tutsplus.com/tutorials/php/hvmc-an-introduction-and-application/
if you have folder structure like:
application/
modules/
users/
models/
users_m.php
then use this to call modelsin you controller
$this->load->model('users/users_m','',TRUE);