-
Javascript Tool
Does anyone know of a utility that will rewrite an html page in javascript example:
html:
<body>
<b>some text here</b>
<hr>
<b>some more text</b>
</body>
javascript:
document.write('<body>');
document.write(' <b>some text "here"</b>');
document.write(' <hr>');
document.write(' <b>some more text</b>');
document.write('</body>');
Jeremy
-
no, but i think that you could easily write a VB app to do that.
-
Don't know of one, though it should be easy to make. Not sure why you would want to.
Anyway, something to point out... don't put the body tag in a script. It will create very bad HTML.
-
Private Sub Command1_Click()
Dim myJavascript() As String
myJavascript = Split(Text1.Text, vbCrLf)
Text1 = ""
For i = 0 To UBound(myJavascript)
Text1.Text = Text1.Text & "document.write('" & myJavascript(i) & "')" & vbCrLf
Next
End Sub
something like that ?
-
1 Attachment(s)
JavaScript Tools
Ok, I am all set.
I tooks sail3005's and CiberTHuG's advise and wrote a tool.
It really is nothing fancy but it does exactly what I need. If you need a tools that does the same thing than I am posting it with this message. If you happen to use it and have any problems then please let me know.
Jeremy
-
no offense, but why would you want to do that?
-
convenience?
I don't see why you would need to have javascript write out a page :eek: