Jump to content

cpx3

Members
  • Posts

    186
  • Joined

  • Last visited

Everything posted by cpx3

  1. Whatever I do, it does not work (it shows only the link). I have only this textformatter and the video is public: <p>https://www.youtube.com/watch?v=ciyEItodGOw</p> I have no idea what else could be wrong…
  2. By the way, it looks as if the module would not even touch the source code. There is just the link, exactly like I put it. But I got an entry in the log file, which says: Retrieved embed for: https://www.youtube.com/watch?v=… [page:241698, field:bodytext_ck] So the module seems to work (I replaced the v= with dots as otherwise the video appears here.) Any idea what might be going wrong?
  3. I uninstalled an reinstalled everything, but the problem remains. I only see the link, even if I configure the module to hide it…
  4. Aaaah… thanks!
  5. Yes, I did at least ten times. But after hitting the Refresh button the module appeared as installed again (and even the textformatter was active in the textfield). Till now I was not able to uninstall the module to do a clean reinstall…
  6. I did, yes. I reset it and set it again, but with no result. I also tried to delete the module to reinstall it, but it immediately reappears after deinstallation so I cannot delete it. When I deleted the files it was shown missing and PW asked me whether I wanted to delete it from the database (what I did) but then I got an SQL-error when trying to reinstall it. Seems as if something is broken with the module…
  7. Hello to all, I just installed Ryan‘s video embed module but I cannot get it to work. The videos appear in the cache, but regardless what settings I have, only the text with the URL will show up (it does neither hide the url if I set that option in the module‘s options.) On an other site it works with the same videos and settings but I have no idea what I am doing wrong. Any idea? Thanks in advance, Bernhard
  8. A million thanks! :)
  9. PS: When I link to another page the modal remains blank...
  10. Bernhard, thanks for the quick answer! If I want to open the page I am actually editing, what would be the url?
  11. Hi to everybody, In my backend I have a markup table that lists some information via a Runtime Markup field. Now I would like that on click on of the items the details appear on a modal. I succeded to open the modal an to display a complete page, but how do I only display the content of another runtime markup field on that modal? Thanks as always, Bernhard
  12. Thanks! :)
  13. Hi to all, I have a very annoying problem: The selector $p = $pages->get("template=data-newsletter-subscribers,email=$strMail"); will always find and update pages that are trashed, even if there exists a none trashed version. What am I doing wrong? Thanks in advance, Bernhard
  14. @adrianI just had the same problem, which took me hours to figure it out...
  15. @Jan RomeroYou are incredible. Danke! (PS: I like your profile image!)
  16. Hi to all, I have a page reference field (select_categories) that references to a page called "unternehmen". When I debug it, PW says that the of the referenced page is "unternehmen". But when I put the condition, I get false. What am I doing wrong?
  17. Thanks for that. Looks like that the problem was that one select_author is a select with a single value... I changed it and now it seems to work.
  18. Hi everyone, I have quite a strange problem. When I use the following code with a terminal php command, it produces the following error message: Fatal Error: Uncaught Error: Call to a member function of() on int in /site/templates/process_pagefields.php:20 #0 {main} thrown (line 20 of /site/templates/process_pagefields.php) When I use it with Tracy it works fine from time to time, but sometimes it echoes "0", too. Any ideas what I am doing wrong? Thanks in advance, Bernhard Here goes the code include("/html/index.php"); // bootstrap ProcessWire // Get derefAsPage property of page_field_b to distinguish multiple/single page fields $deref = $fields->get('select_related_articles')->derefAsPage; foreach($pgs as $p) { // For this page, get the pages selected in page_field_a $selected_pages = $p->select_author; // Standardise $selected_pages to PageArray in case of "single" field if($selected_pages instanceof Page) $selected_pages = $selected_pages->and(); foreach($selected_pages as $selected_page) { // Add this page to page_field_b on the selected page $selected_page->of(false); if($deref) { $selected_page->select_related_articles = $p; echo "Set $p \n"; } else { $selected_page->select_related_articles->add($p); echo "Added $p \n"; } $selected_page->save(); } $numPgs--; echo $numPgs."\r"; }
  19. AndZyk, I found the solution. For whatever reason, the file compiler option was deactivated in config.php, so the templates were not compiled...
  20. Hi fellow programmers, I have a strange problem: when I try to use any functional field I get the error message "undefined function"__richtext()" or whatever I try. As soon as I include <?php namespace ProcessWire; ?> in my template files, everything works fine. The _init.php file exists and is not excluded, the same is true for ready.php and they seem to get included. Any ideas? Thanks, Bernhard
  21. Thanks again for the answer. Actually I only called that selector on a testpage which had nothing on it than this selector plus pages->find. The solution for the moment was to add a "minimum date" (i.e. created>date_minim) which seemed to be the only possibility to increase speed. The interesting fact was however that the same selector with the same data (I did not change anything) worked from 1000 ms to 80000 ms.
  22. Hi to all, I have a quite strange problem. If I open a page that contains the selector select_countries=oesterreich, begin=(start_date=''),begin=(start_date<=today),end=(end_date=''),end=(end_date>=today), template=template-news, checkbox_not_startpage=0, select_categories!=tipps|shortcuts, id!=, limit=5, sort=-created things get so slow that I usually need to restart the whole server to be able to login to PW-admin. I attached the profiler output of the function and you can see that with the exactly same data the output time goes up to minutes... Any idea? When I put the selector in the debugger it has an execution time of about 1200 ms. The problem only seems to appear when the selector is (the first and only) part of a function. Any ideas? Thanks in advance, Bernhard
  23. Thanks for the great help everybody!
  24. Thanks once more for the answers! My problem is that I have no idea how to get the value of select_countries.title (which is a referenced page). I tried (beside many variations): foreach ($items as $p) { echo $p->select_countries.id; } But with no results...
  25. Thanks to everybody for the answer! I tried findRaw which seems to be the most effective but brings me to another problem: How to access page references? I have the following code: $items = $pages->findRaw("template=template-news, select_region=austria, limit=2, objects=1", ["select_countries" => [ "id", "title" ]]); where select_countries are referenced pages. But I have no clue how to access the select_countries id as it neither works with array[0] nor with select_countries->title...
×
×
  • Create New...