# Changing global variable problem

**URL:** https://forum.kirupa.com/t/changing-global-variable-problem/182351
**Category:** flash
**Created:** [March 17, 2006, 11:01am UTC](https://forum.kirupa.com/t/changing-global-variable-problem/182351 "2006-03-17T11:01:27Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![jimmy\_jazz](https://avatars.discourse-cdn.com/v4/letter/j/dfb087/32.png) [@jimmy\_jazz](https://forum.kirupa.com/u/jimmy_jazz)
#### Post date: [March 17, 2006, 11:01am UTC](https://forum.kirupa.com/t/changing-global-variable-problem/182351/1 "2006-03-17T11:01:27Z")

</div>

Hi

I’m having a problem changing the value of a global variable.

I’m using the xml photogallery thats available on Kirupa.  
I have 2 movies on the main timeline: the galley movieclip and a navigation movie clip. I want the buttons in the navigation clip to change the global varable ‘section’ and this to be passed to the galley xml load function. So far i have this for the button:

```auto

gallery1button.onRelease = function(){
	_root.nav.select(0);
	 _global.section= "gallery1";
	};

```

I am using php to deliver the xml data dynamically to flash so I only have one xml file for several galley section. the AS looks like this:

```auto

xmlData.load("photos_xml.php?section="+_global.section);

```

It doesnt seem to be working though. Any ideas?

Thanks in advance.
