use an array from 1 class in a second class


Posted on 16th Feb 2014 07:03 pm by admin

I have a class that adds data to an array

Then I have a second class and I need to check if the data it returns is in the array created in the first class.
But I get undefined variable: Array name

Basically the array is empty outside of the first class.

Is it possible to use that array between classes?

187 Like 49 Dislike
Previous php-forum Next php-forum
Other php-forum

MVC - Code review
I'm in the process of trying to wrap my head around MVC, and as part of that, I'm attempting to impl

Executing an exe
Hi. I have some bizarre problem with exec (other any other method) to launch exe's. I am making a ga

PHP - MySQL Fail
My PHP code will only execute the first part of my code...

Code: <?php

sessio

generate seo frienly url from a text like wordpress
Convert: "åäö" to "aao", "space" to "-", "!?&q

Display certain image depending on time of year
Hi, I am new to these forums and would really appreciate some advice on a piece of coding I have don

Help with captcha script needed
Hello,

I am working on a script where reCAPTCHA or a similar form of CAPTCHA will be used, f

calendar dates and hours compare problem
i have a calendar in wordpress, everything works great except that i can make 2 meetings at the same

Set Categories
I am creating a submission form for somebody to come in and submit products. These products are sep

Problem writing URL into database
How would I write this into the database?

<?php echo "http://".$_SERVER['SER

Mail Script Problems
I have created a PHP mail script. I am having a problem though. In $body i am trying to put two va

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash