placeholder

Dynamic Placeholder substitution in properties in java

Hi, I wanted to substitute the placeholder dynamically in properties in a java application. Like WelcomeMessage=Welcome Mr. {firstName} {lastName} !!! These firstName and LastName variable needs to be substituted dynamically. Should we use velocity template engine for the same? Or are there any other opensource frameworks for the sa...

JQuery to add item to Asp.Net PlaceHolder control

It looks to me that the ASP.Net PlaceHolder control doesn't emit any HTML, and therefore can't be used by clientside javascript or JQuery to add items to the PlaceHolder. Does anyone know of a way around this limitation, or of an ASP.Net control that can be used to dynamically add items by client side code? ...

Can I populate list items in a ASP.NET dropdown list from a ASP.NET Placeholder?

I'm designing my own custom control that contains a .NET dropdownlist. What I'm wondering is if it is possible to populate my dropdownlist with listitems placed in a placeholder? For example: <asp:DropDownList ID="ddlFilter" runat="server" > <asp:PlaceHolder ID="ListItemPlaceholder" runat="server"/> </asp:DropDownList> This doesn't...

C# append to placeholder

So I am trying to make a dynamic form builder where people can add a new form and add fields to that form (the add field brings up several textboxes & dropdown options for that new field). Is there any way to append to a placeholder control when clicking 'add new field'? Also, what is the best way to get the values from those dynamical...

Finding placeholders and put then in an array

In my string I have place holders like: ##NEWSLETTER## , ##FOOTER# ##GOOGLEANALYTICS## etc. Each of those placeholders is delimited by: ## I want to find each of thos placeholders and put them in an array. The tricky part is that what's inside the ## delimiters can be anything. ...

Updating placeholder during runtime

Hi Everyone, here is the problem I am having with placeholder: I have a repeater and within that repeater, I have an item template. Now this template is formatted with a couple of tables, but for this question I have removed them to make things easier to read: <asp:Repeater ID="Repeater1" OnItemDataBound="R1_ItemDataBound" runat="serve...

Creating/Handling events for controls when added during runtime.

I am using a Repeater which contains a placeholder. The placeholder is bound to my database and each ItemTemplate contains 1-6 radiobuttons depending on what the database returns. What I need to do is somehow keep track of which one of the radiobuttons is checked for each question so I can write the user's answers to the database when t...

Extending Zend View Helper Placeholder

I was reading the manual about basic placeholder usage, and it has this example: class Bootstrap extends Zend_Application_Bootstrap_Bootstrap { // ... protected function _initSidebar() { $this->bootstrap('View'); $view = $this->getResource('View'); $view->placeholder('sidebar') // "pref...

jquery.ui sortable using a table and item:tr , placeholder difficulties

Hi I would really like to give some sortable goodness to the myriad old tables I have created. A little work has a proof of concept behaving ok. My one sticking point is that the placeholder does not work at all in IE 7 when using item:TR . It works OK in FF. I can make an perform correctly. It seems to be specific to tables and ...

Loading user controls programatically into a placeholder (asp.net)

In my .aspx page I have; <%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default.aspx.vb" Inherits="_Default" AspCompat="True" %> <%@ Register src="Modules/Content.ascx" tagname="Content" tagprefix="uc1" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-trans...

How to get at contents of placeholder::_1

I currently have the following code: using boost::bind; typedef boost::signal<void(EventDataItem&)> EventDataItemSignal; class EventDataItem { ... EventDataItemSignal OnTrigger; ... } typedef std::list< shared_ptr<EventDataItem> > DataItemList; typedef std::list<boost::signals::connection> ConnectionList; class MyClass { void OnSta...

What's the difference between PlaceHolder and <div />?

In an ASP.NET project I have the following HTML: <asp:PlaceHolder ID="plcTitle" runat="server"></asp:PlaceHolder> <div id="divStrapline" runat="server" /> which are populated with this code: if (this.TitlePanel != null) { plcTitle.Controls.Add(this.TitlePanel); } if (this.Strapline != null) { divStrapline.Controls.Add(this....

Placeholder containing dynamic table is empty unless I create table twice

I am dynamically creating a table that contains a textbox in each cell. The table is put in a placeholder control. Everything displays perfectly. The problem is when I go to retrieve the values entered in the cells. I have the code to generate the table in a separate method called CreateTable(). In order for my program to find a tab...

Adding dynamic links using NavigateURL on ASP.NET (VB)

Hello, I Have this code in my page, and I want that every NavigateUrl display another page like : simple.aspx?id=1, simple.aspx?id=2, ... Where id = c Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Dim c As Integer = 0 While c < 5 Dim Label1 As New Label() Dim ltr As New Literal() Dim lin...

Knowing what input radio is selected on ASP.NET (VB)

Hello, I'm creating input radio dynamicly on a ASP.NET page using PlacHolders. While reader.Read Dim ltr As New Literal() Dim ltr1 As New Literal() Dim ltr2 As New Literal() Dim ltr3 As New Literal() Dim ltr4 As New Literal() ltr.Text = reader.GetString(2) & "<br />" PlaceHolder2.Controls.Add(ltr) ltr1.Text = "<form> <input type = radi...

UserControl, PlaceHolder and UpdatePanel

I dynamically load a UserControl, with an updatepanel inside, into a placeHolder. When I click an button into UserControl, should refresh the updatepanel that there are in it, but refresh entire page and the user control disappears because the aspx page's Page_Load don't load anything if it's a postback. How I can fix it? PD: sorry for ...

Zend Framework - Reusing view header information across Controller

In Zend Framework, I have a common use case where I need to propagate the same information in the top section of a view across a particular controller. For example, if I have a "Book" controller, I want to display the summary book information at the top of the page, and have a tabbed interface below the book to display comments, detaile...

Dynamically creating many instances of ASP.NET usercontrols: How do I create it, and where will my conflicts be?

I haven't seen this implemented before in ASP.NET, but am thinking about a UI that would look and act like this: Conceptual Overview A TabControl is loaded and the first tab contains a grid When a row is double-clicked, a new tab is created with the record detail The content of the tab/record detail is created by a usercontrol Many ta...

How can I create python strings with placeholders with arbitrary number of elements

I can do string="%s"*3 print string %(var1,var2,var3) but I can't get the vars into another variable so that I can create a list of vars on the fly with app logic. for example if condition: add a new %s to string variable vars.append(newvar) else: remove one %s from string vars.pop() print string with placeholders Any id...

scala type inference with _ place holder

List("This","is","Scala").foreach(a => print(a+" ")) compiles fine, but List("This","is","Scala").foreach(print(_+" ")) fails complaining of missing parameter type. I couldn't figure out why it fails. EDIT: I meant print not println - not that it makes logical difference. ...