open directory project (dmoz) module
Hi All,
I am nearing a decent stopping place with the development of my first module. I'm not really a developer, but I've been able to get the jist of what PHP is about. Oh yeah, before I installed drupal last week I'd never worked with PHP before.
The module is merrily an integration of Dwop Live into the Drupal framework. What this gives you is the ability to parse dmoz data into drupal dynamically, but with the benefit of cache so your server isn't fetching the data each time. You can either grab the entire root of dmoz, or like me tailor a specific tree depending on the site.
In any case I could use some feedback on the module if anyone is interested. I've got it working within the Drupal framework, but I still have some wonky bugs to work out:
1. The users session is not persisting when in my module, not sure if there is some sort of _persist flag I need to set?
2. I tried my best to set all the definable data in the admin screen for the module, but the script requires a server path (/home/sites/blah) that I could never set right. Suffice it to say I'm not sure how to join to strings in PHP. There are a few places in the code that call for
$variable = $pathname + $someothervariable;I wasn't sure how to join it properly....in any case I'm learning!
3. Where can I insert a link to this module in the primary navigation of the site?
Comments welcome! Once I get the wonky bugs worked out I'll be happy to post the code to the cvs.
http://www.goodbeats.net/dmoz <- my site is brand new so any comments on it would be welcome as well!
cheers all,
Geoffrey

joining strings
Use "." to concatencate strings:
$file_loc = $path . "/" . $filename;Tried that. Errors galore. Ev
Tried that. Errors galore. Even tried a throwing curly brakets around the parameters as well. :(
Are they really strings?
Are you sure you're joining strings? The dot is the string concatenation operator in PHP, and the plus is the array concatenation operator.
See the PHP manual for string and array operators.
Ahhh,
Ahhh,
The parameter was being passed within a subclass, so I just had to assign it inside the subclass instead of in the header of the module like so:
$this->_serverpath=$server_path = variable_get("dmoz_module_server_path", "");
instead of
$server_path = variable_get("dmoz_module_server_path", "");
I've also seemed to have fixed the wonky cache and breadcrumb issue, as well as anchoring a link in the primary nav.
I've got just two outstanding issues, first is to tweak search so it picks up the data in the module.
However the bigger issue is the session. The module is not persisting the session when the user clicks over. Not sure why that is happening.
Does anyone have any comments on the module in general?? This is my first Drupal module so I would appreciate any comments....
cheers,
Geoffrey
dmoz module
Well, i'd say this would make a useful contribution to the modules library!
;)
Why thank you!
Does anyone know who handles the CVS permissions? I applied to be granted upload permissions but the form returned and error.
My only major concern at this stage is lack of testing. I've tested this on RedHat Linux and WindowsXP and have had a bit of trouble with 'clean url' mode. I've tested for clean url's, and after disabling it I realised it doesn't work! Is there a breakdown of people who use vs dont use clean urls?
Until I get access to upload, you can find a copy of the BETA here
cheers,
Geoffrey
Hellllooooo.....anybody home?
Hellllooooo.....anybody home?
I still have not received permissions to upload files to the CVS. I think this module would make a good addition to Drupal!
please go to devel list
please subscribe yourself to the devel list and ask for cvs access there. the developers and some lurkers hang out there and will grant you access...
see mailing-lists
--
groets
bertb
I'm sorry to say this is pret
I'm sorry to say this is pretty sad.
I posted a few days ago to this list and no replies.
So, including this thread I've tried 3 different ways to get m module posted to the CVS. It may not be great but it works and is stable.
If anyone wants it just reply to this thread.
oops, forgot to login.
oops,
forgot to login.
DMOZ module
I'd love to have the DMOZ module.
DMOZ module
I'd love to have this module.
dmjossel@synfibers.com
Can we keep in touch ??
Hi,
I'm administering an Italian Portal on Choral Music (listed on DMOZ..)
I would be very interested in integrating your module and collaborate on new functions.
I'm working on porting my actual portal to Drupal, so I had to code some custom modules to publish choirs, events, articles, weblinks integrating with attached_file module.
I'm still testing it; hoping to publish oin one month.
If you're interested in collaborating, let me know.....
Matteo
mailto:webmaster@cantincoro.org
Output not correct
FYI,
if you choose
http://www.goodbeats.net/dmoz?c=/World/Italiano/Arte/Musica/Generi/Coral...
the ouput is corrupted due to UTF-8 charset as default.
I had to change into the theme the charset used from UTF-8 to ISO-8859-1.
Hope it helps
Matteo
mailto:webmaster@cantincoro.org
Misleading links
The links to "goodbeats.net" and to the beta download no longer show information about a dmoz module. The links now show a non related page.
--
capmex.biz