Hi everyone
I'm writing a javascript/php chat script, but I've run into a problem
that is probably very, very simple to fix but I don't have a clue.
The problem is with an iframe (should I be using an iframe in the first
place?) that shows all the chat so far - all I want to do is get the view to
scroll to the bottom of that iframe when it first loads or refreshes.
That's the entire problem in a nutshell! Lines of text are added to the
bottom of the file shown in the iframe, but when the number of lines exceeds
the height of the iframe the vertical scrollbar appears (which is desirable)
but the new conversation is hidden off the bottom.
The reason for the iframe btw is that I couldn't find a compatible way
of updating part of a page without using form elements, and I want to use
things like different font colours for different users in the chat pane,
which I can't with form elements.
Any tips or a possible fix for this would be greatly appreciated, and
particularly cross-browser working example code :-)
This has got a lot longer than I expected, I'd better go to bed now,
Cheers in advance to anyone who can help :-)
dillon 1 3376
I don't really have any exprience at this but since nobody else has
answered. Why don't you try:
window.scroll(0 ,99999999);
I don't know if it's cross-browser compatible or what but it's a start.
dillon wrote: Hi everyone
I'm writing a javascript/php chat script, but I've run into a problem that is probably very, very simple to fix but I don't have a clue.
The problem is with an iframe (should I be using an iframe in the first place?) that shows all the chat so far - all I want to do is get the view to scroll to the bottom of that iframe when it first loads or refreshes. That's the entire problem in a nutshell! Lines of text are added to the bottom of the file shown in the iframe, but when the number of lines exceeds the height of the iframe the vertical scrollbar appears (which is desirable) but the new conversation is hidden off the bottom.
The reason for the iframe btw is that I couldn't find a compatible way of updating part of a page without using form elements, and I want to use things like different font colours for different users in the chat pane, which I can't with form elements.
Any tips or a possible fix for this would be greatly appreciated, and particularly cross-browser working example code :-)
This has got a lot longer than I expected, I'd better go to bed now,
Cheers in advance to anyone who can help :-)
dillon This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Timo-Pekka Oikarinen |
last post by:
Is there PHP chat script *without* MySQL?
Demands: absolutely FREE (no adware, shareware etc.), No MySQL needed,
one permanent public chat, can make your own channels (public/private)
like IRC, several admins (one superadmin, me ;-D ), bad word filter,
user nick ban/ip ban/kick (temporary/permanent), small file sharing and
@time script ( http://www.swatch.com/internettime/home.php ) to upper
right corner. Environment: Windows 2000 Pro...
|
by: Don |
last post by:
I'm writing an html page with some JavaScript that reads a web page
into a client-side temp file, then reformats it, then submits that
same file as a URL to the browser for display, via "locate.replace".
I can do all this if the html page containing the script originates
on the client machine, but don't know how to get access to a
client-side temp file when the same html page containing the script is
on a web host. How do I get access...
|
by: Obbligato |
last post by:
Wellll...I'm hoping this is on topic, because if it is, it means there
is a Javascript solution to what I want to do. At the very least it
seems like I need *some* sort of client side script. What I want to do
us allow multiple users in a chat room to talk to each other,
regardless of what browsers or OS or whatever they are using. I also
want to be able to integrate this chat script, whatever it is, to my
own website, so that the controls...
|
by: Gooshi |
last post by:
Is it possible to write a dead simple html chat client ie one form
that can be accessed by two people :
ie a form that has two text areas
- one for me to write to
- one for another person to write to
both text areas have two buttons
- clear
- submit
|
by: Dexter |
last post by:
Hello all,
I need to build a chat using ASP.NET (VB), this chat is to the
online communication with customers.
I would like to know what is best. To use webservices or to use remote
script?
thanks
| |
by: Daniel Friend |
last post by:
I am trying to add the following as my global.asax file in vb. I am getting
errors like crazy. They are as follows
* Error 1 There can be only one 'application' directive.
* Error 4 Validation (ASP.Net): This attribute name must be followed by an
equal (=) sign and a value. If the value is in quotation marks, the
quotation marks must match.
* Error 5 Validation (ASP.Net): Attribute 'Implements' is not a valid
attribute of element...
|
by: www.web20developers.com |
last post by:
http://www.web20developers.com
http://www.web20developers.com/index.php?option=com_content&task=view...
Ajallerix : AJAX, simple, fast Web image gallery demo ; at Novell
AJAX - microlink pattern tutorial : A microlink is a link that opens up
|
by: steven.rojas |
last post by:
I have a chat application based on PHP and Flash, I know that is
necessary execute the socket server script from the console (#!/usr/
local/bin/php -q), but my problem is that I don't have SSH access to
the server where I have to deploy the application (a godaddy server).
Locally I could run the script even in my browser and the chat works
fine, but if I run the script in the server from the browser I
couldn't connect to it. Is there a way...
|
by: Clayton23 |
last post by:
<html>
<head>
<base href="http://chat.webhop.org:8000/themes/colors/">
<title>ConferenceRoom by WebMaster, Inc.</title>
<script language=javascript>
function regNick(form) {
var pass = form.npass.value
var email = form.email.value
document.cr.output('/ns register '+pass+' '+email)
return false
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
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...
| |
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,...
|
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...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
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...
| |