PostId
int64
13
11.8M
PostCreationDate
stringlengths
19
19
OwnerUserId
int64
3
1.57M
OwnerCreationDate
stringlengths
10
19
ReputationAtPostCreation
int64
-33
210k
OwnerUndeletedAnswerCountAtPostTime
int64
0
5.77k
Title
stringlengths
10
250
BodyMarkdown
stringlengths
12
30k
Tag1
stringlengths
1
25
Tag2
stringlengths
1
25
Tag3
stringlengths
1
25
Tag4
stringlengths
1
25
Tag5
stringlengths
1
25
PostClosedDate
stringlengths
19
19
OpenStatus
stringclasses
5 values
unified_texts
stringlengths
47
30.1k
OpenStatus_id
int64
0
4
1,414,288
09/12/2009 04:37:23
170,795
09/09/2009 11:53:20
91
2
J2ME VS Android VS iPhone VS Symbian VS Windows CE
I have very little idea about mobile platform, though I am interested to program for mobile platform. Would you please compare between J2ME VS Android VS iPhone VS Symbian VS Windows CE. I would like to know which one is better, and if there is any VM technology to test the programs. Which one should I choose and why? Is there any IDE, debugging facilities? Personally I would like to code for open source, but any suggestion are welcome. I have preliminary knowledge on java. I would also like to know, if there is anything else that you can recommended. Thank you
java-me
iphone
android
symbian
windows-ce
01/18/2012 12:40:45
not constructive
J2ME VS Android VS iPhone VS Symbian VS Windows CE === I have very little idea about mobile platform, though I am interested to program for mobile platform. Would you please compare between J2ME VS Android VS iPhone VS Symbian VS Windows CE. I would like to know which one is better, and if there is any VM technology to test the programs. Which one should I choose and why? Is there any IDE, debugging facilities? Personally I would like to code for open source, but any suggestion are welcome. I have preliminary knowledge on java. I would also like to know, if there is anything else that you can recommended. Thank you
4
4,612,476
01/06/2011 06:42:17
489,902
10/28/2010 09:26:06
29
3
google map in android emulator problem
instead of it displaying google map it only display grid view. -> i followed all the steps that are in following sites examples http://mobiforge.com/developing/story/using-google-maps-android or http://www.androidpeople.com/android-google-map-application-example/ -> i also set the proxy server run --> run configuration.. --> myapplication-->target tab--> additional command line -http-proxy http://192.68.100.101:8080/ Still i am not getting the google map. NOTE: i tried this in my mobile it works fine but not display in android emulator. where i made mistake plz help me. thank in advance
android
google
map
null
null
null
open
google map in android emulator problem === instead of it displaying google map it only display grid view. -> i followed all the steps that are in following sites examples http://mobiforge.com/developing/story/using-google-maps-android or http://www.androidpeople.com/android-google-map-application-example/ -> i also set the proxy server run --> run configuration.. --> myapplication-->target tab--> additional command line -http-proxy http://192.68.100.101:8080/ Still i am not getting the google map. NOTE: i tried this in my mobile it works fine but not display in android emulator. where i made mistake plz help me. thank in advance
0
11,288,962
07/02/2012 06:51:41
536,480
12/09/2010 13:42:42
452
25
How to do the game like Angry Bird ? The formule of Orbit?
(Android only) Someone talk about the Box2D. 1./ How to do the Game like Angry Bird Infact, I would like to know how to the game like Angry Bird ? The steps should to prepare? 2./ The formule to canculate the orbit of ball from 3 factor: ???? Power, direction (left-right) and the angle(0-90 degree). Thanks you very much
android
box2d
null
null
null
07/02/2012 06:58:29
not a real question
How to do the game like Angry Bird ? The formule of Orbit? === (Android only) Someone talk about the Box2D. 1./ How to do the Game like Angry Bird Infact, I would like to know how to the game like Angry Bird ? The steps should to prepare? 2./ The formule to canculate the orbit of ball from 3 factor: ???? Power, direction (left-right) and the angle(0-90 degree). Thanks you very much
1
8,600,147
12/22/2011 06:24:48
1,111,153
12/22/2011 06:20:58
1
0
Image id as digit cause W3C error
I am using Drupal 7.9 and the images generate a numerical id automatically. It causes W3C validation error **value of attribute "id" invalid: "1" cannot start a name** because id attribute doesn't allow a digit as its name. The image tag is `<img id="1" class="media-image" alt="contact" src="path to iamge" typeof="foaf:Image">`. How can I get rid of this? Any help will be greatly appreciated.
image
drupal
drupal-7
drupal-modules
w3c-validation
12/30/2011 17:45:11
off topic
Image id as digit cause W3C error === I am using Drupal 7.9 and the images generate a numerical id automatically. It causes W3C validation error **value of attribute "id" invalid: "1" cannot start a name** because id attribute doesn't allow a digit as its name. The image tag is `<img id="1" class="media-image" alt="contact" src="path to iamge" typeof="foaf:Image">`. How can I get rid of this? Any help will be greatly appreciated.
2
1,061,578
06/30/2009 03:28:59
127,304
06/23/2009 02:16:41
28
0
Method to return to beginning of function
Does C++ have any type of utility to return to the beginning of a function after a function call? For example, example the call to help() in the calculate function. void help() { cout << "Welcome to this annoying calculator program.\n"; cout << "You can add(+), subtract(-), multiply(*), divide(/),\n"; cout << "find the remainder(%), square root(sqrt()), use exponents(pow(x,x)),\n"; cout << "use parentheses, assign variables (ex: let x = 3), and assign\n"; cout << " constants (ex: const pi = 3.14). Happy Calculating!\n"; return; } void clean_up_mess() // purge error tokens { ts.ignore(print); } const string prompt = "> "; const string result = "= "; void calculate() { while(true) try { cout << prompt; Token t = ts.get(); if (t.kind == help_user) help(); else if (t.kind == quit) return; while (t.kind == print) t=ts.get(); ts.unget(t); cout << result << statement() << endl; } catch(runtime_error& e) { cerr << e.what() << endl; clean_up_mess(); } } While technically my implementation of a help function works fine, it's not perfect. After help is called, and returns, it proceeds with trying to cout << result << statement() << endl; which isn't possible because no values have been entered. Thus it gives a little error message (elsewhere in the program) and then proceeds on with the program. No problem with functionality, but it's ugly and I don't like it (:P). So is there any way for when the help function returns, to return to the beginning of calculate and start over? (I played around with inserting a function call in if(t.kind == help_user) block to call calculate, but as I figured that just delays the problem rather than solving it.)
c++
null
null
null
null
null
open
Method to return to beginning of function === Does C++ have any type of utility to return to the beginning of a function after a function call? For example, example the call to help() in the calculate function. void help() { cout << "Welcome to this annoying calculator program.\n"; cout << "You can add(+), subtract(-), multiply(*), divide(/),\n"; cout << "find the remainder(%), square root(sqrt()), use exponents(pow(x,x)),\n"; cout << "use parentheses, assign variables (ex: let x = 3), and assign\n"; cout << " constants (ex: const pi = 3.14). Happy Calculating!\n"; return; } void clean_up_mess() // purge error tokens { ts.ignore(print); } const string prompt = "> "; const string result = "= "; void calculate() { while(true) try { cout << prompt; Token t = ts.get(); if (t.kind == help_user) help(); else if (t.kind == quit) return; while (t.kind == print) t=ts.get(); ts.unget(t); cout << result << statement() << endl; } catch(runtime_error& e) { cerr << e.what() << endl; clean_up_mess(); } } While technically my implementation of a help function works fine, it's not perfect. After help is called, and returns, it proceeds with trying to cout << result << statement() << endl; which isn't possible because no values have been entered. Thus it gives a little error message (elsewhere in the program) and then proceeds on with the program. No problem with functionality, but it's ugly and I don't like it (:P). So is there any way for when the help function returns, to return to the beginning of calculate and start over? (I played around with inserting a function call in if(t.kind == help_user) block to call calculate, but as I figured that just delays the problem rather than solving it.)
0
3,729,184
09/16/2010 17:34:58
359,179
06/05/2010 12:06:46
51
0
what is vendor independece??
can you please help me to know the meaning of VENDOR INDEPENDECE that provided by FOSS?
homework
null
null
null
null
03/25/2012 16:58:05
off topic
what is vendor independece?? === can you please help me to know the meaning of VENDOR INDEPENDECE that provided by FOSS?
2
11,488,929
07/15/2012 02:32:48
1,505,019
07/05/2012 19:34:01
54
0
way to compare whats going on during a specific time?
so i have multiple timers going on at a given time, is there any way to say, if (randomTimer isGoingOnAtTheSameTimeAs randomTimer2) [self doSomeAwesomeMeth]; any responses would be greatly appreciated!
objective-c
ios
xcode
timer
null
07/16/2012 05:39:55
not a real question
way to compare whats going on during a specific time? === so i have multiple timers going on at a given time, is there any way to say, if (randomTimer isGoingOnAtTheSameTimeAs randomTimer2) [self doSomeAwesomeMeth]; any responses would be greatly appreciated!
1
11,738,287
07/31/2012 10:42:03
894,358
08/15/2011 00:37:36
20
2
How does Behaviour Driven Development (BDD) work with Domain Driven Design (DDD)
My understanding of BDD is that one describes a system in user stories and then developers take those user stories and turn them into an application with the intention of adding real business value with every 'sprint' (period of software development). The result (as far as I can tell) is that **the domain model emerges from the user stories** throughout the development process. That is, after the first 'sprint' much of the domain model will not have been designed. My understanding of DDD is that software development continues with reference to a full domain model, albeit an evolving one. In BDD the model is expected to change, but it is nonetheless 'complete' at all times. This seems to be a fundamental difference between the two approaches. How have people handled this?
domain-driven-design
bdd
null
null
null
null
open
How does Behaviour Driven Development (BDD) work with Domain Driven Design (DDD) === My understanding of BDD is that one describes a system in user stories and then developers take those user stories and turn them into an application with the intention of adding real business value with every 'sprint' (period of software development). The result (as far as I can tell) is that **the domain model emerges from the user stories** throughout the development process. That is, after the first 'sprint' much of the domain model will not have been designed. My understanding of DDD is that software development continues with reference to a full domain model, albeit an evolving one. In BDD the model is expected to change, but it is nonetheless 'complete' at all times. This seems to be a fundamental difference between the two approaches. How have people handled this?
0
2,297,920
02/19/2010 16:34:11
16,853
09/17/2008 21:33:16
15,886
417
JVM OutOfMemory error "death spiral" (not memory leak)
We have recently been migrating a number of applications from running under RedHat linux JDK1.6.0_03 to Solaris 10u8 JDK1.6.0_16 (much higher spec machines) and we have noticed what seems to be a rather pressing problem: under certain loads our JVMs get themselves into a "Death Spiral" and eventually go out of memory. Things to note: - this is **not a case of a memory leak**. These are applications which have been running just fine (in one case for over 3 years) and the out-of-memory errors are not certain in any case. Sometimes the applications work, sometimes they don't - this is **not us moving to a 64-bit VM** - we are still running 32 bit - In one case, using the latest G1 garbage collector on 1.6.0_18 seems to have solved the problem. In another, moving back to 1.6.0_03 has worked - Sometimes our apps are falling over with HotSpot `SIGSEGV` errors - This is affecting applications written in Java as well as Scala The most important point is this: *the behaviour manifests itself in those applications which suddenly get a deluge of data (usually via TCP)*. It's as if the VM decides to keep adding more data (possibly progressing it to the TG) rather than running a GC on "newspace" until it realises that it has to do a full GC and then, *despite practically everything in the VM being garbage, it somehow decides not to collect it!* It sounds crazy but I just don't see what else it is. How else can you explain an app which one minute falls over with a max heap of 1Gb and the next works just fine (never going about 256M when the app is doing *exactly the same thing*) So my questions are: 1. Has anyone else observed this kind of behaviour? 2. has anyone any suggestions as to how I might debug the JVM itself (as opposed to my app)? How do I prove this is a VM issue? 3. Are there any VM-specialist forums out there where I can ask the VM's authors (assuming they aren't on SO)? (We have no support contract) 4. If this is a bug in the latest versions of the VM, how come no-one else has noticed it?
jvm
outofmemoryerror
solaris
java
scala
null
open
JVM OutOfMemory error "death spiral" (not memory leak) === We have recently been migrating a number of applications from running under RedHat linux JDK1.6.0_03 to Solaris 10u8 JDK1.6.0_16 (much higher spec machines) and we have noticed what seems to be a rather pressing problem: under certain loads our JVMs get themselves into a "Death Spiral" and eventually go out of memory. Things to note: - this is **not a case of a memory leak**. These are applications which have been running just fine (in one case for over 3 years) and the out-of-memory errors are not certain in any case. Sometimes the applications work, sometimes they don't - this is **not us moving to a 64-bit VM** - we are still running 32 bit - In one case, using the latest G1 garbage collector on 1.6.0_18 seems to have solved the problem. In another, moving back to 1.6.0_03 has worked - Sometimes our apps are falling over with HotSpot `SIGSEGV` errors - This is affecting applications written in Java as well as Scala The most important point is this: *the behaviour manifests itself in those applications which suddenly get a deluge of data (usually via TCP)*. It's as if the VM decides to keep adding more data (possibly progressing it to the TG) rather than running a GC on "newspace" until it realises that it has to do a full GC and then, *despite practically everything in the VM being garbage, it somehow decides not to collect it!* It sounds crazy but I just don't see what else it is. How else can you explain an app which one minute falls over with a max heap of 1Gb and the next works just fine (never going about 256M when the app is doing *exactly the same thing*) So my questions are: 1. Has anyone else observed this kind of behaviour? 2. has anyone any suggestions as to how I might debug the JVM itself (as opposed to my app)? How do I prove this is a VM issue? 3. Are there any VM-specialist forums out there where I can ask the VM's authors (assuming they aren't on SO)? (We have no support contract) 4. If this is a bug in the latest versions of the VM, how come no-one else has noticed it?
0
3,666,629
09/08/2010 10:10:01
335,515
05/07/2010 14:24:56
52
1
iphone sdk: How to add checkboxes to UITableViewCell??
some time ago someone already asked this question and a few answers were given but i didn't really understand any of them. So i was wondering if anyone could please write an easy to understand tutorial on how to do the things shown on the image below: <http://img208.yfrog.com/img208/6119/screenshotkmr.png> I would be so greatful if anyone can share exactly how to this because it looks really cool and i would love to use something similar in my application :-)!
iphone
objective-c
uitableview
uitableviewcell
null
null
open
iphone sdk: How to add checkboxes to UITableViewCell?? === some time ago someone already asked this question and a few answers were given but i didn't really understand any of them. So i was wondering if anyone could please write an easy to understand tutorial on how to do the things shown on the image below: <http://img208.yfrog.com/img208/6119/screenshotkmr.png> I would be so greatful if anyone can share exactly how to this because it looks really cool and i would love to use something similar in my application :-)!
0
11,428,665
07/11/2012 08:37:44
1,173,474
01/27/2012 12:41:21
10
0
Simulate Form Submit with Symfony 2
I'm working with Symfony 2 and need some advice. I have a Controller, which gets a form-request and searches the database for matches and renders the results (so it's just a basic search). Now I would like to redirect to this controller but without coming from a form. To be more specific: - I'm on the search-page, fill out the form and hit the search button -> I get results for my search. - I'm somewhere else and want to delete a labelCategory of a book -> If some books still use this labelCategory, I want to get search results for this labelCategory. My only idea so far is, to simulate the form submit somehow, but I didn't find out how to do it. I'd be happy for every help of you ;)
forms
symfony-2.0
null
null
null
null
open
Simulate Form Submit with Symfony 2 === I'm working with Symfony 2 and need some advice. I have a Controller, which gets a form-request and searches the database for matches and renders the results (so it's just a basic search). Now I would like to redirect to this controller but without coming from a form. To be more specific: - I'm on the search-page, fill out the form and hit the search button -> I get results for my search. - I'm somewhere else and want to delete a labelCategory of a book -> If some books still use this labelCategory, I want to get search results for this labelCategory. My only idea so far is, to simulate the form submit somehow, but I didn't find out how to do it. I'd be happy for every help of you ;)
0
8,002,003
11/03/2011 21:19:06
458,955
09/26/2010 21:33:23
529
13
Detect multitouch with Ontouch listener Android
I currently have an imageview element that upon being touched, that tests if the action is an actiondown event, and if it is, it gets the coordinates of the touch with getraw(x or y) and then carries out an action based on those coordinates. How would I implement this to get two sets of coordinates from a two finger multitouch event?
android
imageview
multitouch
null
null
null
open
Detect multitouch with Ontouch listener Android === I currently have an imageview element that upon being touched, that tests if the action is an actiondown event, and if it is, it gets the coordinates of the touch with getraw(x or y) and then carries out an action based on those coordinates. How would I implement this to get two sets of coordinates from a two finger multitouch event?
0
10,277,707
04/23/2012 09:13:04
1,074,963
12/01/2011 08:00:44
6
0
Rails 2.3.14/Rails 1.9.3p125 on FreeBSD 9.0 failed
I have encounter a strange error after running $ portmaster -a last week. It reports method `xmlschema' not defined in Date in /usr/local/lib/ruby/gems/1.9/gems/activesupport-2.3.14/lib/active_support/core_ext/date/conversions.rb line 26 method `remove_method'. I cannot rollback nor I know where the problem come from. I have tried reinstall everything in ports by $ portsnap fetch update $ portmaster -Fa then reinstall all the gems. Unfortunately the error still persist. Could a guru help me out? Many thanks!
ruby-on-rails
null
null
null
null
04/25/2012 11:38:50
off topic
Rails 2.3.14/Rails 1.9.3p125 on FreeBSD 9.0 failed === I have encounter a strange error after running $ portmaster -a last week. It reports method `xmlschema' not defined in Date in /usr/local/lib/ruby/gems/1.9/gems/activesupport-2.3.14/lib/active_support/core_ext/date/conversions.rb line 26 method `remove_method'. I cannot rollback nor I know where the problem come from. I have tried reinstall everything in ports by $ portsnap fetch update $ portmaster -Fa then reinstall all the gems. Unfortunately the error still persist. Could a guru help me out? Many thanks!
2
3,066,255
06/17/2010 23:07:06
369,856
06/17/2010 23:07:06
1
0
Does Python Django support custom SQL and denormalized databases with no Foreign Key relationships?
I've just started learning Python Django and have a lot of experience building high traffic websites using PHP and MySQL. What worries me so far is Python's overly optimistic approach that you will never need to write custom SQL and that it automatically creates all these Foreign Key relationships in your database. The one thing I've learned in the last few years of building Chess.com is that its impossible to NOT write custom SQL when you're dealing with something like MySQL that frequently needs to be told what indexes it should use (or avoid), and that Foreign Keys are a death sentence. Percona's strongest recommendation was for us to remove all FKs for optimal performance. Is there a way in Django to do this in the models file? create relationships without creating actual DB FKs? Or is there a way to start at the database level, design/create my database, and then have Django reverse engineer the models file?
python
mysql
django
null
null
null
open
Does Python Django support custom SQL and denormalized databases with no Foreign Key relationships? === I've just started learning Python Django and have a lot of experience building high traffic websites using PHP and MySQL. What worries me so far is Python's overly optimistic approach that you will never need to write custom SQL and that it automatically creates all these Foreign Key relationships in your database. The one thing I've learned in the last few years of building Chess.com is that its impossible to NOT write custom SQL when you're dealing with something like MySQL that frequently needs to be told what indexes it should use (or avoid), and that Foreign Keys are a death sentence. Percona's strongest recommendation was for us to remove all FKs for optimal performance. Is there a way in Django to do this in the models file? create relationships without creating actual DB FKs? Or is there a way to start at the database level, design/create my database, and then have Django reverse engineer the models file?
0
9,788,461
03/20/2012 14:10:45
1,280,939
03/20/2012 13:02:03
1
0
Android : How to click listitem in listactivity with listadpater
i am new to android developing. i want to click on list-item in below code. public class Attendance extends ListActivity { // implements OnItemClickListener @Override protected void onCreate(Bundle savedInstanceState) { // TODO Auto-generated method stub super.onCreate(savedInstanceState); setContentView(R.layout.listplaceholder); ArrayList<HashMap<String, String>> mylist = new ArrayList<HashMap<String, String>>(); RestClient client = new RestClient("http://192.168.69.1/Webservice/Servlet"); String result = null; try { result = client.Execute(RequestMethod.GET); } catch (Exception e) { } Document doc = XMLfunctions.XMLfromString(result); int numResults = XMLfunctions.numResults(doc); if ((numResults <= 0)) { Toast.makeText(Attendance.this, "numresults<=0", Toast.LENGTH_LONG) .show(); finish(); } NodeList nodes = doc.getElementsByTagName("Test1"); for (int i = 0; i < nodes.getLength(); i++) { HashMap<String, String> map = new HashMap<String, String>(); Element e = (Element) nodes.item(i); map.put("name", XMLfunctions.getValue(e, "name")); mylist.add(map); } ListAdapter adapter = new SimpleAdapter(this, mylist, R.layout.testing, new String[] { "name" }, new int[] { R.id.name }); setListAdapter(adapter); //ListView lv = getListView(); // lv.setAdapter(adapter); } public void onListItemClick(ListView parent, View view, int position, long id) { Toast.makeText(this, "Clicking", Toast.LENGTH_SHORT) .show(); } } where i need to make correction and what i need to change in above code. help me, its urgent. mail Id :: [email protected]
android
null
null
null
null
03/20/2012 14:56:28
not a real question
Android : How to click listitem in listactivity with listadpater === i am new to android developing. i want to click on list-item in below code. public class Attendance extends ListActivity { // implements OnItemClickListener @Override protected void onCreate(Bundle savedInstanceState) { // TODO Auto-generated method stub super.onCreate(savedInstanceState); setContentView(R.layout.listplaceholder); ArrayList<HashMap<String, String>> mylist = new ArrayList<HashMap<String, String>>(); RestClient client = new RestClient("http://192.168.69.1/Webservice/Servlet"); String result = null; try { result = client.Execute(RequestMethod.GET); } catch (Exception e) { } Document doc = XMLfunctions.XMLfromString(result); int numResults = XMLfunctions.numResults(doc); if ((numResults <= 0)) { Toast.makeText(Attendance.this, "numresults<=0", Toast.LENGTH_LONG) .show(); finish(); } NodeList nodes = doc.getElementsByTagName("Test1"); for (int i = 0; i < nodes.getLength(); i++) { HashMap<String, String> map = new HashMap<String, String>(); Element e = (Element) nodes.item(i); map.put("name", XMLfunctions.getValue(e, "name")); mylist.add(map); } ListAdapter adapter = new SimpleAdapter(this, mylist, R.layout.testing, new String[] { "name" }, new int[] { R.id.name }); setListAdapter(adapter); //ListView lv = getListView(); // lv.setAdapter(adapter); } public void onListItemClick(ListView parent, View view, int position, long id) { Toast.makeText(this, "Clicking", Toast.LENGTH_SHORT) .show(); } } where i need to make correction and what i need to change in above code. help me, its urgent. mail Id :: [email protected]
1
3,144,592
06/29/2010 20:47:32
343,381
05/17/2010 19:29:26
192
6
UserControl calling methods and using variables outside it's class
I have a UserControl that looks like this: <UserControl x:Class="Test3.UserControl1" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> <Grid> <Button Name="mybutton" Content="Button Content"/> </Grid> </UserControl> And a main window that uses it like so: <Window Name="window_main" x:Class="Test3.Window1" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:local="clr-namespace:Test3"> <StackPanel> <Label Name="mylabel" Content="Old Content"/> <local:UserControl1/> </StackPanel> </Window> What I want to happen, is for mybutton's click event handler to set the content of mylabel to "New Content". However, it appears that this is impossible. Is there in fact a way to do this?
c#
wpf
xaml
null
null
null
open
UserControl calling methods and using variables outside it's class === I have a UserControl that looks like this: <UserControl x:Class="Test3.UserControl1" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> <Grid> <Button Name="mybutton" Content="Button Content"/> </Grid> </UserControl> And a main window that uses it like so: <Window Name="window_main" x:Class="Test3.Window1" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:local="clr-namespace:Test3"> <StackPanel> <Label Name="mylabel" Content="Old Content"/> <local:UserControl1/> </StackPanel> </Window> What I want to happen, is for mybutton's click event handler to set the content of mylabel to "New Content". However, it appears that this is impossible. Is there in fact a way to do this?
0
10,218,770
04/18/2012 22:06:24
1,066,240
11/25/2011 20:42:22
473
24
Feature request: New tag should be created: playframework-1.0
As Play! Framework has been definitely divided into 1.x+ vs. 2.x+ versions, that would be quite useful if users could tag their questions with exact version also for 1.x - `playframework-1.0`. This is not a question, but request to Players! with appropriate SO reputation to create the tag.
tags
playframework
stackoverflow
null
null
04/18/2012 22:07:52
off topic
Feature request: New tag should be created: playframework-1.0 === As Play! Framework has been definitely divided into 1.x+ vs. 2.x+ versions, that would be quite useful if users could tag their questions with exact version also for 1.x - `playframework-1.0`. This is not a question, but request to Players! with appropriate SO reputation to create the tag.
2
11,618,071
07/23/2012 18:13:07
1,120,354
12/29/2011 02:53:42
502
0
How to avoid having to type password every time rsync is run in a Bash script?
In a bash script, I have several rsync statements. Every rsync will prompt for typing password, and defeats very much the automation of doing the job using a script. How to improve this? The destination path of rsync statements are either network drive connected via SAMBA or on a SSH server.
bash
ssh
passwords
rsync
null
07/26/2012 01:07:28
off topic
How to avoid having to type password every time rsync is run in a Bash script? === In a bash script, I have several rsync statements. Every rsync will prompt for typing password, and defeats very much the automation of doing the job using a script. How to improve this? The destination path of rsync statements are either network drive connected via SAMBA or on a SSH server.
2
9,832,919
03/23/2012 01:16:42
1,287,257
03/23/2012 01:04:55
1
0
Generate Poisson Arrival in Java
I would like to create a function in Java that generates Poisson arrivals given the mean arrival rate (lambda) and the mean service rate (mu). In my example I have: 2,2 requests/day, in other words 2,2 arrivals/day and a mean service time of 108 hours. Considering that my program starts at t=0 minutes, I would like to create a function that returns arrivals[], which will contain, t1, t2, and a possible t3. T1,t2 and t3 are the instants (in minutes) during the day where this arrivals occur. I have the following restrictions: `t1 < t2 < t3 < 1440 minutes (24 hours*60 minutes/hour)` `t2-t1 > 108 minutes` `t3-t2 > 108 minutes` `t3+ 108 minutes < 1440 minutes` Can someone please help me? Thank you, Ana
java
poisson
null
null
null
null
open
Generate Poisson Arrival in Java === I would like to create a function in Java that generates Poisson arrivals given the mean arrival rate (lambda) and the mean service rate (mu). In my example I have: 2,2 requests/day, in other words 2,2 arrivals/day and a mean service time of 108 hours. Considering that my program starts at t=0 minutes, I would like to create a function that returns arrivals[], which will contain, t1, t2, and a possible t3. T1,t2 and t3 are the instants (in minutes) during the day where this arrivals occur. I have the following restrictions: `t1 < t2 < t3 < 1440 minutes (24 hours*60 minutes/hour)` `t2-t1 > 108 minutes` `t3-t2 > 108 minutes` `t3+ 108 minutes < 1440 minutes` Can someone please help me? Thank you, Ana
0
10,184,303
04/17/2012 02:30:01
1,128,875
01/03/2012 23:24:45
63
0
Windows environment, how to emulate a user?
Many systems (such as Linux's `su`) allow an admin to "emulate" another user. I am new to a Windows server/domain environment, how can an administrator emulate another (Active Directory) user? For example, I would want to login a Windows XP machine (under the domain) as another user (that is not mine, via emulation).
windows
active-directory
null
null
null
04/17/2012 12:01:47
off topic
Windows environment, how to emulate a user? === Many systems (such as Linux's `su`) allow an admin to "emulate" another user. I am new to a Windows server/domain environment, how can an administrator emulate another (Active Directory) user? For example, I would want to login a Windows XP machine (under the domain) as another user (that is not mine, via emulation).
2
6,172,160
05/30/2011 04:01:22
698,574
04/08/2011 11:45:47
355
1
wordpress _e function.
it shows"-- `Debug: Undefined variable: wordscut on line 168 of /wp-content/theme`" function cutstr($string, $length) { $string =strip_tags($string); preg_match_all("/[x01-x7f]|[xc2-xdf][x80-xbf]|xe0[xa0-xbf][x80-xbf]| [xe1-xef][x80-xbf][x80-xbf]|xf0[x90-xbf][x80-xbf][x80-xbf]|[xf1-xf7][x80-xbf][x80-xbf][x80-xbf]/", $string, $info); for($i=0; $i<count($info[0]); $i++) { $wordscut.= $info[0][$i]; $j= ord($info[0][$i]) > 127 ? $j + 2 : $j + 1; if ($j > $length - 3) { return $wordscut." ..."; } } return join('', $info[0]); } the above is my function. i know in php, a variable can't be declared before it is used.why it shows"`Undefined variable: wordscut, j`..... thank you. 2,* REQUIRED: `Non-printable characters were found in the '''functions.php'`'' file. You may want to check this file for errors. what is `Non-printable characters` .how to correct it? thank you.
wordpress
wordpress-theming
null
null
null
null
open
wordpress _e function. === it shows"-- `Debug: Undefined variable: wordscut on line 168 of /wp-content/theme`" function cutstr($string, $length) { $string =strip_tags($string); preg_match_all("/[x01-x7f]|[xc2-xdf][x80-xbf]|xe0[xa0-xbf][x80-xbf]| [xe1-xef][x80-xbf][x80-xbf]|xf0[x90-xbf][x80-xbf][x80-xbf]|[xf1-xf7][x80-xbf][x80-xbf][x80-xbf]/", $string, $info); for($i=0; $i<count($info[0]); $i++) { $wordscut.= $info[0][$i]; $j= ord($info[0][$i]) > 127 ? $j + 2 : $j + 1; if ($j > $length - 3) { return $wordscut." ..."; } } return join('', $info[0]); } the above is my function. i know in php, a variable can't be declared before it is used.why it shows"`Undefined variable: wordscut, j`..... thank you. 2,* REQUIRED: `Non-printable characters were found in the '''functions.php'`'' file. You may want to check this file for errors. what is `Non-printable characters` .how to correct it? thank you.
0
4,537,128
12/27/2010 07:06:29
280,100
02/24/2010 06:44:29
112
6
Which framework is better for creating a complete software as a service (SaaS) application in Python
I would like to create a billing application and would like to have it as a software as a service (SaaS) so that the hotels and banks could use that application. I have heared about many framework like (Django, Pylons, Werkzeug and Turbogears), but i dont know which to pick it up for developing the SaaS application. Please help me out
python
django
werkzeug
null
null
12/28/2010 03:10:52
not constructive
Which framework is better for creating a complete software as a service (SaaS) application in Python === I would like to create a billing application and would like to have it as a software as a service (SaaS) so that the hotels and banks could use that application. I have heared about many framework like (Django, Pylons, Werkzeug and Turbogears), but i dont know which to pick it up for developing the SaaS application. Please help me out
4
7,646,529
10/04/2011 10:31:26
450,504
08/04/2010 16:01:36
118
0
Develop Multiplayer Game
I would like to develop a multiplayer poker card game for my own purpose. I am very familiar with PHP but I realised that if I were to use PHP for this I would develop a pretty unscalable application by using HTTP push every second. I already developed a single player FLASH/PHP card game and I have some good ideas about efficiently developing the multiplayer card game, but I need some help with the communication and the server side documentation. I did some research over the internet and found that a good idea would be to use FLASH as desktop client that will communicate with a socket server, and the response of that would be taken care of by JAVA. Please correct me if I am wrong. I want all the logic of my application to be on the server side, and the communication between the client and server to be made 100% secure . The reason I made this post is because I really need some help, some walkthrough, some advices or even some sample code. I need to know what I must learn in order to develop my application. Thank you very much for your time !
flash
sockets
multiplayer
null
null
12/05/2011 11:53:50
not constructive
Develop Multiplayer Game === I would like to develop a multiplayer poker card game for my own purpose. I am very familiar with PHP but I realised that if I were to use PHP for this I would develop a pretty unscalable application by using HTTP push every second. I already developed a single player FLASH/PHP card game and I have some good ideas about efficiently developing the multiplayer card game, but I need some help with the communication and the server side documentation. I did some research over the internet and found that a good idea would be to use FLASH as desktop client that will communicate with a socket server, and the response of that would be taken care of by JAVA. Please correct me if I am wrong. I want all the logic of my application to be on the server side, and the communication between the client and server to be made 100% secure . The reason I made this post is because I really need some help, some walkthrough, some advices or even some sample code. I need to know what I must learn in order to develop my application. Thank you very much for your time !
4
11,224,366
06/27/2012 10:40:22
1,225,973
02/22/2012 13:39:02
3
0
How make a build for android gingerbread
I am developing a application of Android Tablet on 3.0 platform, I want to run it on gingerbread too. What should I do for make build.
android
build
null
null
null
06/27/2012 16:49:56
not a real question
How make a build for android gingerbread === I am developing a application of Android Tablet on 3.0 platform, I want to run it on gingerbread too. What should I do for make build.
1
3,820,601
09/29/2010 10:09:07
461,013
09/28/2010 19:23:50
1
0
What are best practices for IPhone web development
I need to know best practices for IPhone/IPAD HTML5 Web development.
iphone
ipad
html5
null
null
05/27/2012 14:35:40
not a real question
What are best practices for IPhone web development === I need to know best practices for IPhone/IPAD HTML5 Web development.
1
11,261,864
06/29/2012 12:34:45
468,968
10/07/2010 10:45:37
509
9
Daily DataBase Manintanence using SQL Server2008 using Stored Procedur
i have created DataBase Maintanence Plan using [wizard][1] though that link for SQL Server2005 i have created Maintenance Plan for SQL Server2008 and it works fine. now i required to complete the same task using Stored Procedure for my Desktop application. i have tried [this stored procedure][2] for that but it doesn't works for me. below is the code snippet i have tried. // sp_add_maintenance_plan [ @plan_name = ] 'plan_name' , //@plan_id = 'plan_id' OUTPUT String planid = ""; string maintenancePlan = "MyMaintenance"; string SQLstr = "DECLARE @plan_id as Varchar(50)"; SQLstr += " EXEC sp_add_maintenance_plan "; SQLstr += " @plan_name='" + maintenancePlan + "',"; SQLstr += " @plan_id= @plan_id OUTPUT"; SQLstr += " SELECT @plan_id"; SqlConnection cnn = new SqlConnection(MSDBconnStr); SqlCommand cmd = new SqlCommand(SQLstr, cnn); cnn.Open(); planid = (string)cmd.ExecuteScalar(); cnn.Close(); // sp_add_maintenance_plan_db [ @plan_id = ] 'plan_id' , //[ @db_name = ] 'database_name' string maintenancePlanDataBase = "MyDataBase"; string SQLstr1 = " EXEC sp_add_maintenance_plan_db "; SQLstr1 += " @plan_id='" + planid + "',"; SQLstr1 += " @db_name='" + maintenancePlanDataBase + "'"; SqlConnection cnn1 = new SqlConnection(MSDBconnStr); SqlCommand cmd1 = new SqlCommand(SQLstr1, cnn1); cnn1.Open(); cmd1.ExecuteNonQuery(); cnn1.Close(); [1]: http://cherupally.blogspot.in/2009/04/schedule-daily-backup-for-sql-server_27.html [2]: http://msdn.microsoft.com/en-us/library/ms190341%28v=sql.90%29.aspx
c#
.net
sql-server-2008
maintenance
maintenance-plan
06/30/2012 03:02:20
off topic
Daily DataBase Manintanence using SQL Server2008 using Stored Procedur === i have created DataBase Maintanence Plan using [wizard][1] though that link for SQL Server2005 i have created Maintenance Plan for SQL Server2008 and it works fine. now i required to complete the same task using Stored Procedure for my Desktop application. i have tried [this stored procedure][2] for that but it doesn't works for me. below is the code snippet i have tried. // sp_add_maintenance_plan [ @plan_name = ] 'plan_name' , //@plan_id = 'plan_id' OUTPUT String planid = ""; string maintenancePlan = "MyMaintenance"; string SQLstr = "DECLARE @plan_id as Varchar(50)"; SQLstr += " EXEC sp_add_maintenance_plan "; SQLstr += " @plan_name='" + maintenancePlan + "',"; SQLstr += " @plan_id= @plan_id OUTPUT"; SQLstr += " SELECT @plan_id"; SqlConnection cnn = new SqlConnection(MSDBconnStr); SqlCommand cmd = new SqlCommand(SQLstr, cnn); cnn.Open(); planid = (string)cmd.ExecuteScalar(); cnn.Close(); // sp_add_maintenance_plan_db [ @plan_id = ] 'plan_id' , //[ @db_name = ] 'database_name' string maintenancePlanDataBase = "MyDataBase"; string SQLstr1 = " EXEC sp_add_maintenance_plan_db "; SQLstr1 += " @plan_id='" + planid + "',"; SQLstr1 += " @db_name='" + maintenancePlanDataBase + "'"; SqlConnection cnn1 = new SqlConnection(MSDBconnStr); SqlCommand cmd1 = new SqlCommand(SQLstr1, cnn1); cnn1.Open(); cmd1.ExecuteNonQuery(); cnn1.Close(); [1]: http://cherupally.blogspot.in/2009/04/schedule-daily-backup-for-sql-server_27.html [2]: http://msdn.microsoft.com/en-us/library/ms190341%28v=sql.90%29.aspx
2
8,179,042
11/18/2011 07:21:34
1,051,342
11/17/2011 08:39:51
1
0
Copy records one table to another table
1)how to copy records from one table to another table? 2)Why i got the error "#1054 - Unknown column ' ' in 'where clause'
mysql
null
null
null
null
11/18/2011 09:02:06
not a real question
Copy records one table to another table === 1)how to copy records from one table to another table? 2)Why i got the error "#1054 - Unknown column ' ' in 'where clause'
1
4,089,817
11/03/2010 17:29:28
50,453
12/31/2008 10:20:16
1,202
50
What are some database migrations tools for PHP?
Having recently played a bit with a few different database schema migration tools (Python, Ruby, Java) I would like to see what is available in the PHP world. I know some of the frameworks have some support for migrations built in but ideally I'd like to find some standalone tools that won't require me to do much more than just the migrations with the project. (for instance, CakePHP seems to have nice migrations support but if I never have to touch a CakePHP application again I'll be a happy happy person)
php
schema
migration
database-schema
null
05/03/2012 12:25:16
not constructive
What are some database migrations tools for PHP? === Having recently played a bit with a few different database schema migration tools (Python, Ruby, Java) I would like to see what is available in the PHP world. I know some of the frameworks have some support for migrations built in but ideally I'd like to find some standalone tools that won't require me to do much more than just the migrations with the project. (for instance, CakePHP seems to have nice migrations support but if I never have to touch a CakePHP application again I'll be a happy happy person)
4
7,805,637
10/18/2011 10:14:59
800,454
06/15/2011 21:39:51
29
3
XPathExpression AddSort
Is it possible to sort the elements and not only the nodes using XPathExpression.AddSort? If I change the example code on the MSDN documentation for [XPathExpression.AddSort](http://msdn.microsoft.com/en-us/library/b2hhe5h7.aspx) a little so I request an element and not the whole node the sort order does not work. var doc = new XPathDocument("contosoBooks.xml"); var nav = doc.CreateNavigator(); var expr = nav.Compile("/bookstore/book/title"); expr.AddSort("title", XmlSortOrder.Descending, XmlCaseOrder.None, "", XmlDataType.Number); var iterator = nav.Select(expr); while (iterator.MoveNext()) { Console.WriteLine(iterator.Current); } I would expect this output: The Gorgias The Confidence Man The Autobiography of Benjamin Franklin But the output is this: The Autobiography of Benjamin Franklin The Confidence Man The Gorgias Here is the xml file for your reference <?xml version="1.0" encoding="utf-8" ?> <bookstore> <book genre="autobiography" publicationdate="1981-03-22" ISBN="1-861003-11-0"> <title>The Autobiography of Benjamin Franklin</title> <author> <first-name>Benjamin</first-name> <last-name>Franklin</last-name> </author> <price>8.99</price> </book> <book genre="novel" publicationdate="1967-11-17" ISBN="0-201-63361-2"> <title>The Confidence Man</title> <author> <first-name>Herman</first-name> <last-name>Melville</last-name> </author> <price>11.99</price> </book> <book genre="philosophy" publicationdate="1991-02-15" ISBN="1-861001-57-6"> <title>The Gorgias</title> <author> <name>Plato</name> </author> <price>9.99</price> </book> </bookstore>
c#
xml
null
null
null
null
open
XPathExpression AddSort === Is it possible to sort the elements and not only the nodes using XPathExpression.AddSort? If I change the example code on the MSDN documentation for [XPathExpression.AddSort](http://msdn.microsoft.com/en-us/library/b2hhe5h7.aspx) a little so I request an element and not the whole node the sort order does not work. var doc = new XPathDocument("contosoBooks.xml"); var nav = doc.CreateNavigator(); var expr = nav.Compile("/bookstore/book/title"); expr.AddSort("title", XmlSortOrder.Descending, XmlCaseOrder.None, "", XmlDataType.Number); var iterator = nav.Select(expr); while (iterator.MoveNext()) { Console.WriteLine(iterator.Current); } I would expect this output: The Gorgias The Confidence Man The Autobiography of Benjamin Franklin But the output is this: The Autobiography of Benjamin Franklin The Confidence Man The Gorgias Here is the xml file for your reference <?xml version="1.0" encoding="utf-8" ?> <bookstore> <book genre="autobiography" publicationdate="1981-03-22" ISBN="1-861003-11-0"> <title>The Autobiography of Benjamin Franklin</title> <author> <first-name>Benjamin</first-name> <last-name>Franklin</last-name> </author> <price>8.99</price> </book> <book genre="novel" publicationdate="1967-11-17" ISBN="0-201-63361-2"> <title>The Confidence Man</title> <author> <first-name>Herman</first-name> <last-name>Melville</last-name> </author> <price>11.99</price> </book> <book genre="philosophy" publicationdate="1991-02-15" ISBN="1-861001-57-6"> <title>The Gorgias</title> <author> <name>Plato</name> </author> <price>9.99</price> </book> </bookstore>
0
1,523,295
10/06/2009 02:11:22
82,970
03/26/2009 06:22:33
71
2
When is Scala 2.8.0 going to be released?
Or a release candidate? My google-fu fails me.
scala
release-cycle
null
null
null
01/19/2012 04:12:08
too localized
When is Scala 2.8.0 going to be released? === Or a release candidate? My google-fu fails me.
3
7,080,501
08/16/2011 15:10:05
719,178
04/21/2011 15:01:15
132
13
Broadcast address
I can't understand what a 'Broadcast address' is. I saw in [this][1] thread that the broadcast address (in the example given by balexandre) is: 192.168.33.128, means that the broadcast address will always be 1 address after the max address range of the IP address ? or there is other calculation that must be in ? thnx !!! [1]: http://stackoverflow.com/questions/1470792/how-to-calculate-the-ip-range-when-the-ip-address-and-the-netmask-is-given
ip-address
broadcast
null
null
null
08/16/2011 15:56:41
off topic
Broadcast address === I can't understand what a 'Broadcast address' is. I saw in [this][1] thread that the broadcast address (in the example given by balexandre) is: 192.168.33.128, means that the broadcast address will always be 1 address after the max address range of the IP address ? or there is other calculation that must be in ? thnx !!! [1]: http://stackoverflow.com/questions/1470792/how-to-calculate-the-ip-range-when-the-ip-address-and-the-netmask-is-given
2
2,737,302
04/29/2010 12:38:40
66,742
02/15/2009 22:58:46
36
6
ASP.NET Nested masterpages, how to set content in the top page from the aspx file?
I have some content from a CMS that I need to move to raw asp.net pages. Since the templates are nested I guess I can use nested masterpages to acomplish it, but I'm finding that I can't set values on the top masterpage from the deep child page. Here is a sample. I have several nested masterpages with contentplaceholders: * top master (with contentPlaceHolder1) * nested master, dependent on top master (with contentPlaceHolder2) * aspx page, dependent on nested master, defines content for contentPlaceHolder1 and 2 The problem is that asp.net doesn't allow me to have the value of contentPlaceHolder1 defined in the content page, it should be defined in the nested master. But the point is that the client page knows that value, not the template masters (for instance, the page knows about the graphic it has to display on the the top, but the placeholder for the graphic is the top master). How can I set values in the aspx page to be rendered in the top master?
asp.net
master-pages
nested
null
null
null
open
ASP.NET Nested masterpages, how to set content in the top page from the aspx file? === I have some content from a CMS that I need to move to raw asp.net pages. Since the templates are nested I guess I can use nested masterpages to acomplish it, but I'm finding that I can't set values on the top masterpage from the deep child page. Here is a sample. I have several nested masterpages with contentplaceholders: * top master (with contentPlaceHolder1) * nested master, dependent on top master (with contentPlaceHolder2) * aspx page, dependent on nested master, defines content for contentPlaceHolder1 and 2 The problem is that asp.net doesn't allow me to have the value of contentPlaceHolder1 defined in the content page, it should be defined in the nested master. But the point is that the client page knows that value, not the template masters (for instance, the page knows about the graphic it has to display on the the top, but the placeholder for the graphic is the top master). How can I set values in the aspx page to be rendered in the top master?
0
5,158,941
03/01/2011 18:51:26
639,914
03/01/2011 18:49:58
1
0
Java hashmap without using java.util
I want to create something similar that has the hashmap structure without using a hash map, in java. what is the best way of doing this.
java
null
null
null
null
03/01/2011 19:09:01
not a real question
Java hashmap without using java.util === I want to create something similar that has the hashmap structure without using a hash map, in java. what is the best way of doing this.
1
8,240,175
11/23/2011 09:55:02
40,676
11/25/2008 15:40:29
2,182
19
ASP.NET MVC 2 jquery datepicker format not set
In my code I want to set the format of dates to d MM yy. I've tried the following but with no success: $().ready(function () { $.datepicker.setDefaults({ dateFormat: 'd MM yy' }); $("#Client_DateOfBirth").datepicker( { maxDate: "+0D", dateFormat: 'd MM yy' }); }); The dates are set as follows: <div class="registration-item"> <%: Html.LabelFor(model =>model.Client.DateOfBirth) %> <%: Html.TextBoxFor(model => model.Client.DateOfBirth)%> <%: Html.ValidationMessageFor(model =>model.Client.DateOfBirth) %> </div> The value is displayed as: 15-8-1988 0:00:00. I don't want this,I want 15 aug 1988. When I pick a value from the datepicker,I get the right value. But when a value is already set,the format is not applied. How can I do this?
jquery
asp.net-mvc
datepicker
null
null
null
open
ASP.NET MVC 2 jquery datepicker format not set === In my code I want to set the format of dates to d MM yy. I've tried the following but with no success: $().ready(function () { $.datepicker.setDefaults({ dateFormat: 'd MM yy' }); $("#Client_DateOfBirth").datepicker( { maxDate: "+0D", dateFormat: 'd MM yy' }); }); The dates are set as follows: <div class="registration-item"> <%: Html.LabelFor(model =>model.Client.DateOfBirth) %> <%: Html.TextBoxFor(model => model.Client.DateOfBirth)%> <%: Html.ValidationMessageFor(model =>model.Client.DateOfBirth) %> </div> The value is displayed as: 15-8-1988 0:00:00. I don't want this,I want 15 aug 1988. When I pick a value from the datepicker,I get the right value. But when a value is already set,the format is not applied. How can I do this?
0
1,451,053
09/20/2009 13:52:32
176,208
09/20/2009 13:42:25
1
0
Distance learning degrees and certificates count during interviews ?
I can understand it is not directly programming related. But if you're learning or doing degree via e-learning method. Or to be precise Distance learning then is it counted by fellow programmers and HR's ? and interviewers ? **Do e-learning degrees/certificates from Universities have any value in programming world ? and in recruitment ?**
e-learning
interview-questions
null
null
null
01/31/2012 13:51:25
not constructive
Distance learning degrees and certificates count during interviews ? === I can understand it is not directly programming related. But if you're learning or doing degree via e-learning method. Or to be precise Distance learning then is it counted by fellow programmers and HR's ? and interviewers ? **Do e-learning degrees/certificates from Universities have any value in programming world ? and in recruitment ?**
4
7,038,619
08/12/2011 10:09:37
385,469
07/07/2010 11:33:24
481
49
installation of xCode 4.2 with iOS5 SDK beta 5 failed
I had downloaded the latest beta version (5) of SDK and tried to install on my MacBookPro, but strangely enough it failed to be installed. Very strange looks the required space 0 for installation, even I have checked all items to be installed. I am currently using OSX 10.6.8, but no idea what could be a problem regarding this. Any help would be appreciated.
ios
xcode
null
null
null
09/26/2011 22:09:42
too localized
installation of xCode 4.2 with iOS5 SDK beta 5 failed === I had downloaded the latest beta version (5) of SDK and tried to install on my MacBookPro, but strangely enough it failed to be installed. Very strange looks the required space 0 for installation, even I have checked all items to be installed. I am currently using OSX 10.6.8, but no idea what could be a problem regarding this. Any help would be appreciated.
3
8,977,865
01/23/2012 20:05:52
1,165,605
01/23/2012 19:00:43
1
0
jboss webservices
I require guidance in implementing webservices using jboss. Currently this is a feasibility study for providing webservice to an internal application. It may be possible that in the future it may have a broader outreach. a) Can you provide me guidance as to how to implement SOAP and also RESTful using jbossWS for java platform. Any documentation links would be helpful. We do not use enterprise java beans. b) Can we do the above without jbossWS. Any alternate method. It would be nice to know the pros and cons. c) Add in eclipse to the scenario and it would be helpful to know what features of eclipse will be helpful in developing webservices with jboss d) Lastly..which is better top down or bottom up approach. Thank you.
web-services
jboss
null
null
null
01/24/2012 20:18:07
not constructive
jboss webservices === I require guidance in implementing webservices using jboss. Currently this is a feasibility study for providing webservice to an internal application. It may be possible that in the future it may have a broader outreach. a) Can you provide me guidance as to how to implement SOAP and also RESTful using jbossWS for java platform. Any documentation links would be helpful. We do not use enterprise java beans. b) Can we do the above without jbossWS. Any alternate method. It would be nice to know the pros and cons. c) Add in eclipse to the scenario and it would be helpful to know what features of eclipse will be helpful in developing webservices with jboss d) Lastly..which is better top down or bottom up approach. Thank you.
4
11,543,673
07/18/2012 14:27:57
322,896
04/22/2010 03:46:17
24
1
Good real-world examples for coding common ajax/javascript web pages
I'm working on a website with heavy javascript/ajax (like facebook.) For example, a settings page with some editable fields and each of the forms is grabbed and submitted via ajax. Also, some javascript to populate data and do some transition effects. I looked at some javascript patterns (e.g. module and memoization) and try to use them in my code. However, I felt that it's a very common settings page but I never knew how experienced developers would design the javascript part (and probably html structure.) It's hard to learn from other websites because most of them just minified their js code. Is there any good resource to learn how to code some common tasks from real-world examples? Thanks!
javascript
html
ajax
web
patterns
07/19/2012 04:31:35
not constructive
Good real-world examples for coding common ajax/javascript web pages === I'm working on a website with heavy javascript/ajax (like facebook.) For example, a settings page with some editable fields and each of the forms is grabbed and submitted via ajax. Also, some javascript to populate data and do some transition effects. I looked at some javascript patterns (e.g. module and memoization) and try to use them in my code. However, I felt that it's a very common settings page but I never knew how experienced developers would design the javascript part (and probably html structure.) It's hard to learn from other websites because most of them just minified their js code. Is there any good resource to learn how to code some common tasks from real-world examples? Thanks!
4
6,974,511
08/07/2011 17:36:57
882,507
08/07/2011 07:06:42
11
0
why this not works ?! :((
there is a php program using regex but not show any thing in output ! whats wrong ? <?php $data='<div id="bodyContent" class="grid_16 push_4"> <form name="cart_quantity" action="http://iran-micro.com/product_info.php/products_id/1407/action/add_product" method="post"> <div> <h1 style="float: left;">xxxxxxxxxxx</h1> <h1>rrrrrrrrrrrrrrrr<br /><span class="smallText">zzzzzzzzzz</span></h1> </div> ' ; preg_match('/<h1 style="float: left;">(?P<cost>.*?)</h1>.*?<h1>(?P<name>.*?)<br />/s', $data, $matches); echo $matches['name']; echo $matches['cost']; ?>
php
regex
null
null
null
09/02/2011 17:05:34
too localized
why this not works ?! :(( === there is a php program using regex but not show any thing in output ! whats wrong ? <?php $data='<div id="bodyContent" class="grid_16 push_4"> <form name="cart_quantity" action="http://iran-micro.com/product_info.php/products_id/1407/action/add_product" method="post"> <div> <h1 style="float: left;">xxxxxxxxxxx</h1> <h1>rrrrrrrrrrrrrrrr<br /><span class="smallText">zzzzzzzzzz</span></h1> </div> ' ; preg_match('/<h1 style="float: left;">(?P<cost>.*?)</h1>.*?<h1>(?P<name>.*?)<br />/s', $data, $matches); echo $matches['name']; echo $matches['cost']; ?>
3
3,423,860
08/06/2010 12:48:14
413,046
08/06/2010 12:48:14
1
0
Cherokee + uWSGI + Pylons
I have successfully deployed a Django app with uWSGI + Cherokee. However, I want to experiment with Pylons before I go decide on Django. So far I have followed the instructions/recommendations here: http://stackoverflow.com/questions/2217679/deploying-pylons-with-uwsgi Paster serve works without a hitch. But when I try to serve via uWSGI, I get nowhere: `/usr/bin/uwsgi -s :5000 --paste config:/var/www/env/helloworld/development.ini -H /var/www/env -M` My uWSGI master and worker processes are spawned. SO, I visit http://localhost:5000 This is what I get: Error 324 (net::ERR_EMPTY_RESPONSE): Unknown error. And my terminal reads back (and repeats when I refresh browser): invalid request block size: 21573...skip What am I doing wrong? I cannot find any guide or step-by-step specific for uWSGI + Cherokee
python
pylons
cherokee
uwsgi
null
null
open
Cherokee + uWSGI + Pylons === I have successfully deployed a Django app with uWSGI + Cherokee. However, I want to experiment with Pylons before I go decide on Django. So far I have followed the instructions/recommendations here: http://stackoverflow.com/questions/2217679/deploying-pylons-with-uwsgi Paster serve works without a hitch. But when I try to serve via uWSGI, I get nowhere: `/usr/bin/uwsgi -s :5000 --paste config:/var/www/env/helloworld/development.ini -H /var/www/env -M` My uWSGI master and worker processes are spawned. SO, I visit http://localhost:5000 This is what I get: Error 324 (net::ERR_EMPTY_RESPONSE): Unknown error. And my terminal reads back (and repeats when I refresh browser): invalid request block size: 21573...skip What am I doing wrong? I cannot find any guide or step-by-step specific for uWSGI + Cherokee
0
7,491,965
09/20/2011 21:23:14
917,748
08/29/2011 11:44:04
41
1
problem with nsurlconnection, basic auth and cookies (i think!)
I have discovered that the server i make REST calls to pass on cookies to my iphone. It also employs HTTP Basic auth. I have an app where you sometimes change account for the auth, so i have discovered that changing the credentials doesn't matter since my "didReceiveAuthenticationChallenge" never is called! I have looked and seen two potential fixes: 1. remove cookies manually whenever credentials are changes 2. setting [request setHTTPShouldHandleCookies:false]; I'm wondering if i'm understanding this correctly, i would have expected the NSURLRequestReloadIgnoringCacheData to take care of caching... What are best practices? EDIT: just tried setting the "shouldhandlecookies" to false, but it seems that the cookies are still passed on to the server! Help would be much appreciated.
iphone
objective-c
cocoa
nsurlconnection
http-caching
null
open
problem with nsurlconnection, basic auth and cookies (i think!) === I have discovered that the server i make REST calls to pass on cookies to my iphone. It also employs HTTP Basic auth. I have an app where you sometimes change account for the auth, so i have discovered that changing the credentials doesn't matter since my "didReceiveAuthenticationChallenge" never is called! I have looked and seen two potential fixes: 1. remove cookies manually whenever credentials are changes 2. setting [request setHTTPShouldHandleCookies:false]; I'm wondering if i'm understanding this correctly, i would have expected the NSURLRequestReloadIgnoringCacheData to take care of caching... What are best practices? EDIT: just tried setting the "shouldhandlecookies" to false, but it seems that the cookies are still passed on to the server! Help would be much appreciated.
0
7,569,295
09/27/2011 12:41:46
202,598
11/04/2009 13:06:12
13
0
Rete Tree view not being displayed using drools plugin for Eclipse
I have been trying to display the Rete Tree view for drools files using the drools plugin for eclipse. But it is failing for me with the following error : I am using Eclipse Indigos, Drools 5.3 and JDK 1.7 . I googled around a bit to solve this issue but none of the suggestions worked. Any help would be highly appreciated ? On a parallel note is their any other way to validate the drools rules other than generating the Rete Tree view ? I want to find any syntactical mistakes as early as possible rather than invoking the validations and finding the drl mistakes at runtime. org.drools.RuntimeDroolsException: Unable to load dialect 'org.drools.rule.builder.dialect.java.JavaDialectConfiguration:java:org.drools.rule.builder.dialect.java.JavaDialectConfiguration' at org.drools.compiler.PackageBuilderConfiguration.addDialect(PackageBuilderConfiguration.java:277) at org.drools.compiler.PackageBuilderConfiguration.buildDialectConfigurationMap(PackageBuilderConfiguration.java:262) at org.drools.compiler.PackageBuilderConfiguration.init(PackageBuilderConfiguration.java:175) at org.drools.compiler.PackageBuilderConfiguration.<init>(PackageBuilderConfiguration.java:153) at org.drools.eclipse.DroolsEclipsePlugin.generateParsedResource(DroolsEclipsePlugin.java:393) at org.drools.eclipse.DroolsEclipsePlugin.generateParsedResource(DroolsEclipsePlugin.java:360) at org.drools.eclipse.DroolsEclipsePlugin.parseResource(DroolsEclipsePlugin.java:273) at org.drools.eclipse.editors.DroolsLineBreakpointAdapter.canToggleLineBreakpoints(DroolsLineBreakpointAdapter.java:44) at org.eclipse.debug.ui.actions.ToggleBreakpointAction.update(ToggleBreakpointAction.java:187) at org.eclipse.ui.texteditor.AbstractRulerActionDelegate.update(AbstractRulerActionDelegate.java:132) at org.eclipse.ui.texteditor.AbstractRulerActionDelegate.setActiveEditor(AbstractRulerActionDelegate.java:89) at org.eclipse.debug.ui.actions.RulerToggleBreakpointActionDelegate.setActiveEditor(RulerToggleBreakpointActionDelegate.java:98) at org.eclipse.ui.internal.EditorPluginAction.editorChanged(EditorPluginAction.java:75) at org.eclipse.ui.internal.EditorActionBuilder$EditorContribution.editorChanged(EditorActionBuilder.java:83) at org.eclipse.ui.internal.EditorActionBuilder$ExternalContributor.setActiveEditor(EditorActionBuilder.java:129) at org.eclipse.ui.internal.EditorActionBars.partChanged(EditorActionBars.java:346) at org.eclipse.ui.internal.WorkbenchPage$3.run(WorkbenchPage.java:709) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42) at org.eclipse.core.runtime.Platform.run(Platform.java:888) at org.eclipse.ui.internal.WorkbenchPage.activatePart(WorkbenchPage.java:698) at org.eclipse.ui.internal.WorkbenchPage.setActivePart(WorkbenchPage.java:3632) at org.eclipse.ui.internal.WorkbenchPage.requestActivation(WorkbenchPage.java:3159) at org.eclipse.ui.internal.PartPane.requestActivation(PartPane.java:279) at org.eclipse.ui.internal.EditorPane.requestActivation(EditorPane.java:98) at org.eclipse.ui.internal.PartPane.setFocus(PartPane.java:325) at org.eclipse.ui.internal.EditorPane.setFocus(EditorPane.java:127) at org.eclipse.ui.internal.PartStack.presentationSelectionChanged(PartStack.java:837) at org.eclipse.ui.internal.PartStack.access$1(PartStack.java:823) at org.eclipse.ui.internal.PartStack$1.selectPart(PartStack.java:137) at org.eclipse.ui.internal.presentations.util.TabbedStackPresentation$1.handleEvent(TabbedStackPresentation.java:133) at org.eclipse.ui.internal.presentations.util.AbstractTabFolder.fireEvent(AbstractTabFolder.java:269) at org.eclipse.ui.internal.presentations.util.AbstractTabFolder.fireEvent(AbstractTabFolder.java:278) at org.eclipse.ui.internal.presentations.defaultpresentation.DefaultTabFolder.access$1(DefaultTabFolder.java:1) at org.eclipse.ui.internal.presentations.defaultpresentation.DefaultTabFolder$2.handleEvent(DefaultTabFolder.java:88) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1053) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1077) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1062) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:774)
eclipse
drools
null
null
null
null
open
Rete Tree view not being displayed using drools plugin for Eclipse === I have been trying to display the Rete Tree view for drools files using the drools plugin for eclipse. But it is failing for me with the following error : I am using Eclipse Indigos, Drools 5.3 and JDK 1.7 . I googled around a bit to solve this issue but none of the suggestions worked. Any help would be highly appreciated ? On a parallel note is their any other way to validate the drools rules other than generating the Rete Tree view ? I want to find any syntactical mistakes as early as possible rather than invoking the validations and finding the drl mistakes at runtime. org.drools.RuntimeDroolsException: Unable to load dialect 'org.drools.rule.builder.dialect.java.JavaDialectConfiguration:java:org.drools.rule.builder.dialect.java.JavaDialectConfiguration' at org.drools.compiler.PackageBuilderConfiguration.addDialect(PackageBuilderConfiguration.java:277) at org.drools.compiler.PackageBuilderConfiguration.buildDialectConfigurationMap(PackageBuilderConfiguration.java:262) at org.drools.compiler.PackageBuilderConfiguration.init(PackageBuilderConfiguration.java:175) at org.drools.compiler.PackageBuilderConfiguration.<init>(PackageBuilderConfiguration.java:153) at org.drools.eclipse.DroolsEclipsePlugin.generateParsedResource(DroolsEclipsePlugin.java:393) at org.drools.eclipse.DroolsEclipsePlugin.generateParsedResource(DroolsEclipsePlugin.java:360) at org.drools.eclipse.DroolsEclipsePlugin.parseResource(DroolsEclipsePlugin.java:273) at org.drools.eclipse.editors.DroolsLineBreakpointAdapter.canToggleLineBreakpoints(DroolsLineBreakpointAdapter.java:44) at org.eclipse.debug.ui.actions.ToggleBreakpointAction.update(ToggleBreakpointAction.java:187) at org.eclipse.ui.texteditor.AbstractRulerActionDelegate.update(AbstractRulerActionDelegate.java:132) at org.eclipse.ui.texteditor.AbstractRulerActionDelegate.setActiveEditor(AbstractRulerActionDelegate.java:89) at org.eclipse.debug.ui.actions.RulerToggleBreakpointActionDelegate.setActiveEditor(RulerToggleBreakpointActionDelegate.java:98) at org.eclipse.ui.internal.EditorPluginAction.editorChanged(EditorPluginAction.java:75) at org.eclipse.ui.internal.EditorActionBuilder$EditorContribution.editorChanged(EditorActionBuilder.java:83) at org.eclipse.ui.internal.EditorActionBuilder$ExternalContributor.setActiveEditor(EditorActionBuilder.java:129) at org.eclipse.ui.internal.EditorActionBars.partChanged(EditorActionBars.java:346) at org.eclipse.ui.internal.WorkbenchPage$3.run(WorkbenchPage.java:709) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42) at org.eclipse.core.runtime.Platform.run(Platform.java:888) at org.eclipse.ui.internal.WorkbenchPage.activatePart(WorkbenchPage.java:698) at org.eclipse.ui.internal.WorkbenchPage.setActivePart(WorkbenchPage.java:3632) at org.eclipse.ui.internal.WorkbenchPage.requestActivation(WorkbenchPage.java:3159) at org.eclipse.ui.internal.PartPane.requestActivation(PartPane.java:279) at org.eclipse.ui.internal.EditorPane.requestActivation(EditorPane.java:98) at org.eclipse.ui.internal.PartPane.setFocus(PartPane.java:325) at org.eclipse.ui.internal.EditorPane.setFocus(EditorPane.java:127) at org.eclipse.ui.internal.PartStack.presentationSelectionChanged(PartStack.java:837) at org.eclipse.ui.internal.PartStack.access$1(PartStack.java:823) at org.eclipse.ui.internal.PartStack$1.selectPart(PartStack.java:137) at org.eclipse.ui.internal.presentations.util.TabbedStackPresentation$1.handleEvent(TabbedStackPresentation.java:133) at org.eclipse.ui.internal.presentations.util.AbstractTabFolder.fireEvent(AbstractTabFolder.java:269) at org.eclipse.ui.internal.presentations.util.AbstractTabFolder.fireEvent(AbstractTabFolder.java:278) at org.eclipse.ui.internal.presentations.defaultpresentation.DefaultTabFolder.access$1(DefaultTabFolder.java:1) at org.eclipse.ui.internal.presentations.defaultpresentation.DefaultTabFolder$2.handleEvent(DefaultTabFolder.java:88) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1053) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1077) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1062) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:774)
0
6,404,292
06/19/2011 18:22:56
805,149
06/19/2011 07:44:20
37
0
Loading jQuery asyncronously
My google analytics is supposed to load asynchronously. I am not sure really what this means: <script type="text/javascript"> var _gaq = _gaq || []; _gaq.push(['_setAccount', 'xxx']); _gaq.push(['_trackPageview']); (function () { var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); })(); </script> I don't need jQuery to be available immediately. Is there a way I can also make this asynchronous?
jquery
null
null
null
null
null
open
Loading jQuery asyncronously === My google analytics is supposed to load asynchronously. I am not sure really what this means: <script type="text/javascript"> var _gaq = _gaq || []; _gaq.push(['_setAccount', 'xxx']); _gaq.push(['_trackPageview']); (function () { var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); })(); </script> I don't need jQuery to be available immediately. Is there a way I can also make this asynchronous?
0
2,744,660
04/30/2010 13:06:14
318,592
04/16/2010 14:45:09
11
0
Appending html data when item in html select list is selected
I have a selector that could look like this: <label for="testselector">Test</label><br /> <select id="testselector" name="test[]" size="5" multiple="multiple"> <option name="test_1" value="1">Test Entry X</option> <option name="test_3" value="2">Test Entry Y</option> <option name="test_5" value="5">Test Entry Z</option> </select> <div id="fieldcontainer"></div> When an entry from the above fields is selected, I want two form fields to appear. I use jquery to add them: $("#fieldcontainer").append("<div><label for=\"testurl\">Test Url</label><br /><input name=\"testurl[]\" type=\"text\" id=\"testurl_1\" value=\"\" /></div>"); $("#fieldcontainer").append("<div><label for=\"testpath\">Test Path</label><br /><input name=\"testpath[]\" type=\"text\" id=\"testpath_1\" value=\"\" /></div>"); I can easily add a click handler to make those form fields appear. But how would I keep track of what form fields were already added? When multiple fields are selected, the appropriate number of input fields needs to be added to the fieldcontainer div. And if they are unselected, the input fields need to be removed again. I also need to retrieve the value from the options in the select list to add them as identifier in the added input fields...
jquery
append
select
html
click
null
open
Appending html data when item in html select list is selected === I have a selector that could look like this: <label for="testselector">Test</label><br /> <select id="testselector" name="test[]" size="5" multiple="multiple"> <option name="test_1" value="1">Test Entry X</option> <option name="test_3" value="2">Test Entry Y</option> <option name="test_5" value="5">Test Entry Z</option> </select> <div id="fieldcontainer"></div> When an entry from the above fields is selected, I want two form fields to appear. I use jquery to add them: $("#fieldcontainer").append("<div><label for=\"testurl\">Test Url</label><br /><input name=\"testurl[]\" type=\"text\" id=\"testurl_1\" value=\"\" /></div>"); $("#fieldcontainer").append("<div><label for=\"testpath\">Test Path</label><br /><input name=\"testpath[]\" type=\"text\" id=\"testpath_1\" value=\"\" /></div>"); I can easily add a click handler to make those form fields appear. But how would I keep track of what form fields were already added? When multiple fields are selected, the appropriate number of input fields needs to be added to the fieldcontainer div. And if they are unselected, the input fields need to be removed again. I also need to retrieve the value from the options in the select list to add them as identifier in the added input fields...
0
11,559,845
07/19/2012 11:25:44
557,352
12/29/2010 16:32:14
329
24
C# Circualr Reference
I have three class and there is a circular reference between them. class A { public A() C { B obj = new B(); } } class B { public B() { C obj = new C(); } } class C { public C() { A obj = new A(); } } When I am creating object of A it's throwing exception. How could I resolve the circular reference.
c#
null
null
null
null
07/20/2012 03:12:47
not a real question
C# Circualr Reference === I have three class and there is a circular reference between them. class A { public A() C { B obj = new B(); } } class B { public B() { C obj = new C(); } } class C { public C() { A obj = new A(); } } When I am creating object of A it's throwing exception. How could I resolve the circular reference.
1
11,418,675
07/10/2012 17:27:46
940,722
09/12/2011 14:04:39
27
1
Netcat send data to PHP
as Netcat sends data (XXX) from one port to php? example: /home/file.php?var=XXX thanks
php
tcp
port
netcat
null
07/10/2012 17:40:31
not a real question
Netcat send data to PHP === as Netcat sends data (XXX) from one port to php? example: /home/file.php?var=XXX thanks
1
6,809,089
07/24/2011 19:23:44
856,720
07/21/2011 19:31:21
9
0
how can i prevent getting an exeption when canceling an already canceled Timer(because some times it's already canceled/done with it) ?
i tried to cancel a Timer.schedule() when i start a new one because i need 1 sechedule at once...but i get this exception Exception in thread "AWT-EventQueue-0" java.lang.IllegalStateException: Timer already cancelled. as u can see the Timer is already canceled, how can i prevent that? i tried this code, still didnt work check it please: note :everything in this code works fine except the 2nd line public void startTimer(byte h, byte m) { timer.cancel();//cancel the Timer whenever i start a new one Date d = new Date(); d.setHours(h); d.setMinutes(m); d.setSeconds(0); UserInterface.setAlarmTime(h, m); timer.schedule(new Alarm(), d); if i remove the 2nd line this code will give me a Timer but i doesnt cancel the old Timer so whenver i call this method i get more timers and this is not what i really need.. so how can i prevent this Exception? there's no methods in the Timer class that will tell me if there's a Timer in schedule, already checked it...so please help me.
java
exception
timer
null
null
null
open
how can i prevent getting an exeption when canceling an already canceled Timer(because some times it's already canceled/done with it) ? === i tried to cancel a Timer.schedule() when i start a new one because i need 1 sechedule at once...but i get this exception Exception in thread "AWT-EventQueue-0" java.lang.IllegalStateException: Timer already cancelled. as u can see the Timer is already canceled, how can i prevent that? i tried this code, still didnt work check it please: note :everything in this code works fine except the 2nd line public void startTimer(byte h, byte m) { timer.cancel();//cancel the Timer whenever i start a new one Date d = new Date(); d.setHours(h); d.setMinutes(m); d.setSeconds(0); UserInterface.setAlarmTime(h, m); timer.schedule(new Alarm(), d); if i remove the 2nd line this code will give me a Timer but i doesnt cancel the old Timer so whenver i call this method i get more timers and this is not what i really need.. so how can i prevent this Exception? there's no methods in the Timer class that will tell me if there's a Timer in schedule, already checked it...so please help me.
0
5,537,952
04/04/2011 11:43:12
164,589
08/28/2009 01:45:01
66
0
Purchase in app
I am a new one for Android development. I am wondering about how to purchase in app. How to begin this feature ? Is there a documentation or API doc? Thanks in advance.
android
in-app-purchase
null
null
null
06/27/2012 13:18:08
not a real question
Purchase in app === I am a new one for Android development. I am wondering about how to purchase in app. How to begin this feature ? Is there a documentation or API doc? Thanks in advance.
1
10,766,662
05/26/2012 13:26:57
313,378
04/10/2010 08:15:53
133
1
Optimizing nhibernate session factory, startup time of webApp really slow
I have implement testing app. which uses fluent nhibernate mapping to db object inside mssql db. Since I want to learn fine tune nhib. mvc3 applications, I'm using this app. for testing purposes which have only one simple entity with 10 enum properties and one string property. So, it is really lightwave, yet startup time according to nhibernate profiler is 4.37 sec. Which is really slow for rendering one entity with few lines checked/unchecked property. Code is the following. **Domain.SessionProvider.cs** public static ISessionFactory CreateSessionFactory() { var config = Fluently.Configure() .Database(MsSqlConfiguration.MsSql2008 .ConnectionString(c => c.FromConnectionStringWithKey("myConnection"))) .Mappings(m => m.FluentMappings.Add<FeaturesMap>()) .ExposeConfiguration(p => p.SetProperty("current_session_context_class", "web")) .BuildConfiguration(); return config.BuildSessionFactory(); } **Global.asax** public class MvcApplication : System.Web.HttpApplication { //SessionPerWebRequest is ommited here as well as other content public static ISessionFactory SessionFactory = SessionProvider.CreateSessionFactory(); protected void Application_Start() { SessionFactory.OpenSession(); } } Inside myController I have following: public ActionResult Index() { return View(GetData()); } private IList<FeaturesViewModel> GetData() { List<Features> data; using (ISession session = MvcApplication.SessionFactory.GetCurrentSession()) { using (ITransaction tx = session.BeginTransaction()) { data = session.Query<Features>().Take(5).ToList(); tx.Commit(); var viewModelData = FeaturesViewModel.FromDomainModel(data); return viewModelData; } } }
c#
asp.net-mvc-3
nhibernate
fluent-nhibernate
null
null
open
Optimizing nhibernate session factory, startup time of webApp really slow === I have implement testing app. which uses fluent nhibernate mapping to db object inside mssql db. Since I want to learn fine tune nhib. mvc3 applications, I'm using this app. for testing purposes which have only one simple entity with 10 enum properties and one string property. So, it is really lightwave, yet startup time according to nhibernate profiler is 4.37 sec. Which is really slow for rendering one entity with few lines checked/unchecked property. Code is the following. **Domain.SessionProvider.cs** public static ISessionFactory CreateSessionFactory() { var config = Fluently.Configure() .Database(MsSqlConfiguration.MsSql2008 .ConnectionString(c => c.FromConnectionStringWithKey("myConnection"))) .Mappings(m => m.FluentMappings.Add<FeaturesMap>()) .ExposeConfiguration(p => p.SetProperty("current_session_context_class", "web")) .BuildConfiguration(); return config.BuildSessionFactory(); } **Global.asax** public class MvcApplication : System.Web.HttpApplication { //SessionPerWebRequest is ommited here as well as other content public static ISessionFactory SessionFactory = SessionProvider.CreateSessionFactory(); protected void Application_Start() { SessionFactory.OpenSession(); } } Inside myController I have following: public ActionResult Index() { return View(GetData()); } private IList<FeaturesViewModel> GetData() { List<Features> data; using (ISession session = MvcApplication.SessionFactory.GetCurrentSession()) { using (ITransaction tx = session.BeginTransaction()) { data = session.Query<Features>().Take(5).ToList(); tx.Commit(); var viewModelData = FeaturesViewModel.FromDomainModel(data); return viewModelData; } } }
0
8,632,359
12/26/2011 00:52:18
1,079,834
12/04/2011 07:25:31
6
0
JQuery Dropable PhotoManger with default items from trash
I'm using the Jquery's simple photo manager just as it is and it's working properly. http://jqueryui.com/demos/droppable/photo-manager.html All I need is when the page is loaded, the trash already has some items. I think I've write code carefuly. My problem is items initialized in the galary can be dragged to trash and then dragged back normaly, but items initialized in the trash cannot be dragged. Please help me to make items initialized in the trash can be dragged.
jquery
jquery-ui
null
null
null
null
open
JQuery Dropable PhotoManger with default items from trash === I'm using the Jquery's simple photo manager just as it is and it's working properly. http://jqueryui.com/demos/droppable/photo-manager.html All I need is when the page is loaded, the trash already has some items. I think I've write code carefuly. My problem is items initialized in the galary can be dragged to trash and then dragged back normaly, but items initialized in the trash cannot be dragged. Please help me to make items initialized in the trash can be dragged.
0
5,482,028
03/30/2011 04:57:27
139,150
07/16/2009 03:00:08
1,056
56
Changing the image upside down
The following favicon.ico file has "W" in it. I want it change the direction upside down. It will look like "M" and the file format will be the same. http://en.wikipedia.org/favicon.ico How is it done?
image
image-processing
photoshop
null
null
03/30/2011 13:36:40
off topic
Changing the image upside down === The following favicon.ico file has "W" in it. I want it change the direction upside down. It will look like "M" and the file format will be the same. http://en.wikipedia.org/favicon.ico How is it done?
2
6,202,748
06/01/2011 14:24:22
55,093
01/14/2009 17:32:50
3,101
104
Android - Customizing the title bar
I want to customize the title bar for an Android application. I have the following layout: <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="80dp" <!-- Problem here --> android:gravity="center_vertical" android:background="#B9121B" > <ImageView android:id="@+id/header" android:src="@drawable/windowtitle" android:layout_width="fill_parent" android:layout_height="fill_parent"/> </LinearLayout> I also have a the following code in the targeted activity: public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); requestWindowFeature(Window.FEATURE_CUSTOM_TITLE); setContentView(R.layout.home); getWindow().setFeatureInt(Window.FEATURE_CUSTOM_TITLE, R.layout.window_title); ... } I don't understand the following: - The height of the title bar doesn't change when changing the `android:layout_height` value. - When I put a picture background instead of a color, and when giving `fill_parent` to the `layout_width` field, the image doesn't stretch to fill the entire space. Did I miss something? Thanks!
android
android-layout
android-titlebar
null
null
null
open
Android - Customizing the title bar === I want to customize the title bar for an Android application. I have the following layout: <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="80dp" <!-- Problem here --> android:gravity="center_vertical" android:background="#B9121B" > <ImageView android:id="@+id/header" android:src="@drawable/windowtitle" android:layout_width="fill_parent" android:layout_height="fill_parent"/> </LinearLayout> I also have a the following code in the targeted activity: public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); requestWindowFeature(Window.FEATURE_CUSTOM_TITLE); setContentView(R.layout.home); getWindow().setFeatureInt(Window.FEATURE_CUSTOM_TITLE, R.layout.window_title); ... } I don't understand the following: - The height of the title bar doesn't change when changing the `android:layout_height` value. - When I put a picture background instead of a color, and when giving `fill_parent` to the `layout_width` field, the image doesn't stretch to fill the entire space. Did I miss something? Thanks!
0
8,863,388
01/14/2012 16:04:13
1,149,433
01/14/2012 15:58:20
1
0
Changing Eclipse Dock Icon
So a while back, I downloaded Eclipse for JS developers. It always launched with the "JS" icon showing in my Win7 dock. Recently, I started using Eclipse for Java EE development, as well. But regardless of what perspective I'm using, the dock icon still says "JS." Now, I'm the kind of person whom that really annoys. Is there any way to change the dock icon WITHOUT re-installing Eclipse?
java
eclipse
windows-7
icons
dock
01/17/2012 04:28:34
too localized
Changing Eclipse Dock Icon === So a while back, I downloaded Eclipse for JS developers. It always launched with the "JS" icon showing in my Win7 dock. Recently, I started using Eclipse for Java EE development, as well. But regardless of what perspective I'm using, the dock icon still says "JS." Now, I'm the kind of person whom that really annoys. Is there any way to change the dock icon WITHOUT re-installing Eclipse?
3
5,514,968
04/01/2011 14:45:52
687,787
04/01/2011 14:45:52
1
0
Does large web developing companies use their own framework or community?
Just as the topic states, do they use their own framework (like written from scratch) or do they use other community frameworks like for instance Zend or Codeigniter as their base? I'm wondering due to the fact that i'm developing my own framework for educational purposes but thinking of moving on to CI or Zend.
php5
frameworks
null
null
null
04/01/2011 15:23:17
not a real question
Does large web developing companies use their own framework or community? === Just as the topic states, do they use their own framework (like written from scratch) or do they use other community frameworks like for instance Zend or Codeigniter as their base? I'm wondering due to the fact that i'm developing my own framework for educational purposes but thinking of moving on to CI or Zend.
1
8,489,792
12/13/2011 13:09:21
956,689
09/21/2011 10:27:33
564
1
is it legal to take acos of 1.0f or -1.0f?
I have a problem with my code where agents moving around suddenly disappear. This seems to be because their positions suddenly become 1.#INF000 in the x and y axis. I did a little research and someone said this can occur with acos if a value is over or under 1 and -1 respectively, but went on to say it could happen if the values were close too. I added an if statement to check to see if I'm ever taking acos of 1 or -1 and it does evaluate to 1 a few frame cycles before they disappear, however I don't really understand the problem to be able to fix it. Can anyone shed any light on this matter? D3DXVECTOR3 D3DXVECTOR3Helper::RotToTarget2DPlane(D3DXVECTOR3 position, D3DXVECTOR3 target)//XY PLANE { //Create std::vector to target D3DXVECTOR3 vectorToTarget = target - position; D3DXVec3Normalize(&vectorToTarget, &vectorToTarget); //creates a displacement std::vector of relative 0, 0, 0 D3DXVECTOR3 neutralDirectionalVector = D3DXVECTOR3(1, 0, 0);//set this to whatever direction your models are loaded facing //Create the angle between them if(D3DXVec3Dot(&vectorToTarget, &neutralDirectionalVector) >= 1.0f ||D3DXVec3Dot(&vectorToTarget, &neutralDirectionalVector) <= -1.0f) { float i = D3DXVec3Dot(&vectorToTarget, &neutralDirectionalVector); float j = 0; //ADDED THIS IF STATEMENT } float angle = acos(D3DXVec3Dot(&vectorToTarget, &neutralDirectionalVector)); if (target.y > position.y) { return D3DXVECTOR3(0, 0, angle); } else { return D3DXVECTOR3(0, 0, -angle); } }//end VecRotateToTarget2DPlane()
c++
math
null
null
null
null
open
is it legal to take acos of 1.0f or -1.0f? === I have a problem with my code where agents moving around suddenly disappear. This seems to be because their positions suddenly become 1.#INF000 in the x and y axis. I did a little research and someone said this can occur with acos if a value is over or under 1 and -1 respectively, but went on to say it could happen if the values were close too. I added an if statement to check to see if I'm ever taking acos of 1 or -1 and it does evaluate to 1 a few frame cycles before they disappear, however I don't really understand the problem to be able to fix it. Can anyone shed any light on this matter? D3DXVECTOR3 D3DXVECTOR3Helper::RotToTarget2DPlane(D3DXVECTOR3 position, D3DXVECTOR3 target)//XY PLANE { //Create std::vector to target D3DXVECTOR3 vectorToTarget = target - position; D3DXVec3Normalize(&vectorToTarget, &vectorToTarget); //creates a displacement std::vector of relative 0, 0, 0 D3DXVECTOR3 neutralDirectionalVector = D3DXVECTOR3(1, 0, 0);//set this to whatever direction your models are loaded facing //Create the angle between them if(D3DXVec3Dot(&vectorToTarget, &neutralDirectionalVector) >= 1.0f ||D3DXVec3Dot(&vectorToTarget, &neutralDirectionalVector) <= -1.0f) { float i = D3DXVec3Dot(&vectorToTarget, &neutralDirectionalVector); float j = 0; //ADDED THIS IF STATEMENT } float angle = acos(D3DXVec3Dot(&vectorToTarget, &neutralDirectionalVector)); if (target.y > position.y) { return D3DXVECTOR3(0, 0, angle); } else { return D3DXVECTOR3(0, 0, -angle); } }//end VecRotateToTarget2DPlane()
0
8,490,205
12/13/2011 13:42:08
1,095,851
12/13/2011 13:35:06
1
0
About GridView in asp.net
I am having a gridview and i have binded some some datum from db as labels using template fields....Now i have to Insert a new row which can be 'N' number of rows...all these rows should contain only textboxes .....i should not use footer template.... So, In a gridview, Datum from db should be shown as labels, and newly added row should contain only textbox so tat we can add some values in the textbox....datum from the DB should not be editable as well in the gridview...Help me to solve this!!!
c#
asp.net
null
null
null
12/13/2011 14:06:30
not a real question
About GridView in asp.net === I am having a gridview and i have binded some some datum from db as labels using template fields....Now i have to Insert a new row which can be 'N' number of rows...all these rows should contain only textboxes .....i should not use footer template.... So, In a gridview, Datum from db should be shown as labels, and newly added row should contain only textbox so tat we can add some values in the textbox....datum from the DB should not be editable as well in the gridview...Help me to solve this!!!
1
4,760,339
01/21/2011 15:08:46
575,458
01/14/2011 09:21:09
1
1
ACE Oledb 12.0 and XLSX problems
Hy everyone, I'm using the following code to set a connection string on my local PC that has Office 2007, SQL Server 2008: string connString = "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=" + MapPath(Request.ApplicationPath) + "\\" + excelFolderName + fileName + ";Extended Properties=\"Excel 12.0 Xml;HDR=YES;IMEX=1\""; My SO is Windows 7 (64) and I'm able to read XLS and XLSX files without problems. No I've released my project into a MS Server 2003 R2 Standard Edition X64 and after bumping into some problems because I didn't have the ACE OLEDB 12.0 installed, I installed "Microsoft Access Database Engine 2010 Redistributable" and am no able to read XLS files. The problem comes when I try to open XLSX (that were created using Office 2007) because I get this error: "External table is not in the expected format" What am I doing wrong? I don't want to install the previous "Microsoft Access Database Engine 2007 Redistributable" because it only has a 32 bits version that forces me to build my project as 32 bits... Thanks in advance
oledb
office
null
null
null
null
open
ACE Oledb 12.0 and XLSX problems === Hy everyone, I'm using the following code to set a connection string on my local PC that has Office 2007, SQL Server 2008: string connString = "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=" + MapPath(Request.ApplicationPath) + "\\" + excelFolderName + fileName + ";Extended Properties=\"Excel 12.0 Xml;HDR=YES;IMEX=1\""; My SO is Windows 7 (64) and I'm able to read XLS and XLSX files without problems. No I've released my project into a MS Server 2003 R2 Standard Edition X64 and after bumping into some problems because I didn't have the ACE OLEDB 12.0 installed, I installed "Microsoft Access Database Engine 2010 Redistributable" and am no able to read XLS files. The problem comes when I try to open XLSX (that were created using Office 2007) because I get this error: "External table is not in the expected format" What am I doing wrong? I don't want to install the previous "Microsoft Access Database Engine 2007 Redistributable" because it only has a 32 bits version that forces me to build my project as 32 bits... Thanks in advance
0
1,044,590
06/25/2009 15:30:33
119,910
06/09/2009 15:18:14
91
11
most professional way to tell a developer they are no good
What is the most professional way to break it to a developer that their not very good. I haven't been a developer for as some of the others out there. But I have already had to deal with some really crazy people. What is the best way(s) to stay professional and critic a developer who really is horrible at his/her job, keeping in mind its a small world and you might HAVE to work with them again.
mentoring
criticism
null
null
null
07/13/2010 19:50:27
off topic
most professional way to tell a developer they are no good === What is the most professional way to break it to a developer that their not very good. I haven't been a developer for as some of the others out there. But I have already had to deal with some really crazy people. What is the best way(s) to stay professional and critic a developer who really is horrible at his/her job, keeping in mind its a small world and you might HAVE to work with them again.
2
11,421,121
07/10/2012 20:08:40
1,510,578
07/08/2012 21:12:00
20
0
PHP: require versus include: practical considerations?
I've read that one of the differences between include and require is that while include only includes the included file if the include statement is encountered, require includes the file into the file hosting the require statement even when the require code is not reached by the execution flow. How can this have any implications. After all, if I have a file which says: <?php echo __LINE__; ?> the output will always be 3, instead of printing the line inside at the position inside the file which includes such include file. Thanks for your insights and comments, John Goche
php
include
require
null
null
null
open
PHP: require versus include: practical considerations? === I've read that one of the differences between include and require is that while include only includes the included file if the include statement is encountered, require includes the file into the file hosting the require statement even when the require code is not reached by the execution flow. How can this have any implications. After all, if I have a file which says: <?php echo __LINE__; ?> the output will always be 3, instead of printing the line inside at the position inside the file which includes such include file. Thanks for your insights and comments, John Goche
0
2,470,784
03/18/2010 14:59:23
276,161
02/18/2010 14:46:53
21
0
convert string of millisecond into datetime in python
I am a newbie in Python. I want to substract interval time from my log file, but the problem is I cannot convert millisecond string of log file into datetime format. For example, I have 15:55:05.12345 and I want to remove 5.12345 seconds from this string, and shwow result of 15.55.00.00000 in Python. How can I do that? Currently, I am using python 2.5. Thank you in advance.
python
milliseconds
datetime
null
null
null
open
convert string of millisecond into datetime in python === I am a newbie in Python. I want to substract interval time from my log file, but the problem is I cannot convert millisecond string of log file into datetime format. For example, I have 15:55:05.12345 and I want to remove 5.12345 seconds from this string, and shwow result of 15.55.00.00000 in Python. How can I do that? Currently, I am using python 2.5. Thank you in advance.
0
3,236,125
07/13/2010 10:14:41
249,991
01/13/2010 16:23:24
421
26
what is easiest way to save mms in pc?
i want to save received mms in my pc through data cable or bluetooth automatically. any one guide me which phone supports functionality like this or is there any specific software available to achieve this? any help would be appreciated.
iphone
android
windows-mobile
blackberry
symbian
07/13/2010 12:31:17
off topic
what is easiest way to save mms in pc? === i want to save received mms in my pc through data cable or bluetooth automatically. any one guide me which phone supports functionality like this or is there any specific software available to achieve this? any help would be appreciated.
2
11,731,665
07/31/2012 00:48:00
1,513,613
07/10/2012 03:43:55
3
0
How to implement the recurring events in symfony2 php
I have the Account class where i have to put monthly interest from the day of opening accounts. How can i implement that thing without cron jobs
php
events
symfony-2.0
recurrence
null
07/31/2012 15:19:28
not a real question
How to implement the recurring events in symfony2 php === I have the Account class where i have to put monthly interest from the day of opening accounts. How can i implement that thing without cron jobs
1
10,755,811
05/25/2012 14:04:26
1,417,535
05/25/2012 13:50:34
1
0
Problems Using C++ OpenCascade
there. I am pretty new on Linux and C++ Programming. I am trying to use OpenCascade, but have some problems to understand how to use it on my program. 1. I installed OpenCascade on Windows (http://www.opencascade.org/getocc/download/loadocc/) 2. Runned Draw Test Harness application 3. Red The first application tutorial (http://www.opencascade.org/org/gettingstarted/appli/) So, I think everytinhg is set up, right? How can I compile a simple application, to show a spline, for example? In fact, wish to create surfaces (geometry), save in .IGES file format and create the triangulated surface mesh (I can use Gmsh to do create this mesh, if a I have the .IGES file geometry). All this may be done on Linux, but the main problem now is to understand how to create a simple application first, to create a simple surface and save as .IGES file format. Please, help me to finish this task, I am really confused to do this! Thanks.
c++
geometry
mesh
opencascade
null
null
open
Problems Using C++ OpenCascade === there. I am pretty new on Linux and C++ Programming. I am trying to use OpenCascade, but have some problems to understand how to use it on my program. 1. I installed OpenCascade on Windows (http://www.opencascade.org/getocc/download/loadocc/) 2. Runned Draw Test Harness application 3. Red The first application tutorial (http://www.opencascade.org/org/gettingstarted/appli/) So, I think everytinhg is set up, right? How can I compile a simple application, to show a spline, for example? In fact, wish to create surfaces (geometry), save in .IGES file format and create the triangulated surface mesh (I can use Gmsh to do create this mesh, if a I have the .IGES file geometry). All this may be done on Linux, but the main problem now is to understand how to create a simple application first, to create a simple surface and save as .IGES file format. Please, help me to finish this task, I am really confused to do this! Thanks.
0
9,151,423
02/05/2012 17:40:45
971,933
09/29/2011 20:24:01
179
0
errors in php class
I built the following php class file, it seems not working at all, I am not sure what is my mistake, so if anybody could point me out, any help will be greatly appreciated! <?php class Arrayfromcsv { public $newrow = array(); public $i=0; public $c=0; public function readCsv($file) { if(($handle = fopen($file, "r")) != FALSE) //open the csv file { while (($data = fgetcsv($handle, 1000, ",")) != FALSE) //loop through each line from csv file and store each line elements into array { $num = count($data); //get the size of each line array for ($this->c=0; $this->c < $num; $this->c++) { if(substr($data[$c], -11, 3) == "PAY") //check if any line has element with substring 'PAY' { $this->newrow[$this->i][0] = $data[$c]; //add the first 2d column data which is the payment reference $this->newrow[$this->i][1] = $data[$c+8]; // add the sacond 2d column data which is the currency type $this->newrow[$this->i][2] = number_format($data[$c+7], 2, '.', ','); //add the third 2d column data which is the debit value converted to British number format $this->i++; //increase the row index } } } fclose($handle); //close file pointer } return this->newrow; } } ?>
php
null
null
null
null
02/05/2012 17:55:05
off topic
errors in php class === I built the following php class file, it seems not working at all, I am not sure what is my mistake, so if anybody could point me out, any help will be greatly appreciated! <?php class Arrayfromcsv { public $newrow = array(); public $i=0; public $c=0; public function readCsv($file) { if(($handle = fopen($file, "r")) != FALSE) //open the csv file { while (($data = fgetcsv($handle, 1000, ",")) != FALSE) //loop through each line from csv file and store each line elements into array { $num = count($data); //get the size of each line array for ($this->c=0; $this->c < $num; $this->c++) { if(substr($data[$c], -11, 3) == "PAY") //check if any line has element with substring 'PAY' { $this->newrow[$this->i][0] = $data[$c]; //add the first 2d column data which is the payment reference $this->newrow[$this->i][1] = $data[$c+8]; // add the sacond 2d column data which is the currency type $this->newrow[$this->i][2] = number_format($data[$c+7], 2, '.', ','); //add the third 2d column data which is the debit value converted to British number format $this->i++; //increase the row index } } } fclose($handle); //close file pointer } return this->newrow; } } ?>
2
10,472,630
05/06/2012 17:26:12
1,319,005
04/07/2012 11:47:20
8
0
which one is best for career asp.net web forms or asp.net mvc
I have one year experience in ASP.NET with C# and now i got two jobs one is in asp.net web forms and another one is in asp.net mvc3 which one is the best and which will have more exposure and more opportunity in future. Please help me to choose the right job to lead my career
asp.net
null
null
null
null
05/06/2012 17:34:48
off topic
which one is best for career asp.net web forms or asp.net mvc === I have one year experience in ASP.NET with C# and now i got two jobs one is in asp.net web forms and another one is in asp.net mvc3 which one is the best and which will have more exposure and more opportunity in future. Please help me to choose the right job to lead my career
2
8,998,190
01/25/2012 05:19:18
1,155,131
01/18/2012 00:26:22
20
0
How would you go about solving this? Old-Fashion Student/Course/School Code. Here's my approach:
I'm just curious if my way of thinking is incorrect. Would my way of thinking work, or would I need pointers/references in my code? How would you approach this? I'm just rough-sketching at this point. Look at my comments for my concerns. Mainly curious as to if I should use pointers, and how to reference classes in my Student class. Shortened Example Problem: Make a program that lets you: 1.) Create/Delete a Student from School 2.) Create/Delete a Course from school 3.) Add/Remove a student from a Course 4.) Print a list of students in a course 5.) Print a list of courses a student is in. class Student { public: string name; int id; Student(){};//Default Construct Student(int idin,string namein) { id=idin; name=namein; } void PrintClasses() { //Umm... I can't create a Class Vector yet because Class is declared under this.. Hmm... Not sure on this part. } }; class Class { public: int id; string name; Student students_in_class; //Is this the right way to store students in the class? Class(){};//Default Constructor Class(int idin, string namein) { id=idin; name=namein; } void PrintStudents() { for (i=0;i<students_in_class.size();i++) { cout<<students_in_class.id<<'\n'; } } }; class School { public: Vector<Student> studentlist; Vector<Class> classlist; //This is where you do everything. void StudentAdd(int id,string name) { //Adds a student to the school Student mystudent=Student(id,name); studentlist.push_back(mystudent); } void StudentAdd2Course(int student_id,int course_id) { for (i=0;i<classlist.size();i++) { if(classlist[i].id==course_id) { //Correct Class ID Found. Now find student Id for (int j=0;j<studentlist.size();j++) if(studentlist[j].id==student_id) classlist[i].students_in_class.push_back(studentlist[j]);//Push Student in class list } } } void StudentRemoveFromCourse(int student_id,int course_id) { for (i=0;i<classlist.size();i++) { if(classlist[i].id==course_id) { //Correct Class ID Found. Now find student Id for (int j=0;j<studentlist.size();j++) if(studentlist[j].id==student_id) classlist[i].students_in_class.erase(studentlist[j]);//Push Student in class list } } } //Other functions like create class, delete class, etc };
c++
class
structure
implementation
null
null
open
How would you go about solving this? Old-Fashion Student/Course/School Code. Here's my approach: === I'm just curious if my way of thinking is incorrect. Would my way of thinking work, or would I need pointers/references in my code? How would you approach this? I'm just rough-sketching at this point. Look at my comments for my concerns. Mainly curious as to if I should use pointers, and how to reference classes in my Student class. Shortened Example Problem: Make a program that lets you: 1.) Create/Delete a Student from School 2.) Create/Delete a Course from school 3.) Add/Remove a student from a Course 4.) Print a list of students in a course 5.) Print a list of courses a student is in. class Student { public: string name; int id; Student(){};//Default Construct Student(int idin,string namein) { id=idin; name=namein; } void PrintClasses() { //Umm... I can't create a Class Vector yet because Class is declared under this.. Hmm... Not sure on this part. } }; class Class { public: int id; string name; Student students_in_class; //Is this the right way to store students in the class? Class(){};//Default Constructor Class(int idin, string namein) { id=idin; name=namein; } void PrintStudents() { for (i=0;i<students_in_class.size();i++) { cout<<students_in_class.id<<'\n'; } } }; class School { public: Vector<Student> studentlist; Vector<Class> classlist; //This is where you do everything. void StudentAdd(int id,string name) { //Adds a student to the school Student mystudent=Student(id,name); studentlist.push_back(mystudent); } void StudentAdd2Course(int student_id,int course_id) { for (i=0;i<classlist.size();i++) { if(classlist[i].id==course_id) { //Correct Class ID Found. Now find student Id for (int j=0;j<studentlist.size();j++) if(studentlist[j].id==student_id) classlist[i].students_in_class.push_back(studentlist[j]);//Push Student in class list } } } void StudentRemoveFromCourse(int student_id,int course_id) { for (i=0;i<classlist.size();i++) { if(classlist[i].id==course_id) { //Correct Class ID Found. Now find student Id for (int j=0;j<studentlist.size();j++) if(studentlist[j].id==student_id) classlist[i].students_in_class.erase(studentlist[j]);//Push Student in class list } } } //Other functions like create class, delete class, etc };
0
11,509,224
07/16/2012 17:14:22
640,558
03/02/2011 04:50:28
2,208
50
What css do I need to allow my auto complete to click anywhere in a row?
I'm playing around with jquery ui and was trying out the autocomplete from the [site][1]. I have got it working and have been able to style it a bit but I am noticing a weird difference between my version and the sites. Say I return ['cat','cate'] to jquery, I can only get either item in the input box if I click on the text of the word itself. On the website or on facebook and other sites you can click on the entire highlighted area. Another example of this is if you go to the main page of SO and under favourite tags search for `html`, you can click on the text itself or you can click on the whitespace and it'll still put html in your search box. To test it, I added the following styling: .ui-autocomplete { list-style: none; width: 100px; height:auto; margin-top: 0px; padding: 0px; margin-left: 0px; } .ui-menu-item:hover { background-color: #006699; cursor: pointer; } When I hoover on the entire row, the mouse pointer changes so it obviously knows its on a row but I cannot click on it unless I click on the text. I'm really new to web development and I'm not sure how to classify it so sorry if this is not a css issue. [1]: http://jqueryui.com/demos/autocomplete/
css
jquery-ui
null
null
null
07/16/2012 17:36:44
too localized
What css do I need to allow my auto complete to click anywhere in a row? === I'm playing around with jquery ui and was trying out the autocomplete from the [site][1]. I have got it working and have been able to style it a bit but I am noticing a weird difference between my version and the sites. Say I return ['cat','cate'] to jquery, I can only get either item in the input box if I click on the text of the word itself. On the website or on facebook and other sites you can click on the entire highlighted area. Another example of this is if you go to the main page of SO and under favourite tags search for `html`, you can click on the text itself or you can click on the whitespace and it'll still put html in your search box. To test it, I added the following styling: .ui-autocomplete { list-style: none; width: 100px; height:auto; margin-top: 0px; padding: 0px; margin-left: 0px; } .ui-menu-item:hover { background-color: #006699; cursor: pointer; } When I hoover on the entire row, the mouse pointer changes so it obviously knows its on a row but I cannot click on it unless I click on the text. I'm really new to web development and I'm not sure how to classify it so sorry if this is not a css issue. [1]: http://jqueryui.com/demos/autocomplete/
3
10,972,478
06/10/2012 21:23:39
754,322
05/15/2011 08:44:08
32
0
Using PBKDF2 for password storing
I've been working on a way to store passwords (or hashes or them) into the database and I've done some research what would be the best solutions and this is what I've come up: The class what I use uses a "salt" key ( 32bit - 64 bit - 128 bit are accepted keys ). Once initiated I pass the following information: - username - password - email address This forms the working salt key which is joined by username:password:email this is all passed to hash_hmac() function ( hash_hmac('SHA512', 'username:password:email', $initialSalt ) ). Once I've got this going, I pass to a PBKDF2 function that does 5000 iterations and returns a 128bit key. And for the end, this 128bit they that I've got from the PBKDF2 is passed to a another function for additional 5000 iterations of SHA512 . This returns a 128bit key at the end, which is stored in the database. When the user wants to login, I check his username, password and email against the hash he's gotten generated. If the password or email address for the account ( even the username ) change so does the key that is stored in the database. Now I ask you - is this good practice ? The way to use this method, will it suffice ? Or do you have any suggestions ? I do apologize if this has been possibly unclear, but with all the articles, suggestions read I still feel that there might be missing ( or overdone ). And the code for the class is visible here: https://github.com/abikobutch3r/marpass/blob/master/marPass.php I thank you all for your time and input, it is much appreciated!
php
security
encryption
null
null
06/12/2012 03:38:37
off topic
Using PBKDF2 for password storing === I've been working on a way to store passwords (or hashes or them) into the database and I've done some research what would be the best solutions and this is what I've come up: The class what I use uses a "salt" key ( 32bit - 64 bit - 128 bit are accepted keys ). Once initiated I pass the following information: - username - password - email address This forms the working salt key which is joined by username:password:email this is all passed to hash_hmac() function ( hash_hmac('SHA512', 'username:password:email', $initialSalt ) ). Once I've got this going, I pass to a PBKDF2 function that does 5000 iterations and returns a 128bit key. And for the end, this 128bit they that I've got from the PBKDF2 is passed to a another function for additional 5000 iterations of SHA512 . This returns a 128bit key at the end, which is stored in the database. When the user wants to login, I check his username, password and email against the hash he's gotten generated. If the password or email address for the account ( even the username ) change so does the key that is stored in the database. Now I ask you - is this good practice ? The way to use this method, will it suffice ? Or do you have any suggestions ? I do apologize if this has been possibly unclear, but with all the articles, suggestions read I still feel that there might be missing ( or overdone ). And the code for the class is visible here: https://github.com/abikobutch3r/marpass/blob/master/marPass.php I thank you all for your time and input, it is much appreciated!
2
481,282
01/26/2009 20:49:59
58,897
01/26/2009 00:16:33
1
1
Perl regex to match strings
I need a Perl regular expression to match a string. I'm assuming only double-quoted strings, that a \" is a literal quote character and NOT the end of the string, and that a \\ is a literal backslash character and should not escape a quote character. If it's not clear, some examples: "\"" # string is 1 character long, contains dobule quote "\\" # string is 1 character long, contains backslash "\\\"" # string is 2 characters long, contains backslash and double quote "\\\\" # string is 2 characters long, contains two backslashes I need a regular expression that can recognize all 4 of these possibilities, and all other simple variations on those possibilities, as valid strings. What I have now is: /".*[^\\]"/ But that's not right - it won't match any of those except the first one. Can anyone give me a push in the right direction on how to handle this?
perl
regex
escaping
null
null
null
open
Perl regex to match strings === I need a Perl regular expression to match a string. I'm assuming only double-quoted strings, that a \" is a literal quote character and NOT the end of the string, and that a \\ is a literal backslash character and should not escape a quote character. If it's not clear, some examples: "\"" # string is 1 character long, contains dobule quote "\\" # string is 1 character long, contains backslash "\\\"" # string is 2 characters long, contains backslash and double quote "\\\\" # string is 2 characters long, contains two backslashes I need a regular expression that can recognize all 4 of these possibilities, and all other simple variations on those possibilities, as valid strings. What I have now is: /".*[^\\]"/ But that's not right - it won't match any of those except the first one. Can anyone give me a push in the right direction on how to handle this?
0
9,957,322
03/31/2012 15:45:59
271,376
02/11/2010 21:03:16
8,050
285
Which constructor is invoked here?
In this code fragment, which constructor is actually called? Vector v = getVector(); Vector has copy constructor, default constructor and assignment operator: class Vecotr{ public: ... Vector(); Vector(const Vector& other); Vector& operator=(const Vector& other); }; getVector returns by value. Vector getVector(); Code usese C++03 standard. Code fragment looks like it is supposed to call default constructor and then assignment operator, but I suspect that this declaration is another form of using copy constructor. Which is correct?
c++
c++03
null
null
null
null
open
Which constructor is invoked here? === In this code fragment, which constructor is actually called? Vector v = getVector(); Vector has copy constructor, default constructor and assignment operator: class Vecotr{ public: ... Vector(); Vector(const Vector& other); Vector& operator=(const Vector& other); }; getVector returns by value. Vector getVector(); Code usese C++03 standard. Code fragment looks like it is supposed to call default constructor and then assignment operator, but I suspect that this declaration is another form of using copy constructor. Which is correct?
0
790,447
04/26/2009 07:50:08
14,752
09/17/2008 02:35:39
405
3
problem with dropdown with php and ajax
For some time i am battling to solve this problem but iam not coming to any conclusion so thought to seek some help here. The problem is that i am getting a blank dropdown instead i should get list of cities populated from the database. Database connection is fine but iam not getting anything in my dropdown. This is what iam doing: <?php require 'includes/connect.php'; - database connection $country=$_REQUEST['country']; - get from form (index.php) $q = "SELECT city FROM city where countryid=".$country; $result = $mysqli->query($q) or die(mysqli_error($mysqli)); if ($result) { ?> <select name="city"> <option>Select City</option> $id = 0; <?php while ($row = $result->fetch_object()) { $src = $row->city; $id = $id + 1; ?> <option value= <?php $id ?> > <?php $src ?></option> <?php } ?> </select> <?php } ?> ajax script is this: <script> function getXMLHTTP() { //fuction to return the xml http object var xmlhttp=false; try{mlhttp=new XMLHttpRequest();} catch(e) { try{ xmlhttp= new ActiveXObject("Microsoft.XMLHTTP"); } catch(e){ try{ xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); } catch(e1){ xmlhttp=false; } } } return xmlhttp; } function getCity(strURL) { var req = getXMLHTTP(); if (req) { req.onreadystatechange = function() { if (req.readyState == 4) { if (req.status == 200) { document.getElementById('citydiv').innerHTML=req.responseText; } else { alert("There was a problem while using XMLHTTP:\n" + req.statusText); } } } req.open("GET", strURL, true); req.send(null); } } </script> This is my form code: <form method="post" action="" name="form1"> <table width="60%" border="0" cellspacing="0" cellpadding="0"> <tr> <td width="150">Country</td> <td width="150"><select name="country" onChange="getCity('findcity.php?country='+this.value)"> <option value="">Select Country</option> <option value="1">New Zealand</option> <option value="2">Canada</option> </select></td> </tr> <tr style=""> <td>City</td> <td ><div id="citydiv"><select name="city"> <option>Select City</option> </select></div></td> </tr> </table> </form>
php
ajax
null
null
null
null
open
problem with dropdown with php and ajax === For some time i am battling to solve this problem but iam not coming to any conclusion so thought to seek some help here. The problem is that i am getting a blank dropdown instead i should get list of cities populated from the database. Database connection is fine but iam not getting anything in my dropdown. This is what iam doing: <?php require 'includes/connect.php'; - database connection $country=$_REQUEST['country']; - get from form (index.php) $q = "SELECT city FROM city where countryid=".$country; $result = $mysqli->query($q) or die(mysqli_error($mysqli)); if ($result) { ?> <select name="city"> <option>Select City</option> $id = 0; <?php while ($row = $result->fetch_object()) { $src = $row->city; $id = $id + 1; ?> <option value= <?php $id ?> > <?php $src ?></option> <?php } ?> </select> <?php } ?> ajax script is this: <script> function getXMLHTTP() { //fuction to return the xml http object var xmlhttp=false; try{mlhttp=new XMLHttpRequest();} catch(e) { try{ xmlhttp= new ActiveXObject("Microsoft.XMLHTTP"); } catch(e){ try{ xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); } catch(e1){ xmlhttp=false; } } } return xmlhttp; } function getCity(strURL) { var req = getXMLHTTP(); if (req) { req.onreadystatechange = function() { if (req.readyState == 4) { if (req.status == 200) { document.getElementById('citydiv').innerHTML=req.responseText; } else { alert("There was a problem while using XMLHTTP:\n" + req.statusText); } } } req.open("GET", strURL, true); req.send(null); } } </script> This is my form code: <form method="post" action="" name="form1"> <table width="60%" border="0" cellspacing="0" cellpadding="0"> <tr> <td width="150">Country</td> <td width="150"><select name="country" onChange="getCity('findcity.php?country='+this.value)"> <option value="">Select Country</option> <option value="1">New Zealand</option> <option value="2">Canada</option> </select></td> </tr> <tr style=""> <td>City</td> <td ><div id="citydiv"><select name="city"> <option>Select City</option> </select></div></td> </tr> </table> </form>
0
7,065,198
08/15/2011 12:59:08
494,143
11/01/2010 23:01:19
1,389
55
Installing Git on a Linux VM (RHEL)
We need to set up a Git server in our team. I have decided to first go with a VM, and expand in the future if needed. I've gathered Linux would be the easiest setup. Problem is, i have very limited experience with Linux, some questions that i'm trying to answer are: 1. What is the actual procedure for installing the Git package? is it a simple matter of RPM installation ? 2. Following the installation, i'd need to map the Git repo to some net share. how is this done? i believe that i need to configure xinetd.d, looking for exact steps. 3. How is authentication is set up for various users to access this machine? 4. Which version of Linux makes any difference? we have the RHEL 5 64 bit here. 5. Anything else i'm currently missing?
linux
git
null
null
null
08/15/2011 15:01:51
off topic
Installing Git on a Linux VM (RHEL) === We need to set up a Git server in our team. I have decided to first go with a VM, and expand in the future if needed. I've gathered Linux would be the easiest setup. Problem is, i have very limited experience with Linux, some questions that i'm trying to answer are: 1. What is the actual procedure for installing the Git package? is it a simple matter of RPM installation ? 2. Following the installation, i'd need to map the Git repo to some net share. how is this done? i believe that i need to configure xinetd.d, looking for exact steps. 3. How is authentication is set up for various users to access this machine? 4. Which version of Linux makes any difference? we have the RHEL 5 64 bit here. 5. Anything else i'm currently missing?
2
11,129,911
06/21/2012 00:11:36
1,351,629
04/23/2012 14:59:24
33
2
What is the faster: to create a new array or iterate through existing?
I have an array, for example (in Java) > int[] a = new int[N]; I have worked with it and now want to have array with zeros. What will take less time: to create a new Array(it will be initialized will zeros) or iterate through existing one and fill it with zeros? I suppose whatever answer is, it will be the same in C++ ?
java
c++
arrays
initialization
null
06/21/2012 00:53:31
not constructive
What is the faster: to create a new array or iterate through existing? === I have an array, for example (in Java) > int[] a = new int[N]; I have worked with it and now want to have array with zeros. What will take less time: to create a new Array(it will be initialized will zeros) or iterate through existing one and fill it with zeros? I suppose whatever answer is, it will be the same in C++ ?
4
2,787,485
05/07/2010 09:23:24
184,814
10/06/2009 08:04:07
502
21
Recursive function for copy of multilevel folder is not working.
> Recursive function for copy of > multilevel folder is not working. I have a code to copy all the mulitilevel folder to new folder. But in between I feel there is problem of proper path recognition, see the code below.. <?php $source = '/var/www/html/pranav_test'; $destination = '/var/www/html/parth'; copy_recursive_dirs($source, $destination); function copy_recursive_dirs($dirsource, $dirdest) { // recursive function to copy // all subdirectories and contents: if(is_dir($dirsource)) { $dir_handle=opendir($dirsource); } if(!is_dir($dirdest)) { mkdir($dirdest, 0777); } while($file=readdir($dir_handle)) {/*echo "<pre>"; print_r($file);*/ if($file!="." && $file!="..") { if(!is_dir($dirsource.DIRECTORY_SEPARATOR.$file)) { copy ($dirsource.DIRECTORY_SEPARATOR.$file, $dirdest.DIRECTORY_SEPARATOR.$dirsource.DIRECTORY_SEPARATOR.$file); } else{ copy_recursive_dirs($dirsource.DIRECTORY_SEPARATOR.$file, $dirdest); } } } closedir($dir_handle); return true; } ?> from the above code the if loop has a copy function as per requirement, but the path applied for destination here is not proper, I have tried with basename function as well.. but it didnt got the expected result.. below is the if loop i am talking about with comment describing the output... if(!is_dir($dirsource.DIRECTORY_SEPARATOR.$file)) { $basefile = basename($dirsource.DIRECTORY_SEPARATOR.$file);//it gives the file name echo "Pranav<br>".$dirdest.DIRECTORY_SEPARATOR.$dirsource.DIRECTORY_SEPARATOR.$file;//it outputs for example "/var/www/html/parth//var/www/html/pranav_test/media/system/js/caption.js" which is not correct.. copy ($dirsource.DIRECTORY_SEPARATOR.$file, $dirdest.DIRECTORY_SEPARATOR.$dirsource.DIRECTORY_SEPARATOR.$file); } as shown above the i cannot get the files and folders copied to expected path.. please guide me to place proper path in the function....
php
copy
filepath
null
null
null
open
Recursive function for copy of multilevel folder is not working. === > Recursive function for copy of > multilevel folder is not working. I have a code to copy all the mulitilevel folder to new folder. But in between I feel there is problem of proper path recognition, see the code below.. <?php $source = '/var/www/html/pranav_test'; $destination = '/var/www/html/parth'; copy_recursive_dirs($source, $destination); function copy_recursive_dirs($dirsource, $dirdest) { // recursive function to copy // all subdirectories and contents: if(is_dir($dirsource)) { $dir_handle=opendir($dirsource); } if(!is_dir($dirdest)) { mkdir($dirdest, 0777); } while($file=readdir($dir_handle)) {/*echo "<pre>"; print_r($file);*/ if($file!="." && $file!="..") { if(!is_dir($dirsource.DIRECTORY_SEPARATOR.$file)) { copy ($dirsource.DIRECTORY_SEPARATOR.$file, $dirdest.DIRECTORY_SEPARATOR.$dirsource.DIRECTORY_SEPARATOR.$file); } else{ copy_recursive_dirs($dirsource.DIRECTORY_SEPARATOR.$file, $dirdest); } } } closedir($dir_handle); return true; } ?> from the above code the if loop has a copy function as per requirement, but the path applied for destination here is not proper, I have tried with basename function as well.. but it didnt got the expected result.. below is the if loop i am talking about with comment describing the output... if(!is_dir($dirsource.DIRECTORY_SEPARATOR.$file)) { $basefile = basename($dirsource.DIRECTORY_SEPARATOR.$file);//it gives the file name echo "Pranav<br>".$dirdest.DIRECTORY_SEPARATOR.$dirsource.DIRECTORY_SEPARATOR.$file;//it outputs for example "/var/www/html/parth//var/www/html/pranav_test/media/system/js/caption.js" which is not correct.. copy ($dirsource.DIRECTORY_SEPARATOR.$file, $dirdest.DIRECTORY_SEPARATOR.$dirsource.DIRECTORY_SEPARATOR.$file); } as shown above the i cannot get the files and folders copied to expected path.. please guide me to place proper path in the function....
0
8,763,498
01/06/2012 19:41:21
790,869
06/09/2011 12:07:52
1
0
Why the difference in behavior of YAML parsers (syck and psych)?
Look at this case: ruby 1.9.2p0 (2010-08-18 revision 29036) [i686-linux] irb(main):006:0> YAML::ENGINE.yamler = "psych" => "psych" irb(main):007:0> '8902-20-13'.to_yaml ArgumentError: invalid date from /usr/local/lib/ruby/1.9.1/date.rb:1022:in `new_by_frags' from /usr/local/lib/ruby/1.9.1/date.rb:1046:in `strptime' from /usr/local/lib/ruby/1.9.1/psych/scalar_scanner.rb:45:in `tokenize' from /usr/local/lib/ruby/1.9.1/psych/visitors/yaml_tree.rb:191:in `visit_String' from /usr/local/lib/ruby/1.9.1/psych/visitors/yaml_tree.rb:63:in `accept' from /usr/local/lib/ruby/1.9.1/psych/visitors/yaml_tree.rb:36:in `<<' from /usr/local/lib/ruby/1.9.1/psych.rb:165:in `dump' from /usr/local/lib/ruby/1.9.1/psych/core_ext.rb:13:in `psych_to_yaml' from /usr/local/lib/ruby/1.9.1/syck/rubytypes.rb:169:in ` irb(main):008:0> YAML::ENGINE.yamler = "syck" => "syck" irb(main):009:0> '8902-20-13'.to_yaml => "--- \"8902-20-13\"\n" When I'm using the psych parser and I need to format a string that vaguely resembles a date, it throws an exception, because he thinks this is a date string. Using syck this problem does not occur. Anyone have any idea?
ruby
yaml
syck
psych
null
null
open
Why the difference in behavior of YAML parsers (syck and psych)? === Look at this case: ruby 1.9.2p0 (2010-08-18 revision 29036) [i686-linux] irb(main):006:0> YAML::ENGINE.yamler = "psych" => "psych" irb(main):007:0> '8902-20-13'.to_yaml ArgumentError: invalid date from /usr/local/lib/ruby/1.9.1/date.rb:1022:in `new_by_frags' from /usr/local/lib/ruby/1.9.1/date.rb:1046:in `strptime' from /usr/local/lib/ruby/1.9.1/psych/scalar_scanner.rb:45:in `tokenize' from /usr/local/lib/ruby/1.9.1/psych/visitors/yaml_tree.rb:191:in `visit_String' from /usr/local/lib/ruby/1.9.1/psych/visitors/yaml_tree.rb:63:in `accept' from /usr/local/lib/ruby/1.9.1/psych/visitors/yaml_tree.rb:36:in `<<' from /usr/local/lib/ruby/1.9.1/psych.rb:165:in `dump' from /usr/local/lib/ruby/1.9.1/psych/core_ext.rb:13:in `psych_to_yaml' from /usr/local/lib/ruby/1.9.1/syck/rubytypes.rb:169:in ` irb(main):008:0> YAML::ENGINE.yamler = "syck" => "syck" irb(main):009:0> '8902-20-13'.to_yaml => "--- \"8902-20-13\"\n" When I'm using the psych parser and I need to format a string that vaguely resembles a date, it throws an exception, because he thinks this is a date string. Using syck this problem does not occur. Anyone have any idea?
0
3,301,579
07/21/2010 16:30:17
398,229
07/21/2010 16:30:17
1
0
best scripting language to develop rational clearcase plugin to extract some functionalities
I just want to know about clearcase. Basically i want to write some application which will extract some files from clearcase vobs. Right now i am not getting any clue that which scripting language like python or perl i should use. basically i am looking for perl scripting for that. I also want to know is there any proper document or book available for clearcase exposed api list and documentation. Thanks in advance, Abhijit
python
clearcase
null
null
null
null
open
best scripting language to develop rational clearcase plugin to extract some functionalities === I just want to know about clearcase. Basically i want to write some application which will extract some files from clearcase vobs. Right now i am not getting any clue that which scripting language like python or perl i should use. basically i am looking for perl scripting for that. I also want to know is there any proper document or book available for clearcase exposed api list and documentation. Thanks in advance, Abhijit
0
5,977,113
05/12/2011 11:13:27
750,440
05/12/2011 11:13:27
1
0
Java : Summation of `multiples of 5` in a group to a given target
I'm struggling to get the below problem working with no approach in right direction. Write a `java function ` such that given an array of ints, is it possible to choose a group of some of the ints, such that the group sums to the given target with these additional constraints: all multiples of 5 in the array must be included in the group. If the value immediately following a multiple of 5 is 1, it must not be chosen. groupSum5(0, {2, 5, 10, 4}, 19) → true groupSum5(0, {2, 5, 10, 4}, 17) → true groupSum5(0, {2, 5, 10, 4}, 12) → false The function siganture is `public boolean groupSum5(int start, int[] nums, int target) ` I'm confused on how to proceed with the problem, Suggestions provided will be appreciated. Other Clarifications related to above problem are: 1>Test scenario --> 5+10 =15 which is not equal to 19,how come 19 is the basis for the first test case.Could you explain how to solve this problem in detail. 2>Test scenario --> 5+10 =15 which is not equal to 17,how come 17 is the basis for the second test case.Could you explain how to solve this problem in detail.
java
algorithm
null
null
null
05/12/2011 21:44:41
not a real question
Java : Summation of `multiples of 5` in a group to a given target === I'm struggling to get the below problem working with no approach in right direction. Write a `java function ` such that given an array of ints, is it possible to choose a group of some of the ints, such that the group sums to the given target with these additional constraints: all multiples of 5 in the array must be included in the group. If the value immediately following a multiple of 5 is 1, it must not be chosen. groupSum5(0, {2, 5, 10, 4}, 19) → true groupSum5(0, {2, 5, 10, 4}, 17) → true groupSum5(0, {2, 5, 10, 4}, 12) → false The function siganture is `public boolean groupSum5(int start, int[] nums, int target) ` I'm confused on how to proceed with the problem, Suggestions provided will be appreciated. Other Clarifications related to above problem are: 1>Test scenario --> 5+10 =15 which is not equal to 19,how come 19 is the basis for the first test case.Could you explain how to solve this problem in detail. 2>Test scenario --> 5+10 =15 which is not equal to 17,how come 17 is the basis for the second test case.Could you explain how to solve this problem in detail.
1
7,750,983
10/13/2011 07:49:50
589,089
01/25/2011 14:00:12
571
24
Calculating the size of an email in .NET
Say I have an email class that has the following properties: public string From { get; set; } public string To { get; set; } public string Subject { get; set; } public string Body { get; set; } public Dictionary<string, byte[]> Attachments { get; set; } I need to calculate the size of the email and if it is less than 10MB email it otherwise send the content as a fax (to prevent it being bounced from its destination). I can calculate the size of attachments relatively easily. Is there an accurate way to calculate the entire email size? I'm guessing I'll need to add the size of the strings as well as any header information that will be appended?
c#
asp.net
email
null
null
null
open
Calculating the size of an email in .NET === Say I have an email class that has the following properties: public string From { get; set; } public string To { get; set; } public string Subject { get; set; } public string Body { get; set; } public Dictionary<string, byte[]> Attachments { get; set; } I need to calculate the size of the email and if it is less than 10MB email it otherwise send the content as a fax (to prevent it being bounced from its destination). I can calculate the size of attachments relatively easily. Is there an accurate way to calculate the entire email size? I'm guessing I'll need to add the size of the strings as well as any header information that will be appended?
0
960,758
06/06/2009 23:03:19
81,359
03/23/2009 11:11:54
272
24
Animated transitions in WPF
I can't figure out what I'm missing here. Here's the problem:<br /> Consider a (Control|Data)Template with a Trigger that switches visibility of some inner UI elements. E.g. show a TextBlock when IsReadOnly==true and show a TextBox when IsReadOnly==false. Everything is perfect if you do this without animation - one or two setters would do the job. But what if you want a fancy animation? Then you would specify which animations to start in EnterActions and ExitActions. But the problem is what exactly the animations should do? Modifying width/height seems really ugly, because fixed sizes in WPF are almost always a wrong way to go and also it's absolutely unflexible. So far, the best I've come up with is modifying MaxHeight/MaxWidth to some extent, this gives just a little more flexibility but still seems brutal. **How do you tell WPF to animate Width/Height of an element from 0 to "as much as needed"?**
wpf
animation
null
null
null
null
open
Animated transitions in WPF === I can't figure out what I'm missing here. Here's the problem:<br /> Consider a (Control|Data)Template with a Trigger that switches visibility of some inner UI elements. E.g. show a TextBlock when IsReadOnly==true and show a TextBox when IsReadOnly==false. Everything is perfect if you do this without animation - one or two setters would do the job. But what if you want a fancy animation? Then you would specify which animations to start in EnterActions and ExitActions. But the problem is what exactly the animations should do? Modifying width/height seems really ugly, because fixed sizes in WPF are almost always a wrong way to go and also it's absolutely unflexible. So far, the best I've come up with is modifying MaxHeight/MaxWidth to some extent, this gives just a little more flexibility but still seems brutal. **How do you tell WPF to animate Width/Height of an element from 0 to "as much as needed"?**
0
1,049,350
06/26/2009 14:08:30
54,964
01/14/2009 11:38:17
1,049
55
Unable to make Less to indicate location in percentage
I have the following settings in .zshrc for Less # colors for Less export LESS_TERMCAP_mb=$'\E[01;31m' export LESS_TERMCAP_md=$'\E[01;31m' export LESS_TERMCAP_me=$'\E[0m' export LESS_TERMCAP_se=$'\E[0m' export LESS_TERMCAP_so=$'\E[01;44;33m' export LESS_TERMCAP_ue=$'\E[0m' export LESS_TERMCAP_us=$'\E[01;32m' I guess that the problem can be similarly solved in .zshrc when I read manuals in Less. **How can you make Less to indicate the location of cursor** at the horizontal bar at the bottom?
less
null
null
null
null
null
open
Unable to make Less to indicate location in percentage === I have the following settings in .zshrc for Less # colors for Less export LESS_TERMCAP_mb=$'\E[01;31m' export LESS_TERMCAP_md=$'\E[01;31m' export LESS_TERMCAP_me=$'\E[0m' export LESS_TERMCAP_se=$'\E[0m' export LESS_TERMCAP_so=$'\E[01;44;33m' export LESS_TERMCAP_ue=$'\E[0m' export LESS_TERMCAP_us=$'\E[01;32m' I guess that the problem can be similarly solved in .zshrc when I read manuals in Less. **How can you make Less to indicate the location of cursor** at the horizontal bar at the bottom?
0
4,916,753
02/06/2011 22:48:18
328,679
04/29/2010 09:00:18
22
0
How to get a Wikipedia entry's template type
I need to find out the template type of a Wikipedia page entry. Up to this point, I've relied on parsing the results from a query to Wikipedia, which works to a point. For instance, if I search for <a href="http://en.wikipedia.org/w/api.php?format=json&action=query&prop=revisions&rvprop=content&rvsection=0&&titles=Joel_Spolsky">Joel Spolsky</a>, I can regex match 'infobox' and find out that this page refers to <a href="http://en.wikipedia.org/wiki/Template:Infobox_person">Infobox Person</a>. But the trouble is, there is no consistent naming scheme for Wikipedia template types, and 'infobox' is often not used in the name of the template. For instance, if I search for the <a href="http://en.wikipedia.org/w/api.php?format=json&action=query&prop=revisions&rvprop=content&rvsection=0&&titles=pittsburgh_Steelers">Pittsburgh Steelers</a> I can't reliably find out a way to extract the <a href="http://en.wikipedia.org/wiki/Template:NFL_team">NFL team</a> template from the results. Is anyone aware of a way to query the template type of a Wikipedia page? Thanks :)
wikipedia
wikipedia-api
null
null
null
null
open
How to get a Wikipedia entry's template type === I need to find out the template type of a Wikipedia page entry. Up to this point, I've relied on parsing the results from a query to Wikipedia, which works to a point. For instance, if I search for <a href="http://en.wikipedia.org/w/api.php?format=json&action=query&prop=revisions&rvprop=content&rvsection=0&&titles=Joel_Spolsky">Joel Spolsky</a>, I can regex match 'infobox' and find out that this page refers to <a href="http://en.wikipedia.org/wiki/Template:Infobox_person">Infobox Person</a>. But the trouble is, there is no consistent naming scheme for Wikipedia template types, and 'infobox' is often not used in the name of the template. For instance, if I search for the <a href="http://en.wikipedia.org/w/api.php?format=json&action=query&prop=revisions&rvprop=content&rvsection=0&&titles=pittsburgh_Steelers">Pittsburgh Steelers</a> I can't reliably find out a way to extract the <a href="http://en.wikipedia.org/wiki/Template:NFL_team">NFL team</a> template from the results. Is anyone aware of a way to query the template type of a Wikipedia page? Thanks :)
0
4,210,370
11/17/2010 23:43:08
353,193
05/28/2010 19:10:43
134
2
How to play a background audio across multiple HTML pages.?
Is there a solution to have the background audio/music play across multiple page on a website, WITHOUT restarting on every page load. The website currently uses a frameset, but I'm looking for an alternative.
html
flash
audio
null
null
null
open
How to play a background audio across multiple HTML pages.? === Is there a solution to have the background audio/music play across multiple page on a website, WITHOUT restarting on every page load. The website currently uses a frameset, but I'm looking for an alternative.
0
4,894,591
02/04/2011 04:33:42
508,532
11/15/2010 17:04:47
1
0
Shipping not transferring to Paypal Express with Magento 1.4.2
I have a site in development that I cannot get the shipping to transfer with using Google Checkout or Paypal Express. I believe the error with Google Checkout is the fact it needs an HTTPS callback url and since I am just developing currently I do not have one. As for the Paypal Express setup, I have followed every possible help guide out there and I seem to be hitting a road block. Why is shipping not showing up on the paypal site? Here is a link to the development site. http://38.98.53.62/ Thanks for any and all suggestions.
magento
paypal
magento-1.4
shipping
null
null
open
Shipping not transferring to Paypal Express with Magento 1.4.2 === I have a site in development that I cannot get the shipping to transfer with using Google Checkout or Paypal Express. I believe the error with Google Checkout is the fact it needs an HTTPS callback url and since I am just developing currently I do not have one. As for the Paypal Express setup, I have followed every possible help guide out there and I seem to be hitting a road block. Why is shipping not showing up on the paypal site? Here is a link to the development site. http://38.98.53.62/ Thanks for any and all suggestions.
0
6,635,315
07/09/2011 14:21:01
836,776
07/09/2011 14:21:01
1
0
Clock iGoogle Gadgets
I am new to igoogle gadgets and this is my second gadget I am about to work on. I want to write a simple gadget of clock but I don't know how to proceed.I tried to search on net, however, no matter what I do I cannot seem to get any closer to the solution.I just want to know the basic concept to how to Proceed with this gadget and some help with coding as i lacks in JavaScript. Can anyone point me in the right direction?Thanks in advance.
javascript
google
clock
google-gadget
null
null
open
Clock iGoogle Gadgets === I am new to igoogle gadgets and this is my second gadget I am about to work on. I want to write a simple gadget of clock but I don't know how to proceed.I tried to search on net, however, no matter what I do I cannot seem to get any closer to the solution.I just want to know the basic concept to how to Proceed with this gadget and some help with coding as i lacks in JavaScript. Can anyone point me in the right direction?Thanks in advance.
0
5,683,578
04/16/2011 00:21:35
700,401
04/09/2011 23:04:22
1
0
python received data
if i want to write if the received data in string print Name : then the received data !! i'm receiving data from android from an open socket to my python !! so how to do this in code to check if the received data is string!!
python
null
null
null
null
07/16/2012 01:57:45
not a real question
python received data === if i want to write if the received data in string print Name : then the received data !! i'm receiving data from android from an open socket to my python !! so how to do this in code to check if the received data is string!!
1
8,626,325
12/24/2011 18:59:32
216,605
11/22/2009 20:25:56
1,686
4
Most efficient way to delete a file if it's below a certain size
What's the most efficient way to delete a file if it's less than 100k? file = '/path/to/file.mov'
python
null
null
null
null
12/24/2011 20:09:14
too localized
Most efficient way to delete a file if it's below a certain size === What's the most efficient way to delete a file if it's less than 100k? file = '/path/to/file.mov'
3
4,828,721
01/28/2011 13:26:17
15,664
09/17/2008 11:41:07
91
5
Using a Windows Account SID as a Security Token
I am creating some web services which I would like to secure using a custom (i.e. NOT WS-Secure, etc) method. Currently my plan is to have a method which takes active directory username & password (over HTTPS, of course) to authenticate the user. This method would then get the account SID for that user and encrypt it using a secure but reversible method and pass this back as a security token. After this the caller will pass the encrypted token as a parameter to each web method as a means of ensuring the caller is authenticated. The token can then be decrypted and turned back into an directory entry (and so confirm their authenticity) fairly trivially. This has the added bonus of allowing methods to absolutely identify the authenticated caller. However, using the SID from the account, which is normally internal only, has me a little concerned. Is this secure?
c#
web-services
security
active-directory
null
null
open
Using a Windows Account SID as a Security Token === I am creating some web services which I would like to secure using a custom (i.e. NOT WS-Secure, etc) method. Currently my plan is to have a method which takes active directory username & password (over HTTPS, of course) to authenticate the user. This method would then get the account SID for that user and encrypt it using a secure but reversible method and pass this back as a security token. After this the caller will pass the encrypted token as a parameter to each web method as a means of ensuring the caller is authenticated. The token can then be decrypted and turned back into an directory entry (and so confirm their authenticity) fairly trivially. This has the added bonus of allowing methods to absolutely identify the authenticated caller. However, using the SID from the account, which is normally internal only, has me a little concerned. Is this secure?
0
7,038,022
08/12/2011 09:17:42
827,726
07/04/2011 08:01:00
7
0
how to build this query?
Table id parentid comment tst_id 1 0 abc 233 2 1 xyz 0 I want to select all ids with parent comment as 0 having tst_id 233 +child comment of the same means id of that parent comment will be in parentid of child comment please help to build this query thanks
php
php5
cakephp
null
null
08/12/2011 10:29:15
not a real question
how to build this query? === Table id parentid comment tst_id 1 0 abc 233 2 1 xyz 0 I want to select all ids with parent comment as 0 having tst_id 233 +child comment of the same means id of that parent comment will be in parentid of child comment please help to build this query thanks
1
2,312,119
02/22/2010 15:59:07
37,759
11/14/2008 18:52:57
323
19
Firefox sporadically displays file stream instead of a document.
When user requests to download a document, I'm writing out a PDF file to HttpResponse using HttpResponse.OutputStream.Write method. It works in every browser except Firefox(3.5.8). In Firefox it sometimes displays the file and sometimes it displays the actual byte stream. When it displays a byte stream, http response is never finished. I see 'transferring data' status and the byte stream ends with EOF. After some time, I get 'connection was reset' window. ![alt text][1] ![alt text][2] ![alt text][3] [1]: http://img31.imageshack.us/img31/7907/displaybytes.png [2]: http://img193.imageshack.us/img193/7246/displayendofstream.png [3]: http://img211.imageshack.us/img211/1774/timeout.png
asp.net
file-download
firefox
null
null
null
open
Firefox sporadically displays file stream instead of a document. === When user requests to download a document, I'm writing out a PDF file to HttpResponse using HttpResponse.OutputStream.Write method. It works in every browser except Firefox(3.5.8). In Firefox it sometimes displays the file and sometimes it displays the actual byte stream. When it displays a byte stream, http response is never finished. I see 'transferring data' status and the byte stream ends with EOF. After some time, I get 'connection was reset' window. ![alt text][1] ![alt text][2] ![alt text][3] [1]: http://img31.imageshack.us/img31/7907/displaybytes.png [2]: http://img193.imageshack.us/img193/7246/displayendofstream.png [3]: http://img211.imageshack.us/img211/1774/timeout.png
0
7,518,698
09/22/2011 17:07:24
959,359
09/22/2011 14:39:43
1
0
Read all files of directory in Objective C?
i'd like to read all files with the suffix `.qa` (QuestionAnswerFile for a ChatBot) in a loop: How? I tried a lot…
objective-c
null
null
null
null
09/22/2011 17:33:10
not a real question
Read all files of directory in Objective C? === i'd like to read all files with the suffix `.qa` (QuestionAnswerFile for a ChatBot) in a loop: How? I tried a lot…
1
9,415,318
02/23/2012 14:49:27
1,228,627
02/23/2012 14:46:31
1
0
Priavate Message
Can we send private message to facebook user. My App needs to send private message to facebook user those are not in my friend's list. Please share with me any C# code or any code if possible Thanks Akash
facebook-graph-api
null
null
null
null
02/24/2012 21:19:20
not a real question
Priavate Message === Can we send private message to facebook user. My App needs to send private message to facebook user those are not in my friend's list. Please share with me any C# code or any code if possible Thanks Akash
1
11,537,470
07/18/2012 08:43:47
878,885
08/04/2011 15:11:48
200
13
Full stops in project name bad practise?
Would it be classed as bad practise to have a solution called "Importer" and then have several projects called Importer.[projectname] Imagine project name is like Importer.Model etc. Is that good or not? I want to confirm my thoughts with other developers Thanks
c#
.net
coding-style
null
null
07/18/2012 09:16:32
not constructive
Full stops in project name bad practise? === Would it be classed as bad practise to have a solution called "Importer" and then have several projects called Importer.[projectname] Imagine project name is like Importer.Model etc. Is that good or not? I want to confirm my thoughts with other developers Thanks
4
10,791,387
05/28/2012 23:16:24
1,422,544
05/28/2012 22:53:10
1
0
Installation error: INSTALL_FAILED_MISSING_SHARED_LIBRARY Mapsforge
I am having terrible problem with an android application. Started to develop android applications about a month ago. Everthing fine till now... Starting implementing a simple MapView application using mapsforge-maps-0.2.4.jar. Android project is based on Android 2.2. jar file is in the libraries file of the project, and additionally added to the build path. This I additionally proved by looking into the path via notepad. Now it is added correctly to the Referenced libraries and each class especially MapView is reachable in eclipse 3.7.2 indigo. After starting the project I get a 05-29 01:06:16.484: E/AndroidRuntime(9617): java.lang.NoClassDefFoundError: org.mapsforge.android.maps.MapView and application crashes. Read another thread concerning an similar problem which advised adding it as uses-library in the manifest file. <uses-library android:name="org.mapsforge.android.maps" /> Unfortunately this yield the problem mentioned above. At this position of have no hint on how to proceed except installing eclipse new, as I can see no error from my side. Do you have any hint?
eclipse
null
null
null
null
05/29/2012 14:35:53
too localized
Installation error: INSTALL_FAILED_MISSING_SHARED_LIBRARY Mapsforge === I am having terrible problem with an android application. Started to develop android applications about a month ago. Everthing fine till now... Starting implementing a simple MapView application using mapsforge-maps-0.2.4.jar. Android project is based on Android 2.2. jar file is in the libraries file of the project, and additionally added to the build path. This I additionally proved by looking into the path via notepad. Now it is added correctly to the Referenced libraries and each class especially MapView is reachable in eclipse 3.7.2 indigo. After starting the project I get a 05-29 01:06:16.484: E/AndroidRuntime(9617): java.lang.NoClassDefFoundError: org.mapsforge.android.maps.MapView and application crashes. Read another thread concerning an similar problem which advised adding it as uses-library in the manifest file. <uses-library android:name="org.mapsforge.android.maps" /> Unfortunately this yield the problem mentioned above. At this position of have no hint on how to proceed except installing eclipse new, as I can see no error from my side. Do you have any hint?
3
3,055,170
06/16/2010 16:16:04
208,066
11/10/2009 18:56:35
1,203
30
Is it appropriate to raise exceptions in stored procedures that wrap around CRUD operations, when the number of rows affected != 1?
This is a pretty specific question, albeit possibly subjective, but I've been using this pattern very frequently while not seeing others use it very often. Am I missing out on something or being too paranoid? I wrap all my `UPDATE`,`DELETE`,`INSERT` operations in stored procedures, and only give `EXECUTE` on my package and `SELECT` on my tables, to my application. For the `UPDATE` and `DELETE` procedures I have an `IF` statement at the end in which I do the following: IF SQL%ROWCOUNT <> 1 THEN RAISE_APPLICATION_ERROR(-20001, 'Invalid number of rows affected: ' || SQL%ROWCOUNT); END IF; One could also do this check in the application code, as the number of rows affected is usually available after a SQL statement is executed. So am I missing something or is this not the safest way to ensure you're updating or deleting exactly what you want to, nothing more, nothing less?
sql
oracle
plsql
null
null
null
open
Is it appropriate to raise exceptions in stored procedures that wrap around CRUD operations, when the number of rows affected != 1? === This is a pretty specific question, albeit possibly subjective, but I've been using this pattern very frequently while not seeing others use it very often. Am I missing out on something or being too paranoid? I wrap all my `UPDATE`,`DELETE`,`INSERT` operations in stored procedures, and only give `EXECUTE` on my package and `SELECT` on my tables, to my application. For the `UPDATE` and `DELETE` procedures I have an `IF` statement at the end in which I do the following: IF SQL%ROWCOUNT <> 1 THEN RAISE_APPLICATION_ERROR(-20001, 'Invalid number of rows affected: ' || SQL%ROWCOUNT); END IF; One could also do this check in the application code, as the number of rows affected is usually available after a SQL statement is executed. So am I missing something or is this not the safest way to ensure you're updating or deleting exactly what you want to, nothing more, nothing less?
0
11,324,210
07/04/2012 07:20:18
1,487,331
06/28/2012 02:26:43
1
0
how do I create test suite included many test case with c#?
Here is my code : but now I want to set this three test as a test suite in a xml file and import it. so how can I write the code?? and here is my xml : < test_suite> < caseBox> < caseName > test1< /caseName> < /caseBox> < caseBox> < caseName>test2< /caseName> < /caseBox> < caseBox> < caseName>test3< /caseName> < /caseBox> < test_suite>
c#
.net
testing
selenium
test-suite
07/05/2012 13:07:21
not a real question
how do I create test suite included many test case with c#? === Here is my code : but now I want to set this three test as a test suite in a xml file and import it. so how can I write the code?? and here is my xml : < test_suite> < caseBox> < caseName > test1< /caseName> < /caseBox> < caseBox> < caseName>test2< /caseName> < /caseBox> < caseBox> < caseName>test3< /caseName> < /caseBox> < test_suite>
1
6,576,809
07/04/2011 23:24:15
434,535
08/30/2010 01:28:30
55
1
How to format complex mathematical expressions?
This might not be the place for this, and if so I do apologize and ask that you point me in the direction where it may be appropriate for me to get an answer. This is a problem I run into when I code alot. new Vector2(parent.Coordinates.X + (Position + parent.Prompt.Length - parent.visibilityIndex) * parent.font.Width, parent.Coordinates.Y); That's quite a line! So I'll break it up into two: new Vector2(parent.Coordinates.X + (Position + parent.Prompt.Length - parent.visibilityIndex) * parent.font.Width, parent.Coordinates.Y); That's a little better, but still way too long. Anywhere else I try to break up the line seems arbitrary and to serve to obfuscate the code further. Am I wrong? What do you do? Again, I apologize if this is the wrong place for this as I am not sure.
c#
math
null
null
null
07/05/2011 12:43:29
off topic
How to format complex mathematical expressions? === This might not be the place for this, and if so I do apologize and ask that you point me in the direction where it may be appropriate for me to get an answer. This is a problem I run into when I code alot. new Vector2(parent.Coordinates.X + (Position + parent.Prompt.Length - parent.visibilityIndex) * parent.font.Width, parent.Coordinates.Y); That's quite a line! So I'll break it up into two: new Vector2(parent.Coordinates.X + (Position + parent.Prompt.Length - parent.visibilityIndex) * parent.font.Width, parent.Coordinates.Y); That's a little better, but still way too long. Anywhere else I try to break up the line seems arbitrary and to serve to obfuscate the code further. Am I wrong? What do you do? Again, I apologize if this is the wrong place for this as I am not sure.
2
5,297,292
03/14/2011 10:21:08
401,048
07/24/2010 13:04:01
44
2
cakephp displays 1 with every flash message
I'm using cakephp and whenever there comes a session based flash message, there comes "1" after every error/success message, why? It is related with "echo" before this flashmessage, so any idea, which file to make correction for it? We're using cakephp 1.2 version - FYI Earliest reply would be appreciated. Thanks !
flash
session
cakephp
message
null
null
open
cakephp displays 1 with every flash message === I'm using cakephp and whenever there comes a session based flash message, there comes "1" after every error/success message, why? It is related with "echo" before this flashmessage, so any idea, which file to make correction for it? We're using cakephp 1.2 version - FYI Earliest reply would be appreciated. Thanks !
0
441,304
01/13/2009 23:26:39
42,595
12/02/2008 19:47:03
375
10
Is there a way to delete files instantly on Windows XP?
On my Mac and any other Unix machine, when I delete a file by any of the several available methods (`rm` on the command line, drag to trash, press delete key) it usually happens instantly. Occasionally it takes a few seconds if it's a huge file. On Windows, when I try to delete something a dialog comes up with a progress bar. On my machine the deletion can take 10 to 20 seconds or even more in some cases. Is there a way to perform a delete operation on Windows XP with no wait period? Also, is there a way to not have to click those "are you sure..." dialogs?
windows
null
null
null
null
03/09/2011 12:49:11
off topic
Is there a way to delete files instantly on Windows XP? === On my Mac and any other Unix machine, when I delete a file by any of the several available methods (`rm` on the command line, drag to trash, press delete key) it usually happens instantly. Occasionally it takes a few seconds if it's a huge file. On Windows, when I try to delete something a dialog comes up with a progress bar. On my machine the deletion can take 10 to 20 seconds or even more in some cases. Is there a way to perform a delete operation on Windows XP with no wait period? Also, is there a way to not have to click those "are you sure..." dialogs?
2
4,772,507
01/23/2011 05:38:42
521,347
11/26/2010 12:04:09
1
3
JSON NO_REFERENCES
I have just started using JSON... I am using it in my project (Spring). I am making JSON string using XStream... I found in tutorial of XStream that using JSON, we have to set it's mode to NO_REFERENCES. I tried out searching it's reason on various sites, but I didn't find it anywhere... I tried removing it from my code... But that also did not had any effect on my output... So, tell me why we have to set it's mode to NO_REFERENCES?
json
null
null
null
null
null
open
JSON NO_REFERENCES === I have just started using JSON... I am using it in my project (Spring). I am making JSON string using XStream... I found in tutorial of XStream that using JSON, we have to set it's mode to NO_REFERENCES. I tried out searching it's reason on various sites, but I didn't find it anywhere... I tried removing it from my code... But that also did not had any effect on my output... So, tell me why we have to set it's mode to NO_REFERENCES?
0
8,789,930
01/09/2012 14:26:54
213,926
11/18/2009 16:54:39
434
17
.htaccess Allow only from a certain script
I have 2 separate servers (Server A and Server B) each with a PHP script (Script 1 and Script 2). I have PHP script 2 on Server B that I want to run, but only from PHP script 1 on Server A. I do not want any other http requests to pass through the directory on Server B where my protected script resides. In other words --> run script 2 on Server B **only if** http request comes from script 1 on Server A. Is this doable in an .htaccess file using Allows and Denys? Or is it done some other way. Thanks.
.htaccess
null
null
null
null
null
open
.htaccess Allow only from a certain script === I have 2 separate servers (Server A and Server B) each with a PHP script (Script 1 and Script 2). I have PHP script 2 on Server B that I want to run, but only from PHP script 1 on Server A. I do not want any other http requests to pass through the directory on Server B where my protected script resides. In other words --> run script 2 on Server B **only if** http request comes from script 1 on Server A. Is this doable in an .htaccess file using Allows and Denys? Or is it done some other way. Thanks.
0