|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Does anyone know of a way to validate xml in CF against an XML Schema other than WDDX?
I believe strongly that it can't be done with native CF tags/functions, but perhaps there's an (open source) solution somewhere? I'm sure I'm not the first person to have this problem. Thanks in advance. |
|
#2
|
|||
|
|||
|
This can be done using the underlying Java API classes. This function validates an XML document against a DTD. I would assume that modifying it to validate against a schema would not be too difficult.
http://www.cflib.org/udf.cfm?ID=1056
__________________
Ask if you have a question, but also help answer questions that you have knowledge of! Thanks, Brian. How to Post a Question in the Forums Last edited by kiteless : June 14th, 2004 at 07:15 PM. |
|
#3
|
|||
|
|||
|
I'll give that a try - unfortunately I'm stuck with CF 4.5, so I can't confirm or deny that I'll have access to the Java API. Thanks.
If I get it working with schemas rather than DTD I'll definately post a followup. |
|
#4
|
|||
|
|||
|
Unfortunately, you won't be able to do anything like this with CF 4.5. You'd need CFMX to call the Java API classes since CFMX is Java-based. My only advice for trying to do this with 4.5 is search for some custom tags, CFX tags, COM, or CORBA components that might do XML validation. You might start here: http://www.cfdev.com/xml/xmlparser/ or here http://www.granularity.net/technologies/
Also, you're probably fully aware, but doing something like this is way, way easier with CFMX than 4.5. CFMX has built-in support for XML, web services, and just about everything else. Good luck. Last edited by kiteless : June 14th, 2004 at 07:23 PM. |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ColdFusion Development > XML Schema Validation in CF? |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|