Autoresize vs autowidth for multi grids

QuestionsAutoresize vs autowidth for multi grids
Glenn asked 9 years ago

Hi Abu
Autowidth on a grid that is wide it cuts off the last part of the grid that shows pages. Autoresize solves this.
Now I want to have some grids on a page that do Autoresize while others I want to use width so I can have 2 side by side.
Autoresize ignores width so all grids are on top of eachother, however autowidth allows for this.
Suggestions?

Thanks
Glenn

4 Answers
Glenn answered 9 years ago

Forgot to show an example of this.
demos/master-detail/master-multi-detail.php

For master grid add either of the two lines below.
$opt["autowidth"] = true; // no change from current view
$opt["autoresize"] = true; // will not allow grids to be side by side

Abu Ghufran answered 9 years ago

Ok, i'll reply back after regenerating it.

Abu Ghufran answered 9 years ago

To work with multiple grids and autoresize, a fix will be required.
Edit lib/inc/jqgrid_dist.php and update line 10-11 from code: http://pastebin.com/1gX9KeCb

To limit autowidth, you can make a container div with width:80% or so, and place grid inside that div.
e.g. <div style="width:80%"><?php echo $out?></div>

Glenn answered 9 years ago

That fixed it.
Thanks Abu!

Your Answer

8 + 4 =

Login with your Social Id:

OR, enter

Attach code here and paste link in question.
Attach screenshot here and paste link in question.



How useful was this discussion?

Click on a star to rate it!

Average rating 0 / 5. Vote count: 0

No votes so far! Be the first to rate it.

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?