detection

How to protect website resource from downloading?

Like this .mp3,you can listen online: http://d1.s.hjfile.cn/podcast/20100222/2010022290717093_217.mp3 But I don't want to allow downloading. How to approach that? ...

php code for language detection doesn't work on WAMP server 2

I'm using this $lang=$_SERVER['HTTP_ACCEPT_LANGUAGE']; to detect the language of the browser. At first, I thought something was wrong with my code. But then I tried this demo, and even if I had my 'display preferred language' as Spanish (es), it displayed the content English (en). Finally, I figured out that it doesn't work in localhost ...

How can I have a file for each language's content in this php language detection demo?

This tutorial is about language selection according to preferred language on browser. lang.php: <?php function dlang($Var) { if(empty($GLOBALS[$Var])) { $GLOBALS[$Var]=(!empty($GLOBALS['_SERVER'][$Var]))? $GLOBALS['_SERVER'][$Var]: (!empty($GLOBALS['HTTP_SERVER_VARS'][$Var]))? $GLOBALS['HTTP_SERVER_VARS'][$Var]:''; } } fun...

How to identify when a USB device is inserted to a WinCE device

I have a touch enabled device with WinCE, I need to show a UI whenever a USB device is inserted to the device. If there any event or method to identify the USB insertion in WinCE. ...

Detecting a website's framework

I was reading the article "50 of the Best Websites Developed Using Ruby on Rails". It seems quite impressive. But is there any way to find out which framework any specific website uses? Say dzone.com, how could I find out which framework it is using? How could I find websites made with, for example, the Spring Framework? ...

How to check an object's type in C++/CLI?

Is there a simple way to check the type of an object? I need something along the following lines: MyObject^ mo = gcnew MyObject(); Object^ o = mo; if( o->GetType() == MyObject ) { // Do somethine with the object } else { // Try something else } At the moment I'm using nested try-catch blocks looking for System::InvalidCastExc...

Why is there no plugin detection tecnique (like navigator.plugins) in PHP?

Why is there no plugin detection tecnique (like navigator.plugins) in PHP? Why it is not implemented? It would be great! Any thoughts on how to do it? Edit: Like in $_SERVER['HTTP_USER_AGENT'] ...

How to detect how far the object on photo is from another objects on that photo?

So for example we have real life photo. how to get (relativly to image dimentions for example) the distance from wall to girls, from girls to trees if all we know ts this picture? Papers with algorithms and\or Open Source programs doing this would be appreciated. As for me Code is Better than just pure algorithm. So if you give algori...

How programmable detect if a user has admin rights (can run installer)

Hi in my code I need to detect if current user has rights to install other application (other application VC2005 redist. package)... and it should work on Vista. As I understand CheckTokenMembership or IsAdministrator do not give a complete solution. Thank you ...

How to detect a image texture?

So we have a photo like this How to detect that a red wall has a white figure painted on it and that that white figure is a texture and than how to cut that wall from the picture? I need an algorithm for performing such operation programaticly (not by hand) ...

Proper method to detect device model (iPhone/iPod Touch)?

Is this the proper way to detect which device a user is running? NSString *currentModel = [[UIDevice currentDevice] model]; if ([currentModel isEqualToString:@"iPhone"]) { // The user is running on iPhone so allow Call, Camera, etc. } else { // The user is running on a different device (iPod / iPad / iPhone Simulator) disallow C...

Collision Detection for Actionscript 3

Well, I was searching for a simple collision detection function for as3, I found Collision Detection Kit, but it is too complicated, I just want a damn function that I give 2 objects as paramenters and that's it. I would like to know where can I find a pixel-perfect collision detection function (The faster, the better) ...

Detect if touch device

Hello, I'm writing a MIDlet using the Kuix UI toolkit, and I want to make changes to the toolkit depending on whether the current device is a touch screen device. (These changes include making buttons bigger, for easier tapping.) Is there a way to detect whether the device has a touch screen using J2ME (MIDP 2)? [edit] as a (crappy) w...

No Flash, How do i handle jcupload ?

I am using http://www.jcupload.com/ (basic) to upload files. I am considering having a friend write a more custom version or to do magic with ajax; so the solution should be able to work without that. With jcupload i include css, a script and write <div id="jcupload_content"></div> in my html and i am done. Problem is, with no flash i g...

How to determine whether a database has been changed or not ?

I have a need to determine if a database on a MS SQL Server has changed between two distinct moments. The change can be structural or data-related and the check should be generic (i.e. independant of the structure of the database). Preferably, I'd like the check to be T-SQL based or with SMOs, not file based. I checked on MSDN but I hav...

Detecting Enter in TextBox ASP.NET no JavaScript Please.

Basically I have a Search Text Box with a LinkButton Control on which the click event is fired. now what i want is when the user type keywords and press enter the Click event got fired. So No Javascript Only ASP.NET With VB.NET v2.0 Sincerely Rajeev [email protected] ...

How can I programmatically determine (in Python) when someone connects into my windows 7 machine via RDP?

This doesn't need to be a real time solution, but are there some log files or system messages that could be read to identify periods of time where someone was connected via RDP to a Windows 7 machine? I'm building a watchdog script for a computer which will be deployed in a remote place and would like to add this metric to a daily statu...

How to detect in a Flex app if a camera is already in use by another application?

I am making an application that plays the video stream from the user's local system (both Windows and Mac). I use the Camera.getCamera() method and in turn Camera.names to get a list of camera attached with the system. Unfortunately, if the camera is already in use by another application, say a desktop application on user's system, the...

Is there a library for ball hitting sound detection

Hi I'm looking for a library to detect when ball hit in a audio of a tennis match. I read this topic but I think there is a suite library for this job. please guide me tanx ...

Is there any fast library(s) for finding human eyes and mouth in Flash? (Actionscript)

So I have real time video stream. With 1 (one) person on It . It Is Black and White, I need to be able to capture this persons eyes and mouth (direction (at least X,Y), state (at least opened or closed) ) So Is there any fast library(s) for finding human eyes and mouth in Flash in such case? (pure Actionscript or Haxe\Java\C++\C port in...