Displaying 20 results from an estimated 300 matches similar to: "string matching in erb template"
2011 Sep 27
2
Dashboard parameters to control VIPs?
Some of the Red Hat Enterprise Linux servers in our environment
sometimes get assigned virtual IP addresses (eth0:1, eth0:2, etc).
Puppet Dashboard''s parameters seem like an ideal way to define and
provision virtual IPs on these servers. One could create a "vip1"
parameter on a node, and define a value of the IP address to use for
that vip. A manifest could then be written to
2009 Dec 24
7
nested variables
Hi all!
I have quation: how i may use nested variables/facts? For example, I
have variable $iface. It''s variable declared in node brakets, and, use
with defenition. iface may be eth0, eth1(Linux), em0, ...
<freebsd>, ...
is fact:
facter | grep eth0 | grep mac
macaddress_eth0 => 54:52:00:3D:CB:40
We don''nt know name of $iface in our module (to generate network
2010 Oct 05
0
Puppet truth, nil and templates
Does Puppet have any genuine concept of truth and nil that survives the
interface with Ruby? has_variable? only returns false if a variable has
never been assigned a value at all in the enclosing scope; there is no
way to assign undef to a regular variable (as opposed to a resource
parameter) within a scope and so make it undefined for the template.
It would be a very useful thing to be able to
2010 Feb 08
17
ZFS ZIL + L2ARC SSD Setup
I have some questions about the choice of SSDs to use for ZIL and L2ARC.
I''m trying to build an OpenSolaris iSCSI SAN out of a whitebox system,
which is intended to be used as a backup SAN during storage migration,
so it''s built on a tight budget.
The system currently has 4GB RAM, 3GHz Core2-Quad and 8x 500GB WD REII
SATA HDDs attached to an Areca 8port ARC-1220 controller
2009 Feb 23
3
Require package not working as expected
I have the following as part of a module:
--------------------------------------------------------------------------------
# Ensure "lsb-release" installed
package {"lsb-release":
ensure => installed,
}
# Use our sources.list
file { "/etc/apt/sources.list":
owner => root,
group => root,
mode =>
2017 Nov 18
2
Dovecots header files not optimized for external plugins
Making third-party plugins for Dovecot is really hard and frustrating.
Using dovecot 2.2.33.2 and the following sources, the compile errors keep
coming. The use of g++ is mandated as the underlying backend this plugin
will access only has a C++ interface.
== Source 1
/* g++-7 -c a.cpp */
#include <byteswap.h>
#include <dovecot/lib.h>
#include <dovecot/auth-request.h>
#include
2006 Oct 17
4
Merb, Mongrel+Erb
Hey there folks-
I''m happy to announce the first useable release of my new pocket-
framework Merb. Merb is a mongrel handler with built in controller
and view templating with erb. It has a nice routing system similar to
rails but much simpler. It uses some of the code from the camping
handler and the rails handler and then some of its own secret sauce
to form imho a nice fast
2011 Jun 17
0
.js.erb not being parsed by .erb first
I am trying to dynamically include a javascript file based on a
configuration option however I keep getting this error:
Error compiling asset application.js:
ArgumentError: wrong number of arguments (3 for 1)
(in c:/Users/Dieter/Documents/event_calendar/vendor/assets/javascripts/event_calendar.js.erb:1)
when trying to run this code:
//<% require ''event_calendar'' %>
//=
2006 Feb 20
7
Native erb lacks -%>, where is Rails'' erb?
Native ERB in ruby, and eruby, seem to lack the -%> feature for
suppressing trailing newlines. Thus
erb -n script
gives errors. Where is Rails ERB so I can invoke it directly?
Thank you
Hugh
2006 Jun 22
2
eRuby/erb
Hello. Prospective Mongrel user here.
Can Mongrel act as a server for eruby or erb files?
Example:
<html>
<body>
<p>The time is <%= Time.now %></p>
</body>
</html>
Pistos
2006 Sep 26
1
erb problems
Hi List,
I just read this mail on the rails mailing list, that might be of interest
for ferret. I don''t even know if it is true, that ferret is causing the erb
problems. If it is, then the fix of rmagick might be applicable to ferret
too...
Cheers, Jan
Caleb wrote:
> Sure enough, I did a search and replace for tabs and replaced them with
> spaces. Is this a difference in the way
2006 Jul 26
0
SAX Parsing and erb?
Hi,
I''m trying to parse a XML document and put some of that information
inside a rhtml file. I also have partials that I want to wrap around
content in the XML stream. However, I don''t have any clue how to pass
an object to the SAX2Listener so it can combine the partials and the XML
together. Normally, in java I would pass the HttpResponse object or the
PrintWriter
2006 Jun 28
0
Getting name of currently rendering ERb template in view?
If I''m writing code in a template and I want to refer to the name of the
template itself so that I can pass it to a helper method, is there a
built-in variable (like controller_name or action_name) that I can use.
Assume x.rhtml and in this template I have helper_method(). I want to
pass "x.rhtml" into helper_method without hardcoding it.
Do I have access to the _currently
2006 Jun 28
3
ERb question with xml
In the rdoc there''s an example:
xml.em { xml.b("emp & bold") }
Which produces:
<em><b>emph & bold</b></em>
But what if I wanted to nest tags with text, i.e.:
<em>just emph and <b>emph & bold</b></em>
?
I''ve messed around with it and have only gotten bizzare results or
nothing displayed at all -
2006 May 30
1
DOM values in ERB Variable?
I am trying to post the current brower window sizes into the user''s
session file with a form_remote_tag call as follows:
<%= form_remote_tag :url => url_for(:controller => "welcome", :action
=> "login", :iheight => "1", :iwidth => "2") %>
But how do I get the DOM data for window.innerHeight and
window.innerWidth into an
2006 Apr 05
1
Tag libraries for ERB/RHTML?
For any JSTL/JSP tag library heads out there - any projects underway to
generate tag libraries for ERB and hopefully standardize some of that
basic RHTML behavior?
Seems like closures are just the thing for implementing a tag processing
class, too.
Thanks,
Wes
--
Posted via http://www.ruby-forum.com/.
2006 Apr 06
0
$SAFE ERB
Hi all,
I''ve got some ERB templates in the database which I want to run in a
$SAFE=2 binding. I''ve got it working in the tests, but as soon as I try
to view it through the full stack, I get an "Insecure operation -
class_eval" exception from
/usr/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/base.rb:1550:in
`class_eval''
Two things:
2006 Feb 07
4
__END__ equivalent for erb?
Time and time again I find the need to terminate evaluation of an erb
file on a certain line for debugging purposes, but can''t figure out a
way to do it. Is this possible?
Thanks!
John
--
Posted with http://DevLists.com. Sign up and save your time!
2006 Feb 20
4
SHow do you suppress ERB newlines globally
Is there a config flag to suppress the newline at the end of every ERB
''%>'' tag, so it would not be necessary to type ''-%> each time?
--
Posted via http://www.ruby-forum.com/.
2006 Jan 22
0
Escaping and Unescaping text in ERb
Instead of continuing the thread hijack, I''ve started a new one....
Douglas Livingstone wrote:
> 2006/1/22, Kevin Olbrich <kevin.olbrich@duke.edu>:
>>
>> You know, this has been bothering me a bit lately. If the point of
>> doing an html escape on the output is to prevent security problems,
>> wouldn''t it make sense for the default action on