Jump to content

Change PHP variable with AJAX/Javascript?


capnH00K

Recommended Posts

if the dir has no id, then why in  your own code do you have

 

$dir = "uploaded/".$id."/music" that is where i based my ajax code for you off of.

 

and at work i don't have any messenger stuff.

Link to post
Share on other sites

Basicly i have 2 variables

- $dir

- $link

 

$dir has a default set - so that it 'opens' a folder (runs through it and list everything inside it - like a folder in windows)... Inside this folder, there can be other folders - so when there's a folder inside the default $dir .. i'm creating a link which should then change the default $dir to the new one - so you kinda "opens" a new dir... it just has to work as the exploded in windows... If you press a folder you open that ...

 

 

Does that make sence?

Link to post
Share on other sites

:shrug:

 

Okay, man i can't get this to work... !

 

Can you just tell me exacly what to type on the the  " // everything from here is brought back from echo in php" line. And what to type in the html/php part to make it resive the php variable...

 

function processNav() {

// everything from here is brought back from echo in php

$('mydiv').innerHTML = req.responseText;

}

 

 

Thanks :)

Link to post
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.