2,295 Posted Topics
Re: assuming the need for a browser sniffer for handheld devices this gets most[code=php]<?php $mobile = "http://m.mysite.com/"; if(preg_match('/Windows CE/i',$_SERVER['HTTP_USER_AGENT'])) { header("location: $mobile");} elseif(preg_match('/Blackberry/i',$_SERVER['HTTP_USER_AGENT'])) { header("location: $mobile");} elseif(preg_match('/PalmOS/i',$_SERVER['HTTP_USER_AGENT'])) { header("location: $mobile");} elseif(preg_match('/PalmSource/i',$_SERVER['HTTP_USER_AGENT'])) { header("location: $mobile");} elseif(preg_match('/SymbianOS/i',$_SERVER['HTTP_USER_AGENT'])) { header("location: $mobile");} elseif(preg_match('/Opera Mini/i',$_SERVER['HTTP_USER_AGENT'])) { header("location: $mobile");} elseif(preg_match('/Nokia/i',$_SERVER['HTTP_USER_AGENT'])) { header("location: $mobile");} elseif(preg_match('/Samsung/i',$_SERVER['HTTP_USER_AGENT'])) { header("location: $mobile");} … | |
![]() | Re: UTF-8 etc have multibyte character encoding characters above the 128 us ascii set get 2 bytes, 3 bytes (up to 6 bytes) to represent them makes it backwards compatible with non-utf8 applications, which display garbage, but ascii garbage and dont crash strlen() appears to be ascii byte counting here is … ![]() |
Re: show the code you are using | |
Re: UTF-8 encoding html charset the GBP pound sign gets 2 bytes in utf8 utf16 its not one of the lower 127 ascii codes that gets directly translated the page that reads the stored data file needs to be charset UTF-8, logically aware of the answer, my phone does not have … | |
Re: As an aside from the code question, notepad and a browser is enough, but notepad is text only notepad replacements([url=http://www.google.ca/search?hl=en&safe=off&ei=3j1sS76oEoX6Naiw4c0E&sa=X&oi=spell&resnum=0&ct=result&cd=1&ved=0CAYQBSgA&q=code+highlighting+editor&spell=1]code highlighting editors[/url]) like notepad2 notepad++ codepad, or an IDE with code highlighting work like notepad, but mark up the code produced like the [noparse][code][/code][/noparse] tags above, it makes 'headslap errors' … | |
Re: show the existing css, | |
Re: when they dont show up in the target frame, are they [LIST][*]links to other sites or yours[INDENT] other sites likely have a framebreaker in their code to prevent using their page in framesets[INDENT]solution is permission from the site owner to display their pages, framebreak can be customized to allow the … | |
Re: [QUOTE=MidiMagic;1118337]I would hate to see a "W3C complain" website.[/QUOTE] I think the OP would have typed complian, (meant to be compliant) but the spell checker 'fixed it' :P Oh I hope they meant compliant, another 'complaint' site aaaaaarrrrrrrrrrrggggggh ![]() | |
Re: you went from no doctype, to xhtml no doctype = html 2, no support for anything, lucky if it works xhtml, support for everything, very strict declarations and positioning required noted several times in several dozens of threads for heaps of questions xhtml requires all elements to be closed, either … | |
Re: Textboxes dont respond well to onclick onchange onfocus onblur are the methods more commonly used I would try the same <input> with the javascript attached to 'onfocus' | |
Re: do actually still wonder why nobody will assist you read your posts, as one of those who could, if so inclined, assist you reads. be better off getting a new login and beginning again | |
Re: its a function of keyboard layout not everyone uses EN-us keyboards the keyboard mapping for other languages, even other subsets of EN, changes the location of keys, and may move non-standard (in the active language character set) characters to 'third' function positions dlannetts answer may be expanded to, 'this is … | |
Re: getting the words out is harder than doing it [url]http://flashexplained.com/actionscript/controlling-the-timeline-with-actionscript/[/url] and its FUN | |
Re: That site is garbage tables, java, flash, fixed sizes -content pushes off screen in small browser windows, too slow to load, invalid code. There is nothing on that site that can't be done better, faster, smaller, browser indepentdent, in css the google search would be '[url=http://www.google.com/search?hl=en&q=vertical+drop+down+css+menu+download&meta=&rlz=]vertical drop down css menu … | |
Re: php forms self posting, the user sees very little not even a filename, everything is on the server [code=php]<?php // form processing verification if isset($_post['bla bla bla']) { /*mysql bla bla bla etc */ } ?> <html><head></head><body><form method='post' name='form1'>[/code]the default action for a form is to post to itself ![]() | |
Re: " have a load of PHP pages that generate XML feeds that need to run hourly for my site to function " = 1 cron job [code=php]<?php include('job1.php'); include('job2.php'); include('job3.php'); include('job4.php'); include('job5.php'); include('job6.php'); include('job7.php'); /* jeopardy music */ include('job9999.php'); ?>[/code] | |
Re: more information required it is easy, [icode]<element value='<php echo $VALUE; ?>' >[/icode] but the exact format depends on where you are getting the values, and what you want them to do, | |
Re: remove all the defined height:s when the page is resized text may wrap on second lines and disappear behind div boundaries a liquid layout sets only width and allows the height to be set by the browser if two elements of diferent sizes are required to occupy the same vertical … | |
Re: Thats been a problem with many apps free to sell, but it doesnt actually work. The person who sold it to you knows it doesnt work, quite often they found the problem insurmountable and just gave up then sell off their partially developed code, or they bought it with onsell … | |
Re: dont use javascript, try php to randomize the images as well, there is no user input, there need be nothing clientside array() and rand() in php has the bonus there is less to download, cant be blocked if javascript is disabled | |
Re: image placement is easy with css css can be an external file that all the files on a site reference, great way to set the style for the entire site, then should you wish, you only need to make a single change to change the whole web page. styles can … | |
![]() | Re: I dont post the url including a user name store the logged in details in the session & use $session['user'] in declarations, so there is one less opening and the session varaible is always available |
Re: I didnt have images, so this is just html/javascript/css refresh the page will reset, I got lazy [code=html]<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <!-- @(#) $Id$ --> <head> <title>bingo Template</title> <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" /> <meta name="Generator" content="almostbob" /> <meta name="Keywords" content="Bingo" /> <meta name="Description" content="Bingo" … | |
Re: yes ________ Less smartass reply yes, but _________ Less smartass reply yes, but only appearance, functions require some scripting, usually javascript _________ reasonable reply Yes, but only appearance, functions require some scripting language example[code=html]<! doctype bla bla bla> <html> <head> <style type='text/css'> a { background:red; color:white; } a:hover { background:white; … | |
Re: the code is not complete all the elements referred to are not shown for a div, that code should work if total is an <input> the correct form would be [icode]document.getElementById('total').value = a;[/icode] code samples should include all the elements referred to, otherwise its just a guess, if this scrap … | |
Re: show the link code [U]You[/U] dont launch their reader, they either have the reader set up to handle urls to pdf files or they will get the download prompt | |
Re: [code=php]<html> <head> <style type='text/css'> div {background:#ddd; color:black; margin 0 auto; width;85%]} </style> </head> <body> <?php echo '<div>'.file_get_contents('textfile1.txt').'</div>'; echo '<div>'.file_get_contents('textfile2.txt').'</div>'; echo '<div>'.file_get_contents('textfile3.txt').'</div>'; echo '<div>'.file_get_contents('textfile4.txt').'</div>'; echo '<div>'.file_get_contents('textfile5.txt').'</div>'; ?> </body></html>[/code] | |
Re: its likely code left over from whatever IDE or CMS the original author was using, Its possible that the software searches for unreasonable words like that as its anchors, and replaces them with proper text when publishing one of the editors adds bb_ to the front of keywords it has … | |
![]() | Re: For the oldies & all the other browsers you havent access to try [url]http://www.browsershots.org[/url] it has been down twice in three days, sorry if it is down when you look |
Re: google translate widget embedded in the page [url]http://translate.google.com/translate_tools[/url] syntax is not always preserved in machine translation | |
Re: css styling [code=css]#frame1 {top:150px; left:150px; height:100px; width:100px;} #frame2 {top:100px; left:100px; height:200px; width:200px; z-index:10; visibility:hidden; }[/code][code=html]<button onclick='document.getElementbyID("frame2").visibility="show";'} />[/code]ignoring the *** positioning, better to set it relative so the document flows, and adjusts to screen changes, hidden and show may not be the right words, w3schools.com for proper format please consider this … | |
Re: the date of the original post is 2005 and no-body has heard of % or em, in this conversation at that point in time it is unncessary to know the size of the window to write scaleable code W3C recommendations for browser/screen/window independent code?? tables are inefficient outdated for most … | |
Re: ran a page consisting of [icode]<?php phpinfo(); ?>[/icode] and got error messages, ran it again and got "This page is Valid XHTML" ran it 3rd time and got error messages suggest the w3c validator [url]http://validator.w3.org/[/url] which gives location of errors at least | |
Re: This is the purpose of AJAX cross browser compatible no popup window issues automatically loads in the current page I am not good with AJAX, but I got my page loading and updating with these code samples [url]http://daniel.lorch.cc/docs/ajax_simple/[/url] | |
Re: top of the forum page dude Announcement: Do not post support questions here! cscgal (The Queen of DaniWeb) [url]http://www.daniweb.com/forums/forum92.html[/url] | |
Re: if going xhtml also have to add [icode]<html xmlns="http://www.w3.org/1999/xhtml">[/icode] or other issues will arise ![]() | |
Re: dont use a flash intro, it will just PO everybody but, I use an animated .gif of a clock just to give feedback that something is happening still it ads 24KB to the pages size | |
Re: I'll try but you need to rethink the 'id's you have chosen [code=html]<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>National Vehicle Movements - Booking Form</title> <style type="text/css"> <!-- body { background-color: #1d255f; margin: 0; padding: 0; } #apDiv1 { position:absolute; width:487px; … | |
Re: whatever you do the url is readable, or it does not work please define what you mean by encryption if for a $_get, try $_post try a session instead of sending url variables send url variables as 1 2 3 and have the translation done serverside so the user does … | |
Re: dont use a popup, you are already using ajax functions, so use ajax to put the form in a layer, and onclick change the z-index and visibility of the layer to put it on top of everything else, so the user has to complete the form and submit/close the layer … | |
Re: the imagined target audience the people who have widescreens, are also the people who have handheld devices, so sites have to display in all resolutions, if not exactly the same just becuase wordwrap will alter, at least readably. W3C current best practice, using ems or %, and the layout will … | |
Re: ASP [LIST][*]is Microsoft proprietary software [*]is expensive [*]runs only on MS servers 10-20% [*]prefers microsoft browsers [*]has a strict language [/LIST] php[LIST][*]is open source [*]free [*]runs on apache unix linux windows MSservers (100%) [*]has hundreds of thousands of free premade scripts [*]works in MS browers Moz Browsers Apple browsers every … ![]() | |
Re: An alternate approach, in sessions its not so difficult, is to make the page function differently if [back]ed into(also if direct accessed when you dont want it). the code is already in the page so no need to mess with browser history, but it displays just a "can't do this … | |
Re: [QUOTE=anu.reka85;1106918]then what is the use of DANIWEB...[/QUOTE] Daniweb provides a forum, where somewhat experienced people can give some help to less experienced people[INDENT]a public service[/INDENT]the protocols for Daniweb require that the less experienced person make some prior attempt to assist themselves the expletive fword is likely to be deleted from … | |
Re: [code=css]input[type=text] { background:white; border:0; border-bottom:1px solid black;} input[type=text]:hover { border:0; border-bottom:1px solid red;} input[type=text]:focus { border:0; border-bottom:1px solid red;} input[type=text]:active { border:0; border-bottom:1px solid red;}[/code] something like this in your <style> or external css file what you want is doable in css | |
Re: [code=html]<select name="myList"> <script type='text/javascript'> var today=new Date(); var mydate=new Date(); if ( today < mydate.setFullYear(2010,0,14)) { document.write("<option value='1' id='1-20-2010'>Option 1</option>"); } if ( today < mydate.setFullYear(2010,0,23)) { document.write("<option value='2' id='1-23-2010'>Option 2</option>"); } if ( today < mydate.setFullYear(2010,0,28)) { document.write("<option value='3' id='1-28-2010'>Option 3</option>"); } </script> </select>[/code]code explanation, compare todays date with … | |
Re: [icode]if(!$homework_question) { echo '[/icode][url]http://php.ca/manual/en/book.mysql.php[/url][icode]'; } else { echo 'Bad lotus,'; } [/icode] | |
Re: mark it solved, and give theMan, Manish, an attaboy :) Lafreak, this problem would be apparent if you got yourself a code highlighting editor notepad++ nodepad2, any of hundreds of notepad replacements or ide-s Wrapped in code tags to enable code highlighting on this page your code looks like this … |
The End.