Posted by guDa on September 2, 2010 at 2:27pm
Hi there,
I'm planning to build a font showcase but I want to develop some feautures.
When an user upload a font to the server using font content type, the font's preview will be created automaticly.
In the uploaded font's node, there will be a textfield to create preview of user's random text.
How must I start to develop these features?
Comments
Step one: Learn
Step one: Learn PHP...
Pobster
Steo two: ?
Step one is OK.
What about step two?
I'm developing a module now but I don't know what is the best way to realize the features.
Step two: Don't run before
Step two: Don't run before you can walk... ;o)
Fonts are a funny thing, you can't just stick some text on a page and get it to render in any old font - the font has to be installed on the clients computer (the person viewing the webpage).
Here's an idea for a workaround, render the text as an image;
http://www.linein.org/blog/2009/02/26/php-font-preview-function-text-to-...
Pobster
Using GD..
I think, using GD, uploaded font may be previewed.
If I create a content name whose name is "font", and I add a file field to upload fonts, then I don't know how to use GD to get preview of uploaded file in node or views.
Yeah... GD is all well and
Yeah... GD is all well and good, but it's HEAVY... As in a heavy load on your CPU... If you're planning on having more than just a couple of page views at a time then the link I sent you before is definitely worth checking out.
The part of the Drupal manual you're looking for is, Theming nodes by content type else you can always install Contemplate which will allow you to theme content-type display in the Drupal UI.
Pobster
Thanks
I suppose that these links are what I looking for.. ;)