Multiple includes losing variables


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

Hey all,

just starting out w php and ran into a problem pretty quickly. I'm
including several files into each page. The variables in the first include file are functional in the main page, but are undefined in subsequent include files.
Did you know?Explore Trending and Topic pages for more stories like this.

I've tried using define() to make them global variables but still have had no luck.

Any help would be greatly appreciated!
No comments posted yet

Your Answer:

Login to answer
196 Like 20 Dislike
Previous forums Next forums
Other forums

Need help with basic sql
Hi,

I am using oracle 10g, and having some small doubts related to sql , here goes the si

removing space from the end of a variable
i have a variable $image which contains the following url "http://tiles.xbox.com/tiles/oo/P5/0m

what does this mean? +=
is anyone able to explain what this code is saying?

i had it written for me awhile back and n

need help modifying script
Hi guys,

I'm fairly new to php and am having a bit of trouble modifying a script.

This

mail()
Hi all. I have a problem with emails. I am trying to set up a mail system where customers can subscr

frames get header location..
i have two frames, one top, one bottom. how do i do a form on the bottom frame that gives me the ur

help removing unwanted graphic
How do I remove the small elongated rectangular shape between the "Latest post" and "

preg_match logical error
Code: <?php
$s = file_get_contents("page.html");
preg_match('/<div cla

Alternate messaging
I have 4 strings in MySQL db1

$string1 : Hello
$string2 : Hi
$string3 : Great
$strin

Wierd if else problem
Hi guys,

this probably aint wierd for you, but it seems like php is playin up to me. may b i

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