Jump to content

flydev

Members
  • Posts

    1,167
  • Joined

  • Last visited

  • Days Won

    38

Everything posted by flydev

  1. I dont get it Marco, did you manage the server or its an hosting plan ? Because as we said, as we can send requests on 80 and 443, there is no firewall blocking it. One thing you could ask them or check on the logs, is if your ip get blocked somewhere, they have antiddos mesures and you might had a bad loop throwing requests during a small period, thats just a idea..
  2. Short answer from mobile, yes. Welcome 🙂
  3. @Marco Ro get and post also works from here, at least we receive http answer code, like @BrendonKoz Also, FYI if it help, GET request on HTTP get redirected to /auth from the js code (window.location.href = "/auth/") and the same request on HTTPS is forbidden. On a VPS or private server, you have to adjust the firewall from the OVH dashboard. If it's an hosting plan, then you have nothing to do. https://docs.ovh.com/it/dedicated/firewall-network/#prerequisiti
  4. @protro thanks 👍 If you have already your site content, you have two simple solutions: A. Using Duplicator: build a package remove all files and folders from the package2.zip and keep only the .sql.zip inside upload the installer.php file and the modified package2.zip on the root directory navigate to https://yoursite.com/installer.php and follow the instructions The modified package2.zip file content 👇 B. Using ProcessDatabaseBackups install the module upload or select a db file restore it ⚠️ As always, make a backup of everything before proceeding
  5. I will add a new answer once I have made some tests, comments are welcome. https://github.com/flydev-fr/Duplicator/issues/37
  6. Just my two cents here, I vote to extend the module's developer doc and/or a note in the coding style guide. That's maybe the role of the community to (help) write it and send it as proposal to @ryan by filling a github issue for an eventual revision.
  7. @Flashmaster82 what's the version of your PHP install ? If I am correct, you need PHP 8.1 to get it working. Just saw the posted issue on the github repo, will comment it there, but @Juergen, as you are using arbitrary Union Type on property declaration in the module, it make it available only on php-8.
  8. On my last post in the thread of AdminStyleDark, when I said: I was refering to this one in particulary. I will send a github PR.
  9. (In my first message, I didn't understood that you was going to modify an existing ProcessWire site). But the message is still valid to get an introduction before the update. What do you mean by "just find the code" ? You mean in an admin page ? You have everything you are looking for in `home.php`, read below. Not really, you could even forget the admin, (even if it's not really the case, but that's how I still see it and saw it), the admin pages, fields and templates let you manage and organize what's inside the db, it's just easier. On your screenshot, we can see that the code of the homepage, is in `/site/templates/home.php` and pull from the database the title of the page from the field `title`, some images for what it look to be, a carousel or hero block `hero_image`, also some client testimonials from `testimonials` field. As you are old, to refresh your memory, remember when you was getting theses data from a database with `select * fields from site_db where page="home"`, now you have it at hand, in an admin page, with a lot of API helpers given by ProcessWire to get/set all of that. Now, if you understand that the $page call give you the current visited page, called `home` in your example, in the page-tree, with a template (file with code) `home.php` then you can understand that $page->title, $page->hero_image and $page->testimonials give you the value (from the db) of theses fields. Anyway, please open with notepad the file /site/templates/home.php and paste it here in the thread so we can get the strategy used (I bet it's the simple one with php include() calls) and we will be able to make things more clear to you.
  10. @protro do you get same result with jsConfig() ? Also, I think it's only exposed on admin pages by default. For frontend you will need (as always) to make it available yourself, as nothing is done on frontend things by default, except processwire api: On your <head> tag in frontend, eg. _main.php : <!-- credit to @soma --> <script type="text/javascript"> var config = <?php echo json_encode($jsConfig); ?>; </script> Then // Set a property from PHP // $config->js() is still here for backward compatibility, use jsConfig() $config->jsConfig('mySettings', [ 'foo' => 'bar', 'bar' => 123, ]); // Get a property (from PHP) $mySettings = $config->jsConfig('mySettings'); // Get a property (from Javascript): var mySettings = ProcessWire.config.mySettings; console.log(mySettings.foo); console.log(mySettings.bar);
  11. @Juergen I needed a solution to start with a quite complex form. I tried the module, thats was fast. Freaking cool ! Thanks .
  12. Hi Mike, welcome, as you are used with Notepad, then you are on the best solutionware to keep using it, easier than wordpress really. Read a bit there and choose an output strategy that feel your dev experience (biased suggestion: Delayed Strat.) : https://processwire.com/docs/front-end/output/ https://processwire.com/docs/tutorials/default-site-profile/ Then watch this vid: And enjoy 👍 edit: before you ask, when you will stumb on some ten years answer forum thread, yes they almost still work in 2022. But at least upgrade your php 3 install 🤣
  13. What about setting the flag as Notice::log || Notice::logOnly ? Also check @ryan comment :
  14. @gebeer Interesting. You want to hook WireLog::___save() and recover the type log on arguments(0) 👉 https://github.com/processwire/processwire/blob/dev/wire/core/WireLog.php#L96-L175
  15. I commited some fixes, will push it at the end of the day. But yes, some modules need to be taken case by case, thats why I think everyone using it could make it better by sending pull-requests. There is also some hardcoded style set by js calls, I put already comments on a todo/known bugs section. About the switch, I think the better solution is to reload the page to apply the default theme set by the user, brainstorming needed there. Thanks for your interest ✌️
  16. Bro, I feel very sad for you in term of having fun while developing (working). I feel lucky to be one of those guys who can refuse tasks that should be done on these pieces of software mentioned above, even more when you worked with ProcessWire. However, it is true that you have to take into account an "architecture" already in place. Bosses are "afraid" of change that concerns the backbone of their business, especially when it works as is. What I would do personally, - it also depends on the "size" of the internal architecture and context - would be to rewrite the mess under processwire in your spare time and give them a demonstration of why and how it's better, with arguments about the added value in terms of maintaining and possible future hiring of developer(s). I think it's easier and safer to hire "pure" developers rather than "closed and trained" developers on a given CMS (multi-skilled). I mean there, a pure PHP developer can jump on ProcessWire, where like a guy like me, can't take the other the opposite way. "courage brother"..
  17. @Violet the only thing which could help here is to check the logs as php-8.1 contain new features and incompatible changes. You can check the logs from the admin side in ProcessWire to see if something weird happen, and/or the PHP log of your hosting provider.
  18. Short answer from mobile. Try with that in .htaccess: RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ /2022/$1
  19. @tires the hook need to be Session::loginSuccess - the one given by @adrian - to redirect the user, after he log in. You can write the target url in the session, and you do not really need the GET variable. But as I said in the first idea, if you need to differentiate a user which come from the mailed url, you "have" to give a GET variable or a segment. If you do not do that, the url set in the session will be for all users. It might not be an issue for you. I all needed template, just set $page->url in the session. Apply logic there. And as I said, without distinction, it will apply for all users.
  20. Quite easy ? (see: https://github.com/baumrock/AdminStyleHello/issues/1#issue-1401993078) https://github.com/flydev-fr/AdminStyleDark/tree/dev
  21. ? Perfect, checking it, thanks.
  22. @bernhard could you take a look at https://github.com/flydev-fr/AdminStyleDark Is this the right way to do it?
  23. Its a matter of taste and organization. You can have 3 pages and only one template. If services and about was using the same template basic-page, you end with only one basic-page.php template to work with. The strategy used and the templates are two distinct things. Add Pages to it, and its 3 differents things.
×
×
  • Create New...