Webmastersite.net
Register Log In

Site thumbnails

Title Site thumbnails
Description How can apache be allowed to use X?
Message Text I happened to stumble across something called gnome-web-photo in my package manager which says it creates thumbnails of web sites. It has no documentation I can find, but I figured out how to make it work from a konsole. The only problem is that when I have PHP execute the same command instead of doing it myself it returns "cannot open display: (null)". I gather apache's user must be stuck in a non-graphical mode. Does anyone know how to let apache's user -- which appears to be www-data -- make use of X? The rest of the site thumbnail capture procedure: 1) You need to have ssh access to the server's root account -- in other words you need either VPS or dedicated. Also make sure PHP isn't in safe mode (though it's not likely to be on VPS/dedicated). 2) Install the gnome-web-photo package. Use apt, yum or urpmi since there will be a billion dependencies on a server... everything associated with X-Windows, GTK+, libpng and Firefox. 3) Somehow make sure the user PHP runs as (usually the same as apache's user) has an X session. 4) Use <img src="{LINKSITETHUMBURL}"> in your templates to show the thumbnails as of 4.0.2.
Rating
  • 0/5
  • 1
  • 2
  • 3
  • 4
  • 5
0/5 based on 0 votes.
Ownership Paul
Views 420 views. Averaging 0 views per day.
Similar Topics
Submission Date Oct 16, 2006 - 2:10 PM