example

BOINC: Is there an easy example how to code a programm for it and how to implement it into their client/server system?

Hi, I did a numeric method as my diploma thesis and coded it in java. It needs a loot of computational time when done adequate. So I looked for an alternative and found BOINC. Unfortunally I didn't have time for doing my method in BOINC, because I'm an aerospace student and not a programmer and I decided to keep my priority on my java p...

GWT simple form validation example

Hi, I'm looking for nice and fast way for validating forms in GWT, that can display errors one by one, focusing on the offending field. I've found gwt-validator and gwt-validation, but their documentation lack of examples. Thanks for help ...

Real-world examples of nested functions

I asked previously how the nested functions work, but unfortunately I still don't quite get it. To understand it better, can someone please show some real-wold, practical usage examples of nested functions? Many thanks ...

Tinyurl API Example - Am i doing it right :D

Hi ... we use super-long Hashes for the Registration of new Users in our Application. The Problem is that these Hashes break in some Email Clients - making the Links unusable. I tried implementing the Tinyurl - API, with a simple Call, but i think it times out sometimes ... sometimes the mail does not reach the user. I updated the Code...

Understanding .get() method

sentence = "The quick brown fox jumped over the lazy dog." characters = {} for character in sentence: characters[character] = characters.get(character,0) + 1 print(characters) I don't understand what characters.get(character,0) + 1 is doing, rest all seems pretty straightforward. Thanks ...

Check even/odd for Palindrome?

Is it a good idea to check for odd/even length of a palindrome number/string? Most snippets I came across don't do this basic test. If length is even, it can't be a palindrome, no? if len(var) % 2 != 0: # could be a palindrome, continue... else: break Or is it just better (i.e faster) to start comparing the first and last numbers...

Zend_ProgressBar: is there a god example / tutorial on how to use it?

I'm trying to use Zend_ProgressBar in my project (made using MVC in Zend Framework). Unfortunately, I cannot find any full example on how to use it. Zend Programmer's Reference Guide has only some code snippets, which are not enough for me. Basically, I don't know how incorporate Zend_ProgressBar with some action in a controller and a...

itextsharp read table

Hello, I've created a pdf with a table using itextsharp. I found an example at http://itextsharp.sourceforge.net/tutorial/ch05.html. Now I'd like to read data from the table again using itextsharp. I can't find any documentation on how to read this data. Can someone give me an example? ...

MVC Custom Model - Where is a simple example?

I need to make a web application and I want to use MVC. However, my Model can't be one of the standard Models -- the data is not stored in a database but instead in an external application accessible only via a API. Since this is the first MVC application I've implemented I'm relying on examples to understand how to go about it. I can...

Drupal Token Examples of Usage

I need to include a node content in another node using some kind of placeholder, for example: [node-5663] will be translated to the node's content (body) where node-id matches 5663. The example above is just an example, what I would need is actually something like this: [table-TABLE-ID] where TABLE-ID will be a field I define in the nod...

Django-cms example. How to run it?

I'm trying to run django-cms example. But I think I'm doing something wrong. Can anybody describe by steps, how to run django-cms example? ...

Tesseract Example for Iphone

I have compiled tesseract for using it in xcode following: http://iphone.olipion.com/cross-compilation/tesseract-ocr I obtain the .a file, import it as framework in the iphone project, and update the header search path for tesseract header files. So now I need a simple example in order to get start. I can't find anything in http :// co...

Problems Executing iPhone "GenericKeychain" Example

I can't get apple's "GenericKeychain" example to run. I have replaced all 5 occurrences, as mentioned in the readme file, of "YOUR_APP_ID_HERE.com.yourcompany" with my own string: se.[company name].[project name].demo. The compilation goes fine but when trying to run it on the phone, an error saying "The executable was signed with invali...

How big can I make an Android application's canvas in terms of pixels?

I've determined an estimate of the size of my Android emulator's screen in pixels, although I think its resolution can be changed to other numbers. Quite frankly though that doesn't eliminate the general problem of not knowing how many pixels on each axis I have to work with on my Android applications in general. The main problem I'm t...

An example of advanced database search

Hi there, im looking for an example script. I saw one yesterday but for the life of me I can't find it again today. The task I have is to allow the user to search 1 database table via input controls on an aspx page where they can select and , or , equals to combine fields, generating the sql on the fly with concat/stringbuilder or sim...

How do you handle key down events on Android? I am having issues making it work.

For an Android program, I am having trouble handling key down and key up events, and the problem I am having with them can almost certainly be generalized to any sort of user input event. I am using Lunar Lander as one of my main learning devices as I make my first meaningful program, and I noticed that it was using onKeyDown as an over...

Are there any B-tree programs or sites that show visually how a B-tree works

I found this website that lets you insert and delete items from a B-tree and shows you visually what the B-tree looks like: java b-tree I'm looking for another website or program similar to this. This site does not allow you to specify a B-tree of order 4 (4 pointers and 3 elements), it only lets you specify B-trees with an even numbe...

Quick question about open_basedir

Hello, On my server, I have following setting: open_basedir /home/ :/usr/lib/php :/usr/local/lib/php :/tmp/ :/usr/local/ :/usr/bin Now, I am little bit confused about ending / in the / home / setting, does that mean that all subfolders inside home have same rights? or does it mean that only home files can...

Looking for database example for webshop

Title says it all. Looking for an example on a webshop (using ORM) database with customers, orders, shoppingcarts, products and so on. Been on google for ages now but cant really find anything good ...

How to create simple PHP COMET server page displaying current time?

How to create simple PHP COMET server page displaying current time? I need code implementation (because it should be trivial) - not theory or just links to library sites. Simple text line conteining corrent time and updating each second. ...