# |
Apr 29th 2017, 06:24 |
loginews |
@hmic I started with cakephp 3 directly. I tried several times. I read the official book for version online. But I believe that the difficulty is that a lot of advanced features are also discussed in the same paragraphs, which make the newcomer helpless. I come from MsAccess platform. Here is what I wrote for myself, in order to clear up the fog: http://cakephp.loginonline.net |
# |
Apr 29th 2017, 06:13 |
hmic |
the book is very clear, 3.x as least as good as 2.x. even more comprehensive |
# |
Apr 29th 2017, 06:12 |
hmic |
are you reading the book or what kind of documentation are you talking about? |
# |
Apr 29th 2017, 06:11 |
metoyoko |
@loginews yes I agree with you that documentation for ver.2 is more readable and explained clearly than ver.3, based on my own experienced. |
# |
Apr 29th 2017, 06:05 |
hiromi2424 |
@metoyoko yeah it is. |
# |
Apr 29th 2017, 06:05 |
metoyoko |
@hiromi2424 afaik that input refers to hasOne association? correct me if im wrong thanks |
# |
Apr 29th 2017, 06:03 |
metoyoko |
@loginews heres the link: https://book.cakephp.org/3.0/en/views/helpers/form.html#creating-inputs-for-associated-data |
# |
Apr 29th 2017, 06:01 |
hiromi2424 |
@loginews You can set association field like `Form->input('param.ADDRESS1')` |
# |
Apr 29th 2017, 06:00 |
hmic |
the book distinguishes between 2.x and 3.x very cleary, i's basically 2 different books with different urls to spot where you are on! |
# |
Apr 29th 2017, 05:59 |
loginews |
yes.... I did not see this in any documentation. It explains why we are getting difficulties. Also, a lot of documentation refer to version 2. You and I are using version 3 of cakephp. |
# |
Apr 29th 2017, 05:58 |
metoyoko |
you need to put .1. if you used hasMany inside your Model like: $this->hasMany('CmsLiquidationsDetails', [ 'foreignKey' => 'liquidations_header_id' ]); |
# |
Apr 29th 2017, 05:56 |
loginews |
where did you get the .1. ? from which documentation. I did not see that. |
# |
Apr 29th 2017, 05:54 |
metoyoko |
@loginews so far no answer. I figured it out that I need to encode inside form/template: $this->Form->control('cms_liquidations_details.1.category_id') instead of $this->Form->control('CmsLiquidationsDetails.1.category_id') and one thing there is no error prompted even in error.log shows empty. 2 days of trials and errors before I solved the problem. So It's so much appreciated if someonce share sample project that already used associatio |
# |
Apr 29th 2017, 05:45 |
loginews |
@metoyoko did anybody answer your question ? |
# |
Apr 29th 2017, 05:34 |
slackebot1 |
https://gist.github.com/loginews/78dbc099fe1689332c299002d361f472 Table param has only one record all the time. I want to edit the field ADDRESS1 (from param table) at the same time as the other fields in table users. I really don’t see how to do that. The docs are too complicated for me. |
# |
Apr 29th 2017, 05:34 |
loginews |
I would be very grateful if someone could help me out. I have already used CakePHP in 3 apps. I am slowly getting used to it. Whenever I am stuck, I can always go back to plain php to develop my application. I have no problem developing any app with plain php and mysql. So the problem is only with the learning the new language. I have a table users which I can edit successfully. See all the bits of codes here: |
# |
Apr 29th 2017, 05:34 |
loginews |
I have about the same difficulty as metoyoko |
# |
Apr 29th 2017, 05:10 |
backstageel |
Does the cakephp upgrade tool moves the prefixed actions to its own controller? |
# |
Apr 29th 2017, 03:34 |
metoyoko |
Where can I download working project that have hasMany and belongsToMany inside it. Thanks. |
# |
Apr 29th 2017, 03:28 |
metoyoko |
I Can't save using hasMany in cakephp 3. Is there any downloadable working cakephp 3 apps that has hasMany and belongsToMany inside it so I can figure out how to pass data from form to model. thanks |
# |
Apr 29th 2017, 03:25 |
metoyoko |
Good Day! |
# |
Apr 28th 2017, 20:28 |
graziel |
i find cake highly customizable as it gives you some basic things that you can follow but at the same time you might change almost every aspect of it |
# |
Apr 28th 2017, 20:28 |
graziel |
at start it might not have much sense but more and more you will use cake the more it will clear things up |
# |
Apr 28th 2017, 20:21 |
pc-world |
My first impression is that files like bootstrap.php which are over 200 lines in size should be part of the core if they are necessary, and not duplicated across every project built with Cake |
# |
Apr 28th 2017, 20:15 |
burzum |
In theory (never tried it) https://github.com/cakephp/app/blob/master/webroot/index.php this file should be enough. You can then start building whatever you want around it. ;) |
# |
Apr 28th 2017, 20:15 |
pc-world |
It doesn't really seem to be minimal, as the template includes SQL schemas (i18n.sql, sessions.ql), a sample test case, views, templates, CSS stuff etc. in webroot, can I delete all of that? |
# |
Apr 28th 2017, 20:13 |
burzum |
Nobody holds you off from creating all the other files, that you'll need in any case, manually if you prefer that. :slightly_smiling_face: |
# |
Apr 28th 2017, 20:12 |
temp1029 |
And btw, most of those 100 files are just placeholders for directories (about 50 I think) and then normal web front end stuff (CSS, images, etc) which don't affect your application logic |
# |
Apr 28th 2017, 20:10 |
dereuromark |
its as easy as that |
# |
Apr 28th 2017, 20:09 |
dereuromark |
no, follow the docs, copy stuff over to your repo and from there on no more updates to pull |
# |
Apr 28th 2017, 20:09 |
pc-world |
So what's the usual git workflow? Clone https://github.com/cakephp/app to be able to pull in updates? |
# |
Apr 28th 2017, 20:08 |
dereuromark |
dont care |
# |
Apr 28th 2017, 20:08 |
dereuromark |
dont are about it - just do your thing |
# |
Apr 28th 2017, 20:08 |
pc-world |
I'd like to know what each file in my project root is doing, and a template of over 100 files doesn't seem to be a good start |
# |
Apr 28th 2017, 20:08 |
dereuromark |
cakephp/app is minimal whats the problem with that? |
# |
Apr 28th 2017, 20:07 |
pc-world |
Isn't there a minimal template or something like that? |
# |
Apr 28th 2017, 20:07 |
pc-world |
Hello, I'm new to CakePHP. Am I really supposed to use a template of over 100 files to start developing an application?! https://github.com/cakephp/app |
# |
Apr 28th 2017, 19:24 |
btx |
@joop to explain a little, `?` *is* short tag syntax and needs to be enabled in the ini to work, and is generally not encouraged (because it’s not default) `<?=` is different and is the equivalent of `<?php echo ... ?` |
# |
Apr 28th 2017, 19:19 |
joop |
thanky you mate |
# |
Apr 28th 2017, 19:17 |
joop |
okey thank you its working now |
# |
Apr 28th 2017, 19:16 |
admad |
so don't use it and use <?php like i said |