473,626 Members | 3,389 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Smiley Click picker using Javascript and FORM woes .. Please help...

OK im prety much a newbie at PHP but it has me hooked.

Im writing a comment system for one of our modules on phpnuke. Its all
going very well, well should i say WAS going very well :)

Ok all the comments work etc and everything is intergrated nicely in the
database. Now im parsing the comments back out to the user and replacing
string like :) with emoticons etc. It works perfectly and i'm seriously
pleased with myself (ok ok remember i said i was new at this :) .....

Now the issue i have is a silly one. I want to present the form input
for the comments in pretty much similair ways to phpbb does on a new
post. I.e present BBCODE icons and smileys that can be clicked and it
inserts into the FORM field ... I have a working javascript that does
just that but try as i might the darn thing will NOT wrap a FORM (even
if wrapping is on). This seems more a MOZILLA problem than IE ( wraps in
that). So if i keep on hitting the same icon again and again it will not
wrap and presents a scrollbar that keeps on going. The actual FORM will
wrap if i insert text inside it manually however so maybe its a
javascript error after all ??

Anyway im hoping someone somewhere can shed some light on this. Here the
test code.
-----------------------------------------------------------------------------
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="content-type">
<title></title>
</head>
<body>
<script type="text/javascript">
<!--
function addsmiley(code)
{
var pretext = document.commen t.post.value;
this.code = code;
document.commen t.post.value = pretext + code;
}
//-->
</script>
<b>Comment on this movie:</b>
<form name="comment" method="post" action="news.ph p"> <textarea
name="post" wrap="hard" rows="8" cols="30"></textarea></form>
<img src="../../forum/images/smiles/icon_biggrin.gi f" alt=":)"
onclick="addsmi ley(':)')" style="border: 0px solid ; width: 15px;
height: 15px; cursor: pointer;">
</body>
</html>
------------------------------------------------------------------------------
Ive tried setting WRAP to Virtual / HARD / SOFT / Physical etc and it
still insists on not wrapping from the javascript ... Anyone any ideas ???

Jul 17 '05 #1
0 1668

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
2018
by: George Hester | last post by:
In a page I have when the user left-clicks the page a Input box for a form gets the focus. But if the user right-clicks the page the Input box is not getting the focus. I'd like the Input box to get the focus no matter where on the page the user clicks be it right-click or left-click. Right now there is no context menu when the user right-clicks. Do you think that's the problem? Any ideas how to get this right-click left-click Input box...
3
3056
by: descds | last post by:
OK im prety much a newbie at PHP but it has me hooked. Im writing a comment system for one of our modules on phpnuke. Its all going very well, well should i say WAS going very well :) Ok all the comments work etc and everything is intergrated nicely in the database. Now im parsing the comments back out to the user and replacing string like :) with emoticons etc. It works perfectly and i'm seriously pleased with myself (ok ok remember i...
13
3847
by: Hussein Patwa | last post by:
Hi there. I'm new to this group. I'm also partially sighted so navigating the web is sometimes quite difficult. I'm looking for a javascript date picker, you know the ones that travel sites use for selecting the departure and arrival dates. I've had a look at some sites, but mostly found calendars. I want to make mys tie accessible, so I really want the three scroll boxes for the day, month and year.
1
2050
by: Simon | last post by:
Is there any way that I can use an input with type file as a directory picker? The input starts a file picker but I want to be able to select a folder rather than a file. Thanks IA, Simon
3
9130
by: DotNetGuy | last post by:
I have been programming in asp.net w/ vb for 3 years now and I feel a need to include more client side script with javascript so here I am. Hopefully in the right place. I have a timecard web app that I need to pick a starting time in hour and minutes 3 times a day for 15 days. On the form I would like to hit a button on Manday and popup an hour dropdown and minute dropdown and submit them to the page without the page doing a postback. The...
0
1679
by: obuli | last post by:
In VB.NET Form,i am using Date Time Picker How to fire "Date Time Picker" 's Click and "Double Click" events... It seems these events are not fired.. any one please help me .. thanks in advance
1
4459
by: Sabbuser | last post by:
Hey Guys please help me out!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! I have placed a Date & Time Picker Control on a form in Windows 2000, When our Organization has upgraded all the PC's with Windows XP. Now i can't find the Date&Time Picker Control on the Form, it is showing a blank box. I have visited the Microsoft website, there i found that "Date&Time Picker Control has been eliminated in Windows XP".
4
4947
by: gggram2000 | last post by:
Hi, I'm using php 5.2.3 with mysql server 5.1 as backend. I have a program in which a person enters or chooses two dates from two datetime pickers and other info, I'm not sure if the problem is in the Datatype for the datetime picker declared in the table editor why none of the fields save in the database. I entered the datatype as DATE. and my datetime pickers code look like this: <script language="javascript" type="text/javascript"...
0
2184
by: =?Utf-8?B?a3BpenpsZQ==?= | last post by:
Hi all. using vs.net 9, C# I've got a trivial dilemma right now with my datetimepicker. It is bound to a datetime field in a database. This field is also set to not allow nulls. The default value of this field is: getdate() My Picker's properties:
0
8641
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8366
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8510
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6125
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5575
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4202
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2628
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1812
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1512
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.