Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

japanime

macrumors 68030
Original poster
Feb 27, 2006
2,916
4,844
Japan
For years, I've been able to print pages in Safari using command-P. Today I tried to print a web page using that shortcut, and instead of opening the print dialog window, my browser redirected to a website that generated a PDF of the page I was viewing.

I'm running Safari 12.0.2 on High Sierra.

Has anyone else experienced this? Is it a stealth "feature" recently added by Apple?
 
Last edited:

cruisin

macrumors 6502a
Apr 1, 2014
962
223
Canada
If anything, it’s a stealth feature of the malware you have. Even in Mojave ⌘ + P still works to bring up the print dialog window (complete with PDF options in the dropdown list in the bottom left). Apple devices have had PDF generation capabilities built in for quite a while now (even iOS), there is no need for a PDF generation website.

Do you have a screenshot? What website was used (I doubt the address starts with apple.com)? Did you install a printer recently (did it come with its own PDF printer)?
 

japanime

macrumors 68030
Original poster
Feb 27, 2006
2,916
4,844
Japan
I don't think it's malware.

Rather, it seems that a custom shortcut I created a couple of years ago doesn't play nice with High Sierra. I had set command-P to bring up the "Save as PDF" option after invoking the print dialog box. Basically, under Sierra and earlier, typing command-P once brings up the print dialog, then typing command-P again brings up the "Save as PDF."

It still works this way when using Preview, Pages, and other apps on High Sierra. However, with Safari, it automatically sends the URL to the PDF-creating website. (It's a legit website, nothing nefarious.)

Problem solved, sort of. I still don't know why my custom shortcut works properly with apps other than Safari. But it doesn't appear to an issue with malware.
 
Last edited:

cruisin

macrumors 6502a
Apr 1, 2014
962
223
Canada
A quick look at the shortcut hack shows that it literally matches "Save as PDF…" or what the shortcut name is set as. Safari (and other apps) are using "Save as PDF" now under Mojave, so in High Sierra you might have combination of both (or just Safari is running the Mojave version). Do a quick check. Under Mojave "Save as PDF" matches everything (Safari, Preview, Word, every app with the default print dialog), so the shortcut (without the …) works as expected, but I still don't get a website so you might have a 3rd party add-on.

If it still doesn't work, you can make your own PDF shortcut. Under the PDF menu in the print dialog, you can edit the menu and add your own PDF save folder. Whatever name you give this, you can reuse the name in the keyboard shortcut menu and it will work similarly (but slightly differently as it makes a PDF in the location you set with default settings).
 
  • Like
Reactions: japanime

japanime

macrumors 68030
Original poster
Feb 27, 2006
2,916
4,844
Japan
A quick look at the shortcut hack shows that it literally matches "Save as PDF…" or what the shortcut name is set as. Safari (and other apps) are using "Save as PDF" now under Mojave, so in High Sierra you might have combination of both (or just Safari is running the Mojave version). Do a quick check. Under Mojave "Save as PDF" matches everything (Safari, Preview, Word, every app with the default print dialog), so the shortcut (without the …) works as expected, but I still don't get a website so you might have a 3rd party add-on.

If it still doesn't work, you can make your own PDF shortcut. Under the PDF menu in the print dialog, you can edit the menu and add your own PDF save folder. Whatever name you give this, you can reuse the name in the keyboard shortcut menu and it will work similarly (but slightly differently as it makes a PDF in the location you set with default settings).
Sorry, I should have been more clear. You are correct. Apple changed the string from "Save as PDF..." to "Save as PDF" under High Sierra, and I edited my shortcut to match that. Still, command-P effectively opens both the initial print dialog and then "Save as PDF" under all apps that I've tested other than Safari. I simply saved another keystroke shortcut to invoke it under Safari, so all is good now.

I doubt I'll ever figure out why the shortcut caused Safari to redirect to the PDF-creating website (pdfmyurl-dot-com); maybe it was something in the OSX development code that never got removed from the master build.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.