Click here to Skip to main content
       

JavaScript

 
GeneralRe: Creating a vertical auto-hide toolbar PinmemberChen Renjun27-Sep-12 16:26 
AnswerRe: Creating a vertical auto-hide toolbar Pinmemberjkirkerx27-Sep-12 19:06 
GeneralRe: Creating a vertical auto-hide toolbar Pinmembern.podbielski28-Sep-12 7:06 
GeneralRe: Creating a vertical auto-hide toolbar Pinmemberjkirkerx28-Sep-12 7:12 
GeneralRe: Creating a vertical auto-hide toolbar Pinmembern.podbielski28-Sep-12 9:43 
GeneralRe: Creating a vertical auto-hide toolbar Pinmemberjkirkerx28-Sep-12 10:05 
GeneralRe: Creating a vertical auto-hide toolbar Pinmembern.podbielski28-Sep-12 11:44 
GeneralRe: Creating a vertical auto-hide toolbar Pinmemberjkirkerx28-Sep-12 13:16 
I found that IE has a different way or syntax for creating html in the dom. Firefox, Safari was pretty straight forward, but IE used table.insertRow(-1), and InnerText instead of InnerHTML. So I spent a week looking at the difference between the two, and found that you can set stuff, but it won't work or produce an error unless it's way off base. So IE just ignores InnerHTML, but picks up InnerText. Go Figure?. I didn't want to mess with more asp.net elements, so I just made them in Javascript. The main point was that if it's even used, then it's created on the fly by the client, if not, there's no extra asp.net code needed.
 
Drove me nuts!
 
So the big picture here, is that it's a very small piece of code in a large Server DLL Control (6 megs). The script is embedded, and everything is code behind.
 
The hard coded id is on the asp.net side, the jquery uses a wildcard for the id, in which the prefix can be anything, as long as the suffix matches. So masterpages are not a problem.
 
I didn't think of using CSS at the time, just wrote it all in mostly javascript. I suppose there are a dozen ways to do it.
 
I use to type out the HTML like your example and append it, just thought I would try something different this time. The createElement seems a little faster than just appending text.
 
I'm amazed at really fast it runs, so I'm going to stick with it for now.
GeneralRe: Creating a vertical auto-hide toolbar Pinmembern.podbielski28-Sep-12 13:51 
GeneralRe: Creating a vertical auto-hide toolbar Pinmemberjkirkerx29-Sep-12 20:24 
GeneralRe: Creating a vertical auto-hide toolbar Pinmembern.podbielski29-Sep-12 23:04 
QuestionFantastic site demonstrating and teaching "responsive" UI concepts using JavaScript, HTML 5, etc. PinmemberBillWoodruff25-Sep-12 14:46 
AnswerRe: Fantastic site demonstrating and teaching "responsive" UI concepts using JavaScript, HTML 5, etc. PinmemberSteve Bondy7-Dec-12 13:38 
QuestionUsing Jquery in DataList Pinmembermrkeivan19-Sep-12 7:17 
AnswerRe: Using Jquery in DataList Pinmemberjkirkerx25-Sep-12 19:01 
AnswerRe: Using Jquery in DataList Pinmembergjllyl9-Oct-12 20:36 
QuestionHow to calculate difference between two dates PinmemberRobymon18-Sep-12 0:46 
AnswerRe: How to calculate difference between two dates PinmemberJoan Murt18-Sep-12 5:59 
Questionfyi: accidental find: using JavaScript DOM in browser to parse a URL PinmemberBillWoodruff14-Sep-12 23:54 
AnswerRe: fyi: accidental find: using JavaScript DOM in browser to parse a URL Pinmemberziggyfish10-Oct-12 7:26 
Questiongoogle map splite write problem Pinmemberchogrf13-Sep-12 3:48 
QuestionFastest way to select all elements in a *ListBox* PinmemberA*****12-Sep-12 20:32 
AnswerRe: Fastest way to select all elements in a *ListBox* PinmemberBobJanova13-Sep-12 0:04 
GeneralRe: Fastest way to select all elements in a *ListBox* PinmemberA*****13-Sep-12 13:27 
GeneralRe: Fastest way to select all elements in a *ListBox* PinmemberA*****13-Sep-12 19:55 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.


Advertise | Privacy | Mobile
Web02 | 2.8.141220.1 | Last Updated 20 Dec 2014
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid