Last post Jan 14, 2006 10:01 PM by cniknet
Jan 14, 2006 11:45 AM|erlendoh|LINK
I'm very new to DNN and asp.net. What I would like to do: Add a textbox and a button/liked text to my skin. What i want it to do is take the text and add it to an url string, and then open the url in a new window.
I've been trying to do this in my skin.ascx file. The textbox was easy:
<asp:textbox id="text1" runat="server" />
How can i code a button that does this in the skin.ascx file, and where do i put this code.
Jan 14, 2006 10:01 PM|cniknet|LINK
I would propose not subjecting the user to a postback if all you are doing is concatenating strings and opening a URL in a new window. Everything you want to achieve can be done with client-side code that is added to the skin:
var someInfo = document.getElementById("someInfo");
var url = "http://something/file.aspx?info=" + someInfo.value;
<input type="text" width="200" id="someInfo"> <input type="button" value="Go" onClick="return launchWindow()">