JavaScript - Notepad Works - Didapro Editor Does Not
Writing Javascript code in Notepad and saving it in HTML works fine. However when I write js in my DiDaPro editor and go to preview the screen it is blank. Why?
Similar TutorialsHi, i need help with notepad. Im just having knack with Microsoft Notepad on building a page with Jscript. The problem im having is the browser does not seem to render my code well, javascript actually. What i have done is i have attached a external Jscript file onto html like <script type="text/javascript" src="joke.js"></script> however my browser doesn read it. I just need help with this. Hello, I am in the midst of designing an HTA application, such that I would be able to open a file via notepad in Javascript using the Shell.Application object. I have the following code, however, It does not work and can't seem to figure the rest out. Code: function test101() { var oShell = new ActiveXObject("Shell.Application") var commandtoRun = 'C:\\WINDOWS\\system32\\notepad.exe "F:\\WEB\\saved items\\A-2010-00455.txt"' oShell.ShellExecute(commandtoRun,"","","open","1"); } Any help with this is greatly appreciated. Thanks in advance. Cheers, Jay Hello everyone, I've got done with a few hours of coding! What took me the longest was the update system. Now, some features notepad elite has: Color Changing Bold/Italic/Underline/Strike Font Changing Saving/Opening And more! Remember, it may seem like a plain old notepad as it is, but in 30 minutes or so a new update will be released. You can check by pressing this button: Some screenshots: Download Notepad Elite! - http://host-a.net/RSEB/Notepad%20Elite.exe Virus scan: I'm trying to get this code to work in browsers other than IE. It prints the contents of a textarea, say, a notepad, first bringing up the print dialog. It does it with an (almost) invisible iframe. At first I thought it was only for IE, but I must have tested incorrectly (after a few dozen times uploading and printing out you lose your sanity) and I now see that it DOES work in FF, but not in Chrome. For me (and maybe others?) that is very good news because it will probably be easier for someone more knowledgeable than me to solve a Chrome problem rather than an "all other than IE" browsers problem. Code: /* for notepad printouts */ function printInput(f){ var ifr = window.frames['printFrame']; if (ifr){ //print the content of the invisible iframe ifr.document.getElementById('content').innerHTML=f.WRKNOTEPAD.value.replace(/\n/g,'<br />'); ifr.focus(); ifr.print(); } else { //print by opening a new window and then closing it var html='<html><head><style type="text/css">div{font:normal 14px Verdana}</style></head><body onload="window.print();window.close()"><div>'+f.WRKNOTEPAD.value.replace(/\n/g,'<br />');+'</div></body></html>' var win = window.open('','_blank','menubar,scrollbars,resizable'); win.document.open(); win.document.write(html); win.document.close(); } } function writeContent(objIframe){ var html='<html><head><style type="text/css">div{font:normal 14px Verdana}</style></head><body><div id="content"></div></body></html>' objIframe.document.write(html); objIframe.document.close(); } I think this bit: if (ifr) tests for IE and if it fails the condition, it dynamically creates a new window to print from. And I now see it does just this in FF. But not in Chrome. So narrowing it down I think the Chrome failure is in this bit: Code: else { //print by opening a new window and then closing it var html='<html><head><style type="text/css">div{font:normal 14px Verdana}</style></head><body onload="window.print();window.close()"><div>'+f.WRKNOTEPAD.value.replace(/\n/g,'<br />');+'</div></body></html>' var win = window.open('','_blank','menubar,scrollbars,resizable'); win.document.open(); win.document.write(html); win.document.close(); } Is there anyone who can see why this would fall over in Chrome? I am working on some sort of a program that will load data from a notepad or Excel file and load it into a ComboBox. The notepad file would have names and phone numbers in it. The ComboBox would only show their names in alphabetical order. There would also be a button that when you click it, it would open up Outlook (if you are signed into Outlook) and auto-fill the form with their phone number @ vtext.net (for texting verizon cell phones). The reason behind this is so the notepad or Excel file can be edited to add more users as the company expands. I'm on a time crunch and haven't really been able to figure out how to do the data on load. If anyone could help and explain their code a little bit I would be very grateful. I haven't touched JavaScript in around 5 years so I'm very rusty. Thanks. hi!! i wanna create a simple javascript editor.. the main thing here is i want something like Tinymce but with some features i want to add.. something simple i can tweak with.. please help guys I am trying to use the HTML created by openWYSIWYG editor on my site. I am wanting to manipulate the created HTML that is generated...but I don't seem to be able to access it. When I pass the value through to a PHP script, it functions in much the similar way that any other textarea does. What I want to do works fine with a standard textbox and acquiring the value using: Code: textareaid.value But this doesn't seem to work when the openWYSIWYG editor is attached. Does anyone know how I can do this?? Cheers The Moose I'm starting out in JS and I'm looking for a good editor. Preferably cheap or free Anyone suggest something pls Nigel Any recommendations for a freeware html/javascript editor??. I am presently using HAPedit. Should it suffice ??
I am looking to create a web script that allows you to create custom strategy maps for various game like battlefield. What I want is the users to select a map (probably an image map with some default icons on it) and then they can lay on custom icons (directional arrows, attack / defend icons, ect, ect) to show a battle plan and then save it as an image. I would assume an image map would be best for this, but I am not sure how users can input, remove, rotate and resize the icons if needed. Is there some sort of script like this I can build on? I only know the basics of javascript and php, but perhaps someone can point me to a guide of some sort? Here is an example of what I want the user to be able to create which I made in photoshop, though it can easily be made in a simple program like paint too. I use http://www.openwebware.com/ wysiwyg editor. It is necessary to change something in it, but I do not know how? When the inserted image in the editor, and then changes the image size, stretches the image in an editor, I want to record a change image size, without editor in <input type='text'> field. Is there any idea how to bring? Thanks! I currently use MSE but it keeps moving things around and changing the formatting of the code. Can anyone recommend an editor that leaves things as I type them? Cheers Daniel. Hi, well i saw this editor http://www.w3schools.com/svg/tryit.a...=trysvg_circle at w3schools and i was wondering if there is something like this available for use in one's site. I mean if there is a service that provides you with the editor for your site or if there is a way out to make something like this if there is already a script available. My knowledge is till html&css so this is what i don't know I assumed this is a javascript based text editor because when I turn off javascript it doesn't work. I was wondering how something like this is created. maybe not this exact one, but how would I create something like it. Maybe just a simple editor that changes text size and color.
Uhm, hi. So, sorry if this is the wrong place, but I hope someone can help. I'm 13 years old, and I'm slowly learning how to code. I made this website for my teacher from scratch using basic HTML tables, with a few PHP include lines I copied from somewhere. Not bad, right? Well, here's the tricky part. When she was using her previous website, she kept messing up her various widgets when she added site content (because Wikispaces sucks ) So, my hope was to create an inline editor (AJAX??) for her to only be able to edit a certain part of the page. A) ONLY SHE SHOULD BE ABLE TO EDIT IT, so I need some kind of a login system. I have access to phpMyAdmin to run MySQL queries and such. B) I was hoping for a top corner login button like Twitter, or the example shown here. C) I know I can give her access to my FTP and make a separate file, and use an include script, but she wouldn't know how to use an FTP. D) I'd prefer if the editor DID NOT use HTML. Reason being, I wouldn't want to have to make her use <br> every time she wants a line break. E) It should be like this. If her username is detected as logged in, a button should be displayed above the editable area that says "Edit". Then, when she clicks that, a text box shows up, she edits her text, and clicks "Submit". I'm sure this would be mighty difficult to do, but I'd much appreciate the help. I know I used phrases such as "MySQL queries" and "PHP include script", but please talk to me as if I were 4 years old. I have extremely limited coding knowledge. Also, please don't get annoyed if I ask a lot of stupid questions. Be sure to let me know if you need any more information! THANK YOU SO MUCH! ~Kyle$calise Hi All, Having a real problem with IE losing focus when clicking outside the wysiwyg iframe. This works fine in Firefox, Chrome, Safari, Opera. Code: <html> <head></head> <body> <script type="text/javascript"> function initializeEditor() { contentEditor.document.designMode='on'; } function insertHTML1() { var html = "<em><u>Some Text</u></em><p>2. Select this text<p><strong></u>Some text</strong>"; document.contentEditor.focus(); range = contentEditor.document.selection.createRange(); document.contentEditor.focus(); range.pasteHTML(html); } function insertHTML2() { var html = "<strong>INSERTED TEXT</strong>"; document.contentEditor.focus(); range = contentEditor.document.selection.createRange(); document.contentEditor.focus(); range.pasteHTML(html); } </script> <iframe name="contentEditor" id="contentEditor" onLoad="initializeEditor();"></iframe> <p><input type="button" value="1. Click Here" onClick="insertHTML1()"> <p><input type="text" value="3. Click Here"> <p><input type="button" value="4. Click Here" onClick="insertHTML2()"> </body> </html> To demonstrate, first follow steps 1, 2 and 4. This works fine! Introduce step 3, clicking in a field outside the iframe and focus is lost. Appreciate any help!! Thanks hi everyone, fairly new to this forum, does anybody know where i can find a good, free color coded editor ? Because of my rather second-rate vision; I would like to get an editor for my Javascript that will check my syntax for me. Missing or extra brackets, semicolons etc are the bane of my life. Any suggestions welcomed. Frank Hello, I am having a bit of a problem sending rich html emails. I just installed CK Editor on my hosting account and it appears to be working fine. But instead large colored fonts, I'm getting html tags only in my email. Links and emails appear to be working fine, though... So instead looking like this: Big Bold Blue. It looks like this: <p><span style='color: rgb(0, 0, 255);'><strong>Big Bold Blue.</strong></span></p> I also tried using mail() function in php, on its own, but that didn't work either. Can anyone help me out with this? I'm not very familiar with JavaScript... Thanks in advance! |