FAQ Database Discussion Community


ZF 2 - Fatal Error: Call to a member function getPosts() on null

php,zend-framework2,fatal-error,member-function
I am creating a website using Zend Framework 2, and I'm using as an example the exercise from the official course of Zend Technology, Zend Framework 2: Fundamentals. I have a table called posts and I want to show the table content in my home page, ordered by id. These...

fatal error using android shared preferance

android,android-activity,android-studio,nullpointerexception,fatal-error
I am working on my first android project and I am using android studio. The project was running fine on my test device and then I chose to clean project and now the app won't run, the exception that is thrown is: Unable to instantiate activity ComponentInfo{com.lonerganonline.league_of_ireland/com.lonerganonline.league_of_ireland.MainActivity}: java.lang.NullPointerException as i...

Unity3d. Cannot allocate memory importing package

osx,unity3d,fatal-error,allocation
When I try to import my project (exported from windows)in my mac, it shows a fatal error that says: cannot allocate memory. It cannot be my computer since it has 32 gb RAM and the package is only 1.44 gb size. When I import the project in the pc with...

Fatal Error While Starting Application (E/AndroidRuntime(4881): FATAL EXCEPTION: main)

java,android,eclipse,main,fatal-error
I am new to ubuntu, i use ubuntu 14:04. android application is able to run on Windows before, I do not know why the ubuntu applications, these applications can not run. regards this is my mainactivity.java package com.iv.daging; import com.special.ResideMenu.ResideMenu; import com.special.ResideMenu.ResideMenuItem; import android.support.v4.app.Fragment; import android.support.v4.app.FragmentActivity; import android.support.v4.app.FragmentTransaction; import android.view.MotionEvent;...

Fatal Python error: (pygame parachute) Bus Error

python,fatal-error,psychopy
Here is my code: from psychopy import visual, event, gui, data, core import random, os from random import shuffle from PIL import Image import glob a = glob.glob("DDtest/targetimagelist1/*") b = glob.glob("DDtest/distractorimagelist1/*") c = glob.glob("DDtest/targetimagelist2/*") d = glob.glob("DDtest/distractorimagelist3/*") e = glob.glob("DDtest/targetimagelist4/*") shuffle(c) shuffle(d) ac = a + c bd = b...

Call to undefined function ecrypt()

function,codeigniter,undefined,fatal-error
ERROR:Fatal error: Call to undefined function ecrypt() code all works fine without the ecrypt function call in the anchor. I want to secure it from code injection. why am i getting the above error? view: <?php echo anchor("resetPasswordController/delete_news/".ecrypt($content1['id']), '<i class="fa fa-trash-o fa-fw"></i>Delete','id="actions"', array ('onClick' => "return confirm('Are you sure you...

Jenkins - Xvfb Plugin - Start socket error

jenkins,jenkins-plugins,fatal-error,socketexception,xvfb
Everything was working good until today, but now I'm seeing an error while my Jenkins (1.585) job, which is running/using Xvfb plugin, it's giving me the following error. Any idea, why it's coming. I tried many times. 15:00:07 Xvfb starting$ Xvfb :10 -screen 0 1024x768x24 -fbdir /production/home/koba/JSlaves/loki10_1/xvfb-2015-02-09_14-59-58-7153097250048722116.fbdir 15:00:07 _XSERVTransSocketINETCreateListener: ...SocketCreateListener()...

Issues with Dates

php,date,fatal-error
I have a need to get the range for Mon-Sun for each week, beginning from current. This is what I came up with: $range = 0; $weekNumber = date("W", strtotime(date('l j F Y') . ' ' . ($range) . ' days')); $weekYear = date("Y", strtotime(date('l j F Y') . '...

Fatal error: Class 'PayPal\Api\Payer' not found codeigniter

codeigniter,paypal,fatal-error,paypal-sdk
I uploaded the paypal php sdk to my codeigniter app inside the libraries/paypal folder. In the same folder I create a paypal.php file and inside it I insert this code: <?php require __DIR__ . '/common.php'; use PayPal\Api\Amount; use PayPal\Api\Details; use PayPal\Api\Item; use PayPal\Api\ItemList; use PayPal\Api\Payer; use PayPal\Api\Payment; use PayPal\Api\RedirectUrls; use...

PHP Error - Object of class could not be converted to String

php,fatal-error
I'm getting an error while coding an articles system. I want to echo the latest article. If there's an easier way to do this, please let me know. Here's the error: Catchable fatal error: Object of class mysqli_result could not be converted to string in /public_html/cms/articles.php on line 5 And...

Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 65488 bytes) In Magento 1.9.1

magento,fatal-error
I have change my unsecure base url from {{base_url}} to {{unsecure_base_url}}. After this I am getting this error "Fatal error:Allowed memory size of 268435456 bytes exhausted (tried to allocate 65488 bytes)". I have tried ti change set ini_set('memory_limit', '512M'). Now it show the error "Fatal error:Allowed memory size of 536870912...

Mac OSX: build opencv_contrib fatal error: file not found opencv2/core.hpp

c++,osx,opencv,cmake,fatal-error
I've been trying to set up opencv_contrib (https://github.com/Itseez/opencv_contrib) on my Mac, but can't get past this problem. Below I've copied the steps I've taken and the current error output. Steps: 1 - Download opencv 2.4.10 and opencv_contrib. Unzip both into a new empty directory. File structure is newfolder/opencv-2.4.10, newfolder/opencv_contrib 2...

poet.books throw fatal error: NSArray element failed to match

ios,swift,ios8,plist,fatal-error
please help, this error broke my app. I have two classes: First Class-Poets class Poets { var poetName:String = "" var poetYearsOfLife:String = "" var poetImage:String = "" var poetBiography:String = "" var books=[Works]() } Second class Work class Works { var nameWork:String = "" var workPoet:String = "" }...

PHP Fatal Error: Using $this when not in object context… Used for redirect()

php,function,class,fatal-error
I am new to PHP. I've been trying to get this authorization code to work, but am getting this error: Call to undefined function redirect() Code: $Auth = Auth::getAuth(); if($Auth->loggedIn()) { redirect(getCoreSitePath().'/account.'.SITE_CONFIG_PAGE_EXTENSION); } if(isset($_REQUEST['error_description'])) { $error = $_REQUEST['error_description']; } redirect(getCoreSitePath()."/login.".SITE_CONFIG_PAGE_EXTENSION."?social_login_error=".urlencode($error)); Based on some Googling, I saw that I might need...

Keep getting a fatal error that says “unexpectedly found nil while unwrapping an Optional value” in iOS

ios,xcode,swift,fatal-error
I run my code on Xcode and it build fine but when I tap a button to change views it crashes with this error. var selectedAccount : ACAccount! var tweets : NSMutableArray? var imageCache : NSCache? var queue : NSOperationQueue? override func viewDidLoad() { super.viewDidLoad() self.navigationItem.title = selectedAccount.accountDescription queue =...

call to member function prepare error

php,sqlite,pdo,fatal-error
I am having an issue executing the below code. I get an error: Fatal error: Call to a member function prepare() on null in C:\xampp\htdocs... everytime I run it. It errors out right when it is about to query the database for some reason. I am creating a function to...

Fatal error catched by register_shutdown_function and update json_encode

php,json,fatal-error
I can catch a fatal error with register_shutdown_function('shutdown') function shutdown(){ $error = error_get_last(); $result['message'] = $error['message']; } and I have an echo json_encode($result); Unfortunately this echo json_encode shows nothing because json is not updated with the message of the fatal error. What can I do to fix this?...

How to make server recognize global filenames

php,.htaccess,cpanel,fatal-error
Let's say the file and folder structure is as below: public_html/interface/index.php public_html/includes/EliteScript.php public_html/interface/site/template.php In 1st one, I should be able to put this require_once("includes/EliteScript.php"); and it must look for includes/EliteScript.php in the server, without forcing me to changing it to ../includes/EliteScript.php in public_html/interface/index.php In 3rd one, I should be able...

Xvfb Jenkins plugin: Unrecognized option: -displayfd

selenium,plugins,jenkins,fatal-error,xvfb
Jenkins version: 1.573 Jenkins Xvfb Plugin version: 1.0.15 (latest) Linux OS: Red Hat Enterprise Linux Server release 5.9 (Tikanga) Xorg -version X Window System Version 7.1.1 Release Date: 12 May 2006 X Protocol Version 11, Revision 0, Release 7.1.1 Build Operating System: Linux 2.6.18-308.13.1.el5 x86_64 Red Hat, Inc. Current Operating...

fatal error: unexpectedly found nil while unwrapping an Optional value in swift(SKProduct)

xcode,swift,error-handling,fatal-error,skproduct
import UIKit import SpriteKit import StoreKit extension SKProduct { func localizedPrice() -> String { let formatter = NSNumberFormatter() formatter.numberStyle = .CurrencyStyle formatter.locale = self.priceLocale return formatter.stringFromNumber(self.price)! } } class BuyCoin: SKScene { var coin200a = SKProduct() override func didMoveToView(view: SKView) { NSLog("The price of this product is \(coin200a.localizedPrice())") } }...

Fatal error: Function name must be a string whilst it shouldn't [closed]

php,arrays,string,fatal-error
I have stumbled over the following error in PHP: "Fatal error: Function name must be a string in F:\Applications\xampp\htdocs\BTB_Sandbox\uploads.php on line 15" and I don't know what the real problem is. Here is line 15 that the error is pointing at: $error = $_FILES(['file_upload']['error']); I hope you could help me,...

Using $this when not in object context php

php,oop,inheritance,fatal-error
I just started learning OOPS in php. I wrote a simple program for implementing inheritance. I am getting a fatal error of $this when not in object context. Can anyone explain me this error, what does it mean? here is my code: <?php class human{ public $gender; public function _construct($gender)...

Extend Laravel 5 Response Facade

php,laravel,fatal-error,facade
I am getting a namespacing issue when trying to extend the Response facade in Laraval 5. I have created a new folder tree under the app directory called Extensions\Facades. In this folder I have a file called AjaxResponse.php which has the following contents: <?php namespace App\Extensions\Facades; use Illuminate\Support\Facades\Response; class AjaxResponse...

git fatal error when pushing md file to Github

github,push,fatal-error
This is driving me crazy. I'm running git on mac osx 10.10.3 I keep getting "does not appear to be a git repository" message when trying to upload an MD file to github, here's what I get: git push origin master fatal: 'github.com/bbenavides/datasciencecoursera.git' does not appear to be a git...

Fatal error: Call to a member function result() on a non-object in code igniter model working fine in localhost

mysql,codeigniter,fatal-error
this my model code: function get_ads($page=0, $type, $limit=1, $order=' order by rand()') { if ($page === 0) { $page = $this->get_adpage(); $qry = "select * from tbl_ads "; $qry .= " where status=1 and pages like '%".$page. "%'"; $qry .= " and type = ".intval($type); $qry .= $order; $qry .=...

Error while retrieving data from parse.com

ios,swift,parse.com,fatal-error
Hello I want to get some data from my parse.com class called "Tags" in this class there are two 3 cols "objectID", "username" and "tagtext". I want to read a record finding by ID and afterwords I want to save "useername" and "tagtext" into two strings. I have done it...

setBackgroundResource from numeric string causes Fatal Error - Android/Java

java,android,android-drawable,fatal-error
I'm attempting to set the background of a layout from a numeric filename (it has to be numeric - this cannot be change) string (the image is 1170.png). I attempted to use the following example: Android drawables However when I do the result is the following: 06-03 08:36:47.551: E/AndroidRuntime(1765): FATAL...

FATAL EXCEPTION: main in Android intent

java,android,exception,mobile,fatal-error
There is a problem when I try to convey my object from one to another Activity. Intent intent = new Intent(this, CreateOrEditContactActivity.class); intent.putExtra("contact", currentContact); startActivity(intent); Below is a description of my class Contact: public class Contact implements Parcelable{ private int ID; private String name; private String surname; private String dob;...

How to search defined class or variable's location

php,undefined,fatal-error
These errors keep coming after changing the PHP website to new server. 1st - Solved by "shaddy" Notice: Undefined variable: es in /home/musthand/public_html/external/site/header.php on line 2 <?php if(!is_object($es)) { require_once('includes/EliteScript.php'); $es = new EliteScript(); $sMemberId = $es->getMemberId(); } // Get the base URL $sBaseUrl = $es->getConfig('baseUrl'); $sImageUrl = $es->getConfig('imageUrl'); $sMemberId...

Fatal Exception: main java.lang.RuntimeException: Unable to start activity a lot of bug

android,exception,project,fatal-error
I added scrollview in my activity_main.xml and its not working anymore. Before scrollview it did not work on Samsung s3,s4. But it worked on other phones and tablets. 02-15 05:37:35.700: D/AndroidRuntime(936): Shutting down VM 02-15 05:37:35.700: W/dalvikvm(936): threadid=1: thread exiting with uncaught exception (group=0xb2a78ba8) 02-15 05:37:35.780: E/AndroidRuntime(936): FATAL EXCEPTION: main...

Symfony2 unit tests produces Fatal Error: Declaration of ContainerAwareEventManager::removeEventListener() must be compatible with

unit-testing,symfony2,controller,phpunit,fatal-error
When calling phpunit on a very simple standard test, it produces the following output and error: Command (in symfony2 root): phpunit -c build/ src Output: PHPUnit 4.1.6-6-g43914fa by Sebastian Bergmann. Configuration read from /srv/xxxxxxxxx/build/phpunit.xml PHP Fatal error: Declaration of Symfony\Bridge\Doctrine\ContainerAwareEventManager::removeEventListener() must be compatible with Doctrine\Common\EventManager::removeEventListener($events, $listener = NULL) in...

Warning: require_once(includes/EliteScript.php) [function.require-once]: failed to open stream: No such file or directory in

php,fatal-error
This is a licence based script and it has a valid licence using SourceGuardian. The script was working fine on client's old server and he hired me to migrate it to the new server. After migrating, everything was working fine but not the login area, when trying to login it...

PHP Fatal error: 'Can't use function return value in write context'

php,database,email,fatal-error
Hi I was wondering if anyone could help me. I've tried looking around but I still don't understand why I am getting this error.This is the error whenever I load the page: PHP Fatal error: Can't use function return value in write context in G:\PleskVhosts\clubbit.co.uk\project\emailPassword.php on line 2 line 2...

I am setting up my sign up and login page using parse on xcode with swift but i keep getting a fatal error. Can somebody see what im doing wrong?

xcode,swift,parse.com,fatal-error
this is what i have so far: import Foundation import Parse import UIKit import Bolts class SignUpViewController: UIViewController, UITextFieldDelegate { @IBOutlet weak var statusLabel: UILabel! @IBOutlet weak var emailTextField: UITextField! @IBOutlet weak var passwordTextField: UITextField! @IBOutlet weak var createAccountButton: UIButton! override func viewDidLoad() { super.viewDidLoad() // Do any additional setup...

Fatal error: Call to a member function is_connected() on a non-object

php,codeigniter,fatal-error
I am getting this error when I try to run my script: Fatal error: Call to a member function is_connected() on a non-object in C:\xampp\htdocs\DataMigrator\ci_my_app\models\ReadData_model.php on line 7 <?php class ReadData_model extends CI_Model { public function get_table($target) { if ($target != 'sender' && $target != 'receiver') { exit('Error: Illegal parameter....

Mage_Core_Model_App' not found magento XAMPP

php,magento,e-commerce,fatal-error
I am setting up magento on my mac in XAMPP server but when I hit the url: http://localhost/magento/ I get a error message : Fatal error: Class 'Mage_Core_Model_App' not found in /Applications/XAMPP/xamppfiles/htdocs/magento/app/Mage.php on line 636 does any one know what exactly issue? thanks in advance....