Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Can I use jQuery to append a form to an article?
Hello
Just a quickie.
Is it possible to use Textpattern tags inside a jQuery function?
Something like this:
$('article').append("<txp:output_form form="myform" />");
Thanks
Offline
Re: Can I use jQuery to append a form to an article?
Textpattern tags are server-side code (and are to be parsed on the server), JavaScript is client-side. Yes, you can use Textpattern tags in any content, in any context — tags and the tag parser don’t care. What you might recognize as JavaScript, is just like any other line of text for Textpattern, its parser and the server.
Offline
Re: Can I use jQuery to append a form to an article?
Thanks Jukka.
I managed to do what I was trying to do by using jQuery’s load function and loading the html content of a form from a text file.
Offline