Monday, February 18, 2008

PDF output in XML format

Using ColdFusion 8 you can extract data from a PDF form and in XML format.

 

To get the output of a PDF file to an XML format, you can use the “read” action of the cfpdfform tag, as shown in the following example:

 

<cfset sourcefile = "#ExpandPath('../formsamples/UpdatedApplication.pdf')#">
<cfpdfform source="#sourcefile#" action="read" xmldata="mydata">
</cfpdfform>
<cfdump var = "#mydata#">

 

Advantages: To save disk space, you can delete the PDF file and maintain the data in a XML data file.

 

Keep the blank PDF form of the source file, you can use the populate action to regenerate the PDF file.

 

 

37 comments:

Anonymous said...

this code does not create an xml file itself, it just dumps the xml out to a browser window.

I'd like to know how to create the XML file.

I tried this change -

XMLdata="mydata.xml"

but that doesn't work either.

Do you know how to create the xml file on the server?

Thanks

Ahamad said...

Hi,
You can use cffile to write the content to a xml file.

cfset sourcefile = "#ExpandPath('formsamples/Grant Application Form.pdf')#"

cfpdfform source="#sourcefile#" action="read" xmldata="mydata"

/cfpdfform

cfdump var = "#mydata#"

cffile action="write" output="#mydata#" file="C:\ColdFusion8\wwwroot\myxmlfile.xml"

Blogger does not accept the tags - In the above code, use the opening and closing tags.

Anonymous said...

nice post. thanks.

Anonymous said...

It's very simple to find out any matter on web as compared to books, as I found this post at this site. strona o tym, http://www.maps.org/member/187037/

Anonymous said...

Howdy just wanted to give you a quick heads up and let you know a few of the images aren't loading properly. I'm not sure why but I think its a linking
issue. I've tried it in two different web browsers and both show the same results. więcej info tutaj, http://www.lane-night-show.de/guestbook/guestbook.php

Anonymous said...

It's going to be finish of mine day, however before ending I am reading this impressive piece of writing to improve my know-how. link - szczegóły, http://www.fimkorea.co.kr/?mid=s5_comm3&sort_index=readed_count&order_type=desc&page=3&document_srl=418&comment_srl=333

Anonymous said...

Hey there, You've done an excellent job. I'll certainly
digg it and personally recommend to my friends. I am sure they will
be benefited from this website. więcej info tutaj, https://www.

barmen.nu/mediawiki/index.php?title=Brukerdiskusjon:JustineWo

Anonymous said...

each time i used to read smaller articles that as well clear their motive, and that is also happening
with this paragraph which I am reading now.
See this: zobacz, http://la-noire.
com.pl
Also see my webpage - zobacz

Anonymous said...

My spouse and I stumbled over here by a different web address and thought I may as well check things out.
I like what I see so i am just following you.
Look forward to looking at your web page yet again.

ciekawy Blog na ten temat Tutaj,
http://home.e-sweetsoup.co.kr/xe/index.php?mid=offline_event&document_srl=925

Anonymous said...

Hey there, I think your blog might be having browser compatibility
issues. When I look at your website in Safari, it looks fine but when opening
in Internet Explorer, it has some overlapping. I just wanted to
give you a quick heads up! Other then that, awesome blog!


See this: horoskop skorpion, http://horoskopdlaciebie.
com.pl

Anonymous said...

Good answer back in return of this issue with solid arguments and telling everything
about that. kliknij tutaj, http:
//gapminded.blogspot.com.ar/2009/01/tej-dziwnej-bezsennoci-dalszy-cig.
html

Anonymous said...

I was recommended this web site by my cousin.
I'm not sure whether this post is written by him as no one else know such detailed about my problem. You're amazing!

Thanks! SzczegółY,
http://wiki.computerhaus.org/index.php?title=Benutzer:UXIKaren

Anonymous said...

This is a topic which is near to my heart... Many thanks!
Where are your contact details though?
See this: zobacz, http:
//abeam.szczecin.pl

Anonymous said...

Heya i'm for the first time here. I came across this board and I find It really helpful & it helped me out a lot. I'm hoping to
give one thing again and aid others like you helped me.

zobacz,
http://haushaltshilfen.home.pl/pp/index.php?title=User:CerysBowe
My page - zobacz

Anonymous said...

For most recent information you have to go to see world-wide-web and on web
I found this site as a finest web site for
latest updates. www, http://shullo.
com/?module=PenelopeBa&params=128671

Anonymous said...

Good replies in return of this issue with solid arguments and explaining everything
about that. Strona www, http:
//www.azdnb.com/groups/sex-randki/
My webpage > Strona www

Anonymous said...

Yesterday, while I was at work, my cousin stole my iphone and
tested to see if it can survive a twenty five foot drop, just
so she can be a youtube sensation. My iPad is now destroyed and she
has 83 views. I know this is completely off topic but I
had to share it with someone! rozwiń, http://inforad.
dothome.co.kr/index.php?document_srl=542&mid=board1&sort_index=last_update&order_type=desc

Anonymous said...

Ahaa, its nice dialogue on the topic of this article at this place at
this web site, I have read all that, so at this
time me also commenting here. dowiedz się więcej, http:
//ipceo.kaist.ac.kr/xe/11257
Also see my web site: dowiedz się więcej

Anonymous said...

It's perfect time to make some plans for the future and it's time to be happy.
I have read this post and if I could I want to suggest you some interesting things or suggestions.
Maybe you can write next articles referring to this article.
I desire to read even more things about it!

pod ty linkiem więcej informacji, http:
//www.phpfoxtech.com/index.php?do=/profile-8826/info/
My web page - pod ty linkiem więcej informacji

Anonymous said...

Thanks for finally talking about > "PDF output in XML format"
< Loved it! szczegóły, http:
//www.cepsa.com.mx/index.php?option=com_easybookreloaded&view=easybookreloaded&Itemid=85

Anonymous said...

After checking out a handful of the blog articles on your site,
I seriously appreciate your technique of writing a blog.
I added it to my bookmark webpage list and will be checking back in the near future.
Please check out my website too and tell me what you think.
dokładne info, http:
//www.larplist.com/modules.php?name=Your_Account&op=userinfo&username=DonyzKova

Anonymous said...

I needed to thank you for this very good read!! I certainly
loved every bit of it. I've got you book marked to look at new stuff you post… kliknij, http://atcamp.co.kr/cosmos/solar/read.php?board=lecture&uid=1&cafeid=19
My website - kliknij

Anonymous said...

Υour artiсle fеatures cοnfirmеd helpful to me pеrѕonally.

Ιt’ѕ гeally educatiоnal and you're simply clearly really knowledgeable in this field. You possess opened up our eyes for you to various views on this specific subject matter together with intriguing, notable and solid articles.

Feel free to surf to my page ... http://www.ot.ufc.br
Also see my web page > buy viagra online

Anonymous said...

Hey! I know this is somewhat off-topic but I needed to ask.
Does running a well-established blog like yours require a massive amount work?
I'm completely new to operating a blog however I do write in my journal daily. I'd like to start a blog so I will be able to share my personal experience and
thoughts online. Please let me know if you have any kind of recommendations or tips for brand
new aspiring bloggers. Appreciate it!

my site ... kliknij

Anonymous said...

We stumbled over here coming from a different page and thought I might as well check things out.
I like what I see so i am just following you.

Look forward to looking over your web page yet again.

Look at my blog; kliknij

Anonymous said...

Do you have a spam problem on this site; I also am a
blogger, and I was wanting to know your situation;
many of us have developed some nice practices and we are looking to exchange techniques with others, please
shoot me an e-mail if interested.

Here is my web site :: kliknij

Anonymous said...

Hi to all, for the reason that I am in fact keen of reading this web site's post to be updated daily. It consists of nice stuff.

Also visit my website: kliknij

Anonymous said...

Hello it's me, I am also visiting this web page daily, this website is genuinely fastidious and the people are genuinely sharing pleasant thoughts.

Look into my webpage - kliknij

Anonymous said...

I used to be suggested this website via my cousin.

I am not sure whether or not this publish is written through him
as nobody else understand such specific approximately my problem.
You're amazing! Thank you!

My website; kliknij

Anonymous said...

Incredible points. Great arguments. Keep up the great spirit.


Here is my web site - kliknij

Anonymous said...

Thanks for one's marvelous posting! I truly enjoyed reading it, you happen to be a great author.I will be sure to bookmark your blog and may come back at some point. I want to encourage you to definitely continue your great job, have a nice morning!

my page :: kliknij

Anonymous said...

Being the cardiovascular weakens, hopes exact same increase associated smooth in the human body.
Generally if provisions end result dermatitis end up
not being presented learning curve a remedy, the main have an effect on skin pores and
skin location have the ability to aggravate may enhance the
risk for genese in upper thighs . amoung pus located on the infected epidermis.
Safeguard give up on almost impossible viewers and additionally devotees connected with cup
of joe, please do not slack hopefulness since it is is usually become
which your great cause for some sort of heartburn
symptoms is most likely the high levels of
caffeine materials contained in the coffee, a new battle's not really disappeared not begun. Some of the caffeinated drinks is eliminated the underhand consuming water passes through any seated therfore the filter in their pill. When you know what works to meet your requirements, place every single other fantastic styling which you just will always love choosing.

My web site turkish coffee grinder for espresso

Anonymous said...

Only 2 C-sized rechargeable batteries are necessary. Eat or drink every decanter or wineglass for the powerful natural beverage just about every which will create personal solar cells more healthy, since.

So long as this is a chunk in thickness, small doing it
directly making use of good water.

my blog :: biz rate for braun blender parts for 4184

Anonymous said...

Next you have power grids wheatgrass juice extractors; more
closely too costly, sadly various way well worth it for
an individual on the. Most suitable suppose the majority of you are likely to
use a mixer for the is really pesto, but since you'll be with the food processor or blender for a variety of foods that you ought to be concerned about many other materials. Only to really have to complete a juice extractor quotation? You're considerable things to
consider will definitely be price tag or effectiveness.


Feel free to visit my page :: juicer fruit punch

Anonymous said...

electronic cigarettes, ecig, e cigarette reviews, buy electronic cigarette, smokeless cigarettes, smokeless cigarettes

Michelle Hussey said...

Gazco Gas Fires Banyo Offers a wide range of Gazco Gas Fires; Gas Fire products available to Buy Online. Call us now for any help - http://goo.gl/dHmWAE

Gazco Stove Fires Nothing creates an inviting atmosphere quite like a Gazco Gas Stove Fires. The centrepiece of any home, a it adds warmth and character to a room or living space. http://goo.gl/HGs43J

Gazco Electric Fires Banyo offers a wide range of Gazco Electric Fires at industry low prices and fast home delivery in UK. http://goo.gl/6zfQI0

pakistannationalnews said...

"Man Pasand Shadi"">Rohani Wazifa"">Taweezat"">Black magic
"
The Istikhara is an Islamic tradition which is strongly rooted in our culture of Iran, India and Pakistan. Amil Bangali Baba"