Is Drake for Drupal 6 planed?
| Comment | File | Size | Author |
|---|---|---|---|
| #58 | cake_embedded_dispatcher.class_.zip | 4.23 KB | thijsje |
| #47 | drake.zip | 30.41 KB | rowlandm |
| #46 | 20100429-drake-properflashmessagesv3.tgz | 855.16 KB | rowlandm |
| #45 | 20100429-drake-properflashmessagesv2.tgz | 854.04 KB | rowlandm |
| #44 | 20100429-drake-properflashmessages.tgz | 853.69 KB | rowlandm |
Comments
Comment #1
tenzing7777 commentedI am getting older now and waiting for Drake for Drupal 6 to arrive. But Whennnnnnnnnnnnnnn?
Comment #2
Anonymous (not verified) commentedI have a project that requires this (for a Drupal 6 site), so in the next month or so, I'll be working on upgrading this module. It looks like it's abandoned - the last commit was 2 years ago. If anyone else is currently working on this, please speak up!
Comment #3
MichaelCole commentedNo, but rock on!
I want to write a "mega-module" and was looking for cakephp or symfony to write it in. I could totally help out on this.
Mike
Comment #4
smurferboy commentedWe're currently launching a project that would also use cakephp and drupal. Is there any progress in the porting to 6 already?
Thanks,
Wouter
Comment #5
geste commentedPearlbear,
I hope you have some luck with this. I never really took a look at it to see how complicated the module is. Drake was something I was going to "get back to sometime" and now that I actually have a working Cake application, I went back to look only to find that it appeared to be abandoned.
I am going to bring up a new Drupal 6 server with the intent to migrate off of our existing Drupal 5 system late in 2009. Wish I was smart enough to help on the module itself, but I will have a Drupal 6 system for several months with no users, so testing maybe?
Jim
Comment #6
burningdog commentedThis is a newbie question, so feel free to flame me ;) But why is the integration between a framework like CakePHP and drupal useful? Why not use one or the other? Now, I know a fair bit about drupal, but haven't used a php framework before - doesn't the performance hit of running a framework inside drupal make it not worth it?
Comment #7
Anonymous (not verified) commented@geste - I'll definitely take you up on the testing. I've been a bit delayed, but I will be digging in when I get back from vacation in a week.
@Roger - no flames here. Basically, my use case is that we have a very complex client-tracking database written in cake, and users of a members-only site in drupal who I want to be able to interact with that database without a second login. I also want to pull user-specific data (pending activities, etc.) from that cake database into drupal blocks.
Comment #8
burningdog commented@pearlbear thanks - that's a specific use-case which shows why this integration is useful :)
Comment #9
Anonymous (not verified) commentedSo a little news on progress and planning for drake:
1) I've done some initial work to port the module to Drupal 6 - but there are a number of snags still.
2) My first goal will be to simply recreate the functionality of the 5.x-1.x version in 6.x. When that happens, I'll figure out how to release the dev snapshot here. (I'm a newbie to how to contribute to drupal projects, or how to assume responsibility for a project, so any guidance in that realm would be especially useful. I've tried to contact the current maintainer, and have failed, so I'm assuming the project is abandoned.)
3) My project includes a need for single sign on, so I'll be adding that to this module for sure.
4) Any other suggestions on how to increase the usefulness of this module (besides dealing with current issues in the queue) are welcome.
Comment #11
kenorb commentedany news?
Comment #12
Anonymous (not verified) commentedThe module was pretty much a disaster. There is a *lot* of work to do (and I am a relatively new module developer). But I'm still slogging away, since this project I am doing requires it. I'll keep everyone posted.
Comment #13
greenc commentedsubscribe
Comment #14
freedomfflow commentedHey there... first day delving into Drupal... I've been using cake for a while now, but I'm far from an expert. But my projects are committed to cake at this point.
I was excited to hear about Drake, but disappointed to see its not available for Drupal 6.
I would be willing to help where I can to try and develop it, but given I know so little about drupal I'm not sure what I can do.
That said, as a drupal newbie, should I downgrade to drupal 5 so I can configure drake? What are the major drawbacks to that?
Thanks
Comment #15
tseven commentedI too am interested in see thing module ported to D6, unfortunately I have no experience with CakePHP,.... YET.
Comment #16
dmadruga commentedSubscribe.
Comment #17
jejk commentedHello
I am quite new to Drupal but quite experienced with CakePHP.
So as my first contribution here is the D6 version of Drake.
Comment #19
pluess commentedFirst of all many thanks to jejk for the D6 Code. I think this code should be added as a dev Version for D6, in order we have a common base to code and patch against.
Unfortunately I don't see any sign of life from the module maintainer for the last 3 years. Is this module still supported? May be the module should be handed over to someone else?
Ths site http://dev.sypad.com/projects/drake which should provide additional information is not reachable any more. If someon has this documentation, it should be added to the drupal module documentations.
Comment #20
mkeplinger commentedWe too have a need for this. Any word on the latest?
Comment #21
toddgee commentedsubscribe
Comment #22
toddgee commented@jejk any interest in becoming the official maintainer so you can check in the code to the Druapl contrib CVS?
http://drupal.org/node/251466
Comment #23
celia_ccs commentedI'm also willing to sponsor the development of Drake to D6.
Comment #24
mkeplinger commentedWe have quite a few people willing to sponser the release of a Drake release for Drupal 6.x. (including me, I could three here).
It there anyone with the right skill-set, and time to put the time into creating a stable release??
Comment #25
kiange commentedSubscribe, too.
Comment #26
klamzo commentedsubscribing
Comment #27
rowlandm commentedI am going to try and do this. I have recently create a cakephp application for organising sporting teams for a club and wanted to integrate it with drupal.
Wish me luck as I am only new to Drupal but do PHP for a living!
Comment #28
luckysmack commentedSubscribing
Any update on this? I could also benefit from using this.
Comment #29
wils.solutions commentedHi Gang,
I'm in the same boat =D
I have It running, what I did:
1 - copied my cakephp app to the drupal folder
2 - changed the ini file, bellow the example:
[settings]
default = "myapp"
[myapp]
path = "myapp\app\webroot"
url = "/myapp"
3 - URL to see the magic:
http://your_drupal_host/drake/?run=images/index
Images = name of my controller
that's It!
Problems:
1 - It's loosing the Session: after a request I need to login again, the module is performing the request and destroying the session. This is being my huge problem.
My Solution: disabled the Session on CakePHP =p
I'm poking around and see what I can improve to get on It!
Anybody else would like to share own experience and tips?
tkx
Wils
Comment #30
rowlandm commentedHi wils.solutions,
Did you use the Drake 6 that jejk mentioned?
Also, could you tell me what drake related records are in your menu_links table?
I haven't been able to get it working yet, and I can't seem to see how I could with the menu_links not being a certain way.
Thanks
Rowland
Comment #31
rowlandm commentedFrom jejk's code I had to change the following in drake.module to get it to kind of work.
It was for $items['drake/documentation']
$items['drake']= array(
'title' => 'Drake Dispatcher',
'page callback' => 'drake_dispatcher',
'access arguments' => array('access drake content'),
'access callback' => true
);
Also had to move the cakephp folder (which contains app cake and vendors folders) to sites/all folder
Am currently having problems with posting - perhaps it is an issue as I am using scaffolding.
Comment #32
rowlandm commentedFrom jejk's code I had to change the following in drake.module to get it to kind of work.
It was for $items['drake/documentation']
$items['drake']= array(
'title' => 'Drake Dispatcher',
'page callback' => 'drake_dispatcher',
'access arguments' => array('access drake content'),
'access callback' => true
);
Comment #33
wils.solutions commentedHey Rowland,
Yes, I'm using the version from jejk.
Here you're my menu entries:
admin_menu 1456 238 admin/build/drake/get admin/build/drake/get Get Drake URL a:1:{s:5:"alter";b:1;} admin_menu 0 0 0 0 0 2 0 238 1456 0 0 0 0 0 0 0 0
Edit Delete admin_menu 1455 238 admin/build/drake/documentation admin/build/drake/documentation Documentation a:1:{s:5:"alter";b:1;} admin_menu
Hey, why is the menu information important for you?
Thank you
Wils
Comment #34
rowlandm commentedHey Wils,
I noticed that in the jejk #17 post download that I couldn't get it working using an example like /drake?run=images/index because it was using drake/documentation to point to the drake_dispatcher module function and didn't work. So I had to add in that code
It was for $items['drake/documentation']
$items['drake']= array(
'title' => 'Drake Dispatcher',
'page callback' => 'drake_dispatcher',
'access arguments' => array('access drake content'),
'access callback' => true
);
to get it working.
Did yours work out of the box? Which Drupal version was that?
And sorry, I probably needed your menu_router table, not your menu_link table - whoops.
Comment #35
wils.solutions commentedHey,
So, my before was working, now I'm doing a fresh setup and found new issues =P
For example: I'm getting the output, just a blank screen, however print $output; display my cakephp app without css hehehe. I'm figuring It out.
1st time I had It running on wwwroot/drupal/mycakephpapp =D now moved to /sites/all =p the problem is: both paths are visible on web :P I need to write some code to restrict access.
I'm, using Drupal6x.
Here you are the menu_route:
regards
Wils
Comment #36
rowlandm commentedCool - I didn't have the first menu_router record you had - I had to set that up.
Found out if I stop the session destroy for Drupal, my cakephp app says :
So I could get it working in this config by setting app/config/core.php Session.start to be false.
But I want my CakePHP to have Session.start so I think we will have to fix the backup/destroy/restore around the cakephp dispatch in drake module.
Will keep trying!
Comment #37
rowlandm commentedFound it!
Simple change to drake/drake.module line 314
$cakeDispatcher->setRestoreSession(true); // it was false and causing problems
So I logged into Drupal, then I jumped into drake and went to drake?run=/fixtures/index (my fixtures controller is scaffolded) and started clicking links and I was still logged into Drupal.
Try that out and let me know.
Comment #38
rowlandm commentedI've tried to put this into a .zip file. Please try and let me know how you go.
Comment #39
rowlandm commentedThings still to do:
1/ Problem with forms redirecting to the normal /fixtures instead of drake?run=/fixtures but that could just be scaffolding/routing issue
NOTE: this was an issue with the CakePHP code. I ended up using $this->flash with a long pause (1000 seconds) so that the user would be forced to click the message as if I redirect it causes problems with the restore of the session and it looks like you have logged out on Drupal when you haven't.
2/ Single sign on across Drupal and CakePHP
3/ Wils mentioned disabling access via sites/all/modules/cakephp
Comment #40
rowlandm commentedSlightly more elegant fix to problem 1 on #39 post above:
Setup an app_controller.php and override the redirect function:
Comment #41
rowlandm commentedAnd the latest update to the codebase, including single sign on for CakePHP based on Drupal login (I just copied the modules and cakephp folder under sites/all folder, so you could see a cakephp example).
To get to the cakephp application use http://hostname/drake?run=/fixtures
Sorry had to use .tgz to get under 1MB upload limit.
Comment #42
wils.solutions commentedCool buddy, I just tried to run the last one and got:
Fatal error: Cannot re-declare class view in /sites/all/modules/views/includes/view.inc on line 19
Some conflict with Drupal Views,
class view extends views_db_object {Would you to enable Views on your setup?
tks
Wils
Comment #43
rowlandm commentedYeah - looks like there is a CakePHP class called view
class View extends Object in cake/lib/view/view.php
So I doubt that you will be able to use Drake with Views.
Could you please try a fresh Drupal install and try the last .tgz file I had. Just so I know it works for someone else!
Comment #44
rowlandm commentedHi there,
Just updated the drake to handle $this->Session->setFlash messages nicely.
Have attached the latest version, you will need to update the app_controller as well as the drake module.
Regards,
Rowland
Comment #45
rowlandm commentedSorry, found a couple of bugs.
1/ Problem when deleting with no delete view and
2/ Issue when no flash message being set
Comment #46
rowlandm commentedBoss told me I should use exceptions in the app_controller to provide a true redirect
So here it is.
Changes made to the app_controller in cakePHP and two files in the drake module
Comment #47
rowlandm commentedHi there,
Further refactoring for drake.
I have created a Drake Component that you can put in your app_controller
Tested and looks good in Drupal 6 with Cake 1.2 and Cake 1.3 working.
I have just zipped up the drake module and put the drake component for CakePHP in the root directory under drake.php
Comment #48
mkeplinger commentedrowlandm - thanks for working on this project. It looks like your current work demands it. Do you have a workable port of this to Drupal 6x?
For those that comment frequently about the need for this module in Drupal 6.x, I am curious what workarounds people have been using? We are now about to investigate how to go about this without Drake, such as iFrames, PHP's virtual() function, and potentially using hook_menu()
So this post is really about 2 questions.
1. Is there a workable port of Drake for 6.x
2. What are people using as an alternative to integrate drupal and cakePHP?
Comment #49
mkeplinger commentedAlso wanted to add that we have a custom module built to integrate Drupal users / permissions, with cakePHP through ACOs (Access Control Objects), and it works quite well. It could probably be adopted here, but my developer doesn't have the time to make it "generic" and support it as a module.
Comment #50
rowlandm commented@mkeplinger
The drake.zip file on comment #47 is the workable port for Drake 6x.
Let me know how you go with it.
Comment #51
toddgee commented@rowlandm, have you considered petitioning to become the maintainer of the project so you can check your code in?
Comment #52
rowlandm commentedNo, not really. Just had a look at Drake because we had some time to do so at work. Not sure if I could continue to maintain this outside of my normal job.
Comment #53
edwinallenz commentedHello every one, it seems that some work it's being doing on this module.
I'm running a test of this module and I have a problem. When I go to http://www.mysite.com/drake/?run=/mycontroller/view if I'm on debug 2, I can see all the debug messages but the view is not rendered. The same issue it's happening when I use debug 0.
This is the testing url
http://www.nktproducts.com/drake/?run=productos/index
I'm using drupal 6 and the las version of drake posted in this thread.
Comment #54
rowlandm commentedHi edwinallenz,
Just curious if you got it working?
I'm not really in a position to have a look though, just curious. When I was testing/using this it was mainly with debug set to 2 - so I am unsure of what it might be.
Cheers
Comment #55
giantgoat commentededwinallenz I seem to be having the same problem as you. Though it seems that whatever debug is set to I dont see the cake view at all. I know it is getting into my cake application but it doesnt seem to render the view at all. Is there some special way for drupal to put the cake view in or should it be seemless?
Thanks
Comment #56
jejk commentedsubscribe
Comment #57
thijsje commentedThanks for the port to Drupal 6 for Drake - it's very useful to me.
When using Drake on a test enviroment, i did run into an issue however. I installed Drupal on a sub folder ('www.blabla.com/sub/') and experienced the following behaviour. When accessing 'www.blabla.com/sub/drake?run=mytestcontroller', i did get nice CakePHP output, but the URL's in the HTML were not translated correctly. For instance, i got:
img src="/sub/cakephp/sub/img/cake.power.gif". Clearly, the second 'sub' is causing the problem.
Did anybody else experience this also?
I was unable to solve the problem with configuration. Could it be that Drake was developed and tested with the assumption in mind that Drupal will reside in the wwwroot (being accessable on 'www.blabla.com/')? If so, then attached an slightly modified version of 'cake_embedded_displacher.class.php' which will solve this. (I started using rowlandm's post 47). Hope this is useful to others.
Comment #58
thijsje commentedComment #59
ericbieller commentedThanks a lot for putting this together! Ran into a problem when trying to implement the #47 code above on cakephp 1.3. I've got the exact code above in my controller file and the component seems to be loading. However I am getting the following error when running /drake " Fatal error: Call to undefined method Drake::redirect() in /sites/all/cakephp/app/app_controller.php on line 10". Not really sure why this would happen as the component is being loaded. Any thoughts? Is there something I'm missing? Thanks!
Comment #60
rowlandm commentedHey guys,
Sorry - but I haven't touched Drupal and Cake for over 3 months now in my new job. I can't even remember how to implement it off the top of my head.
What I can say is I was running the CakePHP application like this:
http://book.cakephp.org/view/34/Production
I must admit I didn't test it any other way.
Hope that helps - although I don't think it does.
Comment #61
emackn commentedguessing this is pretty much dead. someone tell me different.
Comment #62
kenorb commentedDrupal 5 and Drupal 6 is no longer officially supported. If you think this issue is still relevant for 8.x, feel free to re-open.