have made a homepage with nvu and works good but want to restrict access to all pages except the main page. i want everyone that tries to access a subpage directly to be redirected to the mainpage.
is there any simple way to achieve that ? must be in html or javascript.
I have a Web application and the web resources like jss,css,jquery files are located outside of the WEB-INF directory (Java application) and if some user or hacker change the URL could see the source code for many js and jquery files.
Basically am working on the travel booking site,i written the lot of ajax scripts , so am little bit fear of that ajax ,becoz if some one tried to access anonymously So i dont want to user access or takeing my javascript fileTell me how to restrict the use get my javascript filecouple of days back i saw on site, in the i take that site js url , and when i typed on the Browser , the system say , you cant view this URL
I am using IE 6.0. On a page, I have placed a contenteditable div which I want to use as a Rich Text Area. I am using the execCommand method of the document to control bold, italics, underlining, and undo for this div.
I have placed an input element on the page to. All but the undo, are restricted to working only on the div. How can I restrict the undo to working on only the div?
Below is the complete page so you can see what I am talking about. Just paste it into an htm file and traverse to it via your browser. Type something in the div and the input and then try the buttons. Code:
How do i restrict files types that can be accessed when using the input element type file...like the one used when uploading..how do i restrict it to certain files with given file extensions?
I've a textbox field, where user enters his name. I want to restrict him from entering double and singls inverted commas.What kind of function should i write.
I need to restrict an area on the image but also get the coordinates from the image. I am using a form element "input type=image" so I can get the X Y coordinates from an image. I don't want the user clicking on a whole image, in this case a map of a country. I don't want the users clicking off the country's borders in to another country and I want to be able to get the coordinates from inside the country. I have tried to mix the element from the form with the area shape so when someone will click on the image it will first verify if it's over the hotspot and if it's over the poly coords then it will allow the user to click, the form will submit and the coordinates will be stored into the database.
I just don't know how I could integrate javascript into this. This is my code, not really something functional, the coordinates will pass on to the next page as a variable but limiting the area where the users may click is something that I have not figured out. I can create an area shape but without getting the coordinates from the image. Anything will do, even without <input type=image , if there is some way around this so I can make this work.
In JSP / HTML, I want to restrict the size of file being uploaded.
<input type="file" name="myfile"/>
If the user trying to upload a file size bigger than some value say 5MB, i want to give mesage to the user. I don't want to wait till the file gets uploaded to server and then validate the file size. I am looking for client side validation. Can it be done using scripting language or any other way?
Need a solution for this in Internet Explorer. I got a solution using ActiveX control:
var myFSO = new ActiveXObject("Scripting.FileSystemObject"); var filepath = document.getElementById('myfile').value; var thefile = myFSO.getFile(filepath); var sizeInBytes = thefile.size;
But ActiveX controls are not allowed in our application. Is there any alternative way for this?
I'm currently generating some tooltips to display data for certain items in a game. The tooltips and stats work great, however, for certain items, the tooltip gets long and will extend pass the viewable range for the user.
Here are the links: test page: [URL] javascript: [URL] css (for hover div only): [URL]
If you hover over the links of items (like villages, barracks, etc.) a tooltip will pop up to show you the stats. But if you notice, for items like castles, the tooltip can extend past the viewable range for the user.
Does anyone have code to restrict input of a singli quote and a backslash in input field? I need to make sure this code works in IE, FF, Opera. Well, all major browsers
Is there anyway of restricting the amount of webpages open. I would like users of a site only to beable to have two pages (from the site i am talking about) open at anyone time.
I picked up this Drag n Drop script years ago from the net. Modified it slightly but one mod i cant make work is limiting it to only running when the mouse is over an ID called dragid. Currently a mouse drag anywhere in the browser moves the dragid element which is annoying.
HTML Code:
//Drag and Drop script if(document.getElementById){ (function(){ //Stop Opera selecting anything whilst dragging.
Is it possible with jQuery, or JavaScript for that matter, to trap the mouse in a div or other tag so that it can only move around in it. I'd like this for a modal window so thta the user knows that they must do something in the window first before carrying on.
When the number of menus (including a menu and its submenus) reach a particular number, then after that rest of the menus are not getting displayed. Is there any settings available to restrict number of menus in superfish?
I m having trouble restricting an action to a single image. I am trying to make the background fade to full opacity on hover, and have that working like I want to. The problem is that when I hover one image, ALL the images fade to full opacity. Obviously it would be nice to only have the one that is being hovered over. I am sure it is just a simple thing in the code but I just can't figure out what it is.
I was wondering if it is possible to restrict the values of a text input box to only accept set values such as "XBC1". I am trying to make a form for a scanner so you can scan bar codes and it will auto fill the form out and have default values set so incorrect values cant be submitted into the database and mess everything up.
I want to restrict the user from being entering the value in <input type="file">. It works fine in IE but not in Mozilla. I am sending my code also which works in IE and not in Mozilla...
Would u pls let me know whether the following is possible or not: User can be able to insert text on a text-box or text-area(form) as usually we use text-area to do so. But I want to put some readonly text using an open and close tag
for example: <ro>This is readonly text</ro>insert your text here Can I be able to make the text inside <ro>..</ro> tag readonly, it means user can't be able to modify or delete this readonly text. readonly text length not fixed. only way to recognize the readonly text is the <ro> tag.
I am quite new to javascript. I tried searching for this question, couldn't find it. I want to access my url bar by running the script so that i can type a new url at runtime. How do i access it and change it. I don't want to move to a new url until and unless user hits the enter key. I only want to type it.
i have div that will contain numerous other div (products in a shopping cart), say up 50.of these contained divs, i need to access every 5th div begging with 1, so it'd be div # 1, 6, 11, 16, 21 etc. and then use jQuery to Add Class to these divs.can someone point me in the right direction on how to do this?