Routing with API

2011-02-07 Thread tnbrooks
I orginally added the resources for models in my routes file to create
an api for my app.
Router::mapResources('users');
Router::mapResources('topics');
.
As well as the extension parser
Router::parseExtensions();

I'd like to have a web app and an api from the same app so have
created a prefix for my api:
Router::connect('/api/:controller/:action/*', array('prefix' = 'api',
'api' = true));

Now when I go to http://localhost/webapp/api/users the index displays
fine, however if I go to http://localhost/webapp/api/users/1 it no
longer displays the user with id 1 as it did when I didn' have the
prefix.  Have i done something wrong or is this a known issue? The
error I am getting is this:
Error: The requested address '/api/users/1' was not found on this
server.

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php


Re: Routing with API

2011-02-07 Thread tnbrooks
Sorry meant to say that workshowever if I don't have the prefix
set, then it works fine with out the view however the prefix stops the
magic from happening.
assume the only way is to see if there is not id given and from there,
show all else, get the user with the specific id?

On Feb 8, 3:57 pm, Ryan Schmidt google-2...@ryandesign.com wrote:
 On Feb 7, 2011, at 22:23, tnbrooks wrote:

  I'd like to have a web app and an api from the same app so have
  created a prefix for my api:
  Router::connect('/api/:controller/:action/*', array('prefix' = 'api',
  'api' = true));

  Now when I go tohttp://localhost/webapp/api/usersthe index displays
  fine, however if I go tohttp://localhost/webapp/api/users/1it no
  longer displays the user with id 1 as it did when I didn' have the
  prefix.  Have i done something wrong or is this a known issue? The
  error I am getting is this:
  Error: The requested address '/api/users/1' was not found on this
  server.

 Don't you need:

 http://localhost/webapp/api/users/view/1

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php


Yammer with OAuth Component

2011-01-17 Thread tnbrooks
Hi all,
Just wondering if anyone has been able to access the Yammer API using
the OAuth Consumer class created by CakeBaker http://code.42dh.com/oauth/

I keep getting a null value when trying to get the request token, just
wondering if anyone has come across this issue and worked out what was
going on?

Thanks
Trav

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
CakePHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en


Re: Sharing data/values across different controllers

2011-01-17 Thread tnbrooks
You could write them into session using something like:
$this-Session-write('the_value', $value);
then to access it in your other controller you just use:
$this-Session-read('the_value');

This is just one way..there are many others


On Jan 18, 2:27 pm, zer0_gravity zr...@hotmail.com wrote:
 How Do I share a variable or data that exist in a particular
 controller but do not exist in other controller(s)?

 thanks

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
CakePHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en


CakeFest 2010 Videos

2010-09-07 Thread tnbrooks
As I was unable to get to CakeFest (from Australia) and reading some
reviews people stated that there were some videos being posted on
youtubejust wondering if we could get some links posted for all to
view.

I have found this one on using MangoDB:
http://www.youtube.com/watch?v=IEg5zTCXc0Q

Is there anymore out there or are more to be posted in the future?

Thanks
TB

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
CakePHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en


Re: New to CakePHP

2010-03-19 Thread tnbrooks
Check out this:
http://book.cakephp.org/view/219/Blog


On Mar 19, 2:23 pm, Tashi Daw dawtas...@gmail.com wrote:
 Please help me to get started with the cakePHP. I found this framework
 really good for rapid web application development. I have already done
 projects in ZF but i found it really bulky. I have gone through the cakePHP
 documentation, but i found it difficult to understand. So, can any body
 provide me a CRUD application build in cakePHP with authentication. So, that
 i can know how to use elements in views, models and controllers.

 Thanks

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
CakePHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en

To unsubscribe from this group, send email to 
cake-php+unsubscribegooglegroups.com or reply to this email with the words 
REMOVE ME as the subject.