# |
Jun 14th 2021, 11:10 |
kevin.pfeifer |
@dantedantas instead of trying to re-invent the wheel by ourself and handle your AJAX request by ourself inside the webroot folder why not create a controller action which you call via AJAX? Then you are “in the environment” of CakePHP and don’t need to do the whole bootstrapping by ourself |
# |
Jun 14th 2021, 11:08 |
admad |
Bringing any over a decade old app upto would be a rewrite, unless maybe it's WP since it never progressed. |
# |
Jun 14th 2021, 11:05 |
admad |
Rewrite |
# |
Jun 14th 2021, 10:56 |
arthurb |
Morning gents, I have a new client thats running a CakePHP v1.3.21 application and his asking us to quote on upgrading it to v4. In your experience what will be the easiest, upgrade to V2 to V3 to V4 or rewrite from scratch? thanks :) |
# |
Jun 14th 2021, 10:56 |
slackebot |
*image* *1209×424 25 KB* Thank you for your attention and help. Link: https://discourse.cakephp.org/t/how-to-connect-db-from-webroots-folder/9436 |
# |
Jun 14th 2021, 10:56 |
dantedantas |
Dear All, please, could someone explain to me how could I from the folder webroot connect to the DB? I have tried without success: Or maybe I have another choice? So, what I am doing and why: I have a VIEW that is very slow because loads a lot of data. What I did is: I created a horizontal menu and when you click on the button I use AJAX to load the needed info. The files used with AJAX are located in webroot’s folder. |
# |
Jun 14th 2021, 10:54 |
dantedantas |
Servus! :) |
# |
Jun 14th 2021, 10:54 |
kevin.pfeifer |
servus :) |
# |
Jun 14th 2021, 10:53 |
dantedantas |
Hello from Wien. :) |
# |
Jun 14th 2021, 10:50 |
slackebot |
<kevin.pfeifer> |
# |
Jun 14th 2021, 10:49 |
kevin.pfeifer |
a .pot is just a template file from which you generate your .po files for your languages. If you want to have the same string in the msgid and the msgstr use the Software PoEdit, select all strings and go to Edit => “Copy from Source Text” |
# |
Jun 14th 2021, 10:46 |
Lac |
I actually do need it ^^ |
# |
Jun 14th 2021, 10:38 |
dereuromark |
so no need to do such a thing |
# |
Jun 14th 2021, 10:38 |
dereuromark |
exactly :) my point is that it is as expected once you actually use it |
# |
Jun 14th 2021, 10:31 |
Lac |
my msgstr is always empty |
# |
Jun 14th 2021, 10:30 |
dereuromark |
why is that needed? it is by default this when it is empty |
# |
Jun 14th 2021, 10:29 |
Lac |
Hey guys, does anyone know if there's are way to set the msgstr the same as the msgid when generating a pot file through the i18n extract ? Thanks ! |
# |
Jun 14th 2021, 10:10 |
y.teruyacookie |
Thank you for your reply. I’m sorry, I confirm that results of debug($reserves) and debug($cancels) are different. |
# |
Jun 14th 2021, 08:15 |
val |
What would be the correct way to destroy an instance of MyTable class in 3.x so that it would be removed from all places where it is referenced or cached? |
# |
Jun 14th 2021, 08:05 |
alamnaryab |
? |
# |
Jun 14th 2021, 07:13 |
alamnaryab |
would you be able to get my anydesk or teamviewer and debug if I am making any mistake? |
# |
Jun 14th 2021, 07:12 |
alamnaryab |
thank you for your time |
# |
Jun 14th 2021, 07:09 |
conehead |
Really cannot imagine that |
# |
Jun 14th 2021, 07:08 |
conehead |
So if you remove the lines from the scope again it is working without any admin prefix? |
# |
Jun 14th 2021, 07:08 |
conehead |
There must be something other different. |
# |
Jun 14th 2021, 07:06 |
alamnaryab |
if link is there then how it was wroking for non-admin before adding admin scope instead of prefix as you suggested |
# |
Jun 14th 2021, 07:04 |
conehead |
Probably because you are trying to add a link to it? |
# |
Jun 14th 2021, 07:03 |
alamnaryab |
I am on domain/en it is showing error: A route matching "array ( 'prefix' => 'Admin', 'controller' => 'Users', 'action' => 'login', 'plugin' => NULL, '_ext' => NULL, )" could not be found. |
# |
Jun 14th 2021, 07:02 |
alamnaryab |
Missing Route |
# |
Jun 14th 2021, 07:02 |
alamnaryab |
now even non admin also showing error |
# |
Jun 14th 2021, 06:59 |
conehead |
I mean you are not following standards. You expect a prefix not to be on the first position...which is pretty much the definition of a prefix |
# |
Jun 14th 2021, 06:57 |
conehead |
couldnt you just move the routes from the admin prefix to the scope '/' and manually add the admin prefix there? |
# |
Jun 14th 2021, 06:42 |
alamnaryab |
then url becomes as domain/admin/en/controller/action while I need language first then admin |
# |
Jun 14th 2021, 06:41 |
filipecamargo10 |
```$builder->connect('/:language/:controller/:action/*', array(), array('language' => 'en|ar'));``` You have to do the same thing in admin routes |
# |
Jun 14th 2021, 06:41 |
alamnaryab |
admin inside language |
# |
Jun 14th 2021, 06:40 |
alamnaryab |
I tried many things, with that version problem is with admin |
# |
Jun 14th 2021, 06:40 |
filipecamargo10 |
the problem is on admin routes |
# |
Jun 14th 2021, 06:38 |
alamnaryab |
waiting since last week |
# |
Jun 14th 2021, 06:37 |
alamnaryab |
https://discourse.cakephp.org/t/cakephp-4-admin-prefix-routing-with-i18n-language-parameter/9431 |
# |
Jun 14th 2021, 06:37 |
filipecamargo10 |
right |
# |
Jun 14th 2021, 06:37 |
alamnaryab |
https://stackoverflow.com/questions/67888105/cakephp-4-admin-prefix-routing-with-i18n-language-parameter |