Jump to content

DrQuincy

Members
  • Posts

    248
  • Joined

  • Last visited

  • Days Won

    1

DrQuincy last won the day on August 30 2023

DrQuincy had the most liked content!

Profile Information

  • Location
    UK

Recent Profile Visitors

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

DrQuincy's Achievements

Sr. Member

Sr. Member (5/6)

70

Reputation

  1. That's really good, thanks for the suggestions! I'm going to keep that as a potential way. I like it, thinking outside the box. 🙂 My somewhat liazier solution is simply to add a field to the user template: Legacy, Legacy converted, and New. If A Legacy user attempts a login it simply sends them to the password reset page. And when they do they become Legacy converted. Your way is far slicker so I'll present the client with both options.
  2. I have an old custom site I built myself where the passwords are hashed using BCrypt. I'm assuming the answer is no due to the one-way nautre of hashing but is there any way to take my bcrypt-hashed passwords and import them into PW? Where as my passwords stored the BCrypt strength, hash and salt together, PW seems to store the hashed password in two parts. I think it's further complicated by the $config->userAuthSalt value (this looks more like a pepper to me). It can't be done, can it? In which case, will just have to copy the emails, etc across into PW and send them each an email asking they set a new password or display a message on the website if a legcay email is used to attempt a login.
  3. Oh wow, you are amazing, LOL! That worked great. The only downside I can see if that I can't see a way of having a dynamic number of rows in the Google Doc. So I have to paste more than I need for the update to work. E.g. If I paste 10 rows in the Doc that limits it to 10. That should be okay but am I missing something that would allow me to have any numbers of rows pull through?
  4. Hi all, This is nothing to do with PW… I have some data in Google Sheets. Do you know if it's possible, ideally without having to use their API, to create Google Docs that automatically feed in data from certain sheets/cells. E.g. A Google Sheet has a list of addresses that have address in one column and a “type” flag attached to them (e.g. rural, suburban, urban). Let's say there are 3 x types as mentioned. Is it possible to have 3 x Google Docs that feed in addresses filtered by type? And, ideally, if the data is updated in the Sheet it automatically progates into the Docs. Can this be done? I have had a look but can't find anything. It looks like they have a decent enough API but it looks like it would take more work than I have time to spend on it. Thanks.
  5. Thanks! So I guess since that github comment is ~3 months old you have to be on a fairly recent version for the performance increase.
  6. When you access an image from the API you can get the width and height with $imade->width() and $image->height(). When you run these internally does ProcessWire get the sizes from the database or does it actually use GD to get them? I'm assuming if you aren't creating variations on the fly it just reads them from the database (the schema has width and height columns). Just checking that there won't be any significant overhead if doing this on lots of images.
  7. I have a site that has a parallax fixed banner at the top and then the rest of the content goes underneath with a higher z-index. It works great but when — on a Mac at least — you scroll quickly down to the bottom of the page it scrolls beyond the height of the document body and then snaps back and for a breif moment you can see the fixed banner underneath. Is there a CSS property to prevent this?
  8. Thanks! Looks like there are a few LG Ultra Fine options. There's a secondhand 22" one at 4096 x 2304 on eBay at a decent price. Perfect!
  9. I want to get an external display for my new 24" iMac. I don't want something huge but I want it to be retain display. It seems like most monitors out there are either about the size I want (20"–24") but they are “full HD” (only 1080). Or 4k, which is a better resolution, but the screen sizes are huge! Without getting an Apple Studio Display or LG Ulttrafine, does anyone know if a 20"–24" display that is also retina?
  10. I've got this code: $field = wire('fields')->get('mySelectOptionsField'); $options = $field->type->getOptions($field); echo $options->first()->title; The echoed statement is not HTML-encoded. However, when you get select titles from $page rather than from $fields the title is HTML-encoded. I get that this is intended behaviour. I just wanted to check: When in the front-end and using the API is the general rule anything you get via $pages or $page has of set to true by default but anything else — such as my example above — there is no output formatting since that only applies in the context of pages Is there an in-built way to HTML-encoded from $options as above — or should I just used $sanitizer->entites()? Thanks.
  11. Interesting, you learn something new every day! I'll bear that in mind for next time. I think I was put off by this: Since I was reading and writing quite complex models I was more comfortable using JSON and sharing data that way.
  12. I believe bootstrapping for when your other script is not already a PW instance, including command line (I have used that on a project before, by the way, and it's very useful and easy). With the multi-instance option, due to the PHP namespace, you can only write to the main instance. You can read from as many others as you want but you can never save anything as when you run new \ProcessWire\Page you are always creating a page in main instance's namespace. In my case, I needed to read from the main instance and write to the secondary one so it wouldn't work for me. At least that's how I understood it! I couldn't see anything in the doc that allows you to create new pages in secondary instances.
  13. Thanks for confirming. Yes, I am currently using a Textarea rows="1" and removing line returns on save so it effectively does the same thing.
×
×
  • Create New...