Re: CakePHP 1.3.8 - Editing user info causes 404

2016-05-03 Thread Steven Ybarra
Do you have validation when adding a user?

If so, it's probably not adding on an update because it's checking for the
validation.

Turn off validation on the update and see if it works.

i'm not sure the cake1.8 way, but it's something like

$this->MODEL->save($data, $params => array('validate'=>false));

On Mon, May 2, 2016 at 3:05 PM, Josh R  wrote:

> Hello Group,
>
> I am new to this group and CakePHP.
>
> I am dealing with a site that is build using CakePHP version 1.3.8. When
> adding a new user, everything works fine. When modifying a user (either
> through admin's account or through the user's account) the save function
> keeps the URL of the page (with client ID in url as it should) but the page
> doesn't add the updated data to the database, and gives a 404 page. When
> the URL is copied and entered again in browser the User's page appears, but
> like I mentioned no changes to the User's information was recorded. See the
> start and end of the form functions, there are a lot of fields in this form.
>
> Form->create("User", array("url" => array("controller"
> => "admin", "action" => $this->params["action"]))); ?>
> *There are many fields > echo $this->Form->input("...");, etc...*
> Form->end("Enregistrer"); ?>
>
> I was told that this form was working properly a couple months ago (I just
> recently have been looking into this issue), and then one day the saving of
> the form stopped.
>
> Any help is greatly appreciated. I can also send snippets of code if need
> be.
>
> Thank you in advance!
> josh
>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: CakePHP 1.3.8 - Editing user info causes 404

2016-05-03 Thread Josh R
Hi Reuben,

Thanks for your quick response yesterday. The URL I am getting is with the 
user ID.

For example: 
When I am logged in as an administrator and go view all users 
(/admin/admin/view_all_users) and I click to edit user ID="305880" (
/admin/admin/user_edit/305880), after making changes to the form I click 
save (Enregistrer) and the URL I come back to is the same 
(/admin/admin/user_edit/305880) 
but displays a 404 page. I can then copy the URL into another tab and the 
page loads (without any changes saved).

So I've been digging through the CakePHP files for the past couple days and 
I must say it's a bit overwhelming with what seems like duplicate 
files/functions in similar filenames with a Postfix of "_bu" (maybe because 
of the way the original developer built it).

Anyways, what I found is the following, please let me know if I am even 
looking in the right spot...
So as I posted yesterday, the form is in app/views/admin/admin_user_edit.php
Form->create("User", array("url" => array("controller" => 
"admin", "action" => $this->params["action"]))); ?>
*There are many fields > echo $this->Form->input("...");, etc...*
Form->end("Enregistrer"); ?>

I did also find a function in app/controllers/admin_controller.php (I 
highlighted the redirect link for user_edit if user already exists)
function admin_user_edit($id = NULL){
$new_user = false;
if (!$id){
$new_user = true;
}
if (!empty($this->data)){
//print_r($this->data);
$this->_uz_remove_data_not_to_be_saved("UserAddress");
$this->_uz_remove_data_not_to_be_saved("UserPhone");
$this->_uz_remove_data_not_to_be_saved("UserEmail");
$this->_uz_remove_data_not_to_be_saved("UserLink");
$this->_uz_remove_data_not_to_be_saved("UserContact");
//print_r($this->data);
//special for new user
if ($new_user){
$this->User->save($this->data, array("validate" => false));
$id = $this->User->id;
$this->data['User']['user_id'] = $id;
}
//pr($this->data); 
//validate password
if (!empty($this->data['User']['password']) && 
!empty($this->data['User']['confirm_password'])){
if ($this->data['User']['confirm_password'] == 
$this->data['User']['password']){
}
else {
unset($this->data['User']['password']);
unset($this->data['User']['confirm_password']);
}
}
else {
unset($this->data['User']['password']);
unset($this->data['User']['confirm_password']);
}
if (!empty($this->data['ExpertisesUser']['expertise_id'])){
$all_eus = $this->data['ExpertisesUser']['expertise_id'];
unset($this->data['ExpertisesUser']);
foreach ($all_eus as $k => $v){
unset($temp);
$temp['user_id'] = $this->data['User']['user_id'];
$temp['expertise_id'] = $v;
$this->data['ExpertisesUser'][] = $temp;
}
}
else {
unset($this->data['ExpertisesUser']);
}
if (!empty($this->data['UserCircusField']['circus_field_id'])){
$all_eus = $this->data['UserCircusField']['circus_field_id'];
unset($this->data['UserCircusField']);
foreach ($all_eus as $k => $v){
unset($temp);
$temp['user_id'] = $this->data['User']['user_id'];
$temp['circus_field_id'] = $v;
$this->data['UserCircusField'][] = $temp;
}
}
else {
unset($this->data['UserCircusField']);
}
//delete previous circus fields and expertises first
if (!$new_user){
$this->loadModel("UserCircusField");
$this->loadModel("ExpertisesUser");
$this->UserCircusField->deleteAll(array("UserCircusField.user_id" => 
$this->data['User']['user_id']), false);
$this->ExpertisesUser->deleteAll(array("ExpertisesUser.user_id" => 
$this->data['User']['user_id']), false);
}

$this->loadModel("UserProfile");
unset($this->UserProfile->validate);
if ($this->User->saveAll($this->data)){
if ($new_user){
$redirect = array("action" => "new_user_order_creation", 
$this->data['User']['user_id']);
}
else {
$redirect = array("action" => "user_edit", $this->data['User']['user_id']);
}
$this->Session->setFlash("Utilisateur enregistré !", "fs");
$this->redirect($redirect);
}
else {
if ($new_user){
$this->User->delete($this->data['User']['user_id']);
unset($this->data['User']['user_id']);
}
$this->Session->setFlash("Utilisateur non enregistré. Vérifiez les erreurs 
ci-dessous.", "fe");
}
}
else {
//new user/
if ($new_user){
$this->loadModel("UserProfile");
$max_member_number_temp = $this->UserProfile->find('first', 
array("recursive" => -1, "order" => "UserProfile.member_number DESC", 
"limit" => 1));
$this->data['UserProfile']['member_number'] = 
$max_member_number_temp['UserProfile']['member_number'] + 1;
$this->data['UserProfile']['member_since'] = date("Y-m-d");
$this->data['UserProfile']['membership_expiry'] = date("Y-m-d", 
strtotime("+ 1 year"));
$this->set('crumb', array("Utilisateurs" => array("action" => 
"view_all_users"), "Nouvel utilisateur" => array()));
}
//edit user/
else {
$this->data = $this->User->find('first', array('conditions' => 
array("User.user_id" => $id)));
$this->set('crumb', array("Utilisateurs" => array("action" => 
"view_all_users"), "# " . $id => array("action" => "user_edit11", $id)));
}
}
$this->_get_countries();
$this->_get_regions();
$this->_get_

Re: CakePHP Forum launched!

2016-05-03 Thread euromark
This forum should be closed and switched to read only.
The other one should now be the only one in use.

See the PRs to change the links on the CakePHP sites and documentation etc.
Mark


Am Dienstag, 3. Mai 2016 03:01:20 UTC+2 schrieb Reuben:
>
> Maybe this post should get stickied / pinned, so people know all the 
> action should now be at discourse.cakephp.org.
>
> Regards
> Reuben Helms
>
> On Tuesday, 26 April 2016 03:02:49 UTC+10, Megan Lalk wrote:
>>
>> CakePHP Forum launched!
>>
>> *We asked you what you wanted and the feedback was clear! Sign up 
>>  here - **http://discourse.cakephp.org/ 
>> *
>>
>> As you know, a CakePHP forum  is a 
>> welcomed platform by many! - From today, you  can be a part of the 
>> discussion and post your questions, find out the answers and make comments 
>> - all stored in one easy location!
>>
>> Our Google group has been a great place for many developers over the 
>> years, but also comes with a few difficulties. Results from our poll came 
>> in, and the consensus was that we needed a place where we could ask our 
>> questions, find out what others were asking and seek the advise from 
>> others. This platform allows for better interaction with your community!
>>
>> Well there you have it, besides our #CakePHP channel on IRC 
>> , Slack 
>>  channel, Stackoverflow 
>>  and our community 
>> newsletter; You can now also find us on our new CakePHP Forum 
>> .
>>
>>
>>   
>> Larry E. Masters
>>   
>> Co-Founder CakePHP
>>
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: CakePHP 1.3.8 - Editing user info causes 404

2016-05-02 Thread Reuben
Hi Josh

What URL is actually getting posted when the form is submitted?  

My only concern is that $this->params["action"] is not populated with the 
value you are expecting.  

I'm guessing that you are expecting the values of that variable to be 
either add, edit, create or update.  

What are the signatures of those methods in the controller?

Usually an add function will just be `function add()`, but an edit function 
might be `function edit($id)`, in which case, the POST will fail, because 
the action is not providing an id on the URL (i.e. /users/edit is requested 
instead of /users/edit/1).

And last but not least, it looks like these forums are being wound down. 
Head over to http://discourse.cakephp.org for CakePHP discussions. (but 
still reply to this topic, if you need to)

Regards
Reuben Helms

On Tuesday, 3 May 2016 07:42:07 UTC+10, Josh R wrote:
>
> Hello Group,
>
> I am new to this group and CakePHP.
>
> I am dealing with a site that is build using CakePHP version 1.3.8. When 
> adding a new user, everything works fine. When modifying a user (either 
> through admin's account or through the user's account) the save function 
> keeps the URL of the page (with client ID in url as it should) but the page 
> doesn't add the updated data to the database, and gives a 404 page. When 
> the URL is copied and entered again in browser the User's page appears, but 
> like I mentioned no changes to the User's information was recorded. See the 
> start and end of the form functions, there are a lot of fields in this form.
>
> Form->create("User", array("url" => array("controller" 
> => "admin", "action" => $this->params["action"]))); ?>
> *There are many fields > echo $this->Form->input("...");, etc...*
> Form->end("Enregistrer"); ?>
>
> I was told that this form was working properly a couple months ago (I just 
> recently have been looking into this issue), and then one day the saving of 
> the form stopped.
>
> Any help is greatly appreciated. I can also send snippets of code if need 
> be.
>
> Thank you in advance!
> josh
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: CakePHP Forum launched!

2016-05-02 Thread Reuben
Maybe this post should get stickied / pinned, so people know all the action 
should now be at discourse.cakephp.org.

Regards
Reuben Helms

On Tuesday, 26 April 2016 03:02:49 UTC+10, Megan Lalk wrote:
>
> CakePHP Forum launched!
>
> *We asked you what you wanted and the feedback was clear! Sign up 
>  here - **http://discourse.cakephp.org/ 
> *
>
> As you know, a CakePHP forum  is a 
> welcomed platform by many! - From today, you  can be a part of the 
> discussion and post your questions, find out the answers and make comments 
> - all stored in one easy location!
>
> Our Google group has been a great place for many developers over the 
> years, but also comes with a few difficulties. Results from our poll came 
> in, and the consensus was that we needed a place where we could ask our 
> questions, find out what others were asking and seek the advise from 
> others. This platform allows for better interaction with your community!
>
> Well there you have it, besides our #CakePHP channel on IRC 
> , Slack 
>  channel, Stackoverflow 
>  and our community 
> newsletter; You can now also find us on our new CakePHP Forum 
> .
>
>
>   
> Larry E. Masters
>   
> Co-Founder CakePHP
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Cakephp 3.x patchEntity set "'new' => true" to entity in edit function

2016-04-25 Thread heavyKevy
Thanks for the update, I am glad to hear that it is working for you.

It seems to me that in order for the system to know which record is being 
updated, that all of the ids should need to be supplied for every record that 
is being saved in a transaction.  If it is saving a record for which you did 
not supply an id, then it must be able to figure out the id via the 
relationship but can't do that with addresses when there can be multiple 
addresses that are related.

Best regards,
Kevin

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Cakephp 3.x patchEntity set "'new' => true" to entity in edit function

2016-04-25 Thread Paulo Terra
Hi Kevin,

It worked perfectly!!

I just would lime to know why only Addresses need the id. 

But if you dont know, thats OK. You already relped me!!

Thanks a lot!

Best regards,

Paulo Terra

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: cakephp 3 modular programming

2016-04-20 Thread euromark
It's called plugins
https://github.com/FriendsOfCake/awesome-cakephp etc

Mark


Am Mittwoch, 20. April 2016 18:26:27 UTC+2 schrieb Anurag Kumar:
>
> Is it possible to do modular programming with cakePHP 3.
>
> If yes please provide some example on it.
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Cakephp 3.x patchEntity set "'new' => true" to entity in edit function

2016-04-20 Thread heavyKevy
I am not sure why the others appear to be working,  I suggest that you test 
thoroughly to make sure they are doing as expected.
It may be because of the many - to -one relationship though.

Let me know how it goes.
Regards,
Kevin

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Cakephp 3.x patchEntity set "'new' => true" to entity in edit function

2016-04-20 Thread Paulo Terra
Hi Kekin, it is very kind of you help this poor Cake novice. It have been 
hard programing days.

Ok, if I have a hidden ID field of the Addresses I think it is going to 
work. But why do I have to put the Addresses ID and the other entities work 
without it?

Here is the form:

PS: Thanks again for your patience


Form->create($buyer);
?>








Form->input('user.name',['label' => __('Nome')]);?>
Form->input('cpf',['label' 
=> __('CPF')]);?>


Form->input('user.username',['label' => __('Email')]);?>




Form->label(__('Sexo'));?>

 __('Masculino'), 
'Feminino' => __('Feminino'));?>

Form->radio('gender', $options);?>


Form->label('birthdate',__('Data de 
nascimento'));?>
Form->input(
'birthdate',
array (
'label'=> 
false,
'minYear' => 
date('Y') - 100, 
'maxYear' => 
date('Y') - 12,
'empty'=> 
true,
'monthNames'=> true,
'default'=> ''
)
);

?>





Form->input('user.addresses.0.phone',['label' => __('Telefone')]);?>


Form->input('user.addresses.0.celphone',['label' => 
__('Celular')]);?>




Form->input('user.addresses.0.zipcode',['label' => __('CEP')]);?>




Form->input('user.addresses.0.line1',['label' => __('Endereço e 
número')]);?>




Form->input('user.addresses.0.line2',['label' => __('Complemento e 
Bairro')]);?>




Form->input('user.addresses.0.city',['label' 
=> __('Cidade')]);?>


Form->input('user.addresses.0.state',['label' => __('Estado')]);?>


Form->input('user.addresses.0.country_id',['options' => 
$countries,'label' => __('País')]);?>






Form->label(__('Preferências musicais'));
echo $this->Form->input('genres._ids',
[   
'templates' => ['checkboxWrapper' => '{{label}}'],
'options'  => $genres,
'multiple' => 'checkbox',
'label' => false,
//'value' => $buyer
]);   
?>




 




Form->label(__('Receber novidades'));?>
Form->input('newsletter',['type' => 
'checkbox','value' => 'Sim','hiddenField'=>'Não', 'label' => __('Quero 
receber email de novidades do Prefiro Vinil')]);?>






Form->button(__('Salvar'), ['class' => 
'btn-success']) ?>






Form->end() ?>






Em quarta-feira, 20 de abril de 2016 01:11:37 UTC-3, heavyKevy escreveu:
>
> Does your edit form have an input for the address_id?  
>
> something like:"user.addresses.0.id"
>
> I see the id: (29) for the address in the debug output of the entity...
>
> If you need further help with it, you are going to need to show the edit 
> form in order to figure out what may be missing.
>
> Hope that helps...
> Best regards,
> Kevin
>
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"C

Re: Cakephp 3.x patchEntity set "'new' => true" to entity in edit function

2016-04-19 Thread heavyKevy
Does your edit form have an input for the address_id?  

something like:"user.addresses.0.id"

I see the id: (29) for the address in the debug output of the entity...

If you need further help with it, you are going to need to show the edit form 
in order to figure out what may be missing.

Hope that helps...
Best regards,
Kevin

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Cakephp 3.x patchEntity set "'new' => true" to entity in edit function

2016-04-19 Thread Paulo Terra
Hi heavyKevy, thank you for your answer!

Ok, about your first advise, I simplified and its ok, but about the issue, 
that´s it, the problem is the missind ID. But I simlpy don´t know why all 
other entitys comes with the id and Addresses not! That is the problem. Do 
you know why?

Thanks in advance!

Paulo Terra




Em segunda-feira, 18 de abril de 2016 04:50:18 UTC-3, heavyKevy escreveu:
>
> First off you don't need to cotain users 3 times, 
> Users.Addresses.Countries includes all 3 tables already.
>
> Secondly, if the address has the id, it should automatically detect that 
> it is being edited, if the id is missing it will add the address.
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Vacancy for a CakePHP developer in London (Farringdon)

2016-04-14 Thread Dr. Tarique Sani
:D

On Fri, Apr 8, 2016 at 1:18 PM, Jeremy Burns : Class Outfit <
jeremybu...@classoutfit.com> wrote:

> Thank you, but Delhi is a long commute. I don’t think that will work. This
> is an on site position.
>
> On 8 Apr 2016, at 08:18, Kamal Deol  wrote:
>
>
>
> On Fri, Apr 8, 2016 at 8:31 AM, Jeremy Burns 
> wrote:
>
>> An old client of mine is looking someone to take over and develop some
>> code I built for them a year or so ago (CakePHP 2.6). They are only small,
>> so it'd be more of a junior than a senior role (they might consider
>> contract). The business is small but successful and is mainly based in
>> Swindon, but the IT is run from their very small but very friendly London
>> office. The company is run by a really cool switched on chap who
>> understands technology and how important it is to his business. This is an
>> on site only position. No agents or recruiters please.
>>
>> Contact me if you'd like to know more. Send me your CV if you'd like to
>> be considered and I'll forward the good ones on to the client.
>>
>> --
>> Sign up for our Newsletter for updates.
>> http://cakephp.org/newsletter/signup
>>
>> We will soon be closing this Google Group. But don't worry, we have
>> something better coming. Stay tuned for an updated from the CakePHP Team
>> soon.
>>
>> Like Us on FaceBook https://www.facebook.com/CakePHP
>> Follow us on Twitter http://twitter.com/CakePHP
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "CakePHP" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to cake-php+unsubscr...@googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
> 
>
>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
=
Hire a CakePHP dev team : http://sanisoft.com
=

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Vacancy for a CakePHP developer in London (Farringdon)

2016-04-08 Thread Jeremy Burns : Class Outfit
Thank you, but Delhi is a long commute. I don’t think that will work. This is 
an on site position.

> On 8 Apr 2016, at 08:18, Kamal Deol  wrote:
> 
> 
> 
> On Fri, Apr 8, 2016 at 8:31 AM, Jeremy Burns  > wrote:
> An old client of mine is looking someone to take over and develop some code I 
> built for them a year or so ago (CakePHP 2.6). They are only small, so it'd 
> be more of a junior than a senior role (they might consider contract). The 
> business is small but successful and is mainly based in Swindon, but the IT 
> is run from their very small but very friendly London office. The company is 
> run by a really cool switched on chap who understands technology and how 
> important it is to his business. This is an on site only position. No agents 
> or recruiters please.
> 
> Contact me if you'd like to know more. Send me your CV if you'd like to be 
> considered and I'll forward the good ones on to the client.
> 
> -- 
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup 
>  
> We will soon be closing this Google Group. But don't worry, we have something 
> better coming. Stay tuned for an updated from the CakePHP Team soon.
>  
> Like Us on FaceBook https://www.facebook.com/CakePHP 
> 
> Follow us on Twitter http://twitter.com/CakePHP 
> --- 
> You received this message because you are subscribed to the Google Groups 
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to cake-php+unsubscr...@googlegroups.com 
> .
> For more options, visit https://groups.google.com/d/optout 
> .
> 
> 
> -- 
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup 
>  
> We will soon be closing this Google Group. But don't worry, we have something 
> better coming. Stay tuned for an updated from the CakePHP Team soon.
>  
> Like Us on FaceBook https://www.facebook.com/CakePHP 
> 
> Follow us on Twitter http://twitter.com/CakePHP 
> --- 
> You received this message because you are subscribed to the Google Groups 
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to cake-php+unsubscr...@googlegroups.com 
> .
> For more options, visit https://groups.google.com/d/optout 
> .
> 

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: How can I get the user firstname displayed, instead of the User_id

2016-04-06 Thread Anja Liebermann

Hi Clement,

if one User can make a lot of proposals you ahve a on to man relation 
here and your proposals table should contain the field user_id (indexed 
of course *g*)
When you the set those relations properly in your models you will get 
the without further tweeking the user data with the proposal and you can 
display the name.


As long as you have only 4 tables the containable behaviour will not 
beof interest for you. It is useful, when you have man connected models 
and want one information down the chain without fetching a lot of unused 
stuff. But in your case you will not need it.


Since you seem to be in the early stage of your app I would advise you 
like heavykey to set up your database like you want and bake everything 
from your cake console ( I hope you have a mac or Linux system. With 
Windows the cake console is nasty to use) . After baking you will have a 
set of models, Controllers and views, which will give you a good 
starting point for further development. That works with 2.8, too.


Although if you are just starting with your app, then I would advise you 
to start with CakePhp 3.x right away.


Anja



Am 05.04.2016 um 13:04 schrieb Clement Crownrise:

Thanks for your response, do you mean i should create a relationship
between the proposal and the user table?

will creating a proposal "belongs to user AND a User has many Proposal",
fix this problem?

As for containable behavior, please what do you mean ?


Your quick response would be appreciated.


Thanks

On Mon, Apr 4, 2016 at 5:54 PM, Anja Liebermann 
wrote:


In your controller you have to fetch the user together with you proposal.
To achieve this check the following:

Check in Models your connection between proposal to user. Is it set in
both directions?

Check your find statement in the Controller Probably ProposalsController.
To which depth do you fetch the data? Do you use Containable Behaviour? If
yes you have to do some tweeks there.

Without your code I can give you no better advise, but at least you know
now where to check and whch code snippets to post to get qualified answers.

Anja



Am 04.04.2016 um 16:01 schrieb Clement Crownrise:


Note that this is my DB relationship, a user has one profile, and the
proposal table has a User_id colomn, however the profile table is the one
that contains the user's firstname.

Can someone help me please?



--
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have
something better coming. Stay tuned for an updated from the CakePHP Team
soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- You received this message because you are subscribed to a topic in the
Google Groups "CakePHP" group.
To unsubscribe from this topic, visit
https://groups.google.com/d/topic/cake-php/EAZoK3CB30Y/unsubscribe.
To unsubscribe from this group and all its topics, send an email to
cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.







--
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups "CakePHP" group.

To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: How can I get the user firstname displayed, instead of the User_id

2016-04-05 Thread Clement Crownrise
*How many tables do you have? *1 table for users, another for profile,
another for proposal, another for comment, making 4 in total

*And if a first name is a property of a user, why would you put it in the
profiles table and not in the users? *
Users table is tied to profile table, a profile belongs to a user. There is
a relationship between the user and profile tables

*Which version of Cake are you using?*
Cake2.8

*If I understand you correctly, you are saying you have a user that has a
profile and a user has many proposals., *
I am yet to create the association between profile and proposal, I only
have relationship between user and profile.

Thanks

If that is the case, I suggest you design the Db first, then bake the 3
models using the bake console, and then adjust the profile relationship
making sure that it is a HasOne relationship as specified in the
documentation.

If you are using Cake 3  edit each of the table files and pick an
appropriate column as the display:
$this->displayField('username');

This is the field that will be shown in select boxes when using find('list')

In your controller where you use the tables you can contain the other
relationships (if they are set up in the table.php) like as follows:
in the Users controller, the Users Table is loaded automatically so you can
reference it through $this->Users
The call you will need to make to search for more than 1 user will be the
find('all'):
$users = $this->Users->find('all', ['contain'=>['Profiles', 'Proposals']]);
For a single user, call the get method with the id of the user:
$user = $this->Users->get($id, ['contain'=>['Profiles', 'Proposals']]);

Once you have contained the other tables you can reference the fields as
follows:
$user->first_name;
$user->profile->id;
$user->proposal->id;

Hope that helps a little...
Regards,
--Kevin

On Tue, Apr 5, 2016 at 12:38 PM, heavyKevy  wrote:

> How many tables do you have?
> And if a first name is a property of a user, why would you put it in the
> profiles table and not in the users?
> Which version of Cake are you using?
>
> If I understand you correctly, you are saying you have a user that has a
> profile and a user has many proposals.
> If that is the case, I suggest you design the Db first, then bake the 3
> models using the bake console, and then adjust the profile relationship
> making sure that it is a HasOne relationship as specified in the
> documentation.
>
> If you are using Cake 3  edit each of the table files and pick an
> appropriate column as the display:
> $this->displayField('username');
>
> This is the field that will be shown in select boxes when using
> find('list')
>
> In your controller where you use the tables you can contain the other
> relationships (if they are set up in the table.php) like as follows:
> in the Users controller, the Users Table is loaded automatically so you
> can reference it through $this->Users
> The call you will need to make to search for more than 1 user will be the
> find('all'):
> $users = $this->Users->find('all', ['contain'=>['Profiles', 'Proposals']]);
> For a single user, call the get method with the id of the user:
> $user = $this->Users->get($id, ['contain'=>['Profiles', 'Proposals']]);
>
> Once you have contained the other tables you can reference the fields as
> follows:
> $user->first_name;
> $user->profile->id;
> $user->proposal->id;
>
> Hope that helps a little...
> Regards,
> --Kevin
>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to a topic in the
> Google Groups "CakePHP" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/cake-php/EAZoK3CB30Y/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
http://www.clementcrownrise.name/images/nameing.gif

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: How can I get the user firstname displayed, instead of the User_id

2016-04-05 Thread heavyKevy
How many tables do you have?
And if a first name is a property of a user, why would you put it in the 
profiles table and not in the users?
Which version of Cake are you using?

If I understand you correctly, you are saying you have a user that has a 
profile and a user has many proposals.
If that is the case, I suggest you design the Db first, then bake the 3 
models using the bake console, and then adjust the profile relationship 
making sure that it is a HasOne relationship as specified in the 
documentation.

If you are using Cake 3  edit each of the table files and pick an 
appropriate column as the display:
$this->displayField('username');

This is the field that will be shown in select boxes when using find('list')

In your controller where you use the tables you can contain the other 
relationships (if they are set up in the table.php) like as follows:
in the Users controller, the Users Table is loaded automatically so you can 
reference it through $this->Users
The call you will need to make to search for more than 1 user will be the 
find('all'):
$users = $this->Users->find('all', ['contain'=>['Profiles', 'Proposals']]);
For a single user, call the get method with the id of the user:
$user = $this->Users->get($id, ['contain'=>['Profiles', 'Proposals']]);

Once you have contained the other tables you can reference the fields as 
follows:
$user->first_name;
$user->profile->id;
$user->proposal->id;

Hope that helps a little...
Regards,
--Kevin

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: How can I get the user firstname displayed, instead of the User_id

2016-04-05 Thread Clement Crownrise
Thanks for your response, do you mean i should create a relationship
between the proposal and the user table?

will creating a proposal "belongs to user AND a User has many Proposal",
fix this problem?

As for containable behavior, please what do you mean ?


Your quick response would be appreciated.


Thanks

On Mon, Apr 4, 2016 at 5:54 PM, Anja Liebermann 
wrote:

> In your controller you have to fetch the user together with you proposal.
> To achieve this check the following:
>
> Check in Models your connection between proposal to user. Is it set in
> both directions?
>
> Check your find statement in the Controller Probably ProposalsController.
> To which depth do you fetch the data? Do you use Containable Behaviour? If
> yes you have to do some tweeks there.
>
> Without your code I can give you no better advise, but at least you know
> now where to check and whch code snippets to post to get qualified answers.
>
> Anja
>
>
>
> Am 04.04.2016 um 16:01 schrieb Clement Crownrise:
>
>> Note that this is my DB relationship, a user has one profile, and the
>> proposal table has a User_id colomn, however the profile table is the one
>> that contains the user's firstname.
>>
>> Can someone help me please?
>>
>>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> --- You received this message because you are subscribed to a topic in the
> Google Groups "CakePHP" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/cake-php/EAZoK3CB30Y/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
http://www.clementcrownrise.name/images/nameing.gif

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: How can I get the user firstname displayed, instead of the User_id

2016-04-04 Thread Anja Liebermann

In your controller you have to fetch the user together with you proposal.
To achieve this check the following:

Check in Models your connection between proposal to user. Is it set in 
both directions?


Check your find statement in the Controller Probably 
ProposalsController. To which depth do you fetch the data? Do you use 
Containable Behaviour? If yes you have to do some tweeks there.


Without your code I can give you no better advise, but at least you know 
now where to check and whch code snippets to post to get qualified answers.


Anja



Am 04.04.2016 um 16:01 schrieb Clement Crownrise:

Note that this is my DB relationship, a user has one profile, and the
proposal table has a User_id colomn, however the profile table is the one
that contains the user's firstname.

Can someone help me please?



--
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups "CakePHP" group.

To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Carregar endereço a partir do CEP no CakePHP 3 usando AJAX

2016-04-04 Thread Paulo Terra
Ok Diego, obrigado. Vou dar uma olhada. Abs!
Em 04/04/2016 11:52, "Diego Mendonça"  escreveu:

> Eu utilizo esse aqui: https://viacep.com.br/ no próprio site tem um
> tutorial de como fazer com JS
>
> --
> Diego Mendonça
> meadiciona.com/diego182
> vamosfugir.net
>
> On Sun, Apr 3, 2016 at 7:59 PM, Paulo Terra  wrote:
>
>> Sim, mas existem outros webservices confiáveis também.
>>
>> Em sábado, 2 de abril de 2016 20:06:03 UTC-3, Nilson Pena escreveu:
>>>
>>> O correio disponibiliza algum webservice gratuito?
>>>
>>> Em sábado, 2 de abril de 2016, Paulo Terra  escreveu:
>>>
 Estou tentando carregar o endereço a partir do CEP informado pelo
 usuário. Apesar de encontrar várias pessoas perguntando por isso não
 encontro uma resposta que funcione. Alguém já fez isso no CakePHP 3?

 --
 Sign up for our Newsletter for updates.
 http://cakephp.org/newsletter/signup

 We will soon be closing this Google Group. But don't worry, we have
 something better coming. Stay tuned for an updated from the CakePHP Team
 soon.

 Like Us on FaceBook https://www.facebook.com/CakePHP
 Follow us on Twitter http://twitter.com/CakePHP
 ---
 You received this message because you are subscribed to the Google
 Groups "CakePHP" group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to cake-php+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.

>>> --
>> Sign up for our Newsletter for updates.
>> http://cakephp.org/newsletter/signup
>>
>> We will soon be closing this Google Group. But don't worry, we have
>> something better coming. Stay tuned for an updated from the CakePHP Team
>> soon.
>>
>> Like Us on FaceBook https://www.facebook.com/CakePHP
>> Follow us on Twitter http://twitter.com/CakePHP
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "CakePHP" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to cake-php+unsubscr...@googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
>>
>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to a topic in the
> Google Groups "CakePHP" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/cake-php/nfmu-j5wiH8/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Carregar endereço a partir do CEP no CakePHP 3 usando AJAX

2016-04-04 Thread Diego Mendonça
Eu utilizo esse aqui: https://viacep.com.br/ no próprio site tem um
tutorial de como fazer com JS

--
Diego Mendonça
meadiciona.com/diego182
vamosfugir.net

On Sun, Apr 3, 2016 at 7:59 PM, Paulo Terra  wrote:

> Sim, mas existem outros webservices confiáveis também.
>
> Em sábado, 2 de abril de 2016 20:06:03 UTC-3, Nilson Pena escreveu:
>>
>> O correio disponibiliza algum webservice gratuito?
>>
>> Em sábado, 2 de abril de 2016, Paulo Terra  escreveu:
>>
>>> Estou tentando carregar o endereço a partir do CEP informado pelo
>>> usuário. Apesar de encontrar várias pessoas perguntando por isso não
>>> encontro uma resposta que funcione. Alguém já fez isso no CakePHP 3?
>>>
>>> --
>>> Sign up for our Newsletter for updates.
>>> http://cakephp.org/newsletter/signup
>>>
>>> We will soon be closing this Google Group. But don't worry, we have
>>> something better coming. Stay tuned for an updated from the CakePHP Team
>>> soon.
>>>
>>> Like Us on FaceBook https://www.facebook.com/CakePHP
>>> Follow us on Twitter http://twitter.com/CakePHP
>>> ---
>>> You received this message because you are subscribed to the Google
>>> Groups "CakePHP" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to cake-php+unsubscr...@googlegroups.com.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Carregar endereço a partir do CEP no CakePHP 3 usando AJAX

2016-04-03 Thread Paulo Terra
Sim, mas existem outros webservices confiáveis também.

Em sábado, 2 de abril de 2016 20:06:03 UTC-3, Nilson Pena escreveu:
>
> O correio disponibiliza algum webservice gratuito?
>
> Em sábado, 2 de abril de 2016, Paulo Terra > 
> escreveu:
>
>> Estou tentando carregar o endereço a partir do CEP informado pelo 
>> usuário. Apesar de encontrar várias pessoas perguntando por isso não 
>> encontro uma resposta que funcione. Alguém já fez isso no CakePHP 3?
>>
>> -- 
>> Sign up for our Newsletter for updates.
>> http://cakephp.org/newsletter/signup
>>  
>> We will soon be closing this Google Group. But don't worry, we have 
>> something better coming. Stay tuned for an updated from the CakePHP Team 
>> soon.
>>  
>> Like Us on FaceBook https://www.facebook.com/CakePHP
>> Follow us on Twitter http://twitter.com/CakePHP
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "CakePHP" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to cake-php+unsubscr...@googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
>>
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Carregar endereço a partir do CEP no CakePHP 3 usando AJAX

2016-04-03 Thread Paulo Terra
Oi Fabricio, obrigado pela resposta. Minha dificuldade maior é fazer a 
requisição Ajax. Apesar de ler a documentação e consultar alguns exemplos 
daqui do forum, nada funcionou.

Em sábado, 2 de abril de 2016 19:43:43 UTC-3, Fabrício Muniz escreveu:
>
> Qual a dificuldade?
>
> 2016-04-02 18:09 GMT-03:00 Paulo Terra >:
>
>> Estou tentando carregar o endereço a partir do CEP informado pelo 
>> usuário. Apesar de encontrar várias pessoas perguntando por isso não 
>> encontro uma resposta que funcione. Alguém já fez isso no CakePHP 3?
>>
>> -- 
>> Sign up for our Newsletter for updates.
>> http://cakephp.org/newsletter/signup
>>  
>> We will soon be closing this Google Group. But don't worry, we have 
>> something better coming. Stay tuned for an updated from the CakePHP Team 
>> soon.
>>  
>> Like Us on FaceBook https://www.facebook.com/CakePHP
>> Follow us on Twitter http://twitter.com/CakePHP
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "CakePHP" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to cake-php+u...@googlegroups.com .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Carregar endereço a partir do CEP no CakePHP 3 usando AJAX

2016-04-02 Thread Nilson Pena
O correio disponibiliza algum webservice gratuito?

Em sábado, 2 de abril de 2016, Paulo Terra  escreveu:

> Estou tentando carregar o endereço a partir do CEP informado pelo usuário.
> Apesar de encontrar várias pessoas perguntando por isso não encontro uma
> resposta que funcione. Alguém já fez isso no CakePHP 3?
>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Carregar endereço a partir do CEP no CakePHP 3 usando AJAX

2016-04-02 Thread Fabrício Muniz
Qual a dificuldade?

2016-04-02 18:09 GMT-03:00 Paulo Terra :

> Estou tentando carregar o endereço a partir do CEP informado pelo usuário.
> Apesar de encontrar várias pessoas perguntando por isso não encontro uma
> resposta que funcione. Alguém já fez isso no CakePHP 3?
>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Replacement Date Widget

2016-04-01 Thread euromark
Side-note:
A lot of browsers still do not fully support that. Make sure that you at 
least provide a shim/fallback for those.

Mark



Am Donnerstag, 31. März 2016 02:32:39 UTC+2 schrieb Justin Harrison:
>
> I would like to replace the default date widget in CakePHP3 with the HTML5 
> date tag. I would have thought that was quite straight forward but have hit 
> a dead end each time.
> Does anyone have any example code that works here?
>
> Justin
>
>
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Help me design the database structure

2016-04-01 Thread mike karthauser
information about google docs can be found in their support section.
http://lmgtfy.com/?q=google+docs+version+control

On Fri, Apr 1, 2016 at 1:55 PM, Clement Crownrise <
clementcrownr...@gmail.com> wrote:

> @Mike, does google has this type of feature? please do enlighten me the
> more
>
> On Fri, Apr 1, 2016 at 1:51 PM, mike karthauser 
> wrote:
>
>> probably best to look at something like google docs which already has
>> this functionality before you start building something from scratch to
>> handle this.
>>
>> --
>> Sign up for our Newsletter for updates.
>> http://cakephp.org/newsletter/signup
>>
>> We will soon be closing this Google Group. But don't worry, we have
>> something better coming. Stay tuned for an updated from the CakePHP Team
>> soon.
>>
>> Like Us on FaceBook https://www.facebook.com/CakePHP
>> Follow us on Twitter http://twitter.com/CakePHP
>> ---
>> You received this message because you are subscribed to a topic in the
>> Google Groups "CakePHP" group.
>> To unsubscribe from this topic, visit
>> https://groups.google.com/d/topic/cake-php/mKJ3a07u1wg/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to
>> cake-php+unsubscr...@googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> --
> http://www.clementcrownrise.name/images/nameing.gif
>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Help me design the database structure

2016-04-01 Thread Clement Crownrise
@Mike, does google has this type of feature? please do enlighten me the more

On Fri, Apr 1, 2016 at 1:51 PM, mike karthauser 
wrote:

> probably best to look at something like google docs which already has this
> functionality before you start building something from scratch to handle
> this.
>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to a topic in the
> Google Groups "CakePHP" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/cake-php/mKJ3a07u1wg/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
http://www.clementcrownrise.name/images/nameing.gif

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Help me design the database structure

2016-04-01 Thread mike karthauser
probably best to look at something like google docs which already has this
functionality before you start building something from scratch to handle
this.

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Looking for an experienced CakePHP developer

2016-03-30 Thread Clement Crownrise
You can contact me, 

On Wednesday, March 23, 2016 at 8:27:53 PM UTC+1, majna wrote:
>
> Hi,
>
> I'm looking for an experienced CakePHP 2.x developer, freelance, remote, 
> long-term.
> Please LMK if you know somebody.
>
> Thanks!
> majna
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Cakephp 3.2.5] Cannot match provided foreignKey

2016-03-28 Thread 'Manuel Maurer' via CakePHP
Argh, what a stupid mistake

Not sure why I forgot to add primary indices, but adding them did the 
trick. Not a very helpful error message though.

Thanks for the help!

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: CakePHP 3 Role Authorization for controllers and methods

2016-03-27 Thread euromark
I use https://github.com/dereuromark/cakephp-tinyauth to exactly prevent 
this complicated if/switch statement logic from happening all over the 
controllers ;)
One simple to configure ini file, done.
Mark


Am Sonntag, 27. März 2016 11:43:31 UTC+2 schrieb LSRX4EVER:
>
> Hello Everyone,
>
> I'm a beginner CakePHP 3 developer. I learned fairly quick for my skill 
> level. 
> I'm currently working on a management system for a school, where there 
> will be a couple of roles that will only access specific controller 
> functions. (Student, Instructor, Supervisor, Administrator)
> HOWEVER, each user has a user state that I must validate and set 
> permission temporarily for users
> Example:
>
> Active User
> LoginEnter code here...
> Redirected to their role controller, with only access to those methods in 
> that controller
>
> Inactive User (used for setup)
> Login
> Confirm Account Information
> only aloud to access that setup() action
> once confirmed, it will set the user active and log them out
>
> Disabled User
> Is disabled, unauthorized user. Already have that configured
>
>
> My login function looks like:
> public function login()
> {
> $this->viewBuilder()->layout('login'); 
> if($this->Auth->user()){
> return $this->redirect(['controller'=>'Users','action'=>'index']); //index 
> redirect for now
> } else {
> if($this->request->is('post')){
> $user = $this->Auth->identify();
> $login_error=null;
> if($user){
> $session = $this->request->session(); 
> switch($user['user_status']){
> case '1': //Active - Normal Login
> unset($user['created'], $user['expiration'], $user['user_status'], 
> $user['security_question_answer'], $user['security_question_id'], 
> $user['modified']);
> $userid=$user['id'];
> //$user= array_merge($user, array('Roles' => 
> $this->Users->Roles->find('list', ['order' => ['Roles.role_id' => 
> 'ASC']])->matching('Users', function ($q) use ($userid) {return 
> $q->where(['Users.id' => $userid]);})->toArray()));
> $user = array_merge($user, 
> array('role'=>key($this->Users->Roles->find('list', ['order' => 
> ['Roles.role_id' => 'ASC']])->select(['Roles.role_id'])->matching('Users', 
> function ($q) use ($userid) { return $q->where(['Users.id' => 
> $userid]);})->limit(1)->toArray(;
> $user = array_merge($user, array('user_status' => 1));
> $this->Auth->setUser($user);
> return $this->redirect($this->Auth->redirectUrl('/users/index'));
> break;
> case '2': //Disabled 
> $login_error=1;
> $this->set(compact('login_error'));
> break;
> case '3': //Inactive - Redirect to setup method
> unset($user['created'], $user['expiration'], $user['user_status'], 
> $user['security_question_answer'], $user['security_question_id'], 
> $user['modified']);
> $userid=$user['id'];
> //$user= array_merge($user, array('roles' => 
> $this->Users->Roles->find('list', ['order' => ['Roles.role_id' => 
> 'ASC']])->matching('Users', function ($q) use ($userid) {return 
> $q->where(['Users.id' => $userid]);})->toArray()));
> $user = array_merge($user, 
> array('role'=>key($this->Users->Roles->find('list', ['order' => 
> ['Roles.role_id' => 'ASC']])->select(['Roles.role_id'])->matching('Users', 
> function ($q) use ($userid) { return $q->where(['Users.id' => 
> $userid]);})->limit(1)->toArray()), 'status' => 3));
> $this->Auth->setUser($user); //Auth Role to only allow inactive user 
> privilage to login, recovery and setup?
> /*this isnt right*/ return 
> $this->redirect($this->Auth->redirectUrl('/users/setup'));
> break;
> }
> } 
> if($login_error!=1){
> $login_error=0;
> };
> $this->set(compact('login_error'));
> }
> }
> }
>
> My AppController BeforeFilter looks like:
> public function beforeFilter(Event $event)
> {
> $this->Auth->allow(['/users/login', '/users/recovery']);
> /*
> switch(user_status){
> case 'Active'
> switch(role){
> case 'Student'
> allow student controller methods
> break;
> case 'Supervisor'
> allow supervisor controller methods
> break;
> case 'Instructor'
> allow instructor controller methods
> break;
> case 'Administrator'
> allow administrator controller methods
> break;
> }
> deny login and recovery methods
> break;
> case 'Inactive'
> allow setup and logout methods
> deny login and recovery methods
> break;
> default:
> allow login and recovery methods
> break;
> }
> */
> }
>
>
> I have looked at some things, I am running a basic authentication system 
> and I heard of Access Control Lists (ACL), but its seemed quite intricate 
> and I don't want to spend a week trying to figure something out that's far 
> from my reach.
>
> Any suggestions how to accomplish this?
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePH

Re: [Cakephp 3.2.5] Cannot match provided foreignKey

2016-03-25 Thread heavyKevy

>
> In addition to the other reply, i recommend that you use the bake utility 
> to bake your models so that all of the needed files are created along with 
> the correct syntax.
>

from a dos command prompt, cd to your application folder that contains your 
bin and src folders and issue the following commands:
bin\cake bake model Users
bin\cake bake model Articles

in addition, you may want to bake your controllers and templates but make 
sure you don't overwrite any code that you have already written there...
With your tables created correctly and the code baked everything should 
work as expected.

regards,
--Kevin

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: CakePHP 3 + MSSQL = slow query

2016-03-25 Thread heavyKevy
Is there any reason you are not paging it and fetching only 20, or 50 or 
100 records at a time?  That would significantly speed things up for you...
Regards,
--Kevin

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Cakephp 3.2.5] Cannot match provided foreignKey

2016-03-24 Thread Gaurav Kumar
Hello Manuel,

In your tables there is no PRIMARY KEY defined. So, your tables should look 
like this

CREATE TABLE `articles` (
  `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `title` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `user_id` bigint(20) unsigned NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci 
AUTO_INCREMENT=1 ;

CREATE TABLE `users` (
  `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `name` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci 
AUTO_INCREMENT=1 ;

and then your issue will be resolve.

On Thursday, March 24, 2016 at 3:43:58 PM UTC+5:30, Manuel Maurer wrote:
>
> Hello,
>
> I am trying to upgrade some of my applications from Cake 2 to 3. To get 
> used to the new version I tried a few simple things and for some strange 
> reason I cannot get Associations to run...
>
> In my mysql database I have two simple tables:
>
> CREATE TABLE `articles` (
>   `id` bigint(20) UNSIGNED NOT NULL,
>   `title` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
>   `user_id` bigint(20) UNSIGNED NOT NULL
> ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
>
> CREATE TABLE `users` (
>   `id` bigint(20) UNSIGNED NOT NULL,
>   `name` varchar(100) COLLATE utf8_unicode_ci NOT NULL
> ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
>
> In a fresh copy of Cakephp 3.2.5 I added 3 files:
>
> *src/Model/Table/UsersTable.php:*
>
>  namespace App\Model\Table;
> use Cake\ORM\Table;
>
> class UsersTable extends Table
> {
> public function initialize(array $config){
> }
> }
>
>
> *src/Model/Table/ArticlesTable.php:*
>  namespace App\Model\Table;
> use Cake\ORM\Table;
>
> class ArticlesTable extends Table
> {
> public function initialize(array $config){
> $this->belongsTo('Users');
> }
> }
>
>
> *src/Controller/ArticlesController.php:*
>  namespace App\Controller;
>
> class ArticlesController extends AppController 
> {
> public function index(){
> $tmp = $this->Articles->find('all')->contain(['Users']);
> var_dump($tmp);
> exit;
> }
> }
>
> My development system is running MariaDB 10.0.15 and PHP 7.0.4 on W7.
>
> Finally I fire up http://test/articles and get this error:
> * Cannot match provided foreignKey for "Users", got "(user_id)" but 
> expected foreign key for "()" *
>
>
> The last item in the stack trace is this:
>
> Cake\ORM\Association\BelongsTo->_joinCondition 
> CORE\src\ORM\Association.php, line 557
>
>
> On the right hand side I get 
> cakephp-3-2-5\vendor\cakephp\cakephp\src\ORM\Association.php:
>
> 'finder' => $this->finder()
> ];
> 
> if (!empty($options['foreignKey'])) {
> $joinCondition = $this->_joinCondition($options);
> if ($joinCondition) {
> $options['conditions'][] = $joinCondition;
> }
> }
>
>
> And in the arguments table:
>
> [
>   'aliasPath' => 'Users',
>   'propertyPath' => 'user',
>   'includeFields' => true,
>   'foreignKey' => 'user_id',
>   'conditions' => [],
>   'fields' => [],
>   'type' => 'LEFT',
>   'table' => 'users',
>   'finder' => 'all'
> ]
>
>
> As a test I added a foreign key constraint to the database:
>
>
> ALTER 
> 
>  
> TABLE 
> 
>  
> `articles` ADD FOREIGN KEY (`user_id`) REFERENCES `users`(`id`) ON DELETE 
> 
>  
> RESTRICT ON UPDATE 
> 
>  
> RESTRICT;
>
>
> However, that did not have any effects (not that I expected any).
>
> I also tried to specify the foreignKey, className etc. on the association, 
> no change there. I even downgraded to php 5.6 on my linux dev box, that 
> didn't help either.
>
>
> Any suggestions?
>
>
> Best regards,
>
> Manuel
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Cakephp 2.8.1] Multiple assosication to one model with habtm throws a notice

2016-03-24 Thread 'Steffen Reinig' via CakePHP
Hi,

i checked your solution, but it occurs the same error.

public $hasAndBelongsToMany = array (
'Owners' => array (
'className' => 'User',
'with' => 'PermissionOwner',
),
'Rights' => array (
'className' => 'User',
'with' => 'PermissionRight',
)
);

*Notice* (8): Undefined index: User 
[*CORE\Cake\Model\Datasource\DboSource.php*, line *1388*]




On Monday, March 14, 2016 at 8:29:13 PM UTC+1, John Andersen wrote:
>
> Check your model names in the HABTM relationships. Looks like you have a 
> mix of singular and plural.
> Enjoy, John
>
> On Monday, 14 March 2016 05:33:36 UTC+2, Steffen Reinig wrote:
>>
>> Hello Cakephp Fans,
>>
>> today i receive these error: 
>>
>> Notice (8): Undefined index: User [CORE\Cake\Model\Datasource\DboSource.php, 
>> line 1388]
>>
>> Its easy to reproduce:
>>
>> Model: User belongsTo Group
>> Model: Permission habtm Rights (className User)
>>Permission habtm Owners (className User)
>>
>> When i use now 
>> $this->Permission->find('all', array('recursive' => -2)); 
>>
>> the notice will be thrown. But only for the 2nd habtm.
>>
>> The output is like:
>>
>> array(
>> 'Permission' => array(
>> 'id' => '6',
>> ),
>> 'Owner' => array(
>> (int) 0 => array(
>> 'id' => '499',
>> 'PermissionOwner' => array(
>> 'id' => '6',
>> 'user_id' => '499',
>> 'permission_id' => '6'
>> )
>> )
>> ),
>> 'Rights' => array(
>> (int) 0 => array(
>> 'id' => '485',
>> 'PermissionRight' => array(
>> 'id' => '18',
>> 'permission_id' => '6',
>> 'user_id' => '485',
>> ),
>> 'Group' => array()
>> ),
>> (int) 1 => array(
>> 'id' => '124',
>> 'PermissionRight''id' => '19',
>> 'permission_id' => '6',
>> 'user_id' => '124',
>> ),
>> 'Group' => array()
>> )
>> )
>> )
>>
>>
>>
>>
>> Kind Regards
>>
>>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Looking for an experienced CakePHP developer

2016-03-23 Thread 'zhaff' via CakePHP
Hi,

I have sent you an email. Please find my CakePHP 2.x works here 
http://neptunescripts.com

Best regards,
Zhaff

On Thursday, March 24, 2016 at 3:27:53 AM UTC+8, majna wrote:
>
> Hi,
>
> I'm looking for an experienced CakePHP 2.x developer, freelance, remote, 
> long-term.
> Please LMK if you know somebody.
>
> Thanks!
> majna
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Looking for an experienced CakePHP developer

2016-03-23 Thread Fabian Olmos
Hi,

I can help  you
El 23/3/2016 16:28, "majna"  escribió:

> Hi,
>
> I'm looking for an experienced CakePHP 2.x developer, freelance, remote,
> long-term.
> Please LMK if you know somebody.
>
> Thanks!
> majna
>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Looking for an experienced CakePHP developer

2016-03-23 Thread abdessamad kassasse
maybe i can help U

2016-03-23 20:27 GMT+01:00 majna :

> Hi,
>
> I'm looking for an experienced CakePHP 2.x developer, freelance, remote,
> long-term.
> Please LMK if you know somebody.
>
> Thanks!
> majna
>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: php requirements for 3.X

2016-03-22 Thread Andras Kende
Hello Mike,

5.5.31 is greater than 5.5.5.9 so it  will work fine.

http://book.cakephp.org/3.0/en/installation.html#requirements
• PHP 5.5.9 or greater (including PHP 7).



Andras


> On Mar 22, 2016, at 5:55 PM, MikeK  wrote:
> 
> Thanks for your eloquent reply - HOWEVER the latest stable release of php 5.5 
> is 5.5.31 - there is no 5.5.9 as the "requirements" call for. Does anyone 
> really know what cakephp3 REALLY requires?
> 
> 
> 
> -- 
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>  
> We will soon be closing this Google Group. But don't worry, we have something 
> better coming. Stay tuned for an updated from the CakePHP Team soon.
>  
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> --- 
> You received this message because you are subscribed to the Google Groups 
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: php requirements for 3.X

2016-03-22 Thread MikeK
Thanks for your eloquent reply - HOWEVER the latest stable release 
of php 5.5 is 5.5.31 - there is no 5.5.9 as the "requirements" call for. 
Does anyone really know what cakephp3 REALLY requires?


-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: How to set a variable and use everywhere?

2016-03-19 Thread Gaurav Kumar
1. If you need to use that variable in controllers then you can set it in 
the beforeFilter and if you need to access the variable in views then 
beforeRender both you have to do in AppController.

2. Please follow this http://book.cakephp.org/3.0/en/views.html

On Thursday, March 17, 2016 at 10:26:13 AM UTC+5:30, Attachai Saorangtoi 
wrote:
>
> *1. How to set a variable and use everywhere?*
>  
> *2.How to send a variable to Layout and Element?*
>
>
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: php requirements for 3.X

2016-03-18 Thread euromark
The requirement *is* a requirement.


Am Freitag, 18. März 2016 14:32:03 UTC+1 schrieb MikeK:
>
> Am migrating to 3.2 from cakephp 2.x, but my host only offers php 5.4 - I 
> saw the install requirements want 5.5.9
>
> Should I find another host or will 3.2 operate OK on 5.4?
>
> Thanks in advance and sorry if this is a dup - could not find an answer by 
> search.
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Storing encrypted value using getter/setter not working. Stored in plain text.

2016-03-16 Thread Willem
Eventually i changed it to a varbinary(65000) column and it started to 
work. In Cakephp 2 it worked with a varchar column. now it needs to be 
binary in 3 and have enough space.

On Wednesday, March 16, 2016 at 10:19:38 AM UTC+1, heavyKevy wrote:
>
> I hate to state the obvious, but did you verify that the field size was 
> large enough to store the encrypted value?
> I had a similar issue with hashing a password, the field wasn't large 
> enough and the value was saved but cut off so that the password never 
> matched.
> Maybe try it with the max varchar size and see if it will work.
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Storing encrypted value using getter/setter not working. Stored in plain text.

2016-03-16 Thread heavyKevy
I hate to state the obvious, but did you verify that the field size was 
large enough to store the encrypted value?
I had a similar issue with hashing a password, the field wasn't large 
enough and the value was saved but cut off so that the password never 
matched.
Maybe try it with the max varchar size and see if it will work.

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Storing encrypted value using getter/setter not working. Stored in plain text.

2016-03-15 Thread Willem Schwarte
I have already tried to change it to text. This had the same effect. I also 
cleared the caches/orm cAche when intested this. 



> Op 16 mrt. 2016 om 00:12 heeft Christian Quispe  
> het volgende geschreven:
> 
> Cambia tu field de tu base de datos a text, es posible que tu cadena 
> codificada no se guarde completamente.
> 
> 
> 
> Enviado con MailTrack
> 
> 
> Saludos
> 
> Christian Quispe
> 
> Geek and Developer
> Miembro:  GDG Lima (Google Developer Group Lima)
> 
> Portafolio: www.oxicode.io
> 
> ¿A quién le enseñan sus aciertos?, si yo aprendo de mis errores 
> constantemente...
> 
> 
> 2016-03-15 13:46 GMT-05:00 Willem :
>> saving to the database cuts off the encrypted data. varchar(255) and text 
>> fields both have this issue.. 
>> is this a bug in CakePHP
>> -- 
>> Sign up for our Newsletter for updates.
>> http://cakephp.org/newsletter/signup
>>  
>> We will soon be closing this Google Group. But don't worry, we have 
>> something better coming. Stay tuned for an updated from the CakePHP Team 
>> soon.
>>  
>> Like Us on FaceBook https://www.facebook.com/CakePHP
>> Follow us on Twitter http://twitter.com/CakePHP
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "CakePHP" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to cake-php+unsubscr...@googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
> 
> -- 
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>  
> We will soon be closing this Google Group. But don't worry, we have something 
> better coming. Stay tuned for an updated from the CakePHP Team soon.
>  
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> --- 
> You received this message because you are subscribed to the Google Groups 
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Storing encrypted value using getter/setter not working. Stored in plain text.

2016-03-15 Thread Christian Quispe
Cambia tu field de tu base de datos a text, es posible que tu cadena
codificada no se guarde completamente.



Enviado con MailTrack


Saludos

Christian Quispe

*Geek and Developer*
*Miembro: * *GDG Lima (Google Developer Group Lima)*

*Portafolio: www.oxicode.io
*

*¿A quién le enseñan sus aciertos?, si yo aprendo de mis errores
constantemente...*


2016-03-15 13:46 GMT-05:00 Willem :

> *saving to the database cuts off the encrypted data. varchar(255) and text
> fields both have this issue.. *
> *is this a bug in CakePHP*
>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Storing encrypted value using getter/setter not working. Stored in plain text.

2016-03-15 Thread Willem
*saving to the database cuts off the encrypted data. varchar(255) and text 
fields both have this issue.. *
*is this a bug in CakePHP*

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Storing encrypted value using getter/setter not working. Stored in plain text.

2016-03-15 Thread Willem
When I try as follows, the value gets stored encryted, but I cannot read it 
as the getDecryptedUsername function returns false at the decrypt line:

protected function _setUsername($username)
{
 $key = 'wt1U5MACWJFTXGenFoZoiLwQGrLgdbHA';
 if(strlen($username) > 0)
 {
 $username = Security::encrypt($username, $key);
 }
 return($username);
}

protected function _getDecryptedUsername()
{
 $key = 'wt1U5MACWJFTXGenFoZoiLwQGrLgdbHA';
 $username = $this->_properties['username'];
 if(strlen($username) > 0)
 {
 $username = Security::decrypt($username, $key);
 }
 return($username);
}

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: how enable identifier quoting???

2016-03-14 Thread euromark
What part 
of https://github.com/cakephp/app/blob/master/config/app.default.php#L237-L245 
is not understandable?

Mark


Am Montag, 14. März 2016 04:34:29 UTC+1 schrieb Leonidas Savvides:
>
> *If you are using SQL keywords as table column names, you can enable 
> identifier quoting for your database connection in config/app.php.*
>
>
> How do this   
>
>
> long (for long, lat) is prohibited as db name of field...? if change to 
> long1 how apply the change in cakePHP? Also how * enable identifier 
> quoting???*
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Cakephp 2.8.1] Multiple assosication to one model with habtm throws a notice

2016-03-14 Thread John Andersen
Check your model names in the HABTM relationships. Looks like you have a 
mix of singular and plural.
Enjoy, John

On Monday, 14 March 2016 05:33:36 UTC+2, Steffen Reinig wrote:
>
> Hello Cakephp Fans,
>
> today i receive these error: 
>
> Notice (8): Undefined index: User [CORE\Cake\Model\Datasource\DboSource.php, 
> line 1388]
>
> Its easy to reproduce:
>
> Model: User belongsTo Group
> Model: Permission habtm Rights (className User)
>Permission habtm Owners (className User)
>
> When i use now 
> $this->Permission->find('all', array('recursive' => -2)); 
>
> the notice will be thrown. But only for the 2nd habtm.
>
> The output is like:
>
> array(
> 'Permission' => array(
> 'id' => '6',
> ),
> 'Owner' => array(
> (int) 0 => array(
> 'id' => '499',
> 'PermissionOwner' => array(
> 'id' => '6',
> 'user_id' => '499',
> 'permission_id' => '6'
> )
> )
> ),
> 'Rights' => array(
> (int) 0 => array(
> 'id' => '485',
> 'PermissionRight' => array(
> 'id' => '18',
> 'permission_id' => '6',
> 'user_id' => '485',
> ),
> 'Group' => array()
> ),
> (int) 1 => array(
> 'id' => '124',
> 'PermissionRight''id' => '19',
> 'permission_id' => '6',
> 'user_id' => '124',
> ),
> 'Group' => array()
> )
> )
> )
>
>
>
>
> Kind Regards
>
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: How to upgrade TLS version in cakePHP

2016-03-14 Thread Борислав Събев Borislav Sabev
This has nothing to do with CakePHP - it is a pure-PHP issue.
Maybe the versions of PHP you use in the CLI (terminal) abd web are 
different? Check which is which and if different see how to configure the 
web-based one.

It really depends on what OS you are running this. Any web application 
could choose a different PHP version (if available on the server) via the 
web server config. For example, if it is Apache, this could change in the 
.htaccess or in the apache config files.

You need to investigate more but one thing is sure - this is not a Cake 
issue.

Hope this helped.
Cheers, Borislav.



On Monday, 14 March 2016 05:33:39 UTC+2, Arun NV wrote:
>
>
> down votefavorite 
> 
>
> I am using *cakePHP2.2.1* and *PHP5.3.10*.And i have updated *curl* and 
> *libcurl* now curl is supporting *TLS 1.2* in *terminal*. But when i am 
> trying to send *curl* request in *cakePHP* it's shows the*TLS* version as 
> *1.1*. Is there anyway to configure *TLS* in *cakePHP*?
>
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: What is the meaning of this error in cakephp 3?

2016-03-14 Thread Clement Crownrise
I forgot to add

use Cake\Validation\Validator;
to the ArticlesTable file,

I also forgot to add

public function beforefilter(Event $event){

To the AppController.php file.

Thanks all

On Mon, Mar 14, 2016 at 12:59 PM, Willem Schwarte 
wrote:

> So what was the problem?
>
> Op 14 mrt. 2016 om 12:43 heeft Clement Crownrise <
> clementcrownr...@gmail.com> het volgende geschreven:
>
> Thanks All, the error has been fixed.
>
>
>
> On Saturday, March 12, 2016 at 10:30:25 AM UTC+1, Clement Crownrise wrote:
>>
>> Hello, I am doing the blog tutorial in cakephp 3, but I got this notice
>> at the top of my page, please does anyone know the meaning and how to solve
>> it?
>>
>> *Strict* (2048): Declaration of App\Controller\AppController::beforefilter() 
>> should be compatible with 
>> Cake\Controller\Controller::beforeFilter(Cake\Event\Event $event) 
>> [*APP/Controller\AppController.php*, line *29*]
>>
>>
>>
>> *Strict* (2048): Declaration of 
>> App\Controller\UsersController::beforefilter() should be compatible with 
>> App\Controller\AppController::beforefilter() 
>> [*APP/Controller\UsersController.php*, line *10*]
>>
>>
>> Your help will be appreciated
>>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to a topic in the
> Google Groups "CakePHP" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/cake-php/qEur8oKsm48/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
http://www.clementcrownrise.name/images/nameing.gif

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: What is the meaning of this error in cakephp 3?

2016-03-14 Thread Willem Schwarte
So what was the problem?

> Op 14 mrt. 2016 om 12:43 heeft Clement Crownrise  
> het volgende geschreven:
> 
> Thanks All, the error has been fixed.
> 
> 
> 
>> On Saturday, March 12, 2016 at 10:30:25 AM UTC+1, Clement Crownrise wrote:
>> Hello, I am doing the blog tutorial in cakephp 3, but I got this notice at 
>> the top of my page, please does anyone know the meaning and how to solve it?
>> 
>> Strict (2048): Declaration of App\Controller\AppController::beforefilter() 
>> should be compatible with 
>> Cake\Controller\Controller::beforeFilter(Cake\Event\Event $event) 
>> [APP/Controller\AppController.php, line 29]
>> 
>> 
>> 
>> Strict (2048): Declaration of App\Controller\UsersController::beforefilter() 
>> should be compatible with App\Controller\AppController::beforefilter() 
>> [APP/Controller\UsersController.php, line 10]
>> 
>> Your help will be appreciated
> 
> -- 
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>  
> We will soon be closing this Google Group. But don't worry, we have something 
> better coming. Stay tuned for an updated from the CakePHP Team soon.
>  
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> --- 
> You received this message because you are subscribed to the Google Groups 
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: What is the meaning of this error in cakephp 3?

2016-03-14 Thread Clement Crownrise
Thanks All, the error has been fixed.



On Saturday, March 12, 2016 at 10:30:25 AM UTC+1, Clement Crownrise wrote:
>
> Hello, I am doing the blog tutorial in cakephp 3, but I got this notice at 
> the top of my page, please does anyone know the meaning and how to solve it?
>
> *Strict* (2048): Declaration of App\Controller\AppController::beforefilter() 
> should be compatible with 
> Cake\Controller\Controller::beforeFilter(Cake\Event\Event $event) 
> [*APP/Controller\AppController.php*, line *29*]
>
>
>
> *Strict* (2048): Declaration of 
> App\Controller\UsersController::beforefilter() should be compatible with 
> App\Controller\AppController::beforefilter() 
> [*APP/Controller\UsersController.php*, line *10*]
>
>
> Your help will be appreciated
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: What is the meaning of this error in cakephp 3?

2016-03-13 Thread Clement Crownrise
Thanks all, these lines of codes are already added to the
UsersController.php

but the error still persists



namespace App\Controller;

use Cake\Event\Event;
use App\Controller\AppController;
use Cake\Network\Exception\NotFoundException;


class UsersController extends AppController{

public function beforefilter(Event $event){
//parent::beforefilter($event);
//$this->Auth->allow(['add','logout']);
return null;
}


On Sun, Mar 13, 2016 at 9:14 AM, Willem Schwarte 
wrote:

> Yes. That should solve it.
>
> - willem
>
> Op 13 mrt. 2016 om 08:42 heeft heavyKevy  het
> volgende geschreven:
>
> You also need to make sure that you add the following line near the top of
> the file after the namespace with the other use statements:
>
> use Cake\Event\Event;
>
> Best regards,
> --Kevin
>
>
> On Sunday, March 13, 2016 at 1:47:10 AM UTC+7, Clement Crownrise wrote:
>>
>> Hi, Thanks Willem,
>>
>> I have tried it, but the error still persists , look at the code below
>>
>>
>> public function beforefilter(Event $event){
>> //parent::beforefilter($event);
>> //$this->Auth->allow(['add','logout']);
>> return null;
>> }
>>
>> On Sat, Mar 12, 2016 at 11:52 AM, Willem Schwarte 
>> wrote:
>>
>>> Just as it says. You need to have the same method signature as the one
>>> you are overriding. Thus:
>>>
>>> public function beforeFilter(Event $event)
>>> {
>>> return null;
>>> }
>>>
>>>
>>> you forgot the parameter.
>>>
>>>
>>> Willem
>>>
>>>
>>>
>>> On 12 Mar 2016, at 10:30, Clement Crownrise 
>>> wrote:
>>>
>>> Hello, I am doing the blog tutorial in cakephp 3, but I got this notice
>>> at the top of my page, please does anyone know the meaning and how to solve
>>> it?
>>>
>>> *Strict* (2048): Declaration of 
>>> App\Controller\AppController::beforefilter() should be compatible with 
>>> Cake\Controller\Controller::beforeFilter(Cake\Event\Event $event) 
>>> [*APP/Controller\AppController.php*, line *29*]
>>>
>>>
>>>
>>> *Strict* (2048): Declaration of 
>>> App\Controller\UsersController::beforefilter() should be compatible with 
>>> App\Controller\AppController::beforefilter() 
>>> [*APP/Controller\UsersController.php*, line *10*]
>>>
>>>
>>> Your help will be appreciated
>>>
>>> --
>>> Sign up for our Newsletter for updates.
>>> http://cakephp.org/newsletter/signup
>>>
>>> We will soon be closing this Google Group. But don't worry, we have
>>> something better coming. Stay tuned for an updated from the CakePHP Team
>>> soon.
>>>
>>> Like Us on FaceBook https://www.facebook.com/CakePHP
>>> Follow us on Twitter http://twitter.com/CakePHP
>>> ---
>>> You received this message because you are subscribed to the Google
>>> Groups "CakePHP" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to cake-php+u...@googlegroups.com.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>>
>>> --
>>> Sign up for our Newsletter for updates.
>>> http://cakephp.org/newsletter/signup
>>>
>>> We will soon be closing this Google Group. But don't worry, we have
>>> something better coming. Stay tuned for an updated from the CakePHP Team
>>> soon.
>>>
>>> Like Us on FaceBook https://www.facebook.com/CakePHP
>>> Follow us on Twitter http://twitter.com/CakePHP
>>> ---
>>> You received this message because you are subscribed to a topic in the
>>> Google Groups "CakePHP" group.
>>> To unsubscribe from this topic, visit
>>> https://groups.google.com/d/topic/cake-php/qEur8oKsm48/unsubscribe.
>>> To unsubscribe from this group and all its topics, send an email to
>>> cake-php+u...@googlegroups.com.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>>
>>
>> --
>> http://www.clementcrownrise.name/images/nameing.gif
>>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to a topic in the
> Google Groups "CakePHP" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/cake-php/qEur8oKsm48/unsubscribe.
> To unsubscr

Re: 3.0 Database Error : SQLSTATE[HY000] [14] unable to open database file

2016-03-13 Thread Leonidas Savvides
*If you are using SQL keywords as table column names, you can enable 
identifier quoting for your database connection in config/app.php.*

how * enable identifier quoting???*


On Monday, September 29, 2014 at 6:43:14 PM UTC+3, Bayezid Alam wrote:
>
> Dear All,
> i am getting the subjected Error for beta-2 of cake3, while first browsing 
> from localhost.
>
> sub-hints:
> If you are using SQL keywords as table column names, you can enable 
> identifier quoting for your database connection in config/app.php. 
>
> *Notice: * If you want to customize this error message, create 
> src/Template/Error/pdo_error.ctp
>
> Stack Trace 
>
>- CORE/src/Database/Driver/PDODriverTrait.php line 44 
> → PDO->__construct(string, null, null, 
>array)  
>- CORE/src/Database/Driver/Sqlite.php line 62 
> → 
>Cake\Database\Driver\Sqlite->_connect(array) 
> 
>- CORE/src/Database/Schema/BaseSchema.php line 44 
> → Cake\Database\Driver\Sqlite->connect() 
> 
>- CORE/src/Database/Dialect/SqliteDialectTrait.php line 163 
> → 
>Cake\Database\Schema\BaseSchema->__construct(Cake\Database\Driver\Sqlite) 
> 
>- CORE/src/Database/Schema/Collection.php line 59 
> → 
>Cake\Database\Driver\Sqlite->schemaDialect() 
> 
>- CORE/src/Database/Connection.php line 288 
> → 
>Cake\Database\Schema\Collection->__construct(Cake\Database\Connection) 
> 
>- ROOT/plugins/DebugKit/src/Model/Table/LazyTableTrait.php line 38 
> → 
>Cake\Database\Connection->schemaCollection() 
> 
>- ROOT/plugins/DebugKit/src/Model/Table/RequestsTable.php line 41 
> → 
>DebugKit\Model\Table\RequestsTable->ensureTables(array) 
> 
>- CORE/src/ORM/Table.php line 231  → 
>DebugKit\Model\Table\RequestsTable->initialize(array) 
> 
>- CORE/src/ORM/TableRegistry.php line 186  
>→ Cake\ORM\Table->__construct(array)  
>- ROOT/plugins/DebugKit/src/Routing/Filter/DebugBarFilter.php line 178 
> → Cake\ORM\TableRegistry::get(string) 
> 
>- CORE/src/Event/EventManager.php line 268  
>→ DebugKit\Routing\Filter\DebugBarFilter->afterDispatch(Cake\Event\Event, 
>Cake\Network\Request, Cake\Network\Response) 
> 
>- CORE/src/Event/EventManager.php line 235  
>→ Cake\Event\EventManager->_callListener(array, Cake\Event\Event) 
> 
>- CORE/src/Event/EventManagerTrait.php line 76 
> → 
>Cake\Event\EventManager->dispatch(Cake\Event\Event) 
> 
>- CORE/src/Routing/Dispatcher.php line 90  
>→ Cake\Routing\Dispatcher->dispatchEvent(string, array) 
> 
>- ROOT/webroot/index.php line 37  → 
> Cake\Routing\Dispatcher->dispatch(Cake\Network\Request, 
>Cake\Network\Response) 
>
>
> Note: i have manually downloaded from 
> https://github.com/cakephp/cakephp/releases/3.0.0-beta2 
>
> Hope it's proper suggestion
>
> Thanks
> Bayezid
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: What is the meaning of this error in cakephp 3?

2016-03-13 Thread Matías Croce

Maybe you forgot the namespace. You should use:

use  Cake\Event\Event;

or

beforeFilter(Cake\Event\Event $event)



On 12/03/16 15:46, Clement Crownrise wrote:

Hi, Thanks Willem,

I have tried it, but the error still persists , look at the code below


public function beforefilter(Event $event){
//parent::beforefilter($event);
//$this->Auth->allow(['add','logout']);
return null;
}

On Sat, Mar 12, 2016 at 11:52 AM, Willem Schwarte > wrote:


Just as it says. You need to have the same method signature as the
one you are overriding. Thus:

public function beforeFilter(Event $event) { return null; }


you forgot the parameter.


Willem




On 12 Mar 2016, at 10:30, Clement Crownrise
mailto:clementcrownr...@gmail.com>>
wrote:

Hello, I am doing the blog tutorial in cakephp 3, but I got this
notice at the top of my page, please does anyone know the meaning
and how to solve it?

*Strict* (2048): Declaration of 
App\Controller\AppController::beforefilter() should be compatible with 
Cake\Controller\Controller::beforeFilter(Cake\Event\Event $event) 
[*APP/Controller\AppController.php*, line*29*]



*Strict* (2048): Declaration of 
App\Controller\UsersController::beforefilter() should be compatible with 
App\Controller\AppController::beforefilter() 
[*APP/Controller\UsersController.php*, line*10*]

Your help will be appreciated

-- 
Sign up for our Newsletter for updates.

http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we
have something better coming. Stay tuned for an updated from the
CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
---
You received this message because you are subscribed to the
Google Groups "CakePHP" group.
To unsubscribe from this group and stop receiving emails from it,
send an email to cake-php+unsubscr...@googlegroups.com
.
For more options, visit https://groups.google.com/d/optout.


-- 
Sign up for our Newsletter for updates.

http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we
have something better coming. Stay tuned for an updated from the
CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
---
You received this message because you are subscribed to a topic in
the Google Groups "CakePHP" group.
To unsubscribe from this topic, visit
https://groups.google.com/d/topic/cake-php/qEur8oKsm48/unsubscribe.
To unsubscribe from this group and all its topics, send an email
to cake-php+unsubscr...@googlegroups.com
.
For more options, visit https://groups.google.com/d/optout.




--
http://www.clementcrownrise.name/images/nameing.gif
--
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have 
something better coming. Stay tuned for an updated from the CakePHP 
Team soon.


Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
---
You received this message because you are subscribed to the Google 
Groups "CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send 
an email to cake-php+unsubscr...@googlegroups.com 
.

For more options, visit https://groups.google.com/d/optout.


--
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups "CakePHP" group.

To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Cakephp 2.x Receive emails into the application...

2016-03-13 Thread euromark
This might help you
https://github.com/barbushin/php-imap


Am Samstag, 12. März 2016 01:31:18 UTC+1 schrieb April DeRossett:
>
> Ahoy!  I am looking for a way to receive reply emails into my cakephp 
> application and after a ton of research I haven't yet figured out how to 
> make that happen.  Pretend I am an awesome PHP and MySQL programmer but, 
> that I know Nothing about managing an email server.  Does anyone know of a 
> great tutorial or read that would help me get started?  Thanks in advance. 
> April
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: What is the meaning of this error in cakephp 3?

2016-03-13 Thread Willem Schwarte
Yes. That should solve it. 

- willem

> Op 13 mrt. 2016 om 08:42 heeft heavyKevy  het 
> volgende geschreven:
> 
> You also need to make sure that you add the following line near the top of 
> the file after the namespace with the other use statements:
> 
> use Cake\Event\Event;
> 
> Best regards,
> --Kevin
> 
> 
>> On Sunday, March 13, 2016 at 1:47:10 AM UTC+7, Clement Crownrise wrote:
>> Hi, Thanks Willem, 
>> 
>> I have tried it, but the error still persists , look at the code below
>> 
>> 
>> public function beforefilter(Event $event){
>> //parent::beforefilter($event);
>> //$this->Auth->allow(['add','logout']);
>> return null;
>> }
>> 
>>> On Sat, Mar 12, 2016 at 11:52 AM, Willem Schwarte  wrote:
>>> Just as it says. You need to have the same method signature as the one you 
>>> are overriding. Thus:
>>> 
>>> public function beforeFilter(Event $event)
>>> {
>>> return null;
>>> }
>>> 
>>> you forgot the parameter.
>>> 
>>> 
>>> Willem
>>> 
>>> 
>>> 
 On 12 Mar 2016, at 10:30, Clement Crownrise  wrote:
 
 Hello, I am doing the blog tutorial in cakephp 3, but I got this notice at 
 the top of my page, please does anyone know the meaning and how to solve 
 it?
 
 Strict (2048): Declaration of App\Controller\AppController::beforefilter() 
 should be compatible with 
 Cake\Controller\Controller::beforeFilter(Cake\Event\Event $event) 
 [APP/Controller\AppController.php, line 29]
 
 
 
 Strict (2048): Declaration of 
 App\Controller\UsersController::beforefilter() should be compatible with 
 App\Controller\AppController::beforefilter() 
 [APP/Controller\UsersController.php, line 10]
 
 Your help will be appreciated
 
 -- 
 Sign up for our Newsletter for updates.
 http://cakephp.org/newsletter/signup
  
 We will soon be closing this Google Group. But don't worry, we have 
 something better coming. Stay tuned for an updated from the CakePHP Team 
 soon.
  
 Like Us on FaceBook https://www.facebook.com/CakePHP
 Follow us on Twitter http://twitter.com/CakePHP
 --- 
 You received this message because you are subscribed to the Google Groups 
 "CakePHP" group.
 To unsubscribe from this group and stop receiving emails from it, send an 
 email to cake-php+u...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.
>>> 
>>> -- 
>>> Sign up for our Newsletter for updates.
>>> http://cakephp.org/newsletter/signup
>>>  
>>> We will soon be closing this Google Group. But don't worry, we have 
>>> something better coming. Stay tuned for an updated from the CakePHP Team 
>>> soon.
>>>  
>>> Like Us on FaceBook https://www.facebook.com/CakePHP
>>> Follow us on Twitter http://twitter.com/CakePHP
>>> --- 
>>> You received this message because you are subscribed to a topic in the 
>>> Google Groups "CakePHP" group.
>>> To unsubscribe from this topic, visit 
>>> https://groups.google.com/d/topic/cake-php/qEur8oKsm48/unsubscribe.
>>> To unsubscribe from this group and all its topics, send an email to 
>>> cake-php+u...@googlegroups.com.
>>> For more options, visit https://groups.google.com/d/optout.
>> 
>> 
>> 
>> -- 
>> http://www.clementcrownrise.name/images/nameing.gif
> 
> -- 
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>  
> We will soon be closing this Google Group. But don't worry, we have something 
> better coming. Stay tuned for an updated from the CakePHP Team soon.
>  
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> --- 
> You received this message because you are subscribed to the Google Groups 
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: What is the meaning of this error in cakephp 3?

2016-03-12 Thread heavyKevy
You also need to make sure that you add the following line near the top of 
the file after the namespace with the other use statements:

use Cake\Event\Event;

Best regards,
--Kevin


On Sunday, March 13, 2016 at 1:47:10 AM UTC+7, Clement Crownrise wrote:
>
> Hi, Thanks Willem, 
>
> I have tried it, but the error still persists , look at the code below
>
>
> public function beforefilter(Event $event){
> //parent::beforefilter($event);
> //$this->Auth->allow(['add','logout']);
> return null;
> }
>
> On Sat, Mar 12, 2016 at 11:52 AM, Willem Schwarte  > wrote:
>
>> Just as it says. You need to have the same method signature as the one 
>> you are overriding. Thus:
>>
>> public function beforeFilter(Event $event)
>> {
>> return null;
>> }
>>
>>
>> you forgot the parameter.
>>
>>
>> Willem
>>
>>
>>
>> On 12 Mar 2016, at 10:30, Clement Crownrise > > wrote:
>>
>> Hello, I am doing the blog tutorial in cakephp 3, but I got this notice 
>> at the top of my page, please does anyone know the meaning and how to solve 
>> it?
>>
>> *Strict* (2048): Declaration of App\Controller\AppController::beforefilter() 
>> should be compatible with 
>> Cake\Controller\Controller::beforeFilter(Cake\Event\Event $event) 
>> [*APP/Controller\AppController.php*, line *29*]
>>
>>
>>
>> *Strict* (2048): Declaration of 
>> App\Controller\UsersController::beforefilter() should be compatible with 
>> App\Controller\AppController::beforefilter() 
>> [*APP/Controller\UsersController.php*, line *10*]
>>
>>
>> Your help will be appreciated
>>
>> -- 
>> Sign up for our Newsletter for updates.
>> http://cakephp.org/newsletter/signup
>>  
>> We will soon be closing this Google Group. But don't worry, we have 
>> something better coming. Stay tuned for an updated from the CakePHP Team 
>> soon.
>>  
>> Like Us on FaceBook https://www.facebook.com/CakePHP
>> Follow us on Twitter http://twitter.com/CakePHP
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "CakePHP" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to cake-php+u...@googlegroups.com .
>> For more options, visit https://groups.google.com/d/optout.
>>
>>
>> -- 
>> Sign up for our Newsletter for updates.
>> http://cakephp.org/newsletter/signup
>>  
>> We will soon be closing this Google Group. But don't worry, we have 
>> something better coming. Stay tuned for an updated from the CakePHP Team 
>> soon.
>>  
>> Like Us on FaceBook https://www.facebook.com/CakePHP
>> Follow us on Twitter http://twitter.com/CakePHP
>> --- 
>> You received this message because you are subscribed to a topic in the 
>> Google Groups "CakePHP" group.
>> To unsubscribe from this topic, visit 
>> https://groups.google.com/d/topic/cake-php/qEur8oKsm48/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to 
>> cake-php+u...@googlegroups.com .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> -- 
> http://www.clementcrownrise.name/images/nameing.gif
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: What is the meaning of this error in cakephp 3?

2016-03-12 Thread Clement Crownrise
Hi, Thanks Willem,

I have tried it, but the error still persists , look at the code below


public function beforefilter(Event $event){
//parent::beforefilter($event);
//$this->Auth->allow(['add','logout']);
return null;
}

On Sat, Mar 12, 2016 at 11:52 AM, Willem Schwarte 
wrote:

> Just as it says. You need to have the same method signature as the one you
> are overriding. Thus:
>
> public function beforeFilter(Event $event)
> {
> return null;
> }
>
>
> you forgot the parameter.
>
>
> Willem
>
>
>
> On 12 Mar 2016, at 10:30, Clement Crownrise 
> wrote:
>
> Hello, I am doing the blog tutorial in cakephp 3, but I got this notice at
> the top of my page, please does anyone know the meaning and how to solve it?
>
> *Strict* (2048): Declaration of App\Controller\AppController::beforefilter() 
> should be compatible with 
> Cake\Controller\Controller::beforeFilter(Cake\Event\Event $event) 
> [*APP/Controller\AppController.php*, line *29*]
>
>
>
> *Strict* (2048): Declaration of 
> App\Controller\UsersController::beforefilter() should be compatible with 
> App\Controller\AppController::beforefilter() 
> [*APP/Controller\UsersController.php*, line *10*]
>
>
> Your help will be appreciated
>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>
>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to a topic in the
> Google Groups "CakePHP" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/cake-php/qEur8oKsm48/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
http://www.clementcrownrise.name/images/nameing.gif

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: What is the meaning of this error in cakephp 3?

2016-03-12 Thread Willem Schwarte
Just as it says. You need to have the same method signature as the one you are 
overriding. Thus:

public function beforeFilter(Event $event)
{
return null;
}

you forgot the parameter.


Willem



> On 12 Mar 2016, at 10:30, Clement Crownrise  
> wrote:
> 
> Hello, I am doing the blog tutorial in cakephp 3, but I got this notice at 
> the top of my page, please does anyone know the meaning and how to solve it?
> 
> Strict (2048) <>: Declaration of App\Controller\AppController::beforefilter() 
> should be compatible with 
> Cake\Controller\Controller::beforeFilter(Cake\Event\Event $event) 
> [APP/Controller\AppController.php, line 29]
> 
> 
> 
> Strict (2048) <>: Declaration of 
> App\Controller\UsersController::beforefilter() should be compatible with 
> App\Controller\AppController::beforefilter() 
> [APP/Controller\UsersController.php, line 10]
> 
> Your help will be appreciated
> 
> -- 
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup 
>  
> We will soon be closing this Google Group. But don't worry, we have something 
> better coming. Stay tuned for an updated from the CakePHP Team soon.
>  
> Like Us on FaceBook https://www.facebook.com/CakePHP 
> 
> Follow us on Twitter http://twitter.com/CakePHP 
> --- 
> You received this message because you are subscribed to the Google Groups 
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to cake-php+unsubscr...@googlegroups.com 
> .
> For more options, visit https://groups.google.com/d/optout 
> .

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Upgrade manual from 2.7.5 to 2.8.1

2016-03-12 Thread Nicklas
Thanks a lot Andras.

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Upgrade manual from 2.7.5 to 2.8.1

2016-03-11 Thread Andras Kende
Hello,

Just replace the entire: /lib/Cake/ with the latest version (do backup first 
just in case)

Check the migration guide for changes between your versions:
http://book.cakephp.org/2.0/en/appendices.html



Andras Kende


> On Mar 11, 2016, at 3:43 AM, Nicklas  wrote:
> 
> Hi All,
> 
> Is it possible to do a manual upgrade from 2.7.5 to 2.8.1 by doing a file 
> compare and upload the new files?
> 
> The migration guide is not quite clear other then: CakePHP 2.8 is a fully API 
> compatible upgrade from 2.7. This page outlines the changes and improvements 
> made in 2.8.
> 
> 
> 
> 
> -- 
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>  
> We will soon be closing this Google Group. But don't worry, we have something 
> better coming. Stay tuned for an updated from the CakePHP Team soon.
>  
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> --- 
> You received this message because you are subscribed to the Google Groups 
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Virtual fields problem

2016-03-10 Thread LeHung
How about this?

$array = Hash::combine($array, '{n}Tag.name,{n}0.aantai,{n}');

On Fri, Mar 11, 2016 at 4:14 AM, Sam Clauw  wrote:

> Hi 2 all,
>
> I'm working on my first CakePHP blog project: http://kattenbelletjes.be/
> As you can see, there's a footer section that shows the top 25 most
> popular tags.
>
> There are three relevant tables I use the implement those popular tags:
>
> POSTS: id, title, content, slug
> TAGS: id, name, slug
> POST_TAG_LINK: id, post_id, tag_id
>
> I tried to make a CakePHP query via $this->tag->find, but there was a
> persistent SQL error that I couldn't fix.
> So, I tried it on the "$this->tag->query" SQL way:
>
> debug($this->Tag->query(
> "SELECT
> Tag.name,
> COUNT(PostTagLink.id) AS aantal
> FROM
> tags AS Tag
> INNER JOIN
> post_tag_links AS PostTagLink
> ON
> tag.id = PostTagLink.tag_id
> WHERE
> Tag.show = 'Y'
> GROUP BY
> Tag.name
> ORDER BY
> Tag.name ASC"
> ));
>
> The problem is that the output array isn't very nice:
>
> array(
>> (int) 0 => array(
>> 'Tag' => array(
>> 'name' => 'Beauty'
>> ),
>> (int) 0 => array(
>> 'aantal' => '2'
>> )
>> ),
>> (int) 1 => array(
>> 'Tag' => array(
>> 'name' => 'Koken'
>> ),
>> (int) 0 => array(
>> 'aantal' => '1'
>> )
>> ),
>> (int) 2 => array(
>> 'Tag' => array(
>> 'name' => 'Lente'
>> ),
>> (int) 0 => array(
>> 'aantal' => '2'
>> )
>> ),
>> (int) 3 => array(
>> 'Tag' => array(
>> 'name' => 'Wonen'
>> ),
>> (int) 0 => array(
>> 'aantal' => '4'
>> )
>> )
>> )
>
>
> I wan't something like this instead:
>
> array(
>> (int) 0 => array(
>> 'Tag' => array(
>> 'name' => 'Beauty',
>> 'count' => '2'
>> )
>> ),
>> (int) 1 => array(
>> 'Tag' => array(
>> 'name' => 'Koken',
>> 'count' => '1'
>> )
>> ),
>> (int) 2 => array(
>> 'Tag' => array(
>> 'name' => 'Lente',
>> 'count' => '2'
>> )
>> ),
>> (int) 3 => array(
>> 'Tag' => array(
>> 'name' => 'Wonen',
>> 'count' => '4'
>> )
>> )
>> )
>
>
> Is there somebody with a solution on this?
> Thanks 4 helping ;)
>
> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: API Design using CakePHP 3

2016-03-10 Thread Florian Krämer
1) I would *not *avoid that. We use the protection and have no problem at 
all with it.
2) Create a filter and use it in beforeSave()? Create data objects like the 
entities in Cake and filter the date there before sending?
3) No idea what you're talking about, you basically say "It's not working 
righ". We do the transformRequest just once AFAIR.
4) No idea, "It's not working" is nothing you'll get help with.

See 
http://book.cakephp.org/3.0/en/development/routing.html#creating-restful-routes 
There is also the FoC CRUD plugin but we don't use it yet and probably 
won't. Cake is good enough as it is for us so far. We're re-building our 
frontend and a CRM with Angular and Cake3.

On Wednesday, March 9, 2016 at 3:04:19 PM UTC+1, Rafael Queiroz wrote:
>
> Hi guys,
>
> I make a *API* using *CakePHP 3.2.x*, so, and now have a angular app 
> requesting *API*.
> My question is about association data, e.g. i have *Series* *Model* and 
> send the request:
>
> *api.com/series/add <http://api.com/series/add>*
>
> {
> "id": 5,
> "title": "New serie", 
> "hidden": false,
> "courses": {"_ids":["1","2"]}
> }
>
> It's work, many times, i have problems, because first time in edit, i get 
> register and mockup in scope of app, and have problems, because register 
> have all fields, per sample: 
>
> 1. Avoiding Mass Assignment Protection in Entity, because save created = 
> null
> 2. Send all object data, have association data i don't want send, i need 
> using transformRequest in angularJs
> 3. Many times i have problem with CORS, because send a object complex, not 
> expected, if simple object it's work
> 4. I have problem for delete association data, have a garbage in docs, but 
> not work's 100%. [1]
>
> So, this easy save data and associations, now, it's my nightmare.
>
> *My point is about best practices for api, i read articles and have a 
> solution, using sub resources.*
>
>
>
> *I need create new endpoints for retrieve/save/delete associations data in 
> register ?What do you think ? Thank you in advance for your attention*
> [1] 
> http://book.cakephp.org/3.0/en/orm/saving-data.html#patching-hasmany-and-belongstomany
>
> -- 
> Regards,
>
> Rafael F. Queiroz
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Cakephp3] Best way to change database on the fly by user

2016-03-02 Thread rumble
You could bind a database with relation to your app.php and the datasources 
there, and based on param in url or some values in a table, execute in your 
controller:

ConnectionManager::alias($custom_db, 'default');

I am testing similar scenario, but on the model level. 


On Tuesday, February 23, 2016 at 11:20:38 PM UTC, Michał Piotrowski wrote:
>
> Hello !
>
> I used cakephp 3 to implement my apps and it's awesome :)
>
> Now I try to implement datasource by user:
> - one datasource by request
> - every user can use diffrent database
>
>  Now i used vars cache and read it after user login in tables static 
> function defaultConnectionName this solution isn't brilliant but works.
>
> Maybe you can give better solutions.
>
>
>
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Remove first from collections

2016-02-29 Thread John Andersen
I deletion is not possible, would the skip method work for you?
*http://book.cakephp.org/3.0/en/core-libraries/collections.html#Cake\Collection\Collection::skip*

Enjoy, John

On Thursday, 25 February 2016 16:56:27 UTC+2, Rafael Santos wrote:
>
> Hi, 
> i'm using CakePHP's Collections 
>  on a 
> non-cakephp project. I was search for a Collection package and I find yours 
> to be the best. 
> Is there a way to easily delete the first element of a collection? 
> For example,* $collection->first()->remove().*
>
> Thanks
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Form: hasMany fields table validation not working

2016-02-29 Thread Paulo Terra
Ok, thank you very much! I am sorry that I didn't realize this singular and
plural detail.

Thank you very much!

Paulo

2016-02-29 11:36 GMT-03:00 Dakota :

> Not a problem, glad that worked for you.
>
> For future reference, you can usually get nearly instant help on the IRC
> channel (
> http://webchat.freenode.net/?channels=cakephp&uio=MT1mYWxzZSY5PXRydWUmMTE9MjQ2b8),
> depending on who is online of course. Stackoverflow is also usually more
> active than the group.
>
> On Monday, 29 February 2016 16:31:11 UTC+2, Paulo Terra wrote:
>>
>> Great! It Works! Thank you Dakota!
>>
>> 2016-02-29 11:15 GMT-03:00 Dakota :
>>
>>> Hi Paulo,
>>>
>>> Your form field for address zipcode field is in the wrong format.
>>> http://book.cakephp.org/3.0/en/views/helpers/form.html#creating-inputs-for-associated-data
>>> shows the correct format for each type of relation. Basically, instead of
>>> doing
>>> $this->Form->input('address.zipcode');
>>>
>>> You need to do instead do:
>>> $this->Form->input('addresses.0.zipcode');
>>>
>>> For hasMany relations, the key is always plural and you need to specify
>>> a numeric index.
>>>
>>>
>>>
>>> On Sunday, 28 February 2016 22:07:32 UTC+2, Paulo Terra wrote:

 Hi,

 I have 3 tables: User, Buyer and Address:

 User hasMany Address
 User hasOne Buyer
 Address belongsTo User
 Buyer belongsTo User

 In the User form (Users/add.ctp):

 echo $this->Form->input('name',['label' => __('Nome')]);
 echo $this->Form->input('buyer.cpf',['label' => __('CPF')]);
 echo $this->Form->input('address.zipcode');



 UsersTable.php:

 $this->hasMany('Addresses', [
 'foreignKey' => 'user_id'
 ]);

 $this->hasOne('Buyers', [
 'foreignKey' => 'user_id'
 ]);



 BuyersTable.php:

 $this->table('buyers');
 $this->displayField('id');
 $this->primaryKey('id');
 $this->belongsTo('Users', [
 'foreignKey' => 'user_id',
 'joinType' => 'INNER'
 ]);


 AddressTable.php:

 $this->table('addresses');
 $this->displayField('id');
 $this->primaryKey('id');
 $this->belongsTo('Users', [
 'foreignKey' => 'user_id',
 'joinType' => 'INNER'
 ]);



 The field "cpf" from Buyer is recognized by cake as it´s Model is shown
 in the include path:


- *Model*(array)
   - *0*APP/Model/Table/UsersTable.php
   - *1*APP/Model/Entity/User.php
   - *2*APP/Model/Table/SurveysTable.php
   - *3*APP/Model/Table/BuyersTable.php
   - *4*APP/Model/Entity/Buyer.php
   - *5*APP/Model/Entity/Survey.php

 And "cpf" is also a "not null" field, whitch is properly verifyed in
 cake when I save.

 The problem is the "zipcode" field in "Address". It´s is also a
 required field but it is not validated from cake. And, as can be seen, it
 is not loaded in Model list.

 But when I change the relation Address relation from "hasMany" to
 "hasOne" it works (it also validade required field when I save).


 UsersTable.php:

 $this->hasOne('Addresses', [
 'foreignKey' => 'user_id'
 ]);

 $this->hasOne('Buyers', [
 'foreignKey' => 'user_id'
 ]);



- *Model*(array)
   - *0*APP/Model/Table/UsersTable.php
   - *1*APP/Model/Entity/User.php
   - *2*APP/Model/Table/SurveysTable.php
   - *3*APP/Model/Table/BuyersTable.php
   - *4*APP/Model/Entity/Buyer.php
   - *5*APP/Model/Table/AddressesTable.php
   - *6*APP/Model/Entity/Address.php
   - *7*APP/Model/Entity/Survey.php



 Does anyone has a clue about what is happening?

 --
>>> Sign up for our Newsletter for updates.
>>> http://cakephp.org/newsletter/signup
>>>
>>> We will soon be closing this Google Group. But don't worry, we have
>>> something better coming. Stay tuned for an updated from the CakePHP Team
>>> soon.
>>>
>>> Like Us on FaceBook https://www.facebook.com/CakePHP
>>> Follow us on Twitter http://twitter.com/CakePHP
>>> ---
>>> You received this message because you are subscribed to a topic in the
>>> Google Groups "CakePHP" group.
>>> To unsubscribe from this topic, visit
>>> https://groups.google.com/d/topic/cake-php/M8MwE8p8SZc/unsubscribe.
>>> To unsubscribe from this group and all its topics, send an email to
>>> cake-php+u...@googlegroups.com.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. S

Re: Form: hasMany fields table validation not working

2016-02-29 Thread Dakota
Not a problem, glad that worked for you.

For future reference, you can usually get nearly instant help on the IRC 
channel 
(http://webchat.freenode.net/?channels=cakephp&uio=MT1mYWxzZSY5PXRydWUmMTE9MjQ2b8),
 
depending on who is online of course. Stackoverflow is also usually more 
active than the group.

On Monday, 29 February 2016 16:31:11 UTC+2, Paulo Terra wrote:
>
> Great! It Works! Thank you Dakota!
>
> 2016-02-29 11:15 GMT-03:00 Dakota >:
>
>> Hi Paulo,
>>
>> Your form field for address zipcode field is in the wrong format. 
>> http://book.cakephp.org/3.0/en/views/helpers/form.html#creating-inputs-for-associated-data
>>  
>> shows the correct format for each type of relation. Basically, instead of 
>> doing 
>> $this->Form->input('address.zipcode');
>>
>> You need to do instead do:
>> $this->Form->input('addresses.0.zipcode');
>>
>> For hasMany relations, the key is always plural and you need to specify a 
>> numeric index.
>>
>>
>>
>> On Sunday, 28 February 2016 22:07:32 UTC+2, Paulo Terra wrote:
>>>
>>> Hi,
>>>
>>> I have 3 tables: User, Buyer and Address:
>>>
>>> User hasMany Address
>>> User hasOne Buyer
>>> Address belongsTo User
>>> Buyer belongsTo User
>>>
>>> In the User form (Users/add.ctp):
>>>
>>> echo $this->Form->input('name',['label' => __('Nome')]);
>>> echo $this->Form->input('buyer.cpf',['label' => __('CPF')]);
>>> echo $this->Form->input('address.zipcode');
>>>
>>>
>>>
>>> UsersTable.php:
>>>
>>> $this->hasMany('Addresses', [
>>> 'foreignKey' => 'user_id'
>>> ]);
>>> 
>>> $this->hasOne('Buyers', [
>>> 'foreignKey' => 'user_id'
>>> ]);
>>>
>>>
>>>
>>> BuyersTable.php:
>>>
>>> $this->table('buyers');
>>> $this->displayField('id');
>>> $this->primaryKey('id');
>>> $this->belongsTo('Users', [
>>> 'foreignKey' => 'user_id',
>>> 'joinType' => 'INNER'
>>> ]);
>>>
>>>
>>> AddressTable.php:
>>>
>>> $this->table('addresses');
>>> $this->displayField('id');
>>> $this->primaryKey('id');
>>> $this->belongsTo('Users', [
>>> 'foreignKey' => 'user_id',
>>> 'joinType' => 'INNER'
>>> ]);
>>>
>>>
>>>
>>> The field "cpf" from Buyer is recognized by cake as it´s Model is shown 
>>> in the include path:
>>>
>>>
>>>- *Model*(array)
>>>   - *0*APP/Model/Table/UsersTable.php
>>>   - *1*APP/Model/Entity/User.php
>>>   - *2*APP/Model/Table/SurveysTable.php
>>>   - *3*APP/Model/Table/BuyersTable.php
>>>   - *4*APP/Model/Entity/Buyer.php
>>>   - *5*APP/Model/Entity/Survey.php
>>>
>>> And "cpf" is also a "not null" field, whitch is properly verifyed in 
>>> cake when I save.
>>>
>>> The problem is the "zipcode" field in "Address". It´s is also a required 
>>> field but it is not validated from cake. And, as can be seen, it is not 
>>> loaded in Model list.
>>>
>>> But when I change the relation Address relation from "hasMany" to 
>>> "hasOne" it works (it also validade required field when I save).
>>>
>>>
>>> UsersTable.php:
>>>
>>> $this->hasOne('Addresses', [
>>> 'foreignKey' => 'user_id'
>>> ]);
>>> 
>>> $this->hasOne('Buyers', [
>>> 'foreignKey' => 'user_id'
>>> ]);
>>>
>>>
>>>
>>>- *Model*(array)
>>>   - *0*APP/Model/Table/UsersTable.php
>>>   - *1*APP/Model/Entity/User.php
>>>   - *2*APP/Model/Table/SurveysTable.php
>>>   - *3*APP/Model/Table/BuyersTable.php
>>>   - *4*APP/Model/Entity/Buyer.php
>>>   - *5*APP/Model/Table/AddressesTable.php
>>>   - *6*APP/Model/Entity/Address.php
>>>   - *7*APP/Model/Entity/Survey.php
>>>
>>>
>>>
>>> Does anyone has a clue about what is happening?
>>>
>>> -- 
>> Sign up for our Newsletter for updates.
>> http://cakephp.org/newsletter/signup
>>  
>> We will soon be closing this Google Group. But don't worry, we have 
>> something better coming. Stay tuned for an updated from the CakePHP Team 
>> soon.
>>  
>> Like Us on FaceBook https://www.facebook.com/CakePHP
>> Follow us on Twitter http://twitter.com/CakePHP
>> --- 
>> You received this message because you are subscribed to a topic in the 
>> Google Groups "CakePHP" group.
>> To unsubscribe from this topic, visit 
>> https://groups.google.com/d/topic/cake-php/M8MwE8p8SZc/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to 
>> cake-php+u...@googlegroups.com .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe f

Re: Form: hasMany fields table validation not working

2016-02-29 Thread Paulo Terra
Great! It Works! Thank you Dakota!

2016-02-29 11:15 GMT-03:00 Dakota :

> Hi Paulo,
>
> Your form field for address zipcode field is in the wrong format.
> http://book.cakephp.org/3.0/en/views/helpers/form.html#creating-inputs-for-associated-data
> shows the correct format for each type of relation. Basically, instead of
> doing
> $this->Form->input('address.zipcode');
>
> You need to do instead do:
> $this->Form->input('addresses.0.zipcode');
>
> For hasMany relations, the key is always plural and you need to specify a
> numeric index.
>
>
>
> On Sunday, 28 February 2016 22:07:32 UTC+2, Paulo Terra wrote:
>>
>> Hi,
>>
>> I have 3 tables: User, Buyer and Address:
>>
>> User hasMany Address
>> User hasOne Buyer
>> Address belongsTo User
>> Buyer belongsTo User
>>
>> In the User form (Users/add.ctp):
>>
>> echo $this->Form->input('name',['label' => __('Nome')]);
>> echo $this->Form->input('buyer.cpf',['label' => __('CPF')]);
>> echo $this->Form->input('address.zipcode');
>>
>>
>>
>> UsersTable.php:
>>
>> $this->hasMany('Addresses', [
>> 'foreignKey' => 'user_id'
>> ]);
>>
>> $this->hasOne('Buyers', [
>> 'foreignKey' => 'user_id'
>> ]);
>>
>>
>>
>> BuyersTable.php:
>>
>> $this->table('buyers');
>> $this->displayField('id');
>> $this->primaryKey('id');
>> $this->belongsTo('Users', [
>> 'foreignKey' => 'user_id',
>> 'joinType' => 'INNER'
>> ]);
>>
>>
>> AddressTable.php:
>>
>> $this->table('addresses');
>> $this->displayField('id');
>> $this->primaryKey('id');
>> $this->belongsTo('Users', [
>> 'foreignKey' => 'user_id',
>> 'joinType' => 'INNER'
>> ]);
>>
>>
>>
>> The field "cpf" from Buyer is recognized by cake as it´s Model is shown
>> in the include path:
>>
>>
>>- *Model*(array)
>>   - *0*APP/Model/Table/UsersTable.php
>>   - *1*APP/Model/Entity/User.php
>>   - *2*APP/Model/Table/SurveysTable.php
>>   - *3*APP/Model/Table/BuyersTable.php
>>   - *4*APP/Model/Entity/Buyer.php
>>   - *5*APP/Model/Entity/Survey.php
>>
>> And "cpf" is also a "not null" field, whitch is properly verifyed in cake
>> when I save.
>>
>> The problem is the "zipcode" field in "Address". It´s is also a required
>> field but it is not validated from cake. And, as can be seen, it is not
>> loaded in Model list.
>>
>> But when I change the relation Address relation from "hasMany" to
>> "hasOne" it works (it also validade required field when I save).
>>
>>
>> UsersTable.php:
>>
>> $this->hasOne('Addresses', [
>> 'foreignKey' => 'user_id'
>> ]);
>>
>> $this->hasOne('Buyers', [
>> 'foreignKey' => 'user_id'
>> ]);
>>
>>
>>
>>- *Model*(array)
>>   - *0*APP/Model/Table/UsersTable.php
>>   - *1*APP/Model/Entity/User.php
>>   - *2*APP/Model/Table/SurveysTable.php
>>   - *3*APP/Model/Table/BuyersTable.php
>>   - *4*APP/Model/Entity/Buyer.php
>>   - *5*APP/Model/Table/AddressesTable.php
>>   - *6*APP/Model/Entity/Address.php
>>   - *7*APP/Model/Entity/Survey.php
>>
>>
>>
>> Does anyone has a clue about what is happening?
>>
>> --
> Sign up for our Newsletter for updates.
> http://cakephp.org/newsletter/signup
>
> We will soon be closing this Google Group. But don't worry, we have
> something better coming. Stay tuned for an updated from the CakePHP Team
> soon.
>
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Follow us on Twitter http://twitter.com/CakePHP
> ---
> You received this message because you are subscribed to a topic in the
> Google Groups "CakePHP" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/cake-php/M8MwE8p8SZc/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> cake-php+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Form: hasMany fields table validation not working

2016-02-29 Thread Dakota
Hi Paulo,

Your form field for address zipcode field is in the wrong 
format. 
http://book.cakephp.org/3.0/en/views/helpers/form.html#creating-inputs-for-associated-data
 
shows the correct format for each type of relation. Basically, instead of 
doing 
$this->Form->input('address.zipcode');

You need to do instead do:
$this->Form->input('addresses.0.zipcode');

For hasMany relations, the key is always plural and you need to specify a 
numeric index.


On Sunday, 28 February 2016 22:07:32 UTC+2, Paulo Terra wrote:
>
> Hi,
>
> I have 3 tables: User, Buyer and Address:
>
> User hasMany Address
> User hasOne Buyer
> Address belongsTo User
> Buyer belongsTo User
>
> In the User form (Users/add.ctp):
>
> echo $this->Form->input('name',['label' => __('Nome')]);
> echo $this->Form->input('buyer.cpf',['label' => __('CPF')]);
> echo $this->Form->input('address.zipcode');
>
>
>
> UsersTable.php:
>
> $this->hasMany('Addresses', [
> 'foreignKey' => 'user_id'
> ]);
> 
> $this->hasOne('Buyers', [
> 'foreignKey' => 'user_id'
> ]);
>
>
>
> BuyersTable.php:
>
> $this->table('buyers');
> $this->displayField('id');
> $this->primaryKey('id');
> $this->belongsTo('Users', [
> 'foreignKey' => 'user_id',
> 'joinType' => 'INNER'
> ]);
>
>
> AddressTable.php:
>
> $this->table('addresses');
> $this->displayField('id');
> $this->primaryKey('id');
> $this->belongsTo('Users', [
> 'foreignKey' => 'user_id',
> 'joinType' => 'INNER'
> ]);
>
>
>
> The field "cpf" from Buyer is recognized by cake as it´s Model is shown in 
> the include path:
>
>
>- *Model*(array)
>   - *0*APP/Model/Table/UsersTable.php
>   - *1*APP/Model/Entity/User.php
>   - *2*APP/Model/Table/SurveysTable.php
>   - *3*APP/Model/Table/BuyersTable.php
>   - *4*APP/Model/Entity/Buyer.php
>   - *5*APP/Model/Entity/Survey.php
>
> And "cpf" is also a "not null" field, whitch is properly verifyed in cake 
> when I save.
>
> The problem is the "zipcode" field in "Address". It´s is also a required 
> field but it is not validated from cake. And, as can be seen, it is not 
> loaded in Model list.
>
> But when I change the relation Address relation from "hasMany" to "hasOne" 
> it works (it also validade required field when I save).
>
>
> UsersTable.php:
>
> $this->hasOne('Addresses', [
> 'foreignKey' => 'user_id'
> ]);
> 
> $this->hasOne('Buyers', [
> 'foreignKey' => 'user_id'
> ]);
>
>
>
>- *Model*(array)
>   - *0*APP/Model/Table/UsersTable.php
>   - *1*APP/Model/Entity/User.php
>   - *2*APP/Model/Table/SurveysTable.php
>   - *3*APP/Model/Table/BuyersTable.php
>   - *4*APP/Model/Entity/Buyer.php
>   - *5*APP/Model/Table/AddressesTable.php
>   - *6*APP/Model/Entity/Address.php
>   - *7*APP/Model/Entity/Survey.php
>
>
>
> Does anyone has a clue about what is happening?
>
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Problem with TinyMCE

2016-02-23 Thread Charles Beasley
It seems to me this should not be happening.  Although, I cannot decide 
which of the following is the problem.

A)  In the tiny_mce.js file I see some script that doesn't compute [for me 
at least].  

... c.push("")}else{c.push("") ...


The above code is interpreted as PHP when it is not.


B) Is it appropriate for CakePHP to include tiny_mce.js instead of add it 
to the script header?  It is after all located in the plugin's webroot/js 
folder.



--Charles




On Saturday, January 14, 2012 at 11:38:24 PM UTC-6, ali786 wrote:
>
> hi 
> i have a problem with TinyMCE and its not working in my page 
> i see "Parse error" in firebug ( Parse error : syntax error, 
> unexpected T_CONSTANT_ENCAPSED_STRING  ) 
> Please Help me :(

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: CakePHP 3.2.0 Released

2016-02-23 Thread José Lorenzo
Yes, it is

On Monday, February 1, 2016 at 12:18:20 PM UTC+1, rafaelmsantos.com wrote:
>
> Is the intl php extension still required?
>

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Cakephp 3.x How to create dynamic subdomain?

2016-02-23 Thread Dr. Tarique Sani
What is the error?

The *.example.com should point to the same webroot as your www.example.com
and example.com

Do all the magic in your code



On Tue, Feb 16, 2016 at 10:44 AM, Rajaram indira <
rajaramindiras...@gmail.com> wrote:

> Hi,
>
>  I'm doing dynamic sub domain in cakephp 3.x like,
>
> - [].example.com
>
> In sub domain part should be dynamic.
> I was tried wildcard method. But I can't get exact solution for my
> problem.
>
> --
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Find us on Twitter http://twitter.com/CakePHP
>
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> To post to this group, send email to cake-php@googlegroups.com.
> Visit this group at https://groups.google.com/group/cake-php.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
=
Hire a CakePHP dev team : http://sanisoft.com
=

-- 
Sign up for our Newsletter for updates.
http://cakephp.org/newsletter/signup

We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: CakePHP 3.0 location for API-Access

2016-02-21 Thread Anthony GRASSIOT
Didn't use it personnaly but I know that this exists:

  

  

  

You might want to have a look at it.

  

Regards

Anto

  

> On Feb 21 2016, at 5:33 pm, euromark  wrote:  

>

> Take a look at twitter, and how they did it:

>

> https://github.com/cvo-technologies/cakephp-twitter

>

>  

>

>  
Am Sonntag, 21. Februar 2016 15:06:29 UTC+1 schrieb web tools:

>

>> Hello,

>>

>>  

>>

>> I would like to use the API of OpenWeatherMap
() in my CakePHP 3.x Application, but I am not
sure where to put my API-Calls like "**getWeatherByCityname()**" in, because
'**Table**', '**Entity**' and '**Behaviour**' only belongs to relational
Databases.

>>

>>  

>>

>> Is there a best practice?

>>

>>  

>>

>> Thanks!

>>

>> cls

>>

>>  

>>

>>  

>

> \--  
We will soon be closing this Google Group. But don't worry, we have something
better coming. Stay tuned for an updated from the CakePHP Team soon.  
  
Like Us on FaceBook   
Follow us on Twitter   
\---  
You received this message because you are subscribed to the Google Groups
"CakePHP" group.  
To unsubscribe from this group and stop receiving emails from it, send an
email to [cake-php+unsubscr...@googlegroups.com](mailto:cake-
php+unsubscr...@googlegroups.com).  
For more options, visit .  

-- 
We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: CakePHP 3.x and Redis as one of the main Database

2016-02-21 Thread euromark
You could work together and upgrade it to 3.x.

Dont forget to publish it 
on https://github.com/FriendsOfCake/awesome-cakephp then.

Mark


Am Sonntag, 21. Februar 2016 15:06:29 UTC+1 schrieb web tools:
>
> Hello,
>
> I am new to CakePHP and I am wondering which is the best way to use Redis 
> not as Cache but as a main Database with CakePHP 3.x. 
>
> I have found a Plugin for Cake 2, but it seems to be incompatible with 
> CakePHP 3.x (https://github.com/Oefenweb/cakephp-redis).
>
> Does anyone has a tipp?
>
> Thanks, Cls
>

-- 
We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: CakePHP 3.0 location for API-Access

2016-02-21 Thread euromark
Take a look at twitter, and how they did it:
https://github.com/cvo-technologies/cakephp-twitter


Am Sonntag, 21. Februar 2016 15:06:29 UTC+1 schrieb web tools:
>
> Hello, 
>
> I would like to use the API of OpenWeatherMap (
> http://openweathermap.org/api) in my CakePHP 3.x Application, but I am 
> not sure where to put my API-Calls like "*getWeatherByCityname()*" in, 
> because '*Table*', '*Entity*' and '*Behaviour*' only belongs to 
> relational Databases.
>
> Is there a best practice?
>
> Thanks!
> cls
>
>
>

-- 
We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Srange behaviour with find('list')

2016-02-18 Thread Gaurav Kumar
Hello michael,

Check your displayField in the respective table file. If it is different 
from what you are trying to fetch then just add your field in the 
displayField just above the find query.

On Thursday, February 18, 2016 at 1:48:22 AM UTC+5:30, Michael Kornatzki 
wrote:
>
> Hi,
>
> i am using find('list') to get key/values and was very surprised that the 
> key-values are wrong!?
>
> if i use 
>   $corp = $SupplierCorps->find('list');
>   Log::debug($corp->toArray());
> i get
> [22] => 1003022
> [29] => 1003029
> ...
> where the key is the primaryKey defined in the Table-class and the value 
> is the displayField.
>
> This is ok but if  i use
>
> $corp = $SupplierCorps->find('list', ['keyField' => 'SupplCorp_No_auto']);
>
> i get this
> [1440065430] => 1003022
> [1440065437] => 1003029
>
> and this is wrong!
> The key should now the same as the value.
> And if i run the sql against the mysql-Database i get the right results
>
> Do i oversee something?
>
> I use cakePhp 3.1.5
>
> Thanks in advance,
> michael
>
>

-- 
We will soon be closing this Google Group. But don't worry, we have something 
better coming. Stay tuned for an updated from the CakePHP Team soon.

Like Us on FaceBook https://www.facebook.com/CakePHP
Follow us on Twitter http://twitter.com/CakePHP
--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: intl extension to use CakePHP not working

2016-02-17 Thread Rohit Yadav
I am facing the same problem. Please let me know what to. 

what I did:- 
I have Xampp installed build 12 Nov 2015, 
PHP version :- 7.0
Did the things maintained in cakephp 3.0 documentation 

When I open phpinfo() section of xammp it shows INTL section means 
extension enabled. 
But when it try to run bin\cake server then It throws the same error every 
time. I try to searched a lot and did what stackoverflow says and some 
other php blogger says but still getting the same error. 

Please let me know what to do to resolve this issue.

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Wildcard DNS | Domain | Subdomain

2016-02-17 Thread Rajaram indira
Hi swimwithabhra,

 Can you help me to implement this with cakephp 3.x

On Wednesday, March 30, 2011 at 11:57:35 AM UTC+5:30, swimwithabhra wrote:
>
> Hi all, 
> thanks for all your suggestions. 
>
> I will talk to my hosting provider to check whether the virtualhost 
> and other server configurations are correctly done or not. 
> The following is the htaccess I am using -: 
>
>  
> RewriteEngine On 
> RewriteCond %{REQUEST_FILENAME} !-d 
> RewriteCond %{REQUEST_FILENAME} !-f 
> RewriteCond %{HTTP_HOST} ^([^.]+)\.?domain\.com [NC] 
> RewriteCond %1 !^(www)?$ [NC] 
> RewriteRule ^([^/]*)/?([^/]*)?/?$ index.php?user=%1&url=$1 [QSA,L] 
>  
>
> As I am not good with htaccess I am not sure whether it is correct or 
> not. 
>
> I will be waiting for your valuable comments on the above. 
> Thanks.

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Wildcard DNS | Domain | Subdomain

2016-02-17 Thread Rajaram indira
Hi Abhra,

  I'm doing Wildcard DNS with cakephp 3.x. But I can't found exact 
solution for this problem. Can you help me to fix this problem.

On Monday, April 4, 2011 at 11:09:45 AM UTC+5:30, swimwithabhra wrote:
>
> Hi all, 
> I am glad to inform you that finally wildcard DNS is working for me. 
> I just add a A type record and added server alias in virtual host. I 
> didn't have to change anything in the .htaccess file. 
>
> Thank you all for your kind support. 
>
> Regards, 
>
> Abhra Banerjee

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: id of the current user

2016-02-09 Thread Kamal Deol
$this->Auth->User() gives the complete array and then you can access any of
the index .:)

On Thu, Feb 4, 2016 at 9:23 PM, Vishwadeep Kapoor <
vishwadeepkap...@gmail.com> wrote:

> Is there any way to get the value of the current login user in cake php, i
> have search for this every where at stackoverflow they are using *$uid =
> $this->Auth->user('id'); but my application is giving fatal error to this
> "user" *
> any help??
>
> --
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Find us on Twitter http://twitter.com/CakePHP
>
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> To post to this group, send email to cake-php@googlegroups.com.
> Visit this group at https://groups.google.com/group/cake-php.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Sorting paginated data by string length in cakephp 3.x

2016-02-09 Thread euromark
using 3.x virtual fields, expr() func() 
see the docs for that

Mark


Am Sonntag, 7. Februar 2016 17:48:33 UTC+1 schrieb jakubplus:
>
> Hi,
>
> I'd like to use Paginator sorting function, but for sorting by string 
> length like mysql LENGTH(title)
>
> $this->Paginator->sort('title')
>
> How to do that in cakephp 3?
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: $this->render('index');

2016-02-08 Thread John Andersen
Is that the whole search method in your controller?

If yes, then the render call is inside the if statement at the beginning 
and will thus not be invoked due to the return statement just after the if 
statement.

Enjoy, John

On Saturday, 30 January 2016 06:32:22 UTC+2, Maxwell Ochieng wrote:
>
> I have tried for two days now to figure out why $this->render('index'); is 
> not working on my controller method,here is the controller action I am 
> running $this->render('index');
> Thanks.
> public function search(){
> if($this->request->is('put') || $this->request->is('post')){
> return $this->redirect(array(
> '?'=>array(
> 'q'=>$this->request->data('User.searchQuery')
> )
> ));
> $this->User->recursive = 0;
> $searchQuery=$this->request->query('q');
> $this->Paginator->settings = array(
>  'User'=>array(
>'findType'=>'search',
>  'searchQuery'=> $searchQuery
>  )
>  );
> $this->set('users',$this->Paginator->paginate());
> $this->set('searchQuery',$searchQuery);
> //$this->autoRender = false;
>$this->render('index');
> }
> }
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Error in Database Connection BUT dabase.php is correct

2016-02-08 Thread John Andersen
Check that your user "user" has permissions to use the databases.

Enjoy, John

On Sunday, 7 February 2016 18:48:33 UTC+2, Douglas Diniz Landim wrote:
>
> It was a site that was running on a host.
>
> This accommodation accidentally got deleted the domain for the site.
>
> After restoring the area, occurred database errors.
>
> I downloaded the site's files to my localhost, and saved in the www folder 
> of wamp, imported bath in my localhost for testing, and edited the 
> database.php files and wordpress plugin and yet mistakes are the same as 
> they were in accommodation.
>
> Kept files on hosting the FTP because some images of addresses can still 
> point to the hosting.
>
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: CAKE PHP TUTORIAL FOR BEGINNERS

2016-02-08 Thread John Andersen
Hi Priyatam Saha

Which version of CakePHP have you downloaded and installed?
Which tutorial have you followed?

Enjoy, John


On Sunday, 7 February 2016 18:48:33 UTC+2, priyatam saha wrote:
>
> Dear sir,
>I am a new commer to cakephp.I have download and installed cakephp.Now 
> I create a app from somee tutorials.But dont know how to start and from 
> where to start.
>   Thats why I am requesting to you to help me in this field.
>
> Thank You.
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: id of the current user

2016-02-08 Thread Paul Vaughan
In CakePHP 3.2 I am using:

$userid = $this->request->session()->read('Auth.User.id');

I hope that's useful.

Paul.

On 4 February 2016 at 15:53, Vishwadeep Kapoor 
wrote:

> Is there any way to get the value of the current login user in cake php, i
> have search for this every where at stackoverflow they are using *$uid =
> $this->Auth->user('id'); but my application is giving fatal error to this
> "user" *
> any help??
>
> --
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Find us on Twitter http://twitter.com/CakePHP
>
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> To post to this group, send email to cake-php@googlegroups.com.
> Visit this group at https://groups.google.com/group/cake-php.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: CakePHP 3 - Catch invalidargument email -> to exception

2016-02-07 Thread Artur Mamedov
Have the same problem with Carbon::createFromFormat()

try {
   $this->app_from = $date->createFromFormat('Y-m-d', 
$this->request->cookie('app_from'));//$date->subDays(7);//date('Y-m-d', 
strtotime("-7 days"));
   $this->app_to = $date->createFromFormat('Y-m-d', 
$this->request->cookie('app_to'));//$date->now();
} catch (InvalidArgumentException $e) {
   $this->app_from = $date->subDays(7);//date('Y-m-d', strtotime("-7 days"));
   $this->app_to = $date->now();
}


-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Acl alternative

2016-02-04 Thread sphereweb
Can you tell us how you implemented the connection to cassandra? What are 
your thoughts about cassandra vs mysql?

On Sunday, June 3, 2012 at 7:39:49 PM UTC-4, Juan Ezquerro LLanes wrote:
>
> Hi,
>
> I'm using cakephp 2.0 and cassandra as database, so i can't work with 
> default acl implementation, any suggestions,  options, ...?
>
> Thanks
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Using test database

2016-02-04 Thread sphereweb
Can you tell us your experience with cassandra? did you write your own 
driver?

On Monday, July 23, 2012 at 4:48:03 PM UTC-4, Juan Ezquerro LLanes wrote:
>
> If i write a test case i want use the test database config without 
> fixtures, i insert the data manually, i just want to say to my test case 
> 'just use that db with the data and tables already contains'. how can i do 
> that? fixtures do not work with my datasource, i'm using cassandra.

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Cassandra and cakephp

2016-02-04 Thread sphereweb
Also interested in this

On Tuesday, May 29, 2012 at 5:51:50 AM UTC-4, Juan Ezquerro LLanes wrote:
>
> Is there any cassandra datasource for cakephp? Google say yes but i can't 
> find the code.

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Auth Component works in dev, but not in production

2016-02-02 Thread Christian Quispe
compartenos los log y debugs.



Enviado con MailTrack


Saludos

Christian Quispe

*Geek and Developer*
*Miembro: * *GDG Lima (Google Developer Group Lima)*

*Portafolio: www.oxicode.io
*

*¿A quién le enseñan sus aciertos?, si yo aprendo de mis errores
constantemente...*


2016-01-20 4:58 GMT-05:00 Ricardo Escalon :

> I am getting a blank page when I try and use the Auth Component.
>
> The code is straight out of the blog tutorial.
>
>
> http://book.cakephp.org/3.0/en/tutorials-and-examples/blog-auth-example/auth.html
>
> It works in dev, but I get a blank page in production.
>
> Any ideas anyone?
>
> --
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Find us on Twitter http://twitter.com/CakePHP
>
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> To post to this group, send email to cake-php@googlegroups.com.
> Visit this group at https://groups.google.com/group/cake-php.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: CakePHP 3.2.0 Released

2016-02-02 Thread Florian Krämer
Just try it? It's a one minute thing.

On Monday, February 1, 2016 at 12:18:20 PM UTC+1, rafaelmsantos.com wrote:
>
> Is the intl php extension still required?
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: CakePHP 3.2.0 Released

2016-02-01 Thread rafaelmsantos.com
Is the intl php extension still required?

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Bug: flaws in email validation/sending

2016-01-31 Thread euromark
Please open a ticket at https://github.com/cakephp/cakephp/issues
This is just a discission board, not a bug tracker.

Mark


Am Samstag, 30. Januar 2016 05:33:10 UTC+1 schrieb Kim:
>
>
>- CakePHP's email validation allows non-ASCII letter characters, e.g. 
>á, in the  local part of the email address (by the \p{L} unicode category 
>construct). This should not be allowed, see 
>https://en.wikipedia.org/wiki/Email_address#Local_part.
>- It also allows non-ASCII letter characters in the domain part. This 
>allows Internationalized Domain Names (IDN). The problem here lies in the 
>fact that this is not supported by the SmtpTransport. An SMTP client 
> should 
>convert them to so called punycode ASCII, according to 
>https://lists.exim.org/lurker/message/20140812.120609.bf764769.en.html. 
>MTA exim does not accept the SMTP sequence. By the way, conversion to 
>punycode can be done by PHP's idn_to_ascii().
>
> This issues have been tested in the current 2.7 branch, but a quick code 
> inspection confirms that they are also present in the master branch. As a 
> workaround I have switched back to validation by PHP's filter_var(), used 
> in a wrapper validation method.
>
> The first issue can be fixed easily, although the right RFCs have to be 
> consulted. For the second issue, we have to decide if we support IDN for 
> email and if we do, support it (maybe not only in the SmtpTransport).
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Amazon AWS S3

2016-01-31 Thread Florian Krämer
https://github.com/burzum/cakephp-file-storage

Works with S3 and a ton of other storage backends.

On Saturday, January 30, 2016 at 5:32:01 AM UTC+1, fga...@medianet.com.ve 
wrote:
>
> Hi, I am developing a cakephp 3 in AWS, I want to integratewith amazon aws 
> s3, but I cannot find the plugin as I did in 
>
> cakephp 2, can you help me?
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: how to deploy i18n translations ?

2016-01-29 Thread Dino Moreira
One year later and I have this exactly problem. 

Messages in __("English") are translated as expected in WAMP development 
environment. But not in Fedora FC21 Linux Using same apache+php versions...




-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Cakephp find order by then group by

2016-01-29 Thread Shamshad Akther Khan
Thankz a lot sir, Your procedure has helped me solve a problem in live 
tracking issue

On Friday, October 19, 2012 at 2:41:18 PM UTC+6, Vanja Dizdarević wrote:
>
> Seemingly simple task, but not quite, eh...
>
> Solving this with a single query is possible, but you would have to do a 
> manual query (with Model::query), something like:
>
> SELECT Message.* FROM messages as Message
>   RIGHT JOIN (SELECT MAX(created) as last_created, user_id FROM messages 
> GROUP BY user_id)
>   as latest
>   ON Message.created = latest.last_created AND Message.user_id = 
> latest.user_id
>  GROUP BY Message.user_id
>  ORDER BY Message.created DESC;
>
> You cannot instruct MySQL how to decide which row to use when grouping 
> (yeah, i know...), so you would have to use MAX. The problem with this 
> query is that you get ambiguous results if you happen to have 2 messages 
> with same timestamp, user_id, receiver_id, so you would somehow need to 
> sort by created and Message.id too.
>
> Complex queries can become expensive quickly, so it's maybe better to find 
> last message separately for each user.
>
> $senders = $this->Message->find->('all', array(
> 'fields' => array(
> 'DISTINCT Message.user_id'
> )
> 'conditions'=>array(
> 'receiver_id' => $user_id
> )));
> $newMessages = array();
> foreach($senders as $sender) {
> $newMessages[] = $this->Messages->find('first', array(
> 'conditions' => array('user_id' => $sender['Message']['user_id'], 
> 'receiver_id' => $user_id), 
> 'order'=>array('created'=>'desc', 'id'=>'desc')
> ));
> }
>
> Another crazy idea is to create a *Message.last* boolean column and 
> update this field when you insert a new record:
>
> - run "UPDATE messages SET last = 0 WHERE user_id = $user_id AND 
> receiver_id=$receiver_id";
> - Create new message with Message.last = 1
>
> ... and then get last messages with find-all query with condition 
> Message.last = 1.
>
> I wished a thousand times that MySQL had a way of doing this properly in a 
> single query.
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


  1   2   3   4   5   6   7   8   9   10   >