An Interest In:
Web News this Week
- April 12, 2024
- April 11, 2024
- April 10, 2024
- April 9, 2024
- April 8, 2024
- April 7, 2024
- April 6, 2024
August 12, 2011 06:55 pm GMT
Original Link: http://feedproxy.google.com/~r/nettuts/~3/PRMqNfECUdY/
How to Query Web Services with a Build Script
Do you hate that your favorite web service can’t be used in your build scripts? Well, are you sure that’s the case? I’ll show you how to use a popular tool, Phing – which is essentially a port of the popular Apache Ant for PHP – to query the Nettuts+ Prefixr API in today’s quick tip.
Final Sample Phing Project
<?xml version="1.0"?><project name="demo" default="prefixr"><property name="css.path" value="css/style.css" /><target name="prefixr"><echo msg="Updating your stylesheet" /><loadfile property="css.min" file="${css.path}" /><exec command="curl -sSd css='${css.min}' https://prefixr.com/api/index.php > ${css.path}" /></target></project>
Conclusion
The more I use Phing, the more I realize just how powerful it is. While many prefer Apache Ant for its portability, with Phing, I can use my existing PHP knowledge to create any new tasks or filters that I require. That’s incredibly powerful and convenient. What’s your build tool of choice?
Original Link: http://feedproxy.google.com/~r/nettuts/~3/PRMqNfECUdY/
Share this article:
Tweet
View Full Article
TutsPlus - Code
Tuts+ is a site aimed at web developers and designers offering tutorials and articles on technologies, skills and techniques to improve how you design and build websites.More About this Source Visit TutsPlus - Code