Jump to content

WillyC

Members
  • Posts

    327
  • Joined

  • Last visited

  • Days Won

    9

WillyC last won the day on October 4

WillyC had the most liked content!

Profile Information

  • Gender
    Not Telling

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

WillyC's Achievements

Sr. Member

Sr. Member (5/6)

785

Reputation

15

Community Answers

  1. @Siddhi Jagtap u.file perms is no write. /site/assets/* need tobe readerable/writedable to.apache sound like apache .run as account that.not you - mabe find new web host that less truble or u.can find out.user what apache run as - "apache", "nobody", "buldnog", etc. if user "apache": https://processwire.com/docs/security/file-permissions/#determining-what-user-apache-runs-as chgrp -R apache /site/assets find /site/assets -type d -exec chmod 775 {} \; find /site/assets -type f -exec chmod 664 {} \; https://processwire.com/docs/security/file-permissions/#how-to-change-permissions-of-existing-files but also visitarlos cont'la lachpud may helper - https://processwire.com/docs/security/file-permissions/
  2. Bern hard u.can does $wire->addHook('/mymodule/{foo}/{bar}(/{baz})?/', function($e) { return "<pre> foo: $e->foo bar: $e->bar baz: $e->baz "; }); @ bern berna hard @ @bernhard
  3. how.abt u use $cache 2 do jus do it. 1once per hour ? echo $cache->get('topic-count', 3600, function() use($topics) { $str = ''; $strategy = pages()->get("template=genre, name=strategy"); foreach($topics as $topic) { $count = pages()->count("template=game, genre=$strategy, topic=$topic"); $str .= "<li>$topic->title: $count games</li>"; } return $str; }); also.2 make faster u better should uses "id" not name, so "topics" no 'topics.name' and "genre" not genre.name etc. othrwis pw have to look those up for u (?) every time of foreach @rjgamer
  4. @MSP01 1.. pw cachis any.thing it load, so no.many how times u.cal $page->feld or $page->parent->smoga or $page->feld->bilpa --- it load feld or smoga or bilpa 1 time....... if autojoinin for.feld smoga or bilpa then it load it with th 1 queery that loader page 2) yes 1 sql to loader template=settings page and 1 sql to loader somesetting. ifs somesetting.feld is autojoinin then 1 sql for both. if u.cal eithers template=settings page agains or somesetting agains then alredy loadeded so no xtra sql unless u $pages->uncacheAll() whch clearys it all 3- may be. autojoinin can makes littel small faster but at cost of memry .use autojoinin only for.felds that u accessor on.evry load of $page. title good one to be.autojoinin ......most othrs not;;; body or images and most betters not autojoinin
  5. u.can do on anyee page template like .this if($config->ajax){ // u do.ajax $data=['status'=>'ok', 'massage'=>'hi whirld']; header('content-type: application/json'); echo json_encode($data); exit; }else{ // u.do html }
  6. super user.s required to create fielders y templatos purposefulness of super user this.is with out such purpose is not.super
  7. no argumentas needeed what.u wants is event->return wire()->addHookAfter('Page::render', function (HookEvent $event) { $page = $event->return; });
  8. $page->find()start from $page if $page != home { $page->find( 'parnet=/blog/' ) will.alwayse return NO things } so >>> u.must use $pages->find() noT $page->find() !! OAR u can.uses $pages->get('/blog/')->children( 'limit=3, include=all' ) if usesing $pages say shits bout array it mean yoU write-over it some where >>> u did a $pages = array some.where ! fix that.or u can uses wire( 'pages ')->find(' you.selectoro stuff here '); or functiones api pages()->find( 'selectros in this' ) amen
  9. wire( 'sanitizer')->entities( $u->title ) => $url . $u->id, wire( 'sanitizer')->entities( $u->request_type->title ), wire( 'sanitizer' )->entities( $dog_ref->title ) => $url . $dog_ref->id, wire( 'sanitizer' )->entities( $mailer->name ), ... "<a href=''>Schváliť</a>", // u NO.entitties on this.ones
  10. looks.ikes u w ant $table->setEncodeEntities(false);
  11. u want.to set for.use serveors timezine no client not big prolem if.u set wrong
  12. here.u go echo $pages("parent=/")->implode('<a href={url}>{title}</a> ');
  13. template=airport|city, title|body%=air u donut need.Airport bcoz u got %=air template=airport|city, title|body%=air, title%=USA template=airport|city, title|body%=air, title%=USA, id!=[title%=nyc] or.in pw v3 u can do template=airport|city, title|body%=air, title%=USA, title!%=nyc
  14. sorte all.by price ? text=a|b, sort=price sorte.by text thens by price ? text=a|b, sort=text, sort=price
×
×
  • Create New...