-
Posts
4,077 -
Joined
-
Last visited
-
Days Won
87
Everything posted by horst
-
Many thanks for the suggestions, @Robin S I think the main check / exception must be in the getExif method. A check during install will be useless when deploying a site folder from local to stage or live. But it is no harm to have it too. ?
-
What do you think would be the best way? Returning false or throwing an exception?
-
@Arctic This may help you going:
-
There is no argument to the method page::getFields() https://processwire.com/api/ref/page/get-fields/ https://github.com/processwire/processwire/blob/3bf29d050b7f542f04628fc69c2448466e167acd/wire/core/Page.php#L1274-L1299
-
You can mimic a basic authentication in the file "site/templates/admin.php" Therefor you have to handle a set of valid usernames and passwords in that file too, like in the following example: <?php namespace ProcessWire; $validUsers = [ 'user1' => 'pass1', 'user2' => 'pass2', 'user3' => 'pass3' ]; $validAdminUser = false; if(isset($_SERVER['PHP_AUTH_USER']) && isset($_SERVER['PHP_AUTH_PW'])) { if(isset($validUsers[$_SERVER['PHP_AUTH_USER']])) { if($validUsers[$_SERVER['PHP_AUTH_USER']] == $_SERVER['PHP_AUTH_PW']) { $validAdminUser = true; } } } if(!$validAdminUser) { header('WWW-Authenticate: Basic realm="Adminsection"'); header('HTTP/1.0 401 Unauthorized'); echo '401 Unauthorized! Accessing this page needs a valid useraccount!'; exit(); } require($config->paths->adminTemplates . 'controller.php');
-
choose language of login and password forgot pages?
horst replied to gerritvanaaken's topic in Multi-Language Support
Does it all also not work when executed in the ready.php? -
Kids are, - hmm, well, - mysterious. Many, many years back, when I bought my first pelican case, you could read something in the warranty description like: :-)
-
Yep, I think the most tips above linking to the blog are only valid for greater pw versions. (Dev-Branch)
- 11 replies
-
- 1
-
- bootstrapping
- paths
-
(and 1 more)
Tagged with:
-
Which pw version are you running?
- 11 replies
-
- bootstrapping
- paths
-
(and 1 more)
Tagged with:
-
Hi @alanxptm, this is already there in the edit screen for roles. See the screenshot. You need to tip the checkbox and are done.
- 1 reply
-
- 5
-
Instead of that, you can delete the imagefile. Then the frontend page and the admin page will load again. To prevent this in the future, you may configure a setting for max filesize in those imagefields for uploads. (NOTE: not max dimensions, but max filesize and set it do be handled on clientside, not serverside) I think there is a module available for this max-filesize-setting, but can't remember it's name. (ping: @Robin S do you have created one with this feature?)
-
a) Please tell a bit more accurate about what you have installed / enabled. (PW version, which gif extension and version. b) How big is the original anim-gif in filesize? c) How much memory usage is available for PHP?
-
On mobile here, but you can do something like that with a Textformatter Module. I remember one that restrict images, it is available in the modules directory. The author is @Martijn Geerts , maybe you can take this as a starting point or just „borough“ some code from it. Edit: the link to the module: https://modules.processwire.com/modules/textformatter-image-interceptor/
-
Hi @Joss, long time no see. Nice to see you're still making the seas unsafe, Mr. Pirate. :-)
-
-
@Tom. Interesting thread! I do not use any FrontendFramework if I don't have to, (only jQuery). I more and more try to understand the basics and don't want to learn frameworks. Additional to that, I can copy paste the most from @wbmnfktr post, because my setup is as follows: ? My boilerplate for new projects: Starting with one out of 3-4 personal PW-profiles, that are more or less without content, but with special configurations and modules my personal SCSS Skeleton jQuery and / or some personal JS-snippets Tools I use and need: git my own Preprocessor- and Minifier module in PW some code and scss snippets bound to the $config->debug state for developing Tools that may be added on demand: Lazysizes Slick Slider script MixItUp script Thats my tools that give me freedom from things like grunt, gulp, whatever: The first one is my preprocessor and minifier pw module that detects every single file change of js, css, less and scss files (and the @import dependencies) automatic on page load. It can process less & scss and can minify css, js, html. The second one are three little buttons in the top left on frontend pages that can toggle a breakpoint indicator and a hierarchical background color system to identify html elements dimensions and positionings.
-
Login/Register - disable the email validation link
horst replied to JeevanisM's topic in Modules/Plugins
phpinfo() will shed some light. ? -
GET json data via REST API and store value in session
horst replied to jds43's topic in General Support
There are the php functions json_encode and json_decode. You can use one to add it to the session, and the other to read it from the session. (Sorry, on mobile. Therefore no links or examples here. ) -
You may read in this thread about it, but the last post had the best solution for me:
- 1 reply
-
- 1
-
Haha! Good advice! :-)
-
@tires please can you mark your initials post title with [SOLVED], so that every one can see this in the post listings? If you don't know how to: Go to your initial post of the thread and click "Edit", then you are able to not only edit the post body but the title too.
-
Maybe it has to do with that reported issues on github get more attention (at least from Ryan), and that issues on github are much better to handle in that workflow then in the forums here. The forums here are prior to support people with (maybe at first: "undefined issues" for them) that may be uncovered as wrong usage or something different. And sometimes it uncovers to be an issue in the core code base. Those one need to be filed at github to get recognition in the issue resolving workflow! If you want to contribute to this project, you can file an issue at github into the issue repository, using the issue template there. A detailed explanation also is there to help everyone who is willing to participate in this community project.
-
What is $import->post() ?? Do you mean $input->post() ?
-
Please file a github issue (with the pw version)