By _house on
hi,
i tried implementing flexigrid ( http://webplicity.net/flexigrid/ ) for the last 2 hours but i just can't get it to work...
thinking that it may be because i am too stupid, i tried using flexigrid in a generic html file and it just worked.
any help/suggestions would be greatly appreciated :)
thanks in advance,
_house
Comments
So what have you tried?
For the plain html file which version of jQuery did you use, 1.1.* or 1.2.* ?
How did you try to use it within Drupal?
i have used 1.2.x ... within
i have used 1.2.x ...
within drupal i choose "full html" and c/p the example from flexigrid's homepage into the newly created page.
i imported the javascript files via include/common and merged the css file in my theme's css file...
//EDIT:
i already found an included jQuery file in my drupal installation.
updating/excluding/use both versions didn't do any good...
Drupal 5 uses jQuery 1.1.x
Drupal 5 uses jQuery 1.1.x so that may be a problem. Also pages in Drupal do not include jQuery.js by default, it is add in response to a call to drupall_add_js().
according to the source
according to the source code, this particular page uses jQuery, though...
as i stated previously, even updating the jQuery script did not work.
i just get regular tables...
how would you do it?
Flexigrid
Hi,
This is Paulo Marinas of Flexigrid.
Don't really have much time to test your problem through a drupal installation, but two things you can do so I can help you out, if you use Firefox with Web Developer plugin, give me a screenshot of the Javascript error, and a Generated Source through the Web Developer Plugin.
Paulo
hi, thanks a lot for
hi,
thanks a lot for offering your help, but i somehow figured it out by myself during the last 20min.
i still do not know where i made an error, but it's working now.
thanks to all for taking your time :)
regards,
_house
Definitive configuration
Hi,
Could you, please, post your definitive configuration?
Regards
motondo
sure...
sure...
_drupal_add_js('misc/flexigrid.js', 'core', 'header', FALSE, $cache);to drupal/includes/common.inc after line 1611
@import "flexigrid.css";as i said, the only problem i am now facing is that the css files conflict with each other, so this i definitely not the best solution...
We are having the same problem with CSS
I am posting for our lead dev, who is also trying to get flexigrid working. We seem to have the CSS clobbering problem too. The data column widths are out of sync with the header row widths, and there is so much CSS going on, it's hard figure it out.
Can _house, or someone suggest a possible source of the conflict we should investigate? (Hoping he made a little more progress since this post)
The firebug extenstion for
The firebug extenstion for firefox would serve you well here. Using inspect you should be able to quickly determine which css rules are be applies to the various parts of the table.
Try looking at width css
In wordpress, I had a similar problem with the widths getting out of sync. It seemed to be caused by one .css property. In particular, width: 100% on .flexigrid table causes this problem, whereas width: auto seemed to fix it.
the only problem i have now,
the only problem i have now is that the flexigrid css file conflicts with the drupal one.
if someone should have a solution for this problem, it'd be much appreciated...
//EDIT:
it seems like "example 3" isn't really working as well.
i first had to rename post.php to post.xml to get it working at all.
if i now try to go to the next page or change the number of shown rows, it won't work...
The post.php needs to
The post.php needs to generate a valid XML. what does this mean?
well besides following the proper format you need to add this headers:
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT" );
header("Last-Modified: " . gmdate( "D, d M Y H:i:s" ) . "GMT" );
header("Cache-Control: no-cache, must-revalidate" );
header("Pragma: no-cache" );
header("Content-type: text/xml");
adding the headers of content type tells javascript that post.php is an xml file, and it won't matter what extension it does have.
is this the reason why
my xml file has
<?xml version="1.0" encoding="utf-8"?>set as the header.besides from no sorting options and no paginating, everything works fine (the css doesn't work too well, but this is just cosmetical).
if i am adding your header to my file, it does not work and the table shows blank...
then again, i am probably doing something wrong, eh...
whole post.php code
Here is my whole post.php code for your consumption, please run it as a php file not as an xml file or it will not run.
also don't forget to replace hostname, username, dbname, and password.
thanks a lot...
thanks a lot... :)
one thing, though: could you please give me the mysql import cmd to proberbly set up the tables?
i don't know that much about databases, so this would be very nice...
regards,
_house
MySQL Import for Countries
I use this import script from the web for my table:
http://27.org/isocountrylist/
thanks a lot :)
thanks a lot :)
flexigrid css clobbering drupal css
_house,
In reading, it seems like you overcame the CSS conflicts. How did you manage to do it?
I've got the JavaScrip and CSS installed, but the table doesn't look any different and the rest of my site is looking pretty poor: the header/navbar is below the content.
stock 5.7 jquery is a-okay
The jQuery that came with Drupal 5.7 works fine with flexigrid. I'm seeing some css clobbering with the way I've handled my nav and header and I'm noticing that the styles (mouseover and selection and bg images) aren't working correctly in IE6, but this is an improvement!