Re: Anyone care to help with Media Temple dv?

2010-11-03 Thread td-nathan
Try the .htaccess first, next I'd look at php.ini settings like
safemode or basedir restrictions depending on where you placed the
cake install relative to httpdocs

-Nathan

On Nov 2, 7:25 pm, Dave Maharaj m...@davemaharaj.com wrote:
 I had my site on Media Temple gs service no problem. Now moving it to dv and
 I got nothing. Uploaded everything but no htaccess file appears so I think
 that might be part of the problem. Get no error message other than 500
 server error.

 Any ideas / help would be great as I cant seem to find anything.

 Dave

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: Anyone care to help with Media Temple dv?

2010-11-03 Thread td-nathan
You can put it anywhere, but the default security restrictions keep
you from accessing anything outside of httpdocs.  These can easily be
changed in the php.ini file or on a per-domain basis in the vhost.conf
file.  The setting you'd be looking for would be to set
open_basedir=none

As far as permissions, you need to 777 the tmp/ directory and
subdirectories

Hope that helps,
Nathan

On Nov 3, 9:35 am, Dave Maharaj m...@davemaharaj.com wrote:
 Hey thanks.

 Ok htaccess is there and site is up but cache not writable is next
 errorsplenty of those.

 Did some reading and to me it looked like I had np option but to put cake
 folder in httpdocs?Weird no? I was on their (gs) server and was able to move
 my folder outside of the root folder but on a higher end server more $$$ I
 have to keep it in root folder?

 Im no server giuy so please bare with me...any and all tips / advice will be
 greatly appreciated.
 Thanks,

 Dave



 -Original Message-
 From: td-nathan [mailto:tyler.digi...@gmail.com]
 Sent: November-03-10 4:12 AM
 To: CakePHP
 Subject: Re: Anyone care to help with Media Temple dv?

 Try the .htaccess first, next I'd look at php.ini settings like
 safemode or basedir restrictions depending on where you placed the
 cake install relative to httpdocs

 -Nathan

 On Nov 2, 7:25 pm, Dave Maharaj m...@davemaharaj.com wrote:
  I had my site on Media Temple gs service no problem. Now moving it to dv
 and
  I got nothing. Uploaded everything but no htaccess file appears so I think
  that might be part of the problem. Get no error message other than 500
  server error.

  Any ideas / help would be great as I cant seem to find anything.

  Dave

 Check out the new CakePHP Questions sitehttp://cakeqs.organd 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 
 athttp://groups.google.com/group/cake-php?hl=en

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: CakePHP Session on MAMP

2010-09-10 Thread td-nathan
What version of Cake do you have installed?

On Sep 8, 7:20 pm, xwteoh xwt...@gmail.com wrote:
 I encounter a weird problem where I tried to search around and doesn't
 find the answer. Hope someone could help me over here.

 My problem:

 I set a session by calling $this-Session-write('Suppliers',
 $suppliers);  my controller. However when I do 
 $this-Session-read('Suppliers'); at another page, i got no data return. i 
 tried

 with $this-Session-check('Suppliers');, it return false. The weird
 things is, this only happen in MAMP on mac. Same code i tried at WAMP,
 it works fine. I even upload the code to free hosting (00webhost) it
 work fine also.

 Can someone please help. 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


Re: How to implement Comet in CakePHP ?

2010-01-03 Thread td-nathan
I also need to implement a chat room system, are there any good
tutorials for integrating these Jabber systems with CakePHP?  Ideally
something that covers the server-side installation and then how to
build an accessible front-end for users using CakePHP or an existing
plugin?

On Jan 2, 11:26 am, Pablo Viojo pvi...@gmail.com wrote:
 Forget Comet. Take a look at Jabber (A very good 
 serverhttp://www.igniterealtime.org/projects/openfire/) and 
 JsJachttp://blog.jwchat.org/jsjac/if you want to write a robust chat system. 
 (It
 will save a lot of time)

 Regards,

 Pablo Viojo
 pvi...@gmail.comhttp://pviojo.net

 ¿Que necesitas?http://needish.com



 On Sat, Jan 2, 2010 at 3:36 PM, nacho4d nach...@gmail.com wrote:
  Hey.. Its been a while.

  As I said before I want to implement comet chat system in cakePHP,
  (there was a plug-in around there, but it does not seems to work fine
  anymore. not for 1.2)

  So, I have my controller: cometchats_controller.php
  and my action
  function comet(){
  //get database data and pass it to the view
  //do some other stuff...
  }
  the view will be rendered and the message data will be put in a div
  like this div id=content/div
  So, let me know If I am in the correct way.

  I could use afterFilter() callback to run a loop to check the database
  for new message (since it is a chat system)
  In case there is a new message stop the loop, and render the view
  again like this:

  this-render('cometchats/comet/', 'ajax);

  but I want to render only the data inside the content div, so I have
  to assign a div.
  How do I do this?
  Am I right so far?

  On Dec 18 2009, 11:59 pm, nacho4d nach...@gmail.com wrote:
   I have been search this (cometin cakephp) for some time, but I
   couldn't find anything really helpful
   I would appreciate your help. ;)

   On Dec 17, 5:22 pm, cherif_Gsoul cherif.sahel...@gmail.com wrote:

hi, you have to learn more about cakephp is not so hard to learn
ajax's implementation in  cakephp who is made to work with the
prototype framework and ther's a helper for jquery developed by the
community i think, i saw one day a plugin for tchat somewhere do some
google researchs i am sur you will get it. i do some research if i
find something i ll post it here ok?
 tciao.

  Check out the new CakePHP Questions sitehttp://cakeqs.organd 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.comcake-php%2bunsubscr...@googlegroups.c 
  omFor more options, visit this group at
 http://groups.google.com/group/cake-php?hl=en

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: CakeFest IV - America - Help us pick a location!

2009-11-13 Thread td-nathan
1 vote for west coast (LA/SF?)

On Nov 12, 7:43 pm, Graham Weldon gra...@grahamweldon.com wrote:
 Hi all,

 The CakePHP team has been considering the location for the next  
 upcoming CakeFest.
 We've decided to bring it back home to the United Sates of America.
 Thus far we haven't chosen a location for the event, but to ensure we  
 reach as many people as possible, we'd like your opinion on where we  
 should host the event.

 Essentially, our choices are:
 - USA East Coast
 - USA West Coast
 - USA Central

 If I have missed another location that you feel might be more popular  
 or accessible to interested attendees, feel free to suggest it.
 We're keen to hear peoples thoughts on it.

 Cheers,

 Graham Weldon (AKA: Predominant)

 e. gra...@grahamweldon.com
 w.http://grahamweldon.com

--

You received this message because you are subscribed to the Google Groups 
CakePHP group.
To post to this group, send email to cake-...@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=.




Email/IMAP data source

2009-10-21 Thread td-nathan

I need to process an email inbox, monitor it for messages with a
particular subject line.  If it finds a match I need to get the body
content, manipulate, and insert into a database.  Ideally would mark
the message as read and move it to another IMAP folder as well.

I'm poking around PHP documentation imap_open (http://us2.php.net/
imap_open) and found a link 
http://www.linuxscope.net/articles/mailAttachmentsPHP.html#_jmp0_

Before I get too far, I'm wondering if anyone is aware of an existing
CakePHP data source or PHP class that's a good wrapper for the basics
I'm looking for:

IMAP:
connect
list folders
list messages
read messages - from, to, subject, body
move messages to server folders
read/unread status

Thank you!

--~--~-~--~~~---~--~~
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: CakePHP jQuery - Update multiple selects?

2009-05-31 Thread td-nathan

If you want to use code like you had before, check the livequery
plugin. It reattached applicable events as new elements are added to
the DOM (ie. Your change event to a new select box)

On May 30, 2:47 pm, DigitalDude e.blumsten...@googlemail.com wrote:
 Hey,

 THX for the response. I already changed my approach to the problem and
 set up ID's for the elements and use .append to replace the options of
 the elements. This works just finde, i encode my results to JSON and
 jQuery rebuilds the list oft options for my selects the way it should.

 A question related to jQuery in general, are there any good sites or
 tutorials or what I would call a function-overview for such purposes?
 This would be great because it took a LOT of time to gather all
 required information to my topic before I could solve it.

 Regards

 On 30 Mai, 18:43, brian bally.z...@gmail.com wrote:

  This is solely due to jQuery (in fact, probably the source of most
  questions on its mailing list).

  The problem is that you're completely replacing each of the selects,
  rather than just the options. So, the event handlers you set up on the
  selects are no longer once the selects have been replaced. See here:

 http://docs.jquery.com/Frequently_Asked_Questions#Why_do_my_events_st...

  Also, it doesn't appear that you have several sets of these 5 selects
  on a page because you're setting the event handlers using the element
  IDs (eg. '#BookingCountryId'). So, you might want to consider using an
  element id, rather than a class (eg. '.ajax_shop_id'), for the target
  to be updated.

  Or, don't bother and let jQuery find it using the select element itself:

  $('.ajax_page #BookingCountryId').change(function(){
          var self = this;
          var selected = $(this).val();
          ajax_loading_image('.ajax_loading_image');

          $.ajax({
                  type: POST,
                  url: '/bookings/getLocations',
                  data: ajax=trueid=+selected,
                  success: function(msg){
                          $(self).parent('div').html(msg);
                          ajax_remove_loading_image('.ajax_loading_image');
                  }
          });

  });

  However, I recommend that you simply replace the options rather than
  the entire select element.

  On Sat, May 30, 2009 at 9:06 AM, DigitalDude

  e.blumsten...@googlemail.com wrote:

   Hi,

   I'm trying to deal with jQuery in CakePHP and basically I want to do
   the following:

   I have 5 select-boxes in which the user should chose some values, and
   when a value changes the other selects should be updated with the
   corresponding data.
   I figured out how to update selects, that's not a big problem and it
   works fine. But when I chose a value from a select box that has been
   populated with jQuery, the change(function()) in my jQuery script does
   not register the changing of the value, even though the div-id's are
   set correct.
   The part of my js-script where the second selectbox should be checked
   for changed calues is not triggered, I tried many combinations of the
   element-id but it won't start any function in that part.

   Here's what I'm dealing with:
   
   Main-View:
   
   ?php echo $form-create('Booking',array('class'='ajax_page'));?
          fieldset
                  legendAjax Test 1.2/legend
                  div class=ajax_loading_image/div
                  ?php
                  echo $form-input('country_id',array(
                          'label'='Country',
              'empty' = 'Choose country'
                  ));
          echo $form-input('location_id',array(
                          'label'='Location',
                          'type' = 'select',
              'empty' = 'Choose location',
              'div'='input select ajax_location_id'
          ));
                  echo $form-input('shop_id',array(
                          'label'='Shop',
                          'type' = 'select',
              'empty' = 'Choose shop',
                          'div'='input select ajax_shop_id'
                  ));
          ?
   ?php echo $form-end();?

   
   The controller- part(s):
   
      function getLocations() {
          $country_id = $this-params['form']['id'];
          $locations = array();
          $this-layout = null;

          if($country_id  0) {
              $locations = $this-Booking-Shop-Location-find('list',
   array(
                  'contain' = array('Country'),
                  'conditions' = array(
                      'Location.country_id' = $country_id
              )));
          }
          $this-set(compact('locations'));
      }

      function getActiveShops() {
          $location_id = $this-params['form']['id'];
 

Re: Good way to paginate my index view by several keys / and-conditions

2009-05-27 Thread td-nathan

I've dealt with this before and usually end up reading/writing from
the named params and doing some of the lifting that paginator usually
does.  Sometimes tho, if the table is small enough, I just switch to
JavaScript and use the excellent TableSorter jQuery plugin.
http://tablesorter.com/

There's even support for pagination (although you obviously have to
load all rows at once and then it handles pagination in its own way).
It has its drawbacks but if your table isn't thousands of rows I find
this to be a quick fix.

On May 26, 1:55 pm, Bs sommerf...@hs-heilbronn.de wrote:
 Well, right now my index looks just like in the cookbook

 table
 tr
 th?php echo $paginator-sort('Country', ''Country'); ?/th
 th?php echo $paginator-sort('Postal', 'Postal'); ?/th
 th?php echo $paginator-sort('Region', 'Region'); ?/th
 th?php echo $paginator-sort('City', 'City'); ?/th
 /tr
 tr
 .print the model entries
 /tr
 /table

 When the user clicks Country the model view is ordered by country,
 when he clicks Postal it's ordered by postal and so onbut he
 can't order the whole view by Country and Region for example.

 The $paginator is defined as follows:

 var $paginate = array(
                  'fields' = array
 ('Myobject.id','Myobject.Name','Myobject.Country','Myobject.Postal','Myobje 
 ct.Region','Myobject.City'),
                  'limit' = 100,
                  'order' = array(
                  ''Myobject.Country' = 'desc',''Myobject.Postal' = 'asc'
                  )
          );

 On 26 Mai, 19:25, brian bally.z...@gmail.com wrote:

  OK, I understand. It looks like you'll need to check $this-params and
  deal with yourself some of the things paginator does automatically.
  The principle is the same, however: just add however many fields you
  need to the order array.

  It seems like you're going to make the interface overly complicated,
  though. But, without seeing your app, I can't really judge. Just an
  observation.

  On Tue, May 26, 2009 at 12:56 PM, Bs sommerf...@hs-heilbronn.de wrote:

   Hi,

   thanks for the hint but I want to provide the users with buttons to
   paginate the index view dynamically. Just like written in this howto

  http://book.cakephp.org/view/166/Pagination-in-Views

   but not only for singular columns but for 2, 3 or more so that they
   can order their view after country, region and city for example. Right
   now the code in my index view looks like this:

   th?php echo $paginator-sort('Country', 'Country'); ?/th

   And what I would like to do is something like this:

   $sort[] = Country; $sort[] = Region; $sort [] = City;
   th?php echo $paginator-sort($sort, 'Country'); ?/th

   So that the view is sorted by several keys when the user clicks.

   On 26 Mai, 18:37, brian bally.z...@gmail.com wrote:
   On Tue, May 26, 2009 at 11:56 AM, Bs sommerf...@hs-heilbronn.de wrote:

Hi,

I'm trying to order my index view by several conditions. As far as I
can see from the documentation, the $paginator only accepts one key
for sorting the model.

   http://book.cakephp.org/view/166/Pagination-in-Views

 What is the best practice to order my model by several keys? (For
example, ordering my cities by country, region, and city name in my
index view)

   'order' = array(
           'City.country' = 'ASC',
           'City.region' = 'ASC',
           'City.name' = 'ASC'
   )

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---