Jump to content

Manaus

Members
  • Posts

    212
  • Joined

  • Last visited

Everything posted by Manaus

  1. Thanks jmartsch, I'm using Template Engine Fatory, with 2.7. I think the problem resides in passing values to the twig templates. If I do $login = $pages->get('/login/'); And then in the twig template: <p>{{ login.url }}</p> I don't see any value. How do I pass values? Thanks!
  2. Hello, I'm trying out a template engine conversion of a website. In a foo.twig page I'm calling a isValidUser function, which I required in a foo.php template page. But the engine returns the function in unknown. How do I include functions in a twig template? Thanks!
  3. RT @49SD: Oh my god whoever made thing thank you! https://t.co/XalO15FOPn

  4. RT @puleddu: One way to make a friend happy, is to use golden ratio. https://t.co/dFzMfmmorU

  5. Is there a way to translate the prompt to action generated by this code? Thanks!
  6. Basically you have to create download pages under /downloads/, which is created by the plugin, for each file serving. You create them via the admin, or via API. Each /downloads/download/ page allows a file field and creates a unique hash, that you put, when invoking the file download, after the /downloads/hash/ url segment. Like for example /downloads/hash/18297192837oiu etc. Each download page allows for 5 file download, but you can customize the number. You can also customize the expiring time in the plugin settings. Be sure to tweak the plugin code as I mentioned in the post above, at least for me it solved a recurring bug.
  7. Hello, since include is sort of copy'n'pasting code in the calling file, I might have variables value overwriting. Is it possible to have variables valid for the included file alone? Something like $this->title etc? Thanks!
  8. RT @x0rz: #JPEG #TheDefinitiveGuide https://t.co/s4Xp9eAfJw

  9. RT @DannyDutch: If you face swap Mulder & Scully they look like a great Synth Pop band. https://t.co/Sai6CsC8Am

  10. Hello, I've seen a new kind of syntax, using curly brackets as {page.field}, available in the new branch of Processwire. But I can't really find the page reference/blog post about it. Any suggestion on where to find it? Thanks!
  11. Hello, I need to change $user's data on form submission, this is the code: // prepare for saving $user->of(false); // save the data $user->nome = $nome; $user->cognome = $cognome; $user->azienda = $azienda; [...] $user->save(); $user->of(true); But I get an error: Call $page->setOutputFormatting(false) before getting/setting values that will be modified and saved. Can't get the source of the error. Thanks for any suggestion
  12. Solved using $path = $this->config->paths->files . $page->id . '/'; instead of $path = $this->config->paths->root . $this->config->urls->files . $page->id . '/'; Ok. Now how do I code the links to files? ... Using /downloads/{$thepage->dg_downloadhash}/ returns me a 404... Thanks!
  13. Getting closer.. At line 198 of DownloadGuard.module I added this line: $this->message("{$path}.htaccess"); So I get in the messages this awkward line: /Users/utente/Sites/mysupermegawebsite//mysupermegawebsite/site/assets/files/1079/.htaccess Path is $path = $this->config->paths->root . $this->config->urls->files . $page->id . '/'; But I don't know the proper way to edit it... Thanks!
  14. Hello, mine neither works locally, I get a Could not create .htaccess for myfile_xlsx.zip at the needed location. I gave 777 to /assets/ but don't know where the .htaccess file needs to be placed. Config: Pw 2.7.2 Php 5.4.10 Apache 2.2.3 Thanks!
  15. Can't say why, but the downloaded module has weird owner and group, probably the admin, can't say. Wrote to the provider, whose services I am starting to understand less...
  16. The salt is the same on both local and remote (I upped the whole bunch)...
  17. Ah! Thats it! Well forgery is gone, but I cannot login via usual credentials. Should I change pass uploading some temp code? Setting debug to true I see the error resides in session_start(), No such file or directory (2) in /var/www/[...]/web/site/modules/AutoFbPost/AutoFbPost.module Failed to write session data.
  18. Thanks BigPoet, put the string in the config, but nope, still alarmed for forgery... I also deleted an recreated /logs /sessions and /cache, to no avail...
  19. Hi, I downloaded a module (in this case AutoFbPost). After finishing the download I've been logged out, and when I try to log in I get a 'This request was aborted because it appears to be forged.' I cannot find the module within /site/modules/, where is it? Thanks!
  20. I talked to the hosting provider, he said the settings are ok, and "If you are using Wordpress you can activate the Ftp". Is there a parallel in the Processwire world? Any suggestion? Thanks
  21. Thanks horst, the owner is Scrooge, the group is McDuck, but the php user is Mickey. I guess I have to tell the provider to change the first? Thanks
  22. Hello, I get destinationPath is not writable (image) when saving a page with an Image on remote host. This thread advises to put return $this->error($this->destinationPath." is not writable"); on the inputField.module. I get /site/assets/files/1058/ is not writable as a result. Oddly, the dir is 755. Phpinfo does not mention safe_mode, save a sql.safe_mode which I don't think fitting. The website resides under a /test/ directory. Pw version is 2.7.2. Thanks for any suggestion...
  23. RT @iamdevloper: The state of the Node ecosystem after that guy unpublished his modules from npm https://t.co/HPy4KUCOtJ

  24. Hello, I noticed that for geting the image right url I have to print two values <? foreach ($page->children as $child): ?> <img src="<?php echo $child->image->url, $child->image ?>" alt="" /> <? endforeach ?> Is this the normal usage, or am I skipping some important part? Thanks!
×
×
  • Create New...