518 Posted Topics
Re: you can try somthing like: [code=html]<html <head> <title>www.daniweb.com</title> <style type="text/css"> <!-- div#test { margin : 0 auto; padding : 0; width : 98%; } div#test a { display : inline-block; } div#test a[id] { margin-right : 5px; float : left; clear : none; } div#test a { margin-left : 5px; … | |
Re: Hi, i'll provide you with some example later. I just post back when im done to it. -[b]essential[/b] | |
Re: Hi matthewl, try this over at [b]line#4[/b]: [code]var x; var y; var drag = false; // Fixing line#4 >>> var elm = [color=red]( function() { return document.getElementById("view_title"); } ); [/color] // more stuff >>>[/code] -[b]essential[/b] | |
Re: Hi cguan_77, I guess a [icode]<marquee>[/icode] tag would be enough to help you out on getting this issue. | |
Re: Hi, here's a valid frameset document sample: [code=xhtml]<?xml version="1.0" encoding="UTF-8" standalone="no"?> <?xml-stylesheet type="text/css" href="#css_level21" media="screen"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd"> <html id="xhtml10F" xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" /> <meta http-equiv="Window-Target" content="_top" /> <meta http-equiv="imagetoolbar" content="0" /> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <meta http-equiv="Content-Style-Type" content="text/css" /> … | |
Re: Right clicks or any user interaction behavior can be prevented by some scripts, but your code would still be at open when i view it on a validation tool like this [url=http://validator.w3.org/]< O N E >[/url]. | |
Re: Hi, try to put some query mark on your defined [color=red]url[/color] variable : [icode]var url = "logout.php[color=red][b]?[/b][/color]";[/icode] and also bring this up, right after the declaration of your [color=red]http[/color] ( HttpRequest object ). On line#4 [icode](( http.overrideMimeType ) ? http.overrideMimeType("text/xml") : http );[/icode] | |
Re: Hi, You could also try this: [code]<?xml version="1.0" encoding="UTF-8" standalone="no"?> <?xml-stylesheet type="text/css" href="#css_level21" media="screen"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> <head> <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" /> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <meta http-equiv="Content-Style-Type" content="text/css" /> <meta http-equiv="Content-Script-Type" content="text/javascript" /> <title>http://www.daniweb.com :: DHTML JavaScript / AJAX</title> <style id="css21" … | |
Re: Hi, and also using native alert would be a good start for you, it may look a simple function, but it will help you track things that is happening inside your script or when you are implementing new lines' in your code. Here's a simple and not so powerful demo: … | |
Re: Hi, continuing [b]DangerDev[/b]'s advised. if you just need to apply the same style rule over a nested divs', then you could try this instace in your CSS file: [code=css].item_type1, .item_type1 div, .item_type1 div div /* applies the same backgroud on the div that is inside the class(item_type1) div */, .item_type1 … | |
Re: Hi, use another div and hold the 3 divs inside it. e.g. [code][color=red]<div id="hold" style="width : auto; border : none; background-color : transparent;">[/color] <div id="divLeft" style="width : 30%; float : left; clear : left; background-color : #000;">LEFT</div> <div id="divMid" style="width : 40%; float : left; clear : none; background-color : … | |
Re: Hi, Javascript itself cannot obtain those value from the user input, and moving it to the next page, unless you prefer saving those data using cookie session. But why do you need JavaScript for this job? Knowing that PHP alone can handle all sorts of data you need from the … | |
Re: Hi manilaGuy, you could try this simplified ajax example: [code]<?xml version="1.0" encoding="UTF-8" standalone="no"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> <head> <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" /> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <meta http-equiv="Content-Script-Type" content="text/javascript" /> <title>http://www.daniweb.com :: JavaScript / DHTML / AJAX</title> <script type="text/javascript"> // <![CDATA[ var AJAX … | |
![]() | Re: Hi Ashton, here's a valid frameset document, that you can use when you are creating framed pages in your site: [code=xhtml]<?xml version="1.0" encoding="UTF-8" standalone="no"?> <?xml-stylesheet type="text/css" href="#css_level21" media="screen"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd"> <html id="xhtml10F" xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" /> <meta http-equiv="Window-Target" content="_top" /> … |
Re: Hi, here's another layout trick that you can also apply in your page: [code=html]<?xml version="1.0" encoding="utf-8" standalone="no"?> <?xml-stylesheet type="text/css" href="#css21" media="screen"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html id="xhtml10S" xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" /> <meta http-equiv="Window-target" content="_top" /> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <meta http-equiv="Content-Style-Type" … | |
Re: Hi, or you might also want to try this simulated document. In this demo i will verify all the checkboxes set to have defaulted checked values: [code]<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <meta http-equiv="Content-Style-Type" content="text/css"> <meta http-equiv="Content-Script-Type" content="text/javascript"> <title>http://www.daniweb.com</title> <style type="text/css"> … | |
Re: Hi sonia, you could try this: [code]function ConvertToUpperCase() { var result; var numaric = "sonia"; var Character = numaric.charAt(0); result = numaric.replace( Character, Character.toUpperCase() ); // Converting target character to uppercase letter. }[/code] | |
Re: Hi severman, here's a little example on how to deal in such thing, w/o touching the the structure of your [icode]hit(arg1, arg2)[/icode] function, i just added a few lines for the insertion of your image. Here's the code: [code]<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html lang="en"> <head> <meta … | |
Re: Hi, Here's a chained document sample that you may use and expand along with your web activities. Here's the code for the [color=red]startpage[/color]: [code]<?xml version="1.0" encoding="utf-8" standalone="no"?> <?xml-stylesheet type="text/css" href="#css21" media="screen"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html id="xhtml10S" xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" /> <meta … | |
Re: Hi Alex, this may take some time, we will just post back when we get your solution... -[b]essential[/b] | |
Re: Or you could also try this: [code]<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html lang="en"> <head> <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7"> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <meta http-equiv="Content-Script-Type" content="text/javascript"> <title>http://www.daniweb.com</title> <style type="text/css"> <!-- .hidden { display : none } .unhidden { display : block } --> </style> <script type="text/javascript"> <!-- var unhide … | |
Re: Try this instead, [code]function hit( f ) { var i = 3900; f.vaule = i; }[/code] you can then reference it with your attached events' doing this format: [icode]<img src="image1.jpg" onclick="hit( this );" alt="" />[/icode] | |
Re: Hi there, that is a toggle function, used to show and hide elements' inside a page. Maybe its meant to toggle some [icode]<div><elements></elements></div>[/icode] or it can be a ul tag. Is there anything that we can do to help you on solving this issue? | |
Re: Try this code when you are creating dynamic table : [code]<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html lang="en"> <head> <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7"> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <meta http-equiv="Content-Style-Type" content="text/css"> <meta http-equiv="Content-Script-Type" content="text/javascript"> <meta http-equiv="Window-target" content="_top"> <title>Free Live Help!</title> <style type="text/css"> <!-- div#main { background-color : #eee; border : … | |
![]() | Re: Hi Ashton, in the <head> section of your page, you may apply this format: [code]<script type="text/javascript"> <!-- // Basic Sample var tableOn = function( obj ) { document.getElementById( obj ).style.display = "table"; }; onload = function() { document.getElementById("myTable").style.display = "none"; }; // --> </script>[/code] do the same instance as you … |
Re: @hengzhe, is that what you call it, a Cross-Browser compatible!? That declaration of yours won't last long enough to handle what is on up ahead: [b]tsk...tsk...tsk...[/b] [code]<?xml version="1.0" encoding="utf-8" standalone="no"?> <?xml-stylesheet type="text/css" href="#css21" media="screen"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html id="xhtml10S" xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="X-UA-Compatible" … | |
Re: I havent finished it yet, but you'll have to tell me if it does what you exactly needed. Here's my work over this deal: [code]<?xml version="1.0" encoding="utf-8" standalone="no"?> <?xml-stylesheet type="text/css" href="#css21" media="screen"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html id="xhtml10S" xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head profile="http://www.w3.org/2005/10/profile"> <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" … | |
Re: Try to make the [icode]time_ref2 =...[/icode] as a global variable, you can do this by simply removing the [color=red]var[/color] keyword right before it. | |
Re: try to put those interval's with an onload event: [code]window.onload = function() { int = setInterval("sendRequest()", 2000); };[/code] | |
Re: As what have, [b]Shawn[/b] said: Providing us with less lines of codes, will just complicate the whole thing. You must provide us with all the [b]Functions:Classes—Variables: Declared-Values—Labels:Objects/Values[/b] that you used on your stated code. Compacting your code: [code]<script type="text/javascript"> <!-- // Making us guess on what you have on the … | |
![]() | Re: Use only one [icode]<meta.../>[/icode] tag(keywords) and specify all the major keywords that you would want to get indexed by a crawler. e.g. [code]<meta name="keywords" content="english is the most commonly used language on the web, another long description of your choice,...,...," />[/code] and always add a [b]title[/b] attribute along with your … ![]() |
Re: Hi neclark, loading images through AJAX is not advisable, since AJAX is build to handle file that is lower in size and a file within this format (.(x)html, .txt, .js etc.) as long as it is not a media file. So if you are loading a media file with a … | |
Re: Hi apollokid, I've developed a small prototype based image gallery sample, that will easily help me, understanding your needs. Lets say if you have this type of concept, then what are the type of features that you would like to add in as part of this program? [code]<!DOCTYPE html PUBLIC … | |
Re: Hi, Here is a simple demo: [code]<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html lang="en"> <head> <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7"> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <meta http-equiv="Content-Style-Type" content="text/css"> <meta http-equiv="Content-Script-Type" content="text/javascript"> <meta http-equiv="Window-target" content="_top"> <title>Free Live Help!</title> <script type="text/javascript"> <!-- // OBJECT BUILDER \\ var AjaxObjectBuilder = ( function() { /* … | |
Re: Hi blessanm, Are you trying to upload a file, or are you just grabbing data from the user input? Using [b]file[/b] type won't return any value even when you reference it along with some script. If you're just getting data input from the user, then it is better to use … | |
Re: Hi, this might be irrelevant to the issue, but this ensure that your desired effect will work under all conditions. Simply include this script inside the header section of your (x)HTML document. All codes is as follows: [code]<script type="text/javascript"> // <![CDATA[ onload = function() { var ie = (( !!document.all … | |
Re: Try this trick : [code]<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html lang="en"> <head> <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7"> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <meta http-equiv="Content-Style-Type" content="text/css"> <meta http-equiv="Content-Script-Type" content="text/javascript"> <meta http-equiv="Window-target" content="_top"> <title>Free Live Help!</title> <script type="text/javascript"> <!-- /****************************** Developed By DANIuser : essential - * Created : July 25th, 2009 … | |
Re: You could try this variation: [code]<script type="text/javascript"> <!-- var ie = Boolean((( !!document.all === true && !!!document.getElementById ) ? 1 : 0 )); var eCoordinates = ( function( icon ) { var coordsLeft = 0; var coordsTop = 0; var element = ( function( elementID ) { var elementID = … | |
Re: You could also try this one : [code]var validateYear = function( valfield, infofield, required ) { var valfield = valfield || ""; var infofield = infofield || ""; var required = required || ""; var stat = commonCheck( valfield, infofield, required ); if ( stat !== proceed ) { return … | |
Re: It's either you can use plain stylesheet(css), XSLT(xsl) or Ajax/XMLDOM Parser's using javascript. But here's a bit of example, formattimg its layout using [b]XSLT[/b], also try the XML section to get precise results over this issue. From your [b]XML[/b] file, you must add a single of this: [code]<?xml version="1.0" encoding="UTF-8" … | |
Re: Hi morecrab, you could try this: [code]<form action="index.asy" method="post" onsubmit="return false;"> <div> <input type="button" value="prev" onclick="alert('You've pushed the ' + this.value + ' button');" /> <input type="button" value="next" onclick="alert('You've pushed the ' + this.value + ' button');" /> </div> </form>[/code] | |
Re: Javascript can filter all the information you need along with your form mailer. But securing those data with this script, is not advisable. Try PHP instead.. | |
Re: You must declare it first, with the following instance of : [icode]var dado = xmlDoc.responseXML.getElementsByTagName( tag );[/icode] | |
Re: But the problem about this, is that the viewer( user ) can simply view the souce-code on their browser and thats it. Everything is wasted... | |
Re: Those unexpected results happens when you press a key, triggered by your [color=red]onkeypress[/color] event. You can prevent it by simply applying some conditional statement along with your functions that says': [icode]if ( event.type === 'keypress' ) { //...Prevent it from happening[/icode]. | |
Re: Try the following loading sequence of the script (via [b]src[/b]) provided inside this document, and i've also include a simple script that you can apply with your page when injecting dynamic elements. Here's the code: [code]<?xml version="1.0" encoding="utf-8" standalone="no"?> <?xml-stylesheet type="text/css" href="#css21" media="screen"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" … | |
![]() | Re: Hi, charlie AJAX is only capable of handling files within the same domain, so if we are posting/getting request from another source(domain), then it will just dump the whole request sent by your host. This request is not allowed to access any of those files within url process due to … |
Re: Try using this popup.js: [b]popup.js[/b] [code]var win; var popUp = function( mypage, myname, w, h ) { var winW = (( screen.width ) ? screen.width : (( window.clientWidth ) ? window.clientWidth : window.innerWidth )); var winH = (( screen.Height ) ? screen.Height : (( window.clientHeight ) ? window.clientHeight : window.innerHeight … | |
Re: Hi daveg, Try to apply the following changes inside your script: [code]<script type="text/javascript"> var viaID = Boolean( document.getElementById ); var changecolor = function( Id, ctrlhide ) { var stopscript; var current = (( viaID ) ? document.getElementById( ctrlhide ) : document.all[ ctrlhide ] ); var el = (( viaID ) … | |
Re: You could try this: [code]<?xml version="1.0" encoding="utf-8" standalone="no"?> <?xml-stylesheet type="text/css" href="#css21" media="screen"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html id="xhtml10S" xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head profile="http://www.w3.org/2005/10/profile"> <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" /> <meta http-equiv="Window-target" content="_top" /> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <meta http-equiv="Content-Style-Type" content="text/css" /> <meta http-equiv="Content-Script-Type" content="text/javascript" /> <title>Free Live … |
The End.