Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 309
  • Last Modified:

png graphic read an xml file?

can a png graphic read an xml file? is there special software for that?

I have 100 graphics and each with a different copy and domain but instead of opening up each graphic, it would be most ideal to just place a file on the server, then have graphics dynamically read the xml.
0
COwebmaster
Asked:
COwebmaster
  • 6
  • 6
  • 3
7 Solutions
 
HellmarkLinux Systems AdministratorCommented:
Graphics are just data. They cannot perform any function. That would be like saying that you have a book, and you want the book to make you dinner. Data cannot do anything but exist and be manipulated.

However, you can have some PHP (or ASP if you like being Masochistic) script that can work with something like Imagemagick or GD to dynamically generate an image. This way, you can detect which domain is being used, pull up the text for that domain, and pass that text along with a background image and some basic parameters (font, size, color, placement, etc) to generate the image needed right on the fly. Is this what you are wanting?
0
 
COwebmasterAuthor Commented:
yes that is correct.  so what is the best tool out there for this?  Also, what is GD?
0
 
HellmarkLinux Systems AdministratorCommented:
Both GD and ImageMagick are tools for dynamically manipulating and creating images. You've probably seen Macros for doing things in photoshop, well, think of GD and ImageMagick as something similar to that. Most webservers by default have one or the other installed, and both are nice for working with from PHP. Without knowing more information about your server, and what you want to code with, I cannot really help more.
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
COwebmasterAuthor Commented:
it's a linux server.
0
 
HellmarkLinux Systems AdministratorCommented:
Except it isn't a server, nor is it linux only.
0
 
liveaspankajCommented:
if you are familier with Action script you can make a flash that reads image and xml/rss and put the data on it.

If you want to use PHP or JSP or Java there are libraries that is used to create images from data and images.
0
 
HellmarkLinux Systems AdministratorCommented:
Sorry about the last post, I miss read things, thought that someone else was implying that GD was a server application.

As far as your server, could you post information about what is installed? Also, do you have any coding preferences? If you do not have certain things installed, that could effect how you go about things. For instance, if you do not have PHP support in Apache, or use a different http server app that cannot use PHP, then that closes off that as a branch of possibility.
0
 
COwebmasterAuthor Commented:
I host wp sites on my server and have apache, php 5 and my sql.  I also have railo installed.
0
 
liveaspankajCommented:
then you can make a php script and use GD or ImageMagic library
0
 
COwebmasterAuthor Commented:
okay.  what is the url to download GD?
0
 
HellmarkLinux Systems AdministratorCommented:
You may already have GD, or ImageMagick, installed. If not, it would probably be easiest to download and install via your distro's package management tools. Without knowing what you run, we cannot say which method you may use.

If you happen to use a debian based distro (which includes Ubuntu), you would need to run something like:
sudo apt-get install libgd2-xpm-dev php5-gd

For SuSe, I believe you would need to do sudo yast -i php5_gd but I am not totally sure as I am not a Suse user.

For Redhat based stuff (Fedora, RHEL, etc), I think it is sudo yum install php-gd but again, don't quote me on it.
0
 
COwebmasterAuthor Commented:
okay cool.  I use fedora so I'll check it out.  thanks!
0
 
HellmarkLinux Systems AdministratorCommented:
Have you had any luck with this yet?
0
 
COwebmasterAuthor Commented:
Thanks!
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

  • 6
  • 6
  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now