Forum

November 2nd, 2014
A A A
Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

The forums are currently locked and only available for read only access
sp_Feed Topic RSS sp_TopicIcon
Problem with PHP arrays and JQGrid (dynamic columns)
11/02/2010
16:33
Avatar
biochoc
Member
Members
Forum Posts: 3
Member Since:
11/02/2010
sp_UserOfflineSmall Offline

Hi everybody, Cool

I use "JQGrid for PHP" and I'm having a big problem to rename my columns (with labels) dynamically with a loop and two personals arrays of values.

So, when I try to use personals arrays in "grid.php", labels are correctly changed but data no longer appears as if arrays usage was banned or misinterpreted… But I'm just coding simply in PHP and it seems I cannot really in this file.

I try to do something like this :

foreach ($column_name as $i => $value) {
  $grid->setColProperty("$column_name[$i]", array("label"=>"$column_label[$i]"));
}

If I try to manipulate personals arrays in the "grid.php" and with no interaction with jqgrid, the result is the same : no data !

Disturbing, isn't it ? Confused

Thanks for any help…

PS : And sorry for my vocabulary, English isn't my native language.

15/02/2010
13:40
Avatar
biochoc
Member
Members
Forum Posts: 3
Member Since:
11/02/2010
sp_UserOfflineSmall Offline

oki sorry, I wasn't on the good forum (I don't knew, "jqGrid for PHP" was an other and not free version)

http://www.trirand.net/forum/d.....8;#post653

and I have succeed to do what I wanted with "jqGrid" free javascript version and somme PHP code... Bye, Biochoc

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
62 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

OlegK: 1255

markw65: 179

kobruleht: 144

phicarre: 132

YamilBracho: 124

Renso: 118

Member Stats:

Guest Posters: 447

Members: 11373

Moderators: 2

Admins: 1

Forum Stats:

Groups: 1

Forums: 8

Topics: 10592

Posts: 31289

Newest Members:

, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.com

Moderators: tony: 7721, Rumen[Trirand]: 81

Administrators: admin: 66

Comments are closed.
Privacy Policy   Terms and Conditions   Contact Information