473,414 Members | 1,848 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,414 software developers and data experts.

CSS 3 in Firefox / Google Chrome

KeredDrahcir
426 256MB
I'm using a url type as an input box so that the keypad will be optimised for people to enter a web address on mobile devices.
It doesn't allow them to enter it without http at the front but I can't guarantee they will realise the need to put http in front of it so I put that as the value in the box but that means on Google Chrome in rejects the box and an unfinished website address. Since entering in a website is not a required field I don't want it to do this. Is there any way round this?
Expand|Select|Wrap|Line Numbers
  1. <input type="url" name="website" value="http://"/>
Apr 24 '12 #1
4 2304
ariful alam
185 100+
you can add the placeholder attribute in the input tag. it will show a message to user to input with http://
here is the code:

Expand|Select|Wrap|Line Numbers
  1. <input type="url" name="website" placeholder="http://www.yoursitename.com"/>
  2.  
Jul 9 '12 #2
Placeholder does not work in internet explorer v9-oldest...

I suggested
Expand|Select|Wrap|Line Numbers
  1. <input type="text" id="tbox" onfocus="clearVal();" onblur="fillVal('example');" value="example" />
  2. <script>
  3. function fillVal(val){
  4. document.getElementById('tbox').value=val;
  5. }
  6. function clearVal(){
  7. document.getElementById('tbox').value='';
  8. }
  9. </script>
  10.  
Jul 30 '12 #3
ariful alam
185 100+
his asking was related to Firefox/Google Chrome. so, answer was related that.
Jul 30 '12 #4
But my suggestion is works all browsers.
Jul 30 '12 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Guy Macon | last post by:
Serious Security Flaw in Google Chrome: http://www.readwriteweb.com/archives/security_flaw_in_google_chrome.php -- Guy Macon <http://www.GuyMacon.com/>
10
by: Humakt | last post by:
Hey all. It's been a while since I last visited. Short description of program: Board game which's html elements are fully constructed using DHTML/Javascript. Board is constructed of html table,...
0
by: wpjoju | last post by:
i have this code which adds an event listener to a newly opened window but it doesn't seem to work in google chrome. the problem is window.addEventListener seem to work in chrome but if you do...
0
by: catoblepa80 | last post by:
How can i read all google chrome bookmarks and place it into a list or a dictionary? i think the best way is to use regular expressions on the chrome bookmarks file, can you help me to accomplish...
4
by: Hotice | last post by:
I have a form for registering some bookings. The problem is that I want to validate the data users enter in this form. All works fine, excepting the booking hours (ready by and closing time). This...
2
KeredDrahcir
by: KeredDrahcir | last post by:
When using an object tag to embed a video file everything looks fine in Internet Explorer and Safari. However I can't get it to display at all in Opera. More importantly in Firefox and Google Chrome...
3
KeredDrahcir
by: KeredDrahcir | last post by:
Can anyone help me. I don't know if this is a mysql, php or Google Chrome error. I have a login form but for some reason I'm getting an error when I use Google Chrome. It used to work in all...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
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...
0
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...
0
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...
0
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...

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.