# |
Jun 11th 2019, 19:50 |
challgren |
`$ListingsTable->find()->contain(['ListingImages'])` |
# |
Jun 11th 2019, 19:48 |
rightscoreanalysis |
which doesn't work incidently |
# |
Jun 11th 2019, 19:48 |
rightscoreanalysis |
$query->select(['ListingImages.*']); |
# |
Jun 11th 2019, 19:47 |
rightscoreanalysis |
eg. $query->select(['ListingImages.id', 'Listings.id']); |
# |
Jun 11th 2019, 19:46 |
rightscoreanalysis |
hi - anyone know if when I am building an array can I use a wildcard to select all table columns, instead of explicitly specifying each |
# |
Jun 11th 2019, 18:57 |
challgren |
<script>alert(‘This is injected js’);</script> |
# |
Jun 11th 2019, 18:56 |
ricksaccous |
yeah, you'll have to think of things like that |
# |
Jun 11th 2019, 18:56 |
challgren |
But doing so is risky because anyone that can insert a record into the db can potentially introduce javascript |
# |
Jun 11th 2019, 18:56 |
ricksaccous |
then when you display it don't use h() on it |
# |
Jun 11th 2019, 18:55 |
ricksaccous |
save it normally |
# |
Jun 11th 2019, 18:55 |
noel |
How can one save HTML content to the db and then get it out again and display it as HTML content in the template |
# |
Jun 11th 2019, 18:20 |
admad |
@noel since you are in controller just use `$this->loadModel('Articles')` |
# |
Jun 11th 2019, 18:19 |
skie |
there is MethodTest class where exists example how to call method inside package |
# |
Jun 11th 2019, 18:17 |
noel |
I'm trying to work with the ORM (https://book.cakephp.org/3.0/en/orm/query-builder.html)and having some trouble. I have a controller and I want to work with a particular table. I've tried this: `$articles = TableRegistry::getTableLocator()->get('Articles');` but it's giving me an error: `Class 'TableRegistry' not found`. Any clues? |
# |
Jun 11th 2019, 18:16 |
skie |
Did you checked tests cases, in the oracle driver plugin? |
# |
Jun 11th 2019, 18:15 |
skie |
ck |
# |
Jun 11th 2019, 18:12 |
challgren |
@noel if you use mac this https://getgrav.org/blog/macos-mojave-apache-multiple-php-versions is the best guide |
# |
Jun 11th 2019, 18:09 |
nucc1 |
Arckame: if you are writing the plain query yourself, i believe you have to list all the fields you want. (i don't know if cake has special sauce to do different though). |
# |
Jun 11th 2019, 16:57 |
noel |
never mind.. malformed URL |
# |
Jun 11th 2019, 16:50 |
noel |
When I use the cake Http Client for a given GET request I get no body in the response and 301 http code. When I do the same request from POSTMAN I get the expected response with body. What am I missing? |
# |
Jun 11th 2019, 15:58 |
noel |
bizarrely after all my failed attempts to install intl.. I tried composer again and now it's working :man-shrugging: |
# |
Jun 11th 2019, 15:48 |
hochwender |
Reporting my question: I'm using attempting to use the CakePHP 3 Driver for Oracle Database to call a stored procedure. Can someone point me to a working example? I'm unable to make it work. |
# |
Jun 11th 2019, 15:47 |
noel |
Also just noticed that my PHP info seems to think that intl is configured. It shows `--enable-int` |
# |
Jun 11th 2019, 15:41 |
steinkel |
try using --ignore-platform-reqs |
# |
Jun 11th 2019, 15:40 |
steinkel |
composer is the problem? |
# |
Jun 11th 2019, 15:33 |
noel |
@steinkel problem is that cakephp won't even install for me without intl. |
# |
Jun 11th 2019, 15:33 |
Arckame |
using a manual 'join' in a query don't return the joined table fields. Did i miss something or the fields must be manually added in 'select()' |
# |
Jun 11th 2019, 15:32 |
Arckame |
hello |
# |
Jun 11th 2019, 15:30 |
steinkel |
@noel check https://github.com/CakeDC/Intl it could help to bypass this issue if you don't really need intl |
# |
Jun 11th 2019, 15:28 |
JDD_Canada |
I have thre dev machines, both win and *nix, I use docker, just sync my docker file, it works a treat for dev |
# |
Jun 11th 2019, 15:24 |
ricksaccous |
lol |
# |
Jun 11th 2019, 15:24 |
ricksaccous |
disregard it actually |
# |
Jun 11th 2019, 15:24 |
ricksaccous |
that was written in 2014 |
# |
Jun 11th 2019, 15:23 |
ricksaccous |
https://pagegwood.com/web-development/how-to-enable-intl-extension-mamp-osx-10-9-2/ |
# |
Jun 11th 2019, 15:13 |
JDD_Canada |
looking like* |
# |
Jun 11th 2019, 15:13 |
noel |
Still don't understand why none of this was a problem on my last Mojave MAMP PRO setup. I never went through any of this... it just worked out the box. |
# |
Jun 11th 2019, 15:13 |
JDD_Canada |
This is loking liek a rabbit hole right now |
# |
Jun 11th 2019, 15:12 |
JDD_Canada |
doh, sorry, my mac experience is limited ot an old junker I have only to run xcode like, once every two years. It might be easier to either setup a docker in your ide, or re download mamp , and check for options to include intl |
# |
Jun 11th 2019, 15:11 |
noel |
https://bugs.php.net/bug.php?id=72879 |
# |
Jun 11th 2019, 15:10 |
noel |
... which I solved with `brew install icu4c`... but then `make` fails :face_vomiting: |
# |
Jun 11th 2019, 15:05 |
noel |
which I solved with `brew install autoconf` however `pecl install intl` then asks: `Specify where ICU libraries and headers can be found [DEFAULT]`. I assume I don't have the ICU libraries and headers? |