similar to: xml builder using straight xml within the rxml template

Displaying 20 results from an estimated 70000 matches similar to: "xml builder using straight xml within the rxml template"

2005 Nov 03
1
Builder / rxml views: hyphens in XML element names
I''m having a strange problem with an rxml view - it won''t let me put hyphens in the names of XML elements. The original problem line was: xml.VISA-SSL do But in any other place, if I insert a hyphen into the name of any arbitrary element, I get the following kind of error: undefined method `theTextAfterTheHyphen'' for #<#<Class:0xb7617180>:0xb7616f28>
2006 Jul 14
2
how to get builder 2.0 to escape attributes in rxml
I am using rxml to produce opml files and need to escape ampersands in the attributes. builder 2.0 docs found at http://builder.rubyforge.org/ show the following xml = Builder::XmlMarkup.new xml.sample(:escaped=>"This&That", :unescaped=>:"Here&amp;There") xml.target! => <sample escaped="This&amp;That"
2005 May 01
5
Example using Builder::XmlMarkup and .rxml files?
Greetings, I''m a newby to both "R"s in RoR. I would like to use Builder::XmlMarkup to generate my pages. If there is a working downloadable example somewhere, that would probably be enough. Otherwise, here''s what I want to do: With the following controller: class AccountsController < ApplicationController layout ''accounts'' model :account
2008 Jul 03
1
Include xsl template in .rxml file
Hello, I have the following code: xml.instruct! :xml, :version=>"1.0" xml.instruct! ''xml-stylesheet'', :href=>''/stylesheets/java_app.xsl'' xml.blueman do xml.response do xml.code(@response.code) @response.url ||= "" xml.url(@response.url) @response.message ||= "" xml.message(@response.message) end end But when
2006 Nov 07
0
rxml template accidentally rendered within html layout
Hi, I have the following in my controller: def show @quest = Quest.find(params[:id]) respond_to do |format| format.html format.xml end end And in my routes: map.resources :quests I have two views for this action, quests/show.rhtml and quests/show.rxml. Now what I would expect as a response to ''/quests/1.xml'' is that Rails sends, as XML, the rendered rxml
2007 Jul 19
0
xml builder cache (with a slight problem on initial load)
Let me give you the background. I am using rxml for a lot of my views for a rails project. I also noticed that there is a lot of the XML being dynamically generated on data that doesn''t change that often. I worked on trying to cache the xml fragment that I needed but came to the quick realization that cache only handle ERB/RHTML files. Needless to say, I have spent some time creating an
2006 Jul 03
2
XML Builder - xml header...
for some reason, i am getting an extra: <?xml version = "1.0"?> in my xml file.. i am using a file called: lastLogins.rxml and the code looks like: xml = Builder::XmlMarkup.new xml.instruct! :xml, :version=>"1.0", :encoding => ''ISO-8859-1'' xml.loginData do @lastLogins.each do |login| xml.entry do xml.user(login.user)
2005 Aug 22
1
XML Builder question (Brain Teaser? or At A Total Loss?)
I''m trying my best to get Builder to give me a nested representation of my nested database tables, but I think I''m not getting any closer to a solution. In fact, now I''m in Syntax Error land, rapidly approaching Missed Deadline country. Perhaps you could be the one to save my ass? Basically, I have Images which have many Options (intended to represent
2006 Mar 12
0
ERB and Builder template engines shouldn''t be so heavily wired in ActionView::Base
Problem: 1. ERB and Builder template engines are heavily wired in ActionView::Base 2. Should be optional. If we use different engine - why load all their stuff if not needed? 3. There are template engines which expect files in their own locations and cache them in their own way. For instance a template engine may store templates in a database. These engines don''t need any central source
2006 Nov 21
1
RXML vs form_tag etc
Railsers: The documentation for *.rhtml views invariably mentions *.rxml views. They sound like a Good Thing, because some of my generating code mixes Ruby and HTML so densely that the code is full of %><% markers. Dropping down to only one language would be a blessing. However, this documentation invariably avoids mentioning one tiny, insignificant detail: How do you inject raw HTML
2006 Jul 20
1
self referential xml using builder
Hi listers, I''m trying to build an xml doc using Builder, but I''m having trouble getting it to draw a tree structure from a self-referential table. Here''s what I''m after: ========================== ---- object structure ---- node (name => root) - node (name => child 1) - node (name => child 2) - node (name => child 2.1) - node
2016 Nov 30
0
Re: [PATCH] builder: Rearrange how template-building scripts work.
On Monday, 28 November 2016 10:40:51 CET Richard W.M. Jones wrote: > Create a new directory (builder/template). Integrate all of the > scripts into a single program, so that templates are generated more > consistently. > > This also changes how the index file is generated. The script now > generates the index file fragment and saves it under version control, > and then
2008 Jul 24
2
Render HTML in RSS Builder template
Hi, I have written an RSS builder template for my Rails app. Everything works great, but now I want to put some HTML code into the RSS Item description tag. Any idea on how to do that? It seems that Builder automatically escapes the string which messes up the HTML tags. Anyone has an example which uses HTML inside their RSS? Regards, Chris -- Posted via http://www.ruby-forum.com/.
2006 Dec 12
2
RXML partial question
All, I have a RXML template which renders partial RXML templates within it. A snippet is below. The "xml" variable is the parent template''s Builder variable. It is passed into the partial under the name "parent_xml". Why can''t I use :locals => {.... :xml => xml ....} in my call to render the partial? It seems like if I do use :xml => xml, it
2006 Jul 20
2
Why is my rxml view being wrapped by the rhtml template in views/layouts?
Why is my rxml view being wrapped by the rhtml template in views/ layouts? I was experimenting with REST, I had a nice little test program with one table: ''resources''. Here''s what the show method looks like: def show @resource = Resource.find(params[:id]) respond_to do |accepts| accepts.html accepts.xml end end I have a show.rhtml
2006 Feb 02
1
actionmailer - No rhtml, rxml, or delegate template
I''m getting this error when I try to send an email. No rhtml, rxml, or delegate template found for signup_thanks But I do have signup_thanks.rhtml in app/view/notifier This is in the notifier model. class Notifier < ActionMailer::Base def signup_thanks(sent_at = Time.now) @subject = "the subject works!" @body["first_name"] = "first name"
2005 Nov 30
0
How to select between RXML and RHTML template at runtime ?
Hi ! I have some actions which I'd like to serve using XML instead of HTML. I have two action templates: action.rhtml and action.rxml. If I do render :action => 'action', ActionPack automatically selects the RHTML template. Is there a programmatic way of selecting which template I'd like to use ? Thanks ! -- François Beausoleil http://blog.teksol.info/
2006 Jun 08
1
No rhtml, rxml, or delegate template found
hi , i''m having a problem with rendering a partial , the partial is in the apps/view/polls folder with the name : _antwoorden_user.rhtml in the view i''m rendering it with <% if @user %> <%= render :partial => ''polls/antwoorden_user'', :locals => {:poll => @poll, :user => @user} %> <% else %> .... gives me the error => No
2006 Jul 26
1
mixing ebr and builder together and having it render as html in the browser
The first problem is that if you make a builder or .rxml file it always displays as xml in a browser. declare! it and the browser gives and error and if you change rxml to rhtml then it thinks you should be making erb. SO quetion #1 is how do I make builder files render in the browser as html. The next thing that I want to be able to do is be able to render parcials or call other files of other
2016 Jan 14
0
[PATCH 2/2] builder: allow a specific template for --list
Allow the user to specify a template in --list mode, which will be the only result in the resulting output (instead of all the available templates). This makes it easier to find out the details of a specific template. --- builder/builder.ml | 6 ++++++ builder/cmdline.ml | 3 ++- builder/virt-builder.pod | 13 +++++++------ 3 files changed, 15 insertions(+), 7 deletions(-) diff