htmlArea

A directory of browser-based WYSIWYG editors

  MAIN
INDEX
SEARCH
POSTS
WHO'S
ONLINE
LOG
IN

Home: htmlArea 2: htmlArea 2 & 3 archive (read only): htmlArea v2.0:
What am I doing wrong ? PHP newbie.


The htmlArea 2 & 3 editors have been discontinued.

We've made these forums available as a read-only reference and knowledge-base for people using or developing editors based on htmlArea 2 or 3.

Anyone who is interested in taking over version 2 or 3 is free to do so. All we ask is that you choose a new name that doesn't have "htmlarea" in it to avoid confusion with this site. We'll even give you a link in the directory to make it easier for people to find you. If you are developing or hosting an htmlArea based-editor under a new name, please submit it to our directory.

 


adamst
New User

Oct 11, 2004, 11:03 PM

Post #1 of 4 (2033 views)
Shortcut
What am I doing wrong ? PHP newbie. Can't Post

Hi there,

It doesn't seem to be quite working for me at the moment. Here's the code I'm using:

Is there anything obvious that stands out ?

cheers,

Adam

<head>
<script language="Javascript1.2"><!-- // load htmlarea
_editor_url = ""; // URL to htmlarea files
var win_ie_ver = parseFloat(navigator.appVersion.split("MSIE")[1]);
if (navigator.userAgent.indexOf('Mac') >= 0) { win_ie_ver = 0; }
if (navigator.userAgent.indexOf('Windows CE') >= 0) { win_ie_ver = 0; }
if (navigator.userAgent.indexOf('Opera') >= 0) { win_ie_ver = 0; }
if (win_ie_ver >= 5.5) {
document.write('<scr' + 'ipt src="' +_editor_url+ 'editor.js"');
document.write(' language="Javascript1.2"></scr' + 'ipt>');
} else { document.write('<scr'+'ipt>function editor_generate() { return false; }</scr'+'ipt>'); }
// --></script>
<script language="JavaScript1.2" defer>
editor_generate('joke_detail');
</script>
</head>
<img src="images/laidley_intranet_update_header.gif">
<form action="insert_jokes.php" method="post">
<table width="75%" border="0" cellspacing="1" cellpadding="1">
<tr>
<td>
<em> <strong> <font color="#0000FF" size="4" face="Verdana, Arial, Helvetica, sans-serif"><img src="images/laugh.jpg" width="40" height="50"></font></strong></em></td>
<td><font color="#0000FF" size="2" face="Verdana, Arial, Helvetica, sans-serif"><strong>Add New Jokes</strong></font></td>
</tr>
<tr>
<td width="19%"><font color="#0000FF" size="2" face="Verdana, Arial, Helvetica, sans-serif">Short</font></td>
<td width="81%"><input name="joke_short" type="text" size="40"></td>
</tr>
<tr>
<td><font color="#0000FF" size="2" face="Verdana, Arial, Helvetica, sans-serif">Detail</font></td>
<td><textarea name="joke_detail" cols="40" rows="10"></textarea></td>
</tr>
<tr>
<td><font color="#0000FF" size="2" face="Verdana, Arial, Helvetica, sans-serif">Visible</font></td>
<td><input name="joke_display" type="text" value="Y" size="3"></td>
</tr>
<tr>
<td></td>
<td><input type="Submit"></td>
</tr>
</table>
</form>


Luis
Veteran

Oct 12, 2004, 1:21 AM

Post #2 of 4 (2027 views)
Shortcut
Re: [adamst] What am I doing wrong ? PHP newbie. [In reply to] Can't Post

Hi adamst:

Try moving this part:

<script language="JavaScript1.2" defer>
editor_generate('joke_detail');
</script>


after the closing </form> tag.

Greetings


Don't give up!!
http://webstationone.com/test/htmlarea


adamst
New User

Oct 12, 2004, 5:02 PM

Post #3 of 4 (1988 views)
Shortcut
Re: [Luis] What am I doing wrong ? PHP newbie. [In reply to] Can't Post

Hi Luis,

did what you suggested but get an error at line 42, which is:

editor_generate('joke_detail');

Error on page says "object expected"

any ideas ?

cheers,

Adam


adamst
New User

Oct 12, 2004, 5:18 PM

Post #4 of 4 (1986 views)
Shortcut
Re: [adamst] What am I doing wrong ? PHP newbie. [In reply to] Can't Post

Got it Luis,

I didn't have the "_editor_url" pointing to the correct file.

cheers,

Adam

 
 
 


Search for (options)