dynamic

Drupal 6: cck form that fetches from webservice dynamically

I have a cck module that currently does this User enters and saves username for a third party website on the module settings page User adds/edits a node When user gets the add/edit form, their username is fetched from settings, and is used for an api call which fetches some data, this data fills a select on the form. User selects somet...

Dynamic/Anonymous type, returning anonymous types!

this is not a question as i think its discussion, i know you cant return an anonymous type across methods, when i first used anonymous types i thought it would be really nice to be able to return it across methods and when .net 4 came out and with the edition of the dynamic types i thought there might be a hope in returning an anonymous ...

Groovy expando dynamic set name

Is it possibly to dynamically set the class of an expando?? Having set jr = new Expando() Is there a way to def end = 'name' so that jr.end will actually give me the value stored in jr.name ...

Creating website with skins - What's the best way to serve up proper image from my view?

I'm re-writing a website that will support multiple skins. Currently, I'm just planning on allowing images and CSS to be modified, but the underlying HTML will not change. And if the skin does not modify an image or CSS file, it inherits that file from the base skin. With that in mind, here are the 3 ways I've considered so far for se...

Dynamic methods in a Module?

I've got a module called AB. Right now it looks something like this: module AB extend self def some_method(hash) .... end .... end We use it like this: AB.some_method(:thing=>:whatever,:etc=>'you get the idea'). There are about a half-dozen strings that the user has to pass in that I'd like to turn into dynam...

Why do I get this syntax error in my code generating program?

I want to generate some lines of Perl code by using file handling in Perl, for example: open(FILEHANDLE, ">ex.pl") or die "cannot open file for reading: $!"; print FILEHANDLE "use LWP::UserAgent;" .... .... some code is here .... print FILEHANDLE "my \$ua = new LWP::UserAgent(agent => 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; r...

Printing Dynamic Usercontrol via document paginator in WPF : Datagrid is printed empty

Hi, I am trying to print a wpf document. I am using documentpaginator for pagination and a user control to create actual visual to print. My user control has few textboxes and a datagrid binded to data objects which are passed to the user control at runtime. Now the code works great when printing to an XPS document but when it prints t...

Create dynamic link in drupal

Could anyone tell me how to create a dynamic link in drupal? I want to create a link to a group membership list. I have created the view with the argument. How do I create the menu item link to the view? It will be different depending on the group. Thanks ...

jQuery binding live events

Hi I am having troubles binding live events to dynamically created content. I have a page which loads a html page through an ajax call. The loaded html page contains some javascript which is then executed. The executed javascript creates some elements. I want to bind a click event handler to those elements, however after binding them ...

Android dynamic background

Hi, I am somewhat of a new android developer and have a question regarding changing the background dynamically at runtime. What I want to do is set a background color in a LinearLayout Tag, and later change that background color in my activity class. This code below is not working. Am I missing something or is this the wrong approach...

Changing View properties after onCreate().

First time poster, new to Android, and I seem to have hit a roadblock on this problem: I'm creating a dynamic layout, consisting of several identical "composite" objects (these are basically "floating" LinearLayouts, each containing an icon (ImageView) and a caption (TextView)). The (x,y) coordinates of each LinearLayout are subject to...

Is there a XSLT-like JavaScript templating system?

I have a big chunk of deeply-nested semi-structured JSON and would like to generate HTML from it. At the moment I'm using jQote2, but much of the code inside my templates deals with dynamically finding the next template to render and then calling it. What's a single <xsl:apply-tenplates> in XSLT takes several lines with JavaScript and jQ...

Dynamic suggestions for text ctrl in wxPython?

Is there any way to mimic the dynamic suggestions behavior as per the search field on Google? As in, I type something in a text ctrl, and a list of suggestions pops up below for the user to chose from? If wxPython doesn't have such a feature, perhaps some other Python gui has it? EDIT: For use on a Mac. That excludes this example, altho...

iPhone scrollView add elements dynamically with id

Hey guys, I want to populate a scrollView with quite a few different UI elements. Therefore I thought I would write a method that remembers the current Position in the scrollView and just adds the element to the scrollView at the current Position. Something like: - (void)addUIElement:(id)element withWidth:(CGFloat)width andHeight:(...

How to create dynamic/friendly URLs using PHP?

Hello. Can anyone explain how to create friendly URLs? I mean URLs like http://store.steampowered.com/app/22600/ that doesn't have any pages like index.php visible. Any help is appreciated. Thanks. ...

jquery dynamic id selector, remove then add class

Hi I have a table, with rows which all have a cell of a div with a dynamically generated id in the format of btn-insertidhere. When the table row is selected, I want to select this div id, then remove a class and change it to another one. This is down to me wanting to have a button image change from an add symbol to a delete symbol whi...

Dynamic tab generation in struts2

I need to dynamically create the tabs in struts2 using struts2-jquery-grid-plugin, like selecting from multiple select box and then dynamically getting the tabs generated in the grid. Any suggestions? Thanks. ...

Dynamic Control PositionScrolling Issues

I'm creating dynamic controls in a Form and I made a static button to add fields within a panel. When fields are added this button is relocated to be underneath these added lines. But when the button reaches the low end of the panel (having autoscrolling set to true) it disappears and scrolling becomes infinite downwards. So this behavio...

Why can't a base access expression be dynamically dispatched in C#?

I think this question is best understood by an example so here we go: public class Base { // this method works fine public void MethodA(dynamic input) { // handle input } } public class Derived: Base { // Derived was named Super in my original post // This is also fine ...

Create Dynamic div with unique IDs - jQuery

Hey guys, Let me know if I'm not explaining this well enough as I'm confusing myself just thinking about it. I was to be able to click on a button that says "add product" and have it create a unique div each time. For example, the first div would have the id #product1, then #product2 etc. The really tricky part is to have two input fie...