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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
8,946,470 | 01/20/2012 18:58:59 | 1,090,092 | 12/09/2011 16:16:45 | 1 | 0 | Is there a better or more concise way to do this? | My goal was to make a list dynamically list itself into two columns, no matter the length of the list. I would really like to hear from people who know more about JavaScript and jQuery than I do if this code looks good or if there is a better or more concise method for implementing this sort of thing.
Thanks!
http://jsfiddle.net/mkimitch/ZEL5x/12/ | jquery | columns | html-lists | null | null | 01/20/2012 22:37:44 | off topic | Is there a better or more concise way to do this?
===
My goal was to make a list dynamically list itself into two columns, no matter the length of the list. I would really like to hear from people who know more about JavaScript and jQuery than I do if this code looks good or if there is a better or more concise method for implementing this sort of thing.
Thanks!
http://jsfiddle.net/mkimitch/ZEL5x/12/ | 2 |
872,487 | 05/16/2009 14:03:50 | 95,319 | 04/24/2009 06:16:26 | 1 | 0 | What is the most difficult UnitTest case you have ever encountered? | One of the most difficult test cases I have encountered is testing features that operates on files and folders.
It is not easy to mock or simulate files and folders. | unit-testing | null | null | null | null | 10/26/2011 13:13:06 | not constructive | What is the most difficult UnitTest case you have ever encountered?
===
One of the most difficult test cases I have encountered is testing features that operates on files and folders.
It is not easy to mock or simulate files and folders. | 4 |
8,359,690 | 12/02/2011 16:47:21 | 1,077,821 | 12/02/2011 16:34:09 | 1 | 0 | PHP IDEs with remote FTP browsers | Could you recommend a PHP IDE with a remote file browser? I have tried Aptana and NetBeans, they only support project syncing. I know Eclipse has a plugin for it, but I would like to try something else. It is a subjective matter, but what IDE in your opinion has the most usable remote file browser? (file tree preloading, less clicking, being able to handle different encodings etc) | php | ide | ftp | null | null | 12/02/2011 17:06:26 | not constructive | PHP IDEs with remote FTP browsers
===
Could you recommend a PHP IDE with a remote file browser? I have tried Aptana and NetBeans, they only support project syncing. I know Eclipse has a plugin for it, but I would like to try something else. It is a subjective matter, but what IDE in your opinion has the most usable remote file browser? (file tree preloading, less clicking, being able to handle different encodings etc) | 4 |
1,551,251 | 10/11/2009 17:43:22 | 169,599 | 09/07/2009 09:50:36 | 132 | 21 | How to Preserve Value of JQuery Search in ASP.Net MVC | I have an MVC view where I have a search box. On keyup, I perform a JQuery search and render the results to a div>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
<script language="javascript" type="text/javascript">
$(document).ready(function() {
$("#SearchTextBox").keyup(function() {
$("#MyEntityList").load("/MyEntity/IndexSearch/" + "?searchText=" + $('#SearchTextBox').val());
});
//trigger textbox on search - so back button works
$("#SearchTextBox").trigger('keyup');
})
</script>
<h2>MyEntitys</h2>
<div class="searchBar">
<%= Html.Encode("Search by entering a Surname or Company: ") + Html.TextBox("SearchTextBox") %>
</div>
<div id="MyEntityList">
<% Html.RenderPartial("MyEntitySearchResults", Model); %>
</div>
<p>
<%= Html.ActionLink("Create New", "Create") %>
</p>
</asp:Content>
This all works fine. My question is:
What's the nest way to preserver the search so that if a user moves to another view, they are returned to the same set of results etc?
I'm trying to avoid the use of ViewData but in this case is it may be OK.
Thanks
| jquery | mvc | viewdata | null | null | null | open | How to Preserve Value of JQuery Search in ASP.Net MVC
===
I have an MVC view where I have a search box. On keyup, I perform a JQuery search and render the results to a div>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
<script language="javascript" type="text/javascript">
$(document).ready(function() {
$("#SearchTextBox").keyup(function() {
$("#MyEntityList").load("/MyEntity/IndexSearch/" + "?searchText=" + $('#SearchTextBox').val());
});
//trigger textbox on search - so back button works
$("#SearchTextBox").trigger('keyup');
})
</script>
<h2>MyEntitys</h2>
<div class="searchBar">
<%= Html.Encode("Search by entering a Surname or Company: ") + Html.TextBox("SearchTextBox") %>
</div>
<div id="MyEntityList">
<% Html.RenderPartial("MyEntitySearchResults", Model); %>
</div>
<p>
<%= Html.ActionLink("Create New", "Create") %>
</p>
</asp:Content>
This all works fine. My question is:
What's the nest way to preserver the search so that if a user moves to another view, they are returned to the same set of results etc?
I'm trying to avoid the use of ViewData but in this case is it may be OK.
Thanks
| 0 |
1,484,216 | 09/27/2009 19:09:39 | 147,424 | 07/29/2009 21:06:28 | 194 | 17 | Django SESSION_COOKIE_DOMAIN error | Im trying to using SESSION_COOKIE_DOMAIN, but i got error in any browser when i try to go into my admin:
Looks like your browser isn't configured to accept cookies. Please enable cookies, reload this page, and try again.
any idea? | django-admin | null | null | null | null | null | open | Django SESSION_COOKIE_DOMAIN error
===
Im trying to using SESSION_COOKIE_DOMAIN, but i got error in any browser when i try to go into my admin:
Looks like your browser isn't configured to accept cookies. Please enable cookies, reload this page, and try again.
any idea? | 0 |
11,713,870 | 07/29/2012 23:32:34 | 1,561,435 | 07/29/2012 19:27:29 | 1 | 0 | Java coding interface related | Can you tell me where do i put the interface code in the Java?
Do i create a new class to put the code?!
I know the code tho..just not sure if i have to create a new class to put the code. Although I know I can implement it in other class. | java | java-7 | null | null | null | 07/30/2012 02:14:03 | not a real question | Java coding interface related
===
Can you tell me where do i put the interface code in the Java?
Do i create a new class to put the code?!
I know the code tho..just not sure if i have to create a new class to put the code. Although I know I can implement it in other class. | 1 |
2,453,356 | 03/16/2010 09:59:25 | 192,008 | 10/18/2009 13:26:20 | 166 | 8 | Django - Testing with parts of original database | My database has two types of entries: The very dynamic (users, comments, etc) and the more static (email templates, flat-pages).
During testing I want a clean DB but with the real 'semi-static' data.
Is there a way to make Django's testing system to load parts of the original DB ?
Thanks | django-testing | django | null | null | null | null | open | Django - Testing with parts of original database
===
My database has two types of entries: The very dynamic (users, comments, etc) and the more static (email templates, flat-pages).
During testing I want a clean DB but with the real 'semi-static' data.
Is there a way to make Django's testing system to load parts of the original DB ?
Thanks | 0 |
10,396,332 | 05/01/2012 10:19:01 | 1,364,011 | 04/29/2012 10:10:02 | 1 | 0 | Update query not commit - SQLite Manager - Xcode 4.2 - iphone | I have a little problem with an update query in SQLite Manager in my iPhone application:
1) I execute the update query
2) the query return no errors
3) If i watch on my database, the update didn't happen!!
Here's my code for update:
- (void)scrivereCheckSuDB:(NSString *)numero:(NSString *)check
{
NSString *dbPath = [[[NSBundle mainBundle] resourcePath] stringByAppendingPathComponent:@"DylanDB.sqlite"];
bool test = [self createEditableCopyOfDatabaseIfNeeded];
NSString *stmt = [NSString stringWithFormat: @"UPDATE SerieRegolare SET InCollect = '%@' WHERE Numero = '%@'", check, numero];
if (sqlite3_open([dbPath UTF8String], &database) == SQLITE_OK) {
const char *sql = (char*)[stmt UTF8String];
NSString* begin = [NSString stringWithString:@"BEGIN TRANSACTION"];
sqlite3_exec(database, begin.UTF8String , nil , nil , nil);
char* error = nil;
sqlite3_exec(database, sql , nil , nil , &error);
if(error != nil)
{
NSLog(@"Error: %@",[NSString stringWithCString:error]);
}
NSString* commit = [NSString stringWithString:@"COMMIT"];
sqlite3_exec(database, commit.UTF8String , nil , nil , nil);
}
else
sqlite3_close(database);
}
I think I did something wrong in commit....
Thank you for any helps!!
Stefano | iphone | objective-c | update | xcode4.2 | commit | null | open | Update query not commit - SQLite Manager - Xcode 4.2 - iphone
===
I have a little problem with an update query in SQLite Manager in my iPhone application:
1) I execute the update query
2) the query return no errors
3) If i watch on my database, the update didn't happen!!
Here's my code for update:
- (void)scrivereCheckSuDB:(NSString *)numero:(NSString *)check
{
NSString *dbPath = [[[NSBundle mainBundle] resourcePath] stringByAppendingPathComponent:@"DylanDB.sqlite"];
bool test = [self createEditableCopyOfDatabaseIfNeeded];
NSString *stmt = [NSString stringWithFormat: @"UPDATE SerieRegolare SET InCollect = '%@' WHERE Numero = '%@'", check, numero];
if (sqlite3_open([dbPath UTF8String], &database) == SQLITE_OK) {
const char *sql = (char*)[stmt UTF8String];
NSString* begin = [NSString stringWithString:@"BEGIN TRANSACTION"];
sqlite3_exec(database, begin.UTF8String , nil , nil , nil);
char* error = nil;
sqlite3_exec(database, sql , nil , nil , &error);
if(error != nil)
{
NSLog(@"Error: %@",[NSString stringWithCString:error]);
}
NSString* commit = [NSString stringWithString:@"COMMIT"];
sqlite3_exec(database, commit.UTF8String , nil , nil , nil);
}
else
sqlite3_close(database);
}
I think I did something wrong in commit....
Thank you for any helps!!
Stefano | 0 |
4,191,752 | 11/16/2010 06:38:46 | 24,702 | 10/03/2008 01:01:40 | 738 | 85 | Tips for keeping momentum on web projects | im preparing an article on tips for keeping momentum on a web project. basically how to keep the project rolling along smoothly, avoid stagnation & block points
i wanted to show you guys the tricks i use and see if you had any youd like to share
im not covering obvious things like 'use a project schedule' or 'use a spec' - if a person isnt doing that already, no amount of tricks will save them :)
___
**my tips...**
1. **get the ball rolling early on things involving third parties** -
a good example of this is hosting - you can get the shaft and surprises if you leave it 'til launch date to setup live hosting. mainly because there can be delays from the host tech since you may not have direct control over the server. another one is ecom gateway providers (could be delays due to learning their api)
2. **have settings accessible via the cms** -
ive found its better to have settings like how many products to render per shopping page settable via the cms (on a settings page). this is instead of using constants in code. its mainly to guard against the client changing their mind
3. **code simple things both ways, rather then waiting for approval** -
if theres two ways to do something, and its 15 minutes of code to do it either way, code them both. you could put it to the client and ask them which way they would like it. or you can code both, and switch one on. you have a 50/50 chance of getting it right. if not and the client asks for it the other way, you switch it to the other way. the amount of effort expended trying to get a client to decide and emails back and forth often exceeds the 15 minutes effort to code the other method
4. **put in the wrong content** -
this is a strange one, it shouldnt work - its counter-intuitive and you think it would piss off the client (but it doesnt, most of the time). this is only for preview/staging versions of the clients project, not on their live site. if the client hasnt made content available, then use the closest match. something off their old website, or workable place-holder text. this does one of two things: the client goes "thats the wrong text", you say "ok, can you give me the correct text please?", or - it gets them started, they have something to work from rather then starting from scratch (which invites procrastination)
5. **have a change request budget** -
this concept is straight out of PRINCE2 methodology. it basically says when you make a fee proposal, include a chunk of budget for unexpected features. so for a 80 hour project, i would have 5 hours of change request budget. the good thing about this is when the client asks for something off-spec, you dont have to wait for approval of extra money or try and convince them to pay for the feature (they already have). it also cuts down on admin later for invoicing
6. **get clients thinking about what they hadnt thought about - early** -
a good example of this is if a client comes to me to build them a business presence website. if i think a facebook link-up is appropriate, i bring it up at the start of the project. they usually say "i hadnt thought of that". at that point, you can give them material to read or advice. leaving it to launch can throw them off, they may decide to delay to consider the option
7. **dont just offer options, offer a recommendation too** -
if i talk to a client about a feature where there are two ways of doing things, i first describe the two ways, the pros and cons for each, and than a recommendation of what it think is most suitable (and why). this helps for clients who are reluctant to decide (this indecision can cause delays whilst the client stops to think). an example would be if they ask which is better; to integrate a blog into their website, or use a well-established one like *blogger*
8. **use a bug tracking system** -
scope creep is a bitch, that can add so much time to a project. a bug tracking system lets you deal with off-spec features. if a client asks for a feature and you say no, thats not good customer service. if you say yes to everything, youll be there forever. if you say 'yes but its been flagged for post launch implementation', you may be able to segment it off for future coding (doesnt always work, sometimes clients are determined to get their feature now!)
9. **start on things which require client approval early** -
an example would be if you have written a script for an intro video, the client may need a couple of days to review it and work with you to revise it. if you leave it 'til later in the project, it can cause delays in launch whilst they try make time to do the work (they could be busy with their business)
10. **begin some work before the project deposit arrives** -
when im certain the client is locked in for the project, i will do a couple of hours work even before the deposit has arrived (but i will only go so far). this would be stuff like prepare the project folder and dev environment, check that the domain delegation details theyve sent me actually work, minor things (no coding). the reason why this is good is because you have a head-start before the project has even began. its also good to show the client momentum, whilst they are still pumped about their project actually going ahead
___
all comments are welcome, even if you say "that technique is silly because..."
thanks in advance for your input and help | project | management | change | momentum | stalled | 11/17/2010 04:44:57 | off topic | Tips for keeping momentum on web projects
===
im preparing an article on tips for keeping momentum on a web project. basically how to keep the project rolling along smoothly, avoid stagnation & block points
i wanted to show you guys the tricks i use and see if you had any youd like to share
im not covering obvious things like 'use a project schedule' or 'use a spec' - if a person isnt doing that already, no amount of tricks will save them :)
___
**my tips...**
1. **get the ball rolling early on things involving third parties** -
a good example of this is hosting - you can get the shaft and surprises if you leave it 'til launch date to setup live hosting. mainly because there can be delays from the host tech since you may not have direct control over the server. another one is ecom gateway providers (could be delays due to learning their api)
2. **have settings accessible via the cms** -
ive found its better to have settings like how many products to render per shopping page settable via the cms (on a settings page). this is instead of using constants in code. its mainly to guard against the client changing their mind
3. **code simple things both ways, rather then waiting for approval** -
if theres two ways to do something, and its 15 minutes of code to do it either way, code them both. you could put it to the client and ask them which way they would like it. or you can code both, and switch one on. you have a 50/50 chance of getting it right. if not and the client asks for it the other way, you switch it to the other way. the amount of effort expended trying to get a client to decide and emails back and forth often exceeds the 15 minutes effort to code the other method
4. **put in the wrong content** -
this is a strange one, it shouldnt work - its counter-intuitive and you think it would piss off the client (but it doesnt, most of the time). this is only for preview/staging versions of the clients project, not on their live site. if the client hasnt made content available, then use the closest match. something off their old website, or workable place-holder text. this does one of two things: the client goes "thats the wrong text", you say "ok, can you give me the correct text please?", or - it gets them started, they have something to work from rather then starting from scratch (which invites procrastination)
5. **have a change request budget** -
this concept is straight out of PRINCE2 methodology. it basically says when you make a fee proposal, include a chunk of budget for unexpected features. so for a 80 hour project, i would have 5 hours of change request budget. the good thing about this is when the client asks for something off-spec, you dont have to wait for approval of extra money or try and convince them to pay for the feature (they already have). it also cuts down on admin later for invoicing
6. **get clients thinking about what they hadnt thought about - early** -
a good example of this is if a client comes to me to build them a business presence website. if i think a facebook link-up is appropriate, i bring it up at the start of the project. they usually say "i hadnt thought of that". at that point, you can give them material to read or advice. leaving it to launch can throw them off, they may decide to delay to consider the option
7. **dont just offer options, offer a recommendation too** -
if i talk to a client about a feature where there are two ways of doing things, i first describe the two ways, the pros and cons for each, and than a recommendation of what it think is most suitable (and why). this helps for clients who are reluctant to decide (this indecision can cause delays whilst the client stops to think). an example would be if they ask which is better; to integrate a blog into their website, or use a well-established one like *blogger*
8. **use a bug tracking system** -
scope creep is a bitch, that can add so much time to a project. a bug tracking system lets you deal with off-spec features. if a client asks for a feature and you say no, thats not good customer service. if you say yes to everything, youll be there forever. if you say 'yes but its been flagged for post launch implementation', you may be able to segment it off for future coding (doesnt always work, sometimes clients are determined to get their feature now!)
9. **start on things which require client approval early** -
an example would be if you have written a script for an intro video, the client may need a couple of days to review it and work with you to revise it. if you leave it 'til later in the project, it can cause delays in launch whilst they try make time to do the work (they could be busy with their business)
10. **begin some work before the project deposit arrives** -
when im certain the client is locked in for the project, i will do a couple of hours work even before the deposit has arrived (but i will only go so far). this would be stuff like prepare the project folder and dev environment, check that the domain delegation details theyve sent me actually work, minor things (no coding). the reason why this is good is because you have a head-start before the project has even began. its also good to show the client momentum, whilst they are still pumped about their project actually going ahead
___
all comments are welcome, even if you say "that technique is silly because..."
thanks in advance for your input and help | 2 |
7,639,090 | 10/03/2011 18:28:09 | 971,199 | 09/29/2011 13:10:51 | 1 | 0 | New to sql server reporting services | I am new to SSRS,can any one tell me what books i have to refer for report designing and data base we are using sybase,do you have tips and tricks on SSRS . | reporting-services | new | null | null | null | 10/03/2011 19:32:24 | off topic | New to sql server reporting services
===
I am new to SSRS,can any one tell me what books i have to refer for report designing and data base we are using sybase,do you have tips and tricks on SSRS . | 2 |
8,959,849 | 01/22/2012 08:10:15 | 868,331 | 07/28/2011 21:17:27 | 1 | 0 | iOS-like icons grid in OS X | I would like to have a view in my OS-X (Lion) application for displaying icons in a grid that when clicking an icon, the view changes to a different view (depends on the icon clicked) with a similar animation to iOS when clicking an app icon.
What's the best way to that with writing the minimal amount of code?
Thanks in advance! | objective-c | osx | cocoa | null | null | 01/22/2012 15:37:27 | not a real question | iOS-like icons grid in OS X
===
I would like to have a view in my OS-X (Lion) application for displaying icons in a grid that when clicking an icon, the view changes to a different view (depends on the icon clicked) with a similar animation to iOS when clicking an app icon.
What's the best way to that with writing the minimal amount of code?
Thanks in advance! | 1 |
11,109,071 | 06/19/2012 20:41:17 | 1,467,525 | 06/19/2012 20:35:15 | 1 | 0 | How can I resolve towers of hanoi with breadth or depth first search, in Prolog? | in most implementations that I see, using a recursive solution. But, I don´t want this. I want search in tree with a search algorithm, like a breadth-fisrt or depth-first.
thank you | prolog | depth-first-search | breadth-first-search | towers-of-hanoi | null | null | open | How can I resolve towers of hanoi with breadth or depth first search, in Prolog?
===
in most implementations that I see, using a recursive solution. But, I don´t want this. I want search in tree with a search algorithm, like a breadth-fisrt or depth-first.
thank you | 0 |
3,596,333 | 08/29/2010 19:54:26 | 202,919 | 11/04/2009 20:22:58 | 2,210 | 99 | Why are some open source projects (eg. NHibernate/Mono) reluctant to apply patches that fix blocking issues? | I encountered a very embarassing problem yesterday.
My particular experience is with NHibernate and Mono, but I see similar cases involving other projects everywhere.
While everyone seems to [claim][1] that NHibernate is working on Mono, I must admit that I actually tried yesterday, and the 3.0 trunk doesn't work. To me, this is a blocking issue, because it prevents me from using NHibernate for my Mono-based projects.
I had a conversation with the Mono people who directed me to an [old bug report][2] in the NH bug tracker, and [its Mono counterpart][3].
What bothers me most is that neither of the two groups actually wanted to fix the issue. Instead, they just pointed fingers to each other. In the end, it was fixed in NHibernate, but it seems that in 3.0 they re-introduced it again.
Anyways, I wanted to avoid debating about whether NHibernate or Mono is at fault and created a [working patch][4] for NHibernate that fixes the issue.
Guess what! They **didn't** accept it, saying that Mono is errornous...
The people at Mono say that NHibernate only works on Microsoft.NET because of an undocumented bug. I asked them if they would accept a patch if I fixed this in Mono, but they said **no**, too...
In my opinion, this is simply not right. While they are debating about who's guilty, the ones who s*ck this the most are always the average application developers (like me). Especially when I'm willing to fix the issue myself for free, and I'm also willing to contribute the patch to them, for free. All it would take is two clicks to apply the patch. Despite this, they don't care.
So, what do you guys think about it?
Should I start looking for a new ORM, or I'm better off using a custom patched version of NHibernate?
A more general question, why do these people have this attitude? It is not helping anyone.
[1]: http://stackoverflow.com/questions/3413285/what-are-the-differences-between-monos-and-microsofts-asp-net-implementations
[2]: http://216.121.112.228/browse/NH-1865
[3]: https://bugzilla.novell.com/show_bug.cgi?id=519442
[4]: http://216.121.112.228/browse/NH-2312 | .net | nhibernate | open-source | mono | open-source-contribution | 08/29/2010 21:26:09 | not a real question | Why are some open source projects (eg. NHibernate/Mono) reluctant to apply patches that fix blocking issues?
===
I encountered a very embarassing problem yesterday.
My particular experience is with NHibernate and Mono, but I see similar cases involving other projects everywhere.
While everyone seems to [claim][1] that NHibernate is working on Mono, I must admit that I actually tried yesterday, and the 3.0 trunk doesn't work. To me, this is a blocking issue, because it prevents me from using NHibernate for my Mono-based projects.
I had a conversation with the Mono people who directed me to an [old bug report][2] in the NH bug tracker, and [its Mono counterpart][3].
What bothers me most is that neither of the two groups actually wanted to fix the issue. Instead, they just pointed fingers to each other. In the end, it was fixed in NHibernate, but it seems that in 3.0 they re-introduced it again.
Anyways, I wanted to avoid debating about whether NHibernate or Mono is at fault and created a [working patch][4] for NHibernate that fixes the issue.
Guess what! They **didn't** accept it, saying that Mono is errornous...
The people at Mono say that NHibernate only works on Microsoft.NET because of an undocumented bug. I asked them if they would accept a patch if I fixed this in Mono, but they said **no**, too...
In my opinion, this is simply not right. While they are debating about who's guilty, the ones who s*ck this the most are always the average application developers (like me). Especially when I'm willing to fix the issue myself for free, and I'm also willing to contribute the patch to them, for free. All it would take is two clicks to apply the patch. Despite this, they don't care.
So, what do you guys think about it?
Should I start looking for a new ORM, or I'm better off using a custom patched version of NHibernate?
A more general question, why do these people have this attitude? It is not helping anyone.
[1]: http://stackoverflow.com/questions/3413285/what-are-the-differences-between-monos-and-microsofts-asp-net-implementations
[2]: http://216.121.112.228/browse/NH-1865
[3]: https://bugzilla.novell.com/show_bug.cgi?id=519442
[4]: http://216.121.112.228/browse/NH-2312 | 1 |
10,810,049 | 05/30/2012 04:37:31 | 1,425,099 | 05/30/2012 03:28:34 | 1 | 0 | Android: One way Sync of mobile SQLite database with Online (Oracle) database server | I am developing an application to Android/ iPhone / BB devices. On 1st launch of application I want to sync with online Oracle database server and download database in SQLite format to mobile's SD Card. Once the download is finished application will work in offline mode without network connection. When there is any update in the server database and user enabled network connection then mobile local database has to sync with the server database and download latest to SD Card. Is this kind of one way sync is possible. If possible can some one guide me. | android | iphone | null | null | null | 06/06/2012 12:17:03 | not a real question | Android: One way Sync of mobile SQLite database with Online (Oracle) database server
===
I am developing an application to Android/ iPhone / BB devices. On 1st launch of application I want to sync with online Oracle database server and download database in SQLite format to mobile's SD Card. Once the download is finished application will work in offline mode without network connection. When there is any update in the server database and user enabled network connection then mobile local database has to sync with the server database and download latest to SD Card. Is this kind of one way sync is possible. If possible can some one guide me. | 1 |
5,161,887 | 03/01/2011 23:54:23 | 640,330 | 03/01/2011 23:54:23 | 1 | 0 | Dynamically creating 100 divs within body tags | I need to dynamically create 100 divs within the <body> tag. Each div should be 100px x 100px and be floated to the left. The initial background colors of the divs should follow the above color sequence:
Red, pink, purple, blue, green, yellow
Clicking on ANY div should change its background color to the next color in the sequence. For example, clicking on a red div should change it to pink. Clicking on it again should change it to purple.
I can use any javascript library. Must work in the latest versions of Chrome, Safari and Firefox. | javascript | div | null | null | null | 03/02/2011 00:09:15 | not a real question | Dynamically creating 100 divs within body tags
===
I need to dynamically create 100 divs within the <body> tag. Each div should be 100px x 100px and be floated to the left. The initial background colors of the divs should follow the above color sequence:
Red, pink, purple, blue, green, yellow
Clicking on ANY div should change its background color to the next color in the sequence. For example, clicking on a red div should change it to pink. Clicking on it again should change it to purple.
I can use any javascript library. Must work in the latest versions of Chrome, Safari and Firefox. | 1 |
4,271,377 | 11/24/2010 20:44:36 | 135,292 | 07/08/2009 22:21:18 | 117 | 8 | What specific programming skills are useful for "data journalists"? | I'm becoming increasingly interested in the growing field of data journalism - basically finding, interpreting and visualising large quantities of data in order to explain or tell a story. [This Guardian piece][1] gives a good outline of what it entails, and very briefly skims over some of the "technical" skills it requires (MySQL, Python, spreadsheets).
Assuming general computer literacy and a basic understanding of programming, what programming skills or tools would a budding data journalist be advised to learn?
(I'm neither a journalist nor a real software developer, just a geek interested in hearing from people who know better!)
[1]: http://www.guardian.co.uk/news/datablog/2010/oct/01/data-journalism-how-to-guide | career-development | statistics | screen-scraping | data-mining | null | 01/29/2012 02:25:47 | not constructive | What specific programming skills are useful for "data journalists"?
===
I'm becoming increasingly interested in the growing field of data journalism - basically finding, interpreting and visualising large quantities of data in order to explain or tell a story. [This Guardian piece][1] gives a good outline of what it entails, and very briefly skims over some of the "technical" skills it requires (MySQL, Python, spreadsheets).
Assuming general computer literacy and a basic understanding of programming, what programming skills or tools would a budding data journalist be advised to learn?
(I'm neither a journalist nor a real software developer, just a geek interested in hearing from people who know better!)
[1]: http://www.guardian.co.uk/news/datablog/2010/oct/01/data-journalism-how-to-guide | 4 |
4,289,017 | 11/26/2010 22:45:27 | 346,332 | 05/20/2010 16:29:16 | 262 | 23 | C# code question | Could someone please give good samples of opensource `C# / Mono` projects, if possible with tests for `xUnit` / any other testing framework.
*This might also be the source code in `C#` that you've enjoyed the most.*
For example, in `C++` I could probably name any library from `boost sandbox` or the `Qt` framework as an example of well-written and maintained projects (something you really enjoy studying).
Thank you. | c# | open-source | null | null | null | 11/29/2010 04:40:41 | not constructive | C# code question
===
Could someone please give good samples of opensource `C# / Mono` projects, if possible with tests for `xUnit` / any other testing framework.
*This might also be the source code in `C#` that you've enjoyed the most.*
For example, in `C++` I could probably name any library from `boost sandbox` or the `Qt` framework as an example of well-written and maintained projects (something you really enjoy studying).
Thank you. | 4 |
7,432,192 | 09/15/2011 14:07:24 | 348,010 | 05/22/2010 21:12:02 | 38 | 2 | Rails order a find by counts of items on another table | I'm new to rails so please let me know if I am thinking about things incorrectly...
My task is:
I have a Users table and a Posts table. I want to find out which users have the most posts.
What's the right way to do this? | ruby-on-rails | null | null | null | null | null | open | Rails order a find by counts of items on another table
===
I'm new to rails so please let me know if I am thinking about things incorrectly...
My task is:
I have a Users table and a Posts table. I want to find out which users have the most posts.
What's the right way to do this? | 0 |
1,775,503 | 11/21/2009 13:38:23 | 187,606 | 10/10/2009 10:29:32 | 2,984 | 197 | What software do you use for software documentation? | I am currently working on a large PHP CMS / Framework and documenting it extensively as I go along. In addition to phpdoc-style inline comments, I need to document XML structures, details on concepts and practices, write HOWTOs and so on.
At the moment, I am using simple OpenOffice documents for that, but I'm unhappy with it and looking for a "real" documentation system.
So, I am looking for recommendations for **robust, minimalistic, easy-to-use documentation software**.
I have tried a number of Wikis, most prominently Dokuwiki. I like the open-minded approach, the freedom in editing, and the simplicity, but they provide little support in structuring a multi-chapter documentation, and make basic reorganisation tasks very difficult (e.g. moving pages to a different namespace). Working with the plugins is Cumbersome, and they are not really easy to use.
Open Source would be a plus but is not a requirement.
Thanks in advance for any recommendations! | documentation | api | wiki | null | null | 07/03/2012 12:37:08 | not constructive | What software do you use for software documentation?
===
I am currently working on a large PHP CMS / Framework and documenting it extensively as I go along. In addition to phpdoc-style inline comments, I need to document XML structures, details on concepts and practices, write HOWTOs and so on.
At the moment, I am using simple OpenOffice documents for that, but I'm unhappy with it and looking for a "real" documentation system.
So, I am looking for recommendations for **robust, minimalistic, easy-to-use documentation software**.
I have tried a number of Wikis, most prominently Dokuwiki. I like the open-minded approach, the freedom in editing, and the simplicity, but they provide little support in structuring a multi-chapter documentation, and make basic reorganisation tasks very difficult (e.g. moving pages to a different namespace). Working with the plugins is Cumbersome, and they are not really easy to use.
Open Source would be a plus but is not a requirement.
Thanks in advance for any recommendations! | 4 |
10,269,101 | 04/22/2012 15:11:21 | 920,123 | 08/30/2011 16:27:58 | 107 | 2 | Create an image matrix with variable image size | I want to create a website, which contains some images (20-30), and I would like to locate them to fill in the full screen (no downward scrolling).
I would also want to give a size multiplier to highlight the images. I'am interested in php script or wordpress theme.
similar to this:
![enter image description here][1]
[1]: http://i.stack.imgur.com/WKYkk.jpg | php | wordpress | website | wordpress-theming | null | 04/23/2012 15:33:59 | not a real question | Create an image matrix with variable image size
===
I want to create a website, which contains some images (20-30), and I would like to locate them to fill in the full screen (no downward scrolling).
I would also want to give a size multiplier to highlight the images. I'am interested in php script or wordpress theme.
similar to this:
![enter image description here][1]
[1]: http://i.stack.imgur.com/WKYkk.jpg | 1 |
8,682,954 | 12/30/2011 18:59:06 | 1,122,098 | 12/29/2011 23:45:59 | 5 | 0 | What are the best webshops to buy programming books? | So im into programming for a while and I would like to learn more stuff about programming, read some interesting books in free time to become better programmer.
So what are the best webshops to buy books about programming?
I would like to get Code Complete by Steve McConnell and few more... where to order them?
This can be like a list of all the best online stores to get programming books.
Thanks! | books | null | null | null | null | 12/31/2011 20:18:51 | off topic | What are the best webshops to buy programming books?
===
So im into programming for a while and I would like to learn more stuff about programming, read some interesting books in free time to become better programmer.
So what are the best webshops to buy books about programming?
I would like to get Code Complete by Steve McConnell and few more... where to order them?
This can be like a list of all the best online stores to get programming books.
Thanks! | 2 |
7,659,797 | 10/05/2011 10:18:26 | 484,972 | 06/15/2010 10:42:22 | 2,753 | 132 | SpringSource Tool Suite and GWT without using ROO? | I would like to know if anyone has any experience in using STS to create a Spring-enabled GWT web application *without* using Spring ROO.
There are 2 scenarios that I have.
1. I have an existing GWT application (not Spring-enabled, built in Eclipse 3.7) that I want to convert to a Spring-enabled GWT application in STS. I want STS to pick up that this is now Spring-enabled so that I can use the built-in features of STS for Spring.
2. Create a new GWT web application that is Spring-enabled in STS, but without using Spring ROO.
I have as of yet found no tutorials on how to do either. All the examples that point to creating a Spring-enabled GWT web application in STS use ROO to scaffold it for them.
Sorry if it is a bit unclear what I mean. Feel free to comment and I will try to explain more.
Thanks! | spring | gwt | sts-springsourcetoolsuite | null | null | null | open | SpringSource Tool Suite and GWT without using ROO?
===
I would like to know if anyone has any experience in using STS to create a Spring-enabled GWT web application *without* using Spring ROO.
There are 2 scenarios that I have.
1. I have an existing GWT application (not Spring-enabled, built in Eclipse 3.7) that I want to convert to a Spring-enabled GWT application in STS. I want STS to pick up that this is now Spring-enabled so that I can use the built-in features of STS for Spring.
2. Create a new GWT web application that is Spring-enabled in STS, but without using Spring ROO.
I have as of yet found no tutorials on how to do either. All the examples that point to creating a Spring-enabled GWT web application in STS use ROO to scaffold it for them.
Sorry if it is a bit unclear what I mean. Feel free to comment and I will try to explain more.
Thanks! | 0 |
10,089,003 | 04/10/2012 12:41:05 | 480,231 | 04/04/2010 17:00:00 | 586 | 10 | How to call aspx page without opening it | I have a aspx page that I need to call without going directly on that page.<br/>
I have tried to make POST from form but it opens this action url in browser.<br/>
<form method="POST" action="http://mysite/actionpage.aspx">
<input type="submit" value="Submit" />
</form> | asp.net | html | html-form | html-form-post | null | null | open | How to call aspx page without opening it
===
I have a aspx page that I need to call without going directly on that page.<br/>
I have tried to make POST from form but it opens this action url in browser.<br/>
<form method="POST" action="http://mysite/actionpage.aspx">
<input type="submit" value="Submit" />
</form> | 0 |
3,617,284 | 09/01/2010 10:58:54 | 427,234 | 08/21/2010 18:42:21 | 8 | 0 | Android Development: Dialog Box With EditText and Spinner | I have a button that pops up with a dialog box on click.
I want the dialog box to have an EditText and a Spinner inside the dialog box.
I don't know how I'd set the view for it, I have the code for an AlertDialog and it works, it's just the EditText and Spinner that I need to place inside it then I can get on with the rest of the app's code.
Please can someone show me how I'd add an EditText and Spinner please?
Thanks, Alex. | android | dialog | dev | null | null | null | open | Android Development: Dialog Box With EditText and Spinner
===
I have a button that pops up with a dialog box on click.
I want the dialog box to have an EditText and a Spinner inside the dialog box.
I don't know how I'd set the view for it, I have the code for an AlertDialog and it works, it's just the EditText and Spinner that I need to place inside it then I can get on with the rest of the app's code.
Please can someone show me how I'd add an EditText and Spinner please?
Thanks, Alex. | 0 |
5,808,796 | 04/27/2011 18:31:18 | 578,660 | 01/17/2011 14:49:15 | 132 | 20 | how can I learn android... | I am new in making android applications... if you have any good tutorial for learning android (either it is book or video) then plz give me the links.... so that it is helpfull to me... | iphone | android | null | null | null | 04/27/2011 19:20:44 | not a real question | how can I learn android...
===
I am new in making android applications... if you have any good tutorial for learning android (either it is book or video) then plz give me the links.... so that it is helpfull to me... | 1 |
6,650,903 | 07/11/2011 13:35:11 | 838,985 | 07/11/2011 13:35:11 | 1 | 0 | Programming languages and memory usage | I am looking for languages that are not memory intensive as an alternative to Java's JRE. I know I can use C. Are there any other?
Thanks. | java | null | null | null | null | 07/11/2011 13:53:35 | not constructive | Programming languages and memory usage
===
I am looking for languages that are not memory intensive as an alternative to Java's JRE. I know I can use C. Are there any other?
Thanks. | 4 |
6,081,434 | 05/21/2011 11:30:45 | 763,915 | 05/21/2011 11:30:45 | 1 | 0 | Finding a totally nasty, complex, Schröding-Bohr-Bug | I have a really nasty bug in my program, which grew quite complex over time. It's probably the worst bug I've ever had.
I *think* that it might be related to a static variable initialization fiasco, **but how can I ensure myself of that?**
When the bug strikes, the program crashes due to heap corruption at a random point after startup, but far inside the main() function.
To be honest, I don't know what to do.
I'm on Windows 7 using Microsoft Visual Studio 2010 | c++ | initialization | bugs | null | null | 05/21/2011 11:52:32 | not a real question | Finding a totally nasty, complex, Schröding-Bohr-Bug
===
I have a really nasty bug in my program, which grew quite complex over time. It's probably the worst bug I've ever had.
I *think* that it might be related to a static variable initialization fiasco, **but how can I ensure myself of that?**
When the bug strikes, the program crashes due to heap corruption at a random point after startup, but far inside the main() function.
To be honest, I don't know what to do.
I'm on Windows 7 using Microsoft Visual Studio 2010 | 1 |
11,560,941 | 07/19/2012 12:29:51 | 1,177,847 | 01/30/2012 10:36:43 | 58 | 3 | Batch file for loop to unzip files and get timestamps of zip file contents | I have a daily process which generates some zip files out of files that are being created by other processes. I need to create a daily log file which indicates the timestamps the contents of one specific file of each zip file that is found.
I created the following batch script which seemed to work yesterday on my test system, but not anymore today, no idea why...
set VersionDirectory=C:\Test\VersionX\
set ResultOutputFile=C:\Test\LogFile.txt
for /f %%f in ('dir /b %VersionDirectory%\Installable\Packages\pattern*.zip') do (
mkdir %temp%\%%f\
unzip -extract -dir %VersionDirectory%\Installable\Packages\%%f %temp%\%%f\ > nul
for %%a in (%temp%\%%f\InstallScript.xml) do set InstallScriptXMLDate=%%~ta
rmdir /s /q %temp%\%%f\
echo %%f [package from %InstallScriptXMLDate%] >> %ResultOutputFile%
)
Short summary of what this file is supposed to do:
1. Loop through each pattern*.zip file in C:\Test\VersionX\ directory
2. unzip this file to the %temp%\%%f directory (where %%f is the filename)
3. Get the timestamp of the %temp%\%%f\InstallScript.xml and put it in the %InstallScriptXMLDate% variable
4. Delete the %temp%\%%f directory
5. Echo the filename (%%f) and timestamp (%InstallScriptXMLDate%) into the log file
As of now the log file just contains the filenames, followed by the string '[package from ]' string, but missing the actual date timestamp
The unzipping and removing of the zip files is working flawlessly, it's just the timestamp that's not being set.
| command-line | batch | batch-file | null | null | null | open | Batch file for loop to unzip files and get timestamps of zip file contents
===
I have a daily process which generates some zip files out of files that are being created by other processes. I need to create a daily log file which indicates the timestamps the contents of one specific file of each zip file that is found.
I created the following batch script which seemed to work yesterday on my test system, but not anymore today, no idea why...
set VersionDirectory=C:\Test\VersionX\
set ResultOutputFile=C:\Test\LogFile.txt
for /f %%f in ('dir /b %VersionDirectory%\Installable\Packages\pattern*.zip') do (
mkdir %temp%\%%f\
unzip -extract -dir %VersionDirectory%\Installable\Packages\%%f %temp%\%%f\ > nul
for %%a in (%temp%\%%f\InstallScript.xml) do set InstallScriptXMLDate=%%~ta
rmdir /s /q %temp%\%%f\
echo %%f [package from %InstallScriptXMLDate%] >> %ResultOutputFile%
)
Short summary of what this file is supposed to do:
1. Loop through each pattern*.zip file in C:\Test\VersionX\ directory
2. unzip this file to the %temp%\%%f directory (where %%f is the filename)
3. Get the timestamp of the %temp%\%%f\InstallScript.xml and put it in the %InstallScriptXMLDate% variable
4. Delete the %temp%\%%f directory
5. Echo the filename (%%f) and timestamp (%InstallScriptXMLDate%) into the log file
As of now the log file just contains the filenames, followed by the string '[package from ]' string, but missing the actual date timestamp
The unzipping and removing of the zip files is working flawlessly, it's just the timestamp that's not being set.
| 0 |
3,405,695 | 08/04/2010 12:56:55 | 379,693 | 06/30/2010 05:27:59 | 1,347 | 50 | Which are the web links useful for the "Android" related stuff ? | Hello all <b>Android</b>ers,
As such There is no particular repository for Android, i would like to initiate this.
Now, let me clear about my idea: My idea is that Wherever you find any website and if you find it helps for the Android, then pls try to post here. This post **`works as a common Android-Database storing all the website-links which are either of Articles, code, examples, pdf, or any.`**
So that whenever anybody having doubt regarding Android Stuff, then they can easily browse through links and may easily find the solution.
So pls try to submit link !!
| android | website | repository | null | null | 04/20/2012 15:23:58 | not a real question | Which are the web links useful for the "Android" related stuff ?
===
Hello all <b>Android</b>ers,
As such There is no particular repository for Android, i would like to initiate this.
Now, let me clear about my idea: My idea is that Wherever you find any website and if you find it helps for the Android, then pls try to post here. This post **`works as a common Android-Database storing all the website-links which are either of Articles, code, examples, pdf, or any.`**
So that whenever anybody having doubt regarding Android Stuff, then they can easily browse through links and may easily find the solution.
So pls try to submit link !!
| 1 |
8,392,692 | 12/05/2011 22:17:45 | 199,156 | 10/29/2009 18:51:47 | 145 | 2 | Getting started with "Enhance PHP" | I am looking to incorporate a testing framework into a project I am building and came across [Enhance PHP](http://www.enhance-php.com/) which I like but I am having some difficulty finding relevant information on-line since "enhance php" is such a commonly used phrase.
Has anyone worked with this framework that might be able to point me toward some helpful guide? Have you worked with a unit test framework that you think is amazingly better?
Thanks in advance. | php | unit-testing | null | null | null | null | open | Getting started with "Enhance PHP"
===
I am looking to incorporate a testing framework into a project I am building and came across [Enhance PHP](http://www.enhance-php.com/) which I like but I am having some difficulty finding relevant information on-line since "enhance php" is such a commonly used phrase.
Has anyone worked with this framework that might be able to point me toward some helpful guide? Have you worked with a unit test framework that you think is amazingly better?
Thanks in advance. | 0 |
562,608 | 02/18/2009 20:09:08 | 35,903 | 11/09/2008 09:38:52 | 696 | 41 | Aggregation with two Joins (MySQL) | I have one table called **gallery**. For each row in **gallery** there are several rows in the table **picture**. One picture belongs to one gallery. Then there is the table **vote**. There each row is an upvote or a downvote for a certain gallery.
Here is the (simplified) structure:
gallery ( gallery_id )
picture ( picture_id, picture_gallery_ref )
vote ( vote_id, vote_value, vote_gallery_ref )
Now I want one query to give me the following information: All galleries with their own data fields and the number of pictures that are connected to the gallery and the sumarized value of the votes.
Here is my query, but due to the multiple joining the aggregated values are not the right ones. (At least when there is more than one row of either pictures or votes.)
SELECT
*, SUM( vote_value ) as score, COUNT( picture_id ) AS pictures
FROM
gallery
LEFT JOIN
vote
ON gallery_id = vote_gallery_ref
LEFT JOIN
picture
ON gallery_id = picture_gallery_ref
GROUP BY question_id
Because I have noticed that `COUNT( DISTINCT picture_id )` gives me the correct number of pictures I tried this:
( SUM( vote_value ) / GREATEST( COUNT( DISTINCT picture_id ), 1 ) ) AS score
It works in this example, but what if there were more joins in one query?
Just want to know whether there is a better or more 'elegant' way this problem can be solved. Also I'd like to know whether my solution is MySQL-specific or standard SQL? | sql | joins | aggregation | null | null | null | open | Aggregation with two Joins (MySQL)
===
I have one table called **gallery**. For each row in **gallery** there are several rows in the table **picture**. One picture belongs to one gallery. Then there is the table **vote**. There each row is an upvote or a downvote for a certain gallery.
Here is the (simplified) structure:
gallery ( gallery_id )
picture ( picture_id, picture_gallery_ref )
vote ( vote_id, vote_value, vote_gallery_ref )
Now I want one query to give me the following information: All galleries with their own data fields and the number of pictures that are connected to the gallery and the sumarized value of the votes.
Here is my query, but due to the multiple joining the aggregated values are not the right ones. (At least when there is more than one row of either pictures or votes.)
SELECT
*, SUM( vote_value ) as score, COUNT( picture_id ) AS pictures
FROM
gallery
LEFT JOIN
vote
ON gallery_id = vote_gallery_ref
LEFT JOIN
picture
ON gallery_id = picture_gallery_ref
GROUP BY question_id
Because I have noticed that `COUNT( DISTINCT picture_id )` gives me the correct number of pictures I tried this:
( SUM( vote_value ) / GREATEST( COUNT( DISTINCT picture_id ), 1 ) ) AS score
It works in this example, but what if there were more joins in one query?
Just want to know whether there is a better or more 'elegant' way this problem can be solved. Also I'd like to know whether my solution is MySQL-specific or standard SQL? | 0 |
11,086,614 | 06/18/2012 16:00:06 | 1,460,948 | 06/16/2012 17:56:52 | 18 | 0 | Checking charecters in an equation | Ok, so I'm now trying to make a program that lets you input any one step equation, and solve for it. To make it so that you can enter it in any way, I have a for loop running that checks every character to see what it is. But then, I realized that I could not use double digit numbers for this. So I tried adding a little function that checks if there is a character one to the right, to test if it is a number. And if it is a number, combine that plus the one it found, to be a single number. Like if it sees 1, and checks to the right that there is a 0 there, it give you 10. Here is the code for this function
Find = equation.charAt(i);
if (Character.isDigit(Find))
{
if(Found == 0)
{
if(i < equation.length() - 1)
{
FindNext = equation.charAt(i + 1);
if (Character.isDigit(FindNext))
{
one = (Character.toString(Find) + Character.toString(FindNext));
Found = 2;
One = Double.parseDouble(one);
}
}
else
{
one = (Character.toString(Find));
Found = 2;
One = Double.parseDouble(one);
}
}
else
{
if(i + 1 < equation.length() - 1)
{
FindNext = equation.charAt(i + 1);
if (Character.isDigit(FindNext))
{
two = (Character.toString(Find) + Character.toString(FindNext));
Two = Double.parseDouble(one);
}
}
else
{
two = (Character.toString(Find));
Two = Double.parseDouble(two);
}
}
}
So does anyone see what I'm doing wrong? Thanks. | java | char | check | null | null | 06/19/2012 11:45:25 | off topic | Checking charecters in an equation
===
Ok, so I'm now trying to make a program that lets you input any one step equation, and solve for it. To make it so that you can enter it in any way, I have a for loop running that checks every character to see what it is. But then, I realized that I could not use double digit numbers for this. So I tried adding a little function that checks if there is a character one to the right, to test if it is a number. And if it is a number, combine that plus the one it found, to be a single number. Like if it sees 1, and checks to the right that there is a 0 there, it give you 10. Here is the code for this function
Find = equation.charAt(i);
if (Character.isDigit(Find))
{
if(Found == 0)
{
if(i < equation.length() - 1)
{
FindNext = equation.charAt(i + 1);
if (Character.isDigit(FindNext))
{
one = (Character.toString(Find) + Character.toString(FindNext));
Found = 2;
One = Double.parseDouble(one);
}
}
else
{
one = (Character.toString(Find));
Found = 2;
One = Double.parseDouble(one);
}
}
else
{
if(i + 1 < equation.length() - 1)
{
FindNext = equation.charAt(i + 1);
if (Character.isDigit(FindNext))
{
two = (Character.toString(Find) + Character.toString(FindNext));
Two = Double.parseDouble(one);
}
}
else
{
two = (Character.toString(Find));
Two = Double.parseDouble(two);
}
}
}
So does anyone see what I'm doing wrong? Thanks. | 2 |
5,157,695 | 03/01/2011 16:59:49 | 574,700 | 01/13/2011 18:27:28 | 140 | 16 | What is the MYSQL variant of time()? | In my script I store a PHP time() value in the database.
I've got a simple solution, but I bet it is certainly not the most 'clean' solution.
<?php
$time = time();
mysql_query("DELETE * FROM table WHERE expire < '$time';");
?>
Is there an MYSQL fuction with the same format as the PHP time() function?
Thanks in advance!
PS: Please support my English by correcting me :) | php | mysql | null | null | null | null | open | What is the MYSQL variant of time()?
===
In my script I store a PHP time() value in the database.
I've got a simple solution, but I bet it is certainly not the most 'clean' solution.
<?php
$time = time();
mysql_query("DELETE * FROM table WHERE expire < '$time';");
?>
Is there an MYSQL fuction with the same format as the PHP time() function?
Thanks in advance!
PS: Please support my English by correcting me :) | 0 |
11,101,083 | 06/19/2012 12:37:17 | 1,213,807 | 02/16/2012 12:23:37 | 111 | 1 | jQuery accordion auto height | I have a accordion structure. With the following:
http://jsfiddle.net/WABrZ/
And i want, when click header, page get auto height. I want active tab seen center on page. Sorry my grammer. Thanks. | jquery | jquery-ui | accordion | jquery-accordion | null | null | open | jQuery accordion auto height
===
I have a accordion structure. With the following:
http://jsfiddle.net/WABrZ/
And i want, when click header, page get auto height. I want active tab seen center on page. Sorry my grammer. Thanks. | 0 |
6,755,111 | 07/19/2011 22:57:31 | 814,359 | 06/24/2011 15:48:55 | 23 | 0 | c++, read input files, fastest way possible? | I have numerous text files of data in the form of float numbers. I'm looking for the fastest way to read them in C++. I can change the file to binary if that's the fastest.
It would be great if you could give me hint or refer me to a website with complete explanation. or I dont know if there is any library that does the work fast. even if there is any opensource code that does the work, it's very appreciated.
Thanks in advance.
| c++ | c | input | binary | null | null | open | c++, read input files, fastest way possible?
===
I have numerous text files of data in the form of float numbers. I'm looking for the fastest way to read them in C++. I can change the file to binary if that's the fastest.
It would be great if you could give me hint or refer me to a website with complete explanation. or I dont know if there is any library that does the work fast. even if there is any opensource code that does the work, it's very appreciated.
Thanks in advance.
| 0 |
11,425,109 | 07/11/2012 03:26:24 | 923,207 | 09/01/2011 09:42:04 | 382 | 16 | How to include the soap envelope tag when marshalling using JAXB? | I am marshalling a soap request using JAXB. It is working but the resulting XML does not contain the <code>soap:Envelope</code> tag. Also, the namespace is indicated on root element instead of inside the <code>soap:Envelope</code> tag. There is also an additional <code>standalone</code> attribute on the xml tag. How can I achieved an output similar to the 2nd XML below using JAXB's marshaller?
Currently, here's how my marshalled XML looks like:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<Customer xmlns:ns="http://www.example.org/beanLevelNamespace">
<ns:id>201200001</ns:id>
<ns:name>Name</ns:name>
<ns:age>18</ns:age>
</Customer>
And here is how I want it to look like:
<?xml version="1.0" encoding="UTF-8"?>
<soap:Envelope
xmlns:soap="http://www.w3.org/2001/12/soap-envelope"
soap:encodingStyle="http://www.w3.org/2001/12/soap-encoding">
<soap:Body xmlns:ns="http://www.example.org/beanLevelNamespace">
<Customer>
<ns:id>201200001</ns:id>
<ns:name>Name</ns:name>
<ns:age>18</ns:age>
</Customer>
</soap:Body>
</soap:Envelope>
| java | xml | soap | jaxb | marshalling | null | open | How to include the soap envelope tag when marshalling using JAXB?
===
I am marshalling a soap request using JAXB. It is working but the resulting XML does not contain the <code>soap:Envelope</code> tag. Also, the namespace is indicated on root element instead of inside the <code>soap:Envelope</code> tag. There is also an additional <code>standalone</code> attribute on the xml tag. How can I achieved an output similar to the 2nd XML below using JAXB's marshaller?
Currently, here's how my marshalled XML looks like:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<Customer xmlns:ns="http://www.example.org/beanLevelNamespace">
<ns:id>201200001</ns:id>
<ns:name>Name</ns:name>
<ns:age>18</ns:age>
</Customer>
And here is how I want it to look like:
<?xml version="1.0" encoding="UTF-8"?>
<soap:Envelope
xmlns:soap="http://www.w3.org/2001/12/soap-envelope"
soap:encodingStyle="http://www.w3.org/2001/12/soap-encoding">
<soap:Body xmlns:ns="http://www.example.org/beanLevelNamespace">
<Customer>
<ns:id>201200001</ns:id>
<ns:name>Name</ns:name>
<ns:age>18</ns:age>
</Customer>
</soap:Body>
</soap:Envelope>
| 0 |
8,689,036 | 12/31/2011 15:55:22 | 1,122,714 | 12/30/2011 09:47:16 | 1 | 0 | Codeigniter not working on one server but working fine on other server | I developed the site in codeigniter, its working fine on one server but not working on other server. I guess the db connection is not working because when i create db connection with simple file outside the codeigniter frame than connection was ok. To me the problem is that db connection is not working with codeigniter.
I would appreciate the help,
thanks. | codeigniter | working | null | null | null | 01/05/2012 19:48:30 | not a real question | Codeigniter not working on one server but working fine on other server
===
I developed the site in codeigniter, its working fine on one server but not working on other server. I guess the db connection is not working because when i create db connection with simple file outside the codeigniter frame than connection was ok. To me the problem is that db connection is not working with codeigniter.
I would appreciate the help,
thanks. | 1 |
6,153,123 | 05/27/2011 13:47:56 | 504,407 | 11/11/2010 11:13:23 | 23 | 0 | A published reference for the solution to compute the 'elbow' for a curve | I asked a question about several months ago: http://stackoverflow.com/questions/4471993/compute-the-elbow-for-a-curve-automatically-and-mathematically.
One answer is that:
the point with maximum curvature, i.e., the second derivative, will do. It can be approximated with a central difference:
secondDerivative[i] = x[i+1] + x[i-1] - 2 * x[i].
It is good. My new question is that:
1. why can we compute the 'elbow' for a curve like this?
2. Is there any published reference for this solution? I wan to write a paper and I have to tell the readers the reasons.
| math | curve | paper | derivative | null | 05/27/2011 18:52:05 | off topic | A published reference for the solution to compute the 'elbow' for a curve
===
I asked a question about several months ago: http://stackoverflow.com/questions/4471993/compute-the-elbow-for-a-curve-automatically-and-mathematically.
One answer is that:
the point with maximum curvature, i.e., the second derivative, will do. It can be approximated with a central difference:
secondDerivative[i] = x[i+1] + x[i-1] - 2 * x[i].
It is good. My new question is that:
1. why can we compute the 'elbow' for a curve like this?
2. Is there any published reference for this solution? I wan to write a paper and I have to tell the readers the reasons.
| 2 |
10,855,806 | 06/01/2012 18:52:03 | 922,593 | 08/31/2011 23:15:25 | 50 | 1 | Parse External JSON File with jQuery | I have a 2 MB JSON object that I'm hoping to parse with jQuery. I dumped the whole object into a file named "timeline.js" and I'm hoping to parse through it as a dataset to grab records as needed.
My dataset started as an XML file, but I read that JSON would be more efficient as I'm using jQuery to pull the data and place it in the DOM.
Below is the first record of my object. How would I parse this object to grab the record with a 'profileid' of 1016?
{
timeline:{
record:[
{
profileid:1016,
title:'Adam',
parentprofileid:0,
type:'Person',
minzoomlevel:29,
maxzoomlevel:66,
isapproxstart:1,
isapproxend:1,
startdate:-4181,
enddate:-3251,
shortdescription:'Name means "red" or "man" he is...',
article:'<div><span>The first member of...',
status:22,
scriptures:{
scripture:[
{
profileid:1016,
scripturetext:'Genesis 2:7',
referencetext:'Birth'
},
{
profileid:1016,
scripturetext:'Genesis 5:4',
referencetext:'Death'
}
]
}
}, | javascript | jquery | xml | ajax | json | null | open | Parse External JSON File with jQuery
===
I have a 2 MB JSON object that I'm hoping to parse with jQuery. I dumped the whole object into a file named "timeline.js" and I'm hoping to parse through it as a dataset to grab records as needed.
My dataset started as an XML file, but I read that JSON would be more efficient as I'm using jQuery to pull the data and place it in the DOM.
Below is the first record of my object. How would I parse this object to grab the record with a 'profileid' of 1016?
{
timeline:{
record:[
{
profileid:1016,
title:'Adam',
parentprofileid:0,
type:'Person',
minzoomlevel:29,
maxzoomlevel:66,
isapproxstart:1,
isapproxend:1,
startdate:-4181,
enddate:-3251,
shortdescription:'Name means "red" or "man" he is...',
article:'<div><span>The first member of...',
status:22,
scriptures:{
scripture:[
{
profileid:1016,
scripturetext:'Genesis 2:7',
referencetext:'Birth'
},
{
profileid:1016,
scripturetext:'Genesis 5:4',
referencetext:'Death'
}
]
}
}, | 0 |
6,461,902 | 06/23/2011 23:40:11 | 21,441 | 09/23/2008 23:56:39 | 12,583 | 413 | Resolving workspace dependencies for Virgo in Eclipse | I'm looking to get started with Eclipse Virgo, so I grabbed the required plugins for Eclipse based on the [Programmer Guide]().
Next, I started two new projects in my Eclipse workspace, both configured as Virgo bundles (call these A and B). Then, I created a new class `com.foo.Bar` in bundle B. I modified the Manifest of bundle B to export `com.foo`, saved. Last, I imported `com.foo` in bundle A.
Bundle A's manifest has an error:
> Import-Package: com.foo [0.0.0, oo) could not be resolved
What do I need to do to configure Eclipse to resolve dependencies using the projects in my workspace?
I've already tried adding bundle B to the build path of bundle A, but this makes no difference. | java | eclipse | eclipse-virgo | spring-dm-server | null | null | open | Resolving workspace dependencies for Virgo in Eclipse
===
I'm looking to get started with Eclipse Virgo, so I grabbed the required plugins for Eclipse based on the [Programmer Guide]().
Next, I started two new projects in my Eclipse workspace, both configured as Virgo bundles (call these A and B). Then, I created a new class `com.foo.Bar` in bundle B. I modified the Manifest of bundle B to export `com.foo`, saved. Last, I imported `com.foo` in bundle A.
Bundle A's manifest has an error:
> Import-Package: com.foo [0.0.0, oo) could not be resolved
What do I need to do to configure Eclipse to resolve dependencies using the projects in my workspace?
I've already tried adding bundle B to the build path of bundle A, but this makes no difference. | 0 |
56,090 | 09/11/2008 09:02:49 | 1,612 | 08/17/2008 14:52:15 | 409 | 31 | Subversion merge history visualisation | Are there any utilities out there which can draw pictures of the merge history of a subversion repo - we always commit merges with a (fairly) consistent log message, and it would be handy to be able to automatically extract this info into a single picture that shows what branches occurred when, and what the state of merges is.
I'm just interested in an informational tool, not something to help with actually performing merges. | svn | merge | visualization | null | null | null | open | Subversion merge history visualisation
===
Are there any utilities out there which can draw pictures of the merge history of a subversion repo - we always commit merges with a (fairly) consistent log message, and it would be handy to be able to automatically extract this info into a single picture that shows what branches occurred when, and what the state of merges is.
I'm just interested in an informational tool, not something to help with actually performing merges. | 0 |
1,434,760 | 09/16/2009 18:40:58 | 142,122 | 07/21/2009 15:49:26 | 79 | 2 | One line if statements | I was recently involved in an argument with a coworker involving one line if statements and wanted to see what stackoverflow thought.
Do you feel that the statement should be written as:
if(condition)
{
statement = new assignment;
}
OR
if(condition)
statement=new assignment;
please provide a good reason for your decision. | if-statement | null | null | null | null | 09/16/2009 18:50:28 | not constructive | One line if statements
===
I was recently involved in an argument with a coworker involving one line if statements and wanted to see what stackoverflow thought.
Do you feel that the statement should be written as:
if(condition)
{
statement = new assignment;
}
OR
if(condition)
statement=new assignment;
please provide a good reason for your decision. | 4 |
10,323,645 | 04/25/2012 20:56:30 | 1,357,195 | 04/25/2012 20:41:11 | 1 | 0 | how to pass a params into a controller action in ruby on rails | i would appreciate if someone could help me on ruby on rails.
can i pass a params[:something] onto a controller?
in my index view i have
<button value="1" name="most_recent" type="submit" class="btn" data-toggle="button">Most Recent</button>
<button value="1" name="score" type="submit" class="btn" data-toggle="button">Score</button>
essentially if a button is pressed, the value goes into my index controller and i can receive it by doing
params[:score]
to see if the score button was pressed. however, also on my index template i have
<%= form_tag search_photos_path, :method => 'get' do %>
<p>
<%= text_field_tag :search, params[:search],
:class => "input-medium search-query expand" %>
<%= submit_tag 'Search', :name => nil, :class => "btn" %>
</p>
<% end %>
when a user clicks search, it goes to my search action. is there a way to send what params[:score] is? if it has been clicked, i want to be able to know it has been clicked. i tried doing params[:search] in my search action, but it returns nil even though i clicked on the search button.
thank you | ruby-on-rails | controller | params | null | null | null | open | how to pass a params into a controller action in ruby on rails
===
i would appreciate if someone could help me on ruby on rails.
can i pass a params[:something] onto a controller?
in my index view i have
<button value="1" name="most_recent" type="submit" class="btn" data-toggle="button">Most Recent</button>
<button value="1" name="score" type="submit" class="btn" data-toggle="button">Score</button>
essentially if a button is pressed, the value goes into my index controller and i can receive it by doing
params[:score]
to see if the score button was pressed. however, also on my index template i have
<%= form_tag search_photos_path, :method => 'get' do %>
<p>
<%= text_field_tag :search, params[:search],
:class => "input-medium search-query expand" %>
<%= submit_tag 'Search', :name => nil, :class => "btn" %>
</p>
<% end %>
when a user clicks search, it goes to my search action. is there a way to send what params[:score] is? if it has been clicked, i want to be able to know it has been clicked. i tried doing params[:search] in my search action, but it returns nil even though i clicked on the search button.
thank you | 0 |
6,719,757 | 07/16/2011 19:37:10 | 848,068 | 07/16/2011 19:27:34 | 1 | 0 | is learning the win32 API and MFC worthwhile for a Qt developer? | I am an expert Qt Developer and i know most of its classes and functions. But i think it is at a high level of abstraction. so i decided to learn win32 APIs and MFC, is my decision good or bad ? and why ?
thanks | winapi | qt | mfc | null | null | 07/16/2011 23:54:50 | not constructive | is learning the win32 API and MFC worthwhile for a Qt developer?
===
I am an expert Qt Developer and i know most of its classes and functions. But i think it is at a high level of abstraction. so i decided to learn win32 APIs and MFC, is my decision good or bad ? and why ?
thanks | 4 |
2,231,583 | 02/09/2010 18:48:01 | 247,230 | 01/09/2010 20:51:29 | 68 | 1 | Data driven UITableViewController implementations? | I have a UITableViewController which is starting to get a bit crazy with all the switch statements for each UITableView delegate.
Does anyone have any suggestions or examples of more of a data driven implementation for a UITableViewController? I'm thinking some type of data structure which would hold references of where to go to get cells for certain section/rows, where to get the section names, etc.
I think the More iPhone Development book describes something like this, just wanted to poll the community and see if anyone had some lessons learned on their own implementation. | iphone | uitableviewcontroller | uitableview | null | null | null | open | Data driven UITableViewController implementations?
===
I have a UITableViewController which is starting to get a bit crazy with all the switch statements for each UITableView delegate.
Does anyone have any suggestions or examples of more of a data driven implementation for a UITableViewController? I'm thinking some type of data structure which would hold references of where to go to get cells for certain section/rows, where to get the section names, etc.
I think the More iPhone Development book describes something like this, just wanted to poll the community and see if anyone had some lessons learned on their own implementation. | 0 |
11,502,392 | 07/16/2012 10:23:05 | 861,818 | 07/25/2011 15:01:32 | 36 | 4 | android ics: date/time is restored to 1970/XX/XX after phone encryption, is this an issue? | since Android ICS supports phone encryption, I try this feature today, but I found that after performing phone encryption, system date/time is restored to 1970/XX/XX, is this an issue?
if not, I don't think this is an user friendly design.
if yes, why does it restore to 1970s? I just encrypt my phone not factory reset?
| android | encryption | ice-cream-sandwich | null | null | 07/18/2012 02:34:07 | off topic | android ics: date/time is restored to 1970/XX/XX after phone encryption, is this an issue?
===
since Android ICS supports phone encryption, I try this feature today, but I found that after performing phone encryption, system date/time is restored to 1970/XX/XX, is this an issue?
if not, I don't think this is an user friendly design.
if yes, why does it restore to 1970s? I just encrypt my phone not factory reset?
| 2 |
7,177,892 | 08/24/2011 15:15:25 | 608,491 | 02/08/2011 17:04:52 | 158 | 5 | Random key generator | does this code good ?
function randomLink($length) {
mt_srand(make_seed());
$possible = '0123456789' . 'abcdefghjiklmnopqrstuvwxyz' . 'ABCDEFGHIJKLMNOPQRSTUVWXYZ';
$str = "";
while (strlen($str) < $length) {
$str .= substr($possible, mt_rand(0, strlen($possible) - 1), 1);
}
$query = "SELECT tinylink FROM urls WHERE tinylink='$str'" ;
$result = $myDB->Execute($query) or die(GetDbError($myDB->ErrorMsg()));
$check_field = $result->Fields("tinylink");
if ($check_field == $str) {
randomLink($config['link_lenght'])
} else {
return $str;
}
}
In my opinion something will be wrong, because after one month vacation i'm totally forgot everything. It's my quick way/job "to do something". | php | sql | null | null | null | 08/24/2011 15:19:17 | off topic | Random key generator
===
does this code good ?
function randomLink($length) {
mt_srand(make_seed());
$possible = '0123456789' . 'abcdefghjiklmnopqrstuvwxyz' . 'ABCDEFGHIJKLMNOPQRSTUVWXYZ';
$str = "";
while (strlen($str) < $length) {
$str .= substr($possible, mt_rand(0, strlen($possible) - 1), 1);
}
$query = "SELECT tinylink FROM urls WHERE tinylink='$str'" ;
$result = $myDB->Execute($query) or die(GetDbError($myDB->ErrorMsg()));
$check_field = $result->Fields("tinylink");
if ($check_field == $str) {
randomLink($config['link_lenght'])
} else {
return $str;
}
}
In my opinion something will be wrong, because after one month vacation i'm totally forgot everything. It's my quick way/job "to do something". | 2 |
4,302,530 | 11/29/2010 09:50:14 | 523,716 | 11/29/2010 09:50:14 | 1 | 0 | Ruby on rails save data inside loop | how to save data inside loop in ruby on rails... i m trying to save data but only one record is saved. Please figure this out...?
Thanks in advance, | ruby-on-rails | null | null | null | null | 11/29/2010 16:38:28 | not a real question | Ruby on rails save data inside loop
===
how to save data inside loop in ruby on rails... i m trying to save data but only one record is saved. Please figure this out...?
Thanks in advance, | 1 |
9,011,338 | 01/25/2012 22:27:53 | 617,413 | 02/15/2011 08:14:43 | 328 | 3 | iOS: should my app only be released in local App Store? | I have an iOS application which I targeted for Danish users. The UI language is English or Danish, but the news content is Danish -- this is the main part of its functionality.
The first day the app was released, the app was downloaded about 80 times, but only 5% was users from the Danish App Store.
For fear of bad ratings, wouldn't it be reasonable to change the app only to be released in the Danish App Store? | ios | app-store | itunesconnect | null | null | 01/25/2012 22:44:37 | off topic | iOS: should my app only be released in local App Store?
===
I have an iOS application which I targeted for Danish users. The UI language is English or Danish, but the news content is Danish -- this is the main part of its functionality.
The first day the app was released, the app was downloaded about 80 times, but only 5% was users from the Danish App Store.
For fear of bad ratings, wouldn't it be reasonable to change the app only to be released in the Danish App Store? | 2 |
7,736,676 | 10/12/2011 07:35:07 | 983,476 | 10/07/2011 06:29:53 | 34 | 5 | C# code for open/close drawer and printing the receipt at the same time? | Does any body know how to create a C# application that can open a drawer connected to the computer and print receipt at same time? | c# | list | crystal-reports | slidingdrawer | thermal-printer | 10/12/2011 15:17:48 | not a real question | C# code for open/close drawer and printing the receipt at the same time?
===
Does any body know how to create a C# application that can open a drawer connected to the computer and print receipt at same time? | 1 |
3,937,855 | 10/14/2010 21:47:13 | 353,009 | 04/07/2010 21:03:24 | 6 | 0 | Determine BlackBerry width including vertical scroll area | I need to detect the height of a web page displayed on a BlackBerry and I've tried the following.
height, window.innerHeight, and screen.availHeight
My BB 9700 simulator returns values of 304, 327, and 360 respectively. The closest "correct" value is 360 since that's the actual height of the displayed page.
However, the site has a vertical scroll and the actual height is closer to 600 or so. Is there a way I can detect the height that *includes* the scrollable region that isn't seen unless you scroll?
Thanks! | web-applications | blackberry | null | null | null | null | open | Determine BlackBerry width including vertical scroll area
===
I need to detect the height of a web page displayed on a BlackBerry and I've tried the following.
height, window.innerHeight, and screen.availHeight
My BB 9700 simulator returns values of 304, 327, and 360 respectively. The closest "correct" value is 360 since that's the actual height of the displayed page.
However, the site has a vertical scroll and the actual height is closer to 600 or so. Is there a way I can detect the height that *includes* the scrollable region that isn't seen unless you scroll?
Thanks! | 0 |
2,999,109 | 06/08/2010 16:08:02 | 361,562 | 06/08/2010 16:08:02 | 1 | 0 | How does one tell JRuby to reload/refresh a Java Class? | I am scripting Java using JRuby. By using JRebel, I can the automatically reload changed Java classes into the JRuby JVM without restarting. When I add a new Java method JRebel automatically reloads the class. My problem is that I cannot call this new method directly. Can I ask JRuby to refresh its method cache for the newly reloaded Java class? My only workaround is to call the new method reflectively using java_send.
Example:
step 1. Start irb session and java_import a Java class (say Person).
step 2. Add a getName method to Person and compile.
step 3. Create an instance of Person (p = Person.new). JRebel will show that it reloaded the java class.
step 4. Calling p.get_name results in a NoMethodError but p.java_send('getName') invokes the newly implemented getName method
| jruby | null | null | null | null | null | open | How does one tell JRuby to reload/refresh a Java Class?
===
I am scripting Java using JRuby. By using JRebel, I can the automatically reload changed Java classes into the JRuby JVM without restarting. When I add a new Java method JRebel automatically reloads the class. My problem is that I cannot call this new method directly. Can I ask JRuby to refresh its method cache for the newly reloaded Java class? My only workaround is to call the new method reflectively using java_send.
Example:
step 1. Start irb session and java_import a Java class (say Person).
step 2. Add a getName method to Person and compile.
step 3. Create an instance of Person (p = Person.new). JRebel will show that it reloaded the java class.
step 4. Calling p.get_name results in a NoMethodError but p.java_send('getName') invokes the newly implemented getName method
| 0 |
7,087,834 | 08/17/2011 04:10:52 | 318,403 | 03/31/2010 06:40:57 | 66 | 2 | Adwhirl Ads in Ipad | Hi I am Developing a universal App.i am showing adWhirl Ads on Iphone.its Working Fine<br>
Now i want to display the Ads in Ipad.i have small doubts regarding this...<br>
1)Is there any Configuration changes in Adwhirl For Ipad
2)Can I use Same Adwhirl Api For Iphone And Ipad
3)How can i Change Frames specific to ipad
Can Any one help me to get out of this | ipad | adwhirl | null | null | null | null | open | Adwhirl Ads in Ipad
===
Hi I am Developing a universal App.i am showing adWhirl Ads on Iphone.its Working Fine<br>
Now i want to display the Ads in Ipad.i have small doubts regarding this...<br>
1)Is there any Configuration changes in Adwhirl For Ipad
2)Can I use Same Adwhirl Api For Iphone And Ipad
3)How can i Change Frames specific to ipad
Can Any one help me to get out of this | 0 |
7,511,008 | 09/22/2011 07:19:30 | 757,507 | 05/17/2011 14:05:57 | 1 | 0 | Don't understand the output of this C program | Here's the code:
#include <stdio.h>
int main (void)
{
int value[10];
int index;
value[0] = 197;
value[2] = -100;
value[5] = 350;
value[3] = value[0] + value[5];
value[9] = value[5] / 10;
--value[2];
for(index = 0; index < 10; ++index)
printf("value[%i] = %i\n", index, value[index]);
return 0;
}
Here's the output when compile:
value[0] = 197
value[1] = 0
value[2] = -101
value[3] = 547
value[4] = 0
value[5] = 350
value[6] = 0
value[7] = 0
value[8] = 1784505816
value[9] = 35
I don't understand why value[8] returns 1784505816?
Isn't value[8] supposed be = value[6] = value[7] = 0? By the way, I compile the code via gcc under Mac OS X Lion. | c | null | null | null | null | null | open | Don't understand the output of this C program
===
Here's the code:
#include <stdio.h>
int main (void)
{
int value[10];
int index;
value[0] = 197;
value[2] = -100;
value[5] = 350;
value[3] = value[0] + value[5];
value[9] = value[5] / 10;
--value[2];
for(index = 0; index < 10; ++index)
printf("value[%i] = %i\n", index, value[index]);
return 0;
}
Here's the output when compile:
value[0] = 197
value[1] = 0
value[2] = -101
value[3] = 547
value[4] = 0
value[5] = 350
value[6] = 0
value[7] = 0
value[8] = 1784505816
value[9] = 35
I don't understand why value[8] returns 1784505816?
Isn't value[8] supposed be = value[6] = value[7] = 0? By the way, I compile the code via gcc under Mac OS X Lion. | 0 |
1,904,745 | 12/15/2009 01:43:42 | 108,869 | 04/27/2009 03:23:36 | 633 | 10 | advantage of using applicationcontext.getbean vs @configurable | what is the advantage of using **@configurable** compared to on **bean that not managed by bean doing di** by **applicationcontext.getbean**? any anyone list pro and cons?
| java | spring | dependency-injection | aspectj | null | 08/18/2011 10:56:50 | not constructive | advantage of using applicationcontext.getbean vs @configurable
===
what is the advantage of using **@configurable** compared to on **bean that not managed by bean doing di** by **applicationcontext.getbean**? any anyone list pro and cons?
| 4 |
10,442,531 | 05/04/2012 04:01:52 | 906,436 | 08/22/2011 18:27:09 | 353 | 2 | PHP: Validating URL with Curl | $fileSource = "http://google.com";
$ch = curl_init($fileSource);
curl_setopt($ch, CURLOPT_NOBODY, true);
curl_exec($ch);
$retcode = curl_getinfo($ch, CURLINFO_HTTP_CODE);
if ($retcode != 200) {
$error .= "The source specified is not a valid URL.";
}
curl_close($ch);
Here's my issue. When I use the above and set `$fileSource = "http://google.com";` it does not work, whereas if I set it to `$fileSource = "http://www.google.com/";` it works.
What's the issue? | php | curl | null | null | null | null | open | PHP: Validating URL with Curl
===
$fileSource = "http://google.com";
$ch = curl_init($fileSource);
curl_setopt($ch, CURLOPT_NOBODY, true);
curl_exec($ch);
$retcode = curl_getinfo($ch, CURLINFO_HTTP_CODE);
if ($retcode != 200) {
$error .= "The source specified is not a valid URL.";
}
curl_close($ch);
Here's my issue. When I use the above and set `$fileSource = "http://google.com";` it does not work, whereas if I set it to `$fileSource = "http://www.google.com/";` it works.
What's the issue? | 0 |
5,455,555 | 03/28/2011 06:51:38 | 398,863 | 07/22/2010 08:35:29 | 1 | 0 | twitter4j : How to get tweet text with anchor to hash tag and urls | I am using twitter4j for searching and displaying tweets. Here is the code snippet
Query query = new Query(queryString);
QueryResult result = twitter.search(query);
for (Tweet tweet : result.getTweets()) {
System.out.pritnln(tweet.getFromUser() + ":" + tweet.getText());
}
Here tweet.getText() returns plain text without anchor tag (plain text not html) even if it has hashtag and url to some website. How can I get twitter text with anchor tag as you see in twitter search result on twitter?
| twitter | twitter4j | null | null | null | null | open | twitter4j : How to get tweet text with anchor to hash tag and urls
===
I am using twitter4j for searching and displaying tweets. Here is the code snippet
Query query = new Query(queryString);
QueryResult result = twitter.search(query);
for (Tweet tweet : result.getTweets()) {
System.out.pritnln(tweet.getFromUser() + ":" + tweet.getText());
}
Here tweet.getText() returns plain text without anchor tag (plain text not html) even if it has hashtag and url to some website. How can I get twitter text with anchor tag as you see in twitter search result on twitter?
| 0 |
8,799,524 | 01/10/2012 06:41:11 | 1,140,243 | 01/10/2012 06:27:07 | 1 | 0 | iPhone app with libcaldav library | I am doing an iPhone app, which includes a libcaldav library( http://sourceforge.net/projects/libcaldav/ ).
The library used C language to write. But there are so many errors (I solved a lot). Now, there are new errors as follows coming from the inttypes.h file. Can anyone help me ?
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/CoreFoundation.framework/Headers/CoreFoundation.h:30:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:6:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIAccelerometer.h:8:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.h:9:
In file included from /Users/Frankie/Desktop/ppp/ppp/ppp-Prefix.pch:12:
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:260:10: **error: unknown type name 'intmax_t' [1]**
extern intmax_t imaxabs(intmax_t j);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:260:27: **error: unknown type name 'intmax_t' [1]**
extern intmax_t imaxabs(intmax_t j);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:264:9: **error: unknown type name 'intmax_t' [1]**
intmax_t quot;
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:265:9: **error: unknown type name 'intmax_t' [1]**
intmax_t rem;
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:268:28: **error: unknown type name 'intmax_t' [1]**
extern imaxdiv_t imaxdiv(intmax_t numer, intmax_t denom);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:268:44: **error: unknown type name 'intmax_t' [1]**
extern imaxdiv_t imaxdiv(intmax_t numer, intmax_t denom);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:271:10: **error: unknown type name 'intmax_t' [1]**
extern intmax_t strtoimax(const char * restrict nptr, char ** restrict endptr, int base);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:272:10: **error: unknown type name 'uintmax_t'; did you mean 'uintptr_t'? [3]**
extern uintmax_t strtoumax(const char * restrict nptr, char ** restrict endptr, int base);
^~~~~~~~~
uintptr_t
fix-it:"/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h":{272:10-272:19}:"uintptr_t"
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/i386/types.h:109:24: note: 'uintptr_t' declared here [3]
typedef unsigned long uintptr_t;
^
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/CoreFoundation.framework/Headers/CoreFoundation.h:30:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:6:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIAccelerometer.h:8:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.h:9:
In file included from /Users/Frankie/Desktop/ppp/ppp/ppp-Prefix.pch:12:
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:282:10: error: unknown type name 'intmax_t' [1]
extern intmax_t wcstoimax(const wchar_t * restrict nptr, wchar_t ** restrict endptr, int base);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:283:10: error: unknown type name 'uintmax_t'; did you mean 'uintptr_t'? [3]
extern uintmax_t wcstoumax(const wchar_t * restrict nptr, wchar_t ** restrict endptr, int base);
^~~~~~~~~
uintptr_t
fix-it:"/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h":{283:10-283:19}:"uintptr_t"
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/i386/types.h:109:24: note: 'uintptr_t' declared here [3]
typedef unsigned long uintptr_t;
^
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/OSByteOrder.h:43:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/CoreFoundation.framework/Headers/CFByteOrder.h:10:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/CoreFoundation.framework/Headers/CoreFoundation.h:43:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:6:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIAccelerometer.h:8:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.h:9:
In file included from /Users/Frankie/Desktop/ppp/ppp/ppp-Prefix.pch:12:
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:42:1: error: unknown type name 'uint16_t' [1]
uint16_t
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:48:5: error: use of undeclared identifier 'uint16_t' [3]
uint16_t result;
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:50:5: error: use of undeclared identifier 'result' [3]
result = *(volatile uint16_t *)((uintptr_t)base + byteOffset);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:50:25: error: unknown type name 'uint16_t' [1]
result = *(volatile uint16_t *)((uintptr_t)base + byteOffset);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:51:25: error: use of undeclared identifier 'result' [3]
return _OSSwapInt16(result);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:55:1: error: unknown type name 'uint32_t' [1]
uint32_t
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:61:5: error: use of undeclared identifier 'uint32_t' [3]
uint32_t result;
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:63:5: error: use of undeclared identifier 'result' [3]
result = *(volatile uint32_t *)((uintptr_t)base + byteOffset);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:63:25: error: unknown type name 'uint32_t' [1]
result = *(volatile uint32_t *)((uintptr_t)base + byteOffset);
^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated. | iphone | objective-c | c | caldav | null | 01/10/2012 14:35:14 | not a real question | iPhone app with libcaldav library
===
I am doing an iPhone app, which includes a libcaldav library( http://sourceforge.net/projects/libcaldav/ ).
The library used C language to write. But there are so many errors (I solved a lot). Now, there are new errors as follows coming from the inttypes.h file. Can anyone help me ?
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/CoreFoundation.framework/Headers/CoreFoundation.h:30:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:6:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIAccelerometer.h:8:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.h:9:
In file included from /Users/Frankie/Desktop/ppp/ppp/ppp-Prefix.pch:12:
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:260:10: **error: unknown type name 'intmax_t' [1]**
extern intmax_t imaxabs(intmax_t j);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:260:27: **error: unknown type name 'intmax_t' [1]**
extern intmax_t imaxabs(intmax_t j);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:264:9: **error: unknown type name 'intmax_t' [1]**
intmax_t quot;
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:265:9: **error: unknown type name 'intmax_t' [1]**
intmax_t rem;
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:268:28: **error: unknown type name 'intmax_t' [1]**
extern imaxdiv_t imaxdiv(intmax_t numer, intmax_t denom);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:268:44: **error: unknown type name 'intmax_t' [1]**
extern imaxdiv_t imaxdiv(intmax_t numer, intmax_t denom);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:271:10: **error: unknown type name 'intmax_t' [1]**
extern intmax_t strtoimax(const char * restrict nptr, char ** restrict endptr, int base);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:272:10: **error: unknown type name 'uintmax_t'; did you mean 'uintptr_t'? [3]**
extern uintmax_t strtoumax(const char * restrict nptr, char ** restrict endptr, int base);
^~~~~~~~~
uintptr_t
fix-it:"/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h":{272:10-272:19}:"uintptr_t"
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/i386/types.h:109:24: note: 'uintptr_t' declared here [3]
typedef unsigned long uintptr_t;
^
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/CoreFoundation.framework/Headers/CoreFoundation.h:30:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:6:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIAccelerometer.h:8:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.h:9:
In file included from /Users/Frankie/Desktop/ppp/ppp/ppp-Prefix.pch:12:
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:282:10: error: unknown type name 'intmax_t' [1]
extern intmax_t wcstoimax(const wchar_t * restrict nptr, wchar_t ** restrict endptr, int base);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h:283:10: error: unknown type name 'uintmax_t'; did you mean 'uintptr_t'? [3]
extern uintmax_t wcstoumax(const wchar_t * restrict nptr, wchar_t ** restrict endptr, int base);
^~~~~~~~~
uintptr_t
fix-it:"/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/inttypes.h":{283:10-283:19}:"uintptr_t"
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/i386/types.h:109:24: note: 'uintptr_t' declared here [3]
typedef unsigned long uintptr_t;
^
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/OSByteOrder.h:43:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/CoreFoundation.framework/Headers/CFByteOrder.h:10:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/CoreFoundation.framework/Headers/CoreFoundation.h:43:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:6:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIAccelerometer.h:8:
In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.h:9:
In file included from /Users/Frankie/Desktop/ppp/ppp/ppp-Prefix.pch:12:
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:42:1: error: unknown type name 'uint16_t' [1]
uint16_t
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:48:5: error: use of undeclared identifier 'uint16_t' [3]
uint16_t result;
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:50:5: error: use of undeclared identifier 'result' [3]
result = *(volatile uint16_t *)((uintptr_t)base + byteOffset);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:50:25: error: unknown type name 'uint16_t' [1]
result = *(volatile uint16_t *)((uintptr_t)base + byteOffset);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:51:25: error: use of undeclared identifier 'result' [3]
return _OSSwapInt16(result);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:55:1: error: unknown type name 'uint32_t' [1]
uint32_t
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:61:5: error: use of undeclared identifier 'uint32_t' [3]
uint32_t result;
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:63:5: error: use of undeclared identifier 'result' [3]
result = *(volatile uint32_t *)((uintptr_t)base + byteOffset);
^
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/usr/include/libkern/i386/OSByteOrder.h:63:25: error: unknown type name 'uint32_t' [1]
result = *(volatile uint32_t *)((uintptr_t)base + byteOffset);
^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated. | 1 |
7,643,050 | 10/04/2011 03:43:25 | 487,171 | 10/26/2010 04:04:54 | 23 | 2 | Which Java based workflow engine should I use? | I am looking for a off the shelf workflow engine to be used in my Java based web application. Following are my initial requirements -
1. The engine should have a nice UI to create/manage workflows.
2. Should work with Oracle database
3. Provides java api or web service api to interact with workflow from my application so that I can build logic on the workflow.
4. Ability to define custom business rules.
As of now I am looking at JBoss JBPM and Drools together. Do let me know if you have experience of this or other contenders which I should consider for evaluation? | java | workflow | null | null | null | 10/06/2011 07:15:46 | not constructive | Which Java based workflow engine should I use?
===
I am looking for a off the shelf workflow engine to be used in my Java based web application. Following are my initial requirements -
1. The engine should have a nice UI to create/manage workflows.
2. Should work with Oracle database
3. Provides java api or web service api to interact with workflow from my application so that I can build logic on the workflow.
4. Ability to define custom business rules.
As of now I am looking at JBoss JBPM and Drools together. Do let me know if you have experience of this or other contenders which I should consider for evaluation? | 4 |
10,899,559 | 06/05/2012 14:50:28 | 1,145,976 | 01/12/2012 16:40:23 | 28 | 0 | pass by reference by inner function in C | here's my code...
void B(int *count)
{
do{
*count = *count + 1;
while(condition);
}
void A(int *count)
{
*count = 0;
calculating(count);
}
int main()
{
int count;
A(&count);
return 0;
}
I checked [websites][1] for pass by reference in c, but it doesn't seem to work on this ...and I am really confused about pointer pass by reference, such as
void C(int **a)
{
*a=*a+1;
}
Please recommend a more detailed tutorial/book about pointers
(including function pointer) in C, thanks in advance!
[1]: http://publib.boulder.ibm.com/infocenter/lnxpcomp/v8v101/index.jsp?topic=/com.ibm.xlcpp8l.doc/language/ref/cplr233.htm | c | pointers | null | null | null | 06/05/2012 14:53:11 | not a real question | pass by reference by inner function in C
===
here's my code...
void B(int *count)
{
do{
*count = *count + 1;
while(condition);
}
void A(int *count)
{
*count = 0;
calculating(count);
}
int main()
{
int count;
A(&count);
return 0;
}
I checked [websites][1] for pass by reference in c, but it doesn't seem to work on this ...and I am really confused about pointer pass by reference, such as
void C(int **a)
{
*a=*a+1;
}
Please recommend a more detailed tutorial/book about pointers
(including function pointer) in C, thanks in advance!
[1]: http://publib.boulder.ibm.com/infocenter/lnxpcomp/v8v101/index.jsp?topic=/com.ibm.xlcpp8l.doc/language/ref/cplr233.htm | 1 |
10,966,429 | 06/10/2012 04:49:36 | 1,446,940 | 06/10/2012 04:15:27 | 1 | 0 | Problems with navigablestrings and unicode in BeautifulSoup | I am having some problems with navigablestrings and unicode in BeautifulSoup (python).
Basically, I am parsing four results pages from youtube, and putting the top result's extension (end of the url after youtube.com/watch?=) into a list.
I then loop the list in two other functions, on one, it throws this error: `TypeError: 'NavigableString' object is not callable`. However, the other one says `TypeError: 'unicode' object is not callable`. Both are using the same exact string.
What am I doing wrong here? I know that my parsing code is probably not perfect, I'm using both BeautifulSoup and regex. In the past whenever I get NavigableString errors, I have just thrown in a ".encode('ascii', 'ignore') or simply str(), and that has seemed to work. Any help would be appreciated!
for url in urls:
response = urllib2.urlopen(url)
html = response.read()
soup = BeautifulSoup(html)
link_data = soup.findAll("a", {"class":"yt-uix-tile-link result-item-translation-title"})[0]
ext = re.findall('href="/(.*)">', str(link_data))[0]
if isinstance(ext, str):
exts.append('http://www.youtube.com/'+ext.replace(' ',''))
and then:
for ext in exts:
description = description(ext)
embed = embed(ext) | python | beautifulsoup | null | null | null | null | open | Problems with navigablestrings and unicode in BeautifulSoup
===
I am having some problems with navigablestrings and unicode in BeautifulSoup (python).
Basically, I am parsing four results pages from youtube, and putting the top result's extension (end of the url after youtube.com/watch?=) into a list.
I then loop the list in two other functions, on one, it throws this error: `TypeError: 'NavigableString' object is not callable`. However, the other one says `TypeError: 'unicode' object is not callable`. Both are using the same exact string.
What am I doing wrong here? I know that my parsing code is probably not perfect, I'm using both BeautifulSoup and regex. In the past whenever I get NavigableString errors, I have just thrown in a ".encode('ascii', 'ignore') or simply str(), and that has seemed to work. Any help would be appreciated!
for url in urls:
response = urllib2.urlopen(url)
html = response.read()
soup = BeautifulSoup(html)
link_data = soup.findAll("a", {"class":"yt-uix-tile-link result-item-translation-title"})[0]
ext = re.findall('href="/(.*)">', str(link_data))[0]
if isinstance(ext, str):
exts.append('http://www.youtube.com/'+ext.replace(' ',''))
and then:
for ext in exts:
description = description(ext)
embed = embed(ext) | 0 |
8,565,858 | 12/19/2011 18:42:14 | 488,238 | 10/27/2010 00:20:58 | 36 | 1 | consuming web services in IOS app and caching | I am working on an app that consumes web services for authentication. Once authenticated I request several other methods via soap calls to retrieve this data. All of this is working fine with the exception of logging in the second time.
The first time the app is run I can login with sending user/pass from my textfields. When logging out of the app I load the login screen again. This time I put in the same username but instead of the correct password, I enter in a bogus password and I am still able to login. I have created a series of NSLog statements to track down whats going on and I do see the new user/pass variables being sent but its as if this connection has been cached and it doesn't matter what I'm sending in the password field this time.
Are there tmp files stored in the apps sandbox that could be deleted to see if this would correct the problem? I think things are being cached and at this point I am beginning to look server side and/or to local tmp files.
I also tried sending changing up my soap header to include no-cache directives but I need to do more research on that.
thanks in advance! | iphone | objective-c | null | null | null | null | open | consuming web services in IOS app and caching
===
I am working on an app that consumes web services for authentication. Once authenticated I request several other methods via soap calls to retrieve this data. All of this is working fine with the exception of logging in the second time.
The first time the app is run I can login with sending user/pass from my textfields. When logging out of the app I load the login screen again. This time I put in the same username but instead of the correct password, I enter in a bogus password and I am still able to login. I have created a series of NSLog statements to track down whats going on and I do see the new user/pass variables being sent but its as if this connection has been cached and it doesn't matter what I'm sending in the password field this time.
Are there tmp files stored in the apps sandbox that could be deleted to see if this would correct the problem? I think things are being cached and at this point I am beginning to look server side and/or to local tmp files.
I also tried sending changing up my soap header to include no-cache directives but I need to do more research on that.
thanks in advance! | 0 |
6,010,908 | 05/15/2011 20:05:34 | 648,723 | 11/23/2010 20:29:27 | 300 | 6 | How to create M V C for data that have relation | Consider this Scenario:
I want to build an MVC application for Northwind Database.I want to have a view that list some orders and I want to crate links for CustomerID and EmployeeID and a details link for [OrderDetails] that when user clicks any of this links related data will appear in same page.Ok my problem is how to decouple this data that have relation into views and controllers that show related data in a page but controllers responsible for a part of information and how config routing for this sample?
thanks a lot | asp.net-mvc | mvc | asp.net-mvc-2 | asp.net-mvc-3 | asp.net-mvc-routing | null | open | How to create M V C for data that have relation
===
Consider this Scenario:
I want to build an MVC application for Northwind Database.I want to have a view that list some orders and I want to crate links for CustomerID and EmployeeID and a details link for [OrderDetails] that when user clicks any of this links related data will appear in same page.Ok my problem is how to decouple this data that have relation into views and controllers that show related data in a page but controllers responsible for a part of information and how config routing for this sample?
thanks a lot | 0 |
3,373,622 | 07/30/2010 16:47:12 | 324,922 | 04/24/2010 13:27:12 | 13 | 0 | view internet page | Can someone describe in details what is the path from the moment I type an address on the browser box to the moment I see the internet page. | browser | internet | null | null | null | 07/30/2010 16:51:05 | not a real question | view internet page
===
Can someone describe in details what is the path from the moment I type an address on the browser box to the moment I see the internet page. | 1 |
11,721,331 | 07/30/2012 12:13:55 | 1,553,570 | 07/26/2012 05:42:26 | 1 | 1 | I want to compare two values in MVC 4 | I want to compare two values in MVC 4,in which are stored in Database. Out of which one is of type 'Long' and other is 'String'.So how can I compare in between those in MVC 4? | knowledge-management | null | null | null | null | 07/31/2012 07:27:21 | not a real question | I want to compare two values in MVC 4
===
I want to compare two values in MVC 4,in which are stored in Database. Out of which one is of type 'Long' and other is 'String'.So how can I compare in between those in MVC 4? | 1 |
6,899,583 | 08/01/2011 14:04:27 | 705,385 | 04/13/2011 06:15:52 | 9 | 0 | Sencha Touch web Mobile application development | recently i switched my platform to blackberry core application development to sencha touch web mobile application development.As i am totally blank with this framework..so pls help me regarding this. as ide, plugins, web-server or browser whatever are the requirements for the develpment.
1 thing more i want to know that....as i heard smwhere it is a cross platform framework,,,
so pls suggest,,the initial...steps of development..with both aspect as android and iphone..
Thanks in advance... | android | sencha-touch | null | null | null | 08/07/2011 08:48:10 | not a real question | Sencha Touch web Mobile application development
===
recently i switched my platform to blackberry core application development to sencha touch web mobile application development.As i am totally blank with this framework..so pls help me regarding this. as ide, plugins, web-server or browser whatever are the requirements for the develpment.
1 thing more i want to know that....as i heard smwhere it is a cross platform framework,,,
so pls suggest,,the initial...steps of development..with both aspect as android and iphone..
Thanks in advance... | 1 |
3,105,645 | 06/23/2010 21:21:58 | 289,666 | 03/09/2010 13:00:04 | 1,293 | 34 | Google Maps API V3 - need help with multiple markers | I'm pretty new to google maps so please be patient!
My code was working fine untill i tried to add multiple markers, would really appreciate it if anyone could glance at it and see if i'm missing something...
<script type="text/javascript">
$(function() {
var map_markers = [ [ [52.951946], [1.018124] ], [ [52.955311], [0.987997] ] ];
var options = {
zoom: 13,
center: latlng,
mapTypeControl: false,
mapTypeId: google.maps.MapTypeId.ROADMAP
};
var map = new google.maps.Map(document.getElementById('map_canvas'), options);
//markers
for (var i = 0; i < map_markers.length; i++) {
var m = map_markers[i];
var myLatLng = new google.maps.LatLng(m[0], m[1]);
var marker = new google.maps.Marker({
position: myLatLng,
map: map
});
}
})
</script>
| javascript | google-maps | google-maps-api-3 | null | null | null | open | Google Maps API V3 - need help with multiple markers
===
I'm pretty new to google maps so please be patient!
My code was working fine untill i tried to add multiple markers, would really appreciate it if anyone could glance at it and see if i'm missing something...
<script type="text/javascript">
$(function() {
var map_markers = [ [ [52.951946], [1.018124] ], [ [52.955311], [0.987997] ] ];
var options = {
zoom: 13,
center: latlng,
mapTypeControl: false,
mapTypeId: google.maps.MapTypeId.ROADMAP
};
var map = new google.maps.Map(document.getElementById('map_canvas'), options);
//markers
for (var i = 0; i < map_markers.length; i++) {
var m = map_markers[i];
var myLatLng = new google.maps.LatLng(m[0], m[1]);
var marker = new google.maps.Marker({
position: myLatLng,
map: map
});
}
})
</script>
| 0 |
2,864,362 | 05/19/2010 09:46:38 | 309,239 | 04/05/2010 14:04:10 | 220 | 10 | What is the best way to call MSWord from C++ | my question is: What is the best way to call MSWord from C++
I never did this before. I always used VB6 and the Word-COM-Library:
C:\Program Files\Microsoft Office\OfficeXX\MSWORD.olb
resp:
"Microsoft Word XX.0 Object Library"
how should I use/call Word from C++ (VS2010) ?
should I use .NET ? (C++CLI)
do you have a good step by step explanation?
regards and many thanks in advance
Oops | c++ | ms-word | null | null | null | null | open | What is the best way to call MSWord from C++
===
my question is: What is the best way to call MSWord from C++
I never did this before. I always used VB6 and the Word-COM-Library:
C:\Program Files\Microsoft Office\OfficeXX\MSWORD.olb
resp:
"Microsoft Word XX.0 Object Library"
how should I use/call Word from C++ (VS2010) ?
should I use .NET ? (C++CLI)
do you have a good step by step explanation?
regards and many thanks in advance
Oops | 0 |
2,368,569 | 03/03/2010 03:32:28 | 56,332 | 01/18/2009 02:03:52 | 51 | 1 | Is there a "Socket Connection Pool" of sorts for Java EE apps? | I'm writing a JAX-RS web service. It responds to client invocations by:
1. Retrieving some info from a database
2. Making a call to an external server
For 2) the server does not expose a web service interface (i.e. no WSDL interface or REST API). Instead, it uses a custom protocol over TCPIP. I'd like to make client calls from my JAX-RS resource *directly* to this server but I don't want to have to open a connection, authenticate, and close the connection for each call to my JAX-RS resource. Is there a way around this? In other words, is there something like a "socket connection pool" available to Java EE apps? Would I have to use something like an ESB? Or is there an alternative that I'm overlooking? | jax-rs | java-ee | connectionpool | resources | null | null | open | Is there a "Socket Connection Pool" of sorts for Java EE apps?
===
I'm writing a JAX-RS web service. It responds to client invocations by:
1. Retrieving some info from a database
2. Making a call to an external server
For 2) the server does not expose a web service interface (i.e. no WSDL interface or REST API). Instead, it uses a custom protocol over TCPIP. I'd like to make client calls from my JAX-RS resource *directly* to this server but I don't want to have to open a connection, authenticate, and close the connection for each call to my JAX-RS resource. Is there a way around this? In other words, is there something like a "socket connection pool" available to Java EE apps? Would I have to use something like an ESB? Or is there an alternative that I'm overlooking? | 0 |
1,367,324 | 09/02/2009 12:11:27 | 146,250 | 07/28/2009 08:42:42 | 159 | 12 | how to perform mathematical operations on Array of Arrays? | I have an array of array like below with all numeric values. I want to perform some mathematical operations with these values.
1) Add and print the values of each array elements.
e.g. sum $VAR1 = sum1
sum $VAR2 = sum2
2) Add all the values from each variables.
e.g. sum $VAR1 + $VAR2 +...+ $VARn = totalsum.
3) Finding percentage of each variable's total (sum1, sum2, etc) with the totalsum.
$VAR1 = [
'17071',
'16120',
'16292',
'upto n numbers'
];
$VAR2 = [
'1306',
'1399',
'1420',
'upto n numbers'
];
.
.
.
$VARn = [
'1835',
'1946',
'upto n numbers'
];
I have tried below code to perform addition of first array ref but its not giving me the correct values.
my $total = 0;
($total+=$_) for $input[0];
print $total;
| perl | arrays | null | null | null | null | open | how to perform mathematical operations on Array of Arrays?
===
I have an array of array like below with all numeric values. I want to perform some mathematical operations with these values.
1) Add and print the values of each array elements.
e.g. sum $VAR1 = sum1
sum $VAR2 = sum2
2) Add all the values from each variables.
e.g. sum $VAR1 + $VAR2 +...+ $VARn = totalsum.
3) Finding percentage of each variable's total (sum1, sum2, etc) with the totalsum.
$VAR1 = [
'17071',
'16120',
'16292',
'upto n numbers'
];
$VAR2 = [
'1306',
'1399',
'1420',
'upto n numbers'
];
.
.
.
$VARn = [
'1835',
'1946',
'upto n numbers'
];
I have tried below code to perform addition of first array ref but its not giving me the correct values.
my $total = 0;
($total+=$_) for $input[0];
print $total;
| 0 |
11,481,977 | 07/14/2012 07:44:03 | 1,450,561 | 06/12/2012 07:07:20 | 3 | 0 | what is augmented reality concept in android | I am new to android i need to do an app which is related to Augmented Reality but i am not at all aware of this concept ,can any one provide a good link for starters in this concept(with example provided) | android | null | null | null | null | 07/14/2012 08:35:33 | not a real question | what is augmented reality concept in android
===
I am new to android i need to do an app which is related to Augmented Reality but i am not at all aware of this concept ,can any one provide a good link for starters in this concept(with example provided) | 1 |
8,621,600 | 12/23/2011 23:38:44 | 331,000 | 05/02/2010 21:44:58 | 136 | 4 | Rails 3.1 compiled assets don't load | ruby 1.9.3p6 (2011-12-20 revision 34080) [x86_64-linux]
Rails 3.1.1
I tried to compile assets on VDS using "bundle exec rake assets:precompile RAILS_ENV=production --trace" command but it was "out of memory".
So i compiled assets on local machine and the pushed them to git repo and pulled on VDS.
But i still get error:
Started GET "/" for xxx.xx.xx.xx at 2011-12-24 02:19:50 +0300
Processing by HomeController#index as HTML
Rendered home/index.html.haml within layouts/application_home (0.1ms)
Completed 500 Internal Server Error in 2ms
ActionView::Template::Error (application.css isn't precompiled):
4: %meta{:content => "text/html; charset=utf-8", "http-equiv" => "Content-Type"}/
5: %title KUKARACHA
6: / CSS Files
7: = stylesheet_link_tag :application
8: -#%link{:href => "http://fonts.googleapis.com/css?family=Rokkitt:400,700", :rel => "stylesheet", :type => "text/css"}/
9: -#%link{:href => "http://fonts.googleapis.com/css?family=Droid+Sans:400,700", :rel => "stylesheet", :type => "text/css"}/
10: -#%link{:href => "http://fonts.googleapis.com/css?family=Droid+Serif:400,400italic", :rel => "stylesheet", :type => "text/css"}/
app/views/layouts/application_home.html.haml:7:in `_app_views_layouts_application_home_html_haml__4328675822247688096_183774960'
app/controllers/home_controller.rb:3:in `index'
How to overcome this error? | ruby-on-rails | ruby-on-rails-3.1 | asset-pipeline | null | null | 12/26/2011 20:02:42 | too localized | Rails 3.1 compiled assets don't load
===
ruby 1.9.3p6 (2011-12-20 revision 34080) [x86_64-linux]
Rails 3.1.1
I tried to compile assets on VDS using "bundle exec rake assets:precompile RAILS_ENV=production --trace" command but it was "out of memory".
So i compiled assets on local machine and the pushed them to git repo and pulled on VDS.
But i still get error:
Started GET "/" for xxx.xx.xx.xx at 2011-12-24 02:19:50 +0300
Processing by HomeController#index as HTML
Rendered home/index.html.haml within layouts/application_home (0.1ms)
Completed 500 Internal Server Error in 2ms
ActionView::Template::Error (application.css isn't precompiled):
4: %meta{:content => "text/html; charset=utf-8", "http-equiv" => "Content-Type"}/
5: %title KUKARACHA
6: / CSS Files
7: = stylesheet_link_tag :application
8: -#%link{:href => "http://fonts.googleapis.com/css?family=Rokkitt:400,700", :rel => "stylesheet", :type => "text/css"}/
9: -#%link{:href => "http://fonts.googleapis.com/css?family=Droid+Sans:400,700", :rel => "stylesheet", :type => "text/css"}/
10: -#%link{:href => "http://fonts.googleapis.com/css?family=Droid+Serif:400,400italic", :rel => "stylesheet", :type => "text/css"}/
app/views/layouts/application_home.html.haml:7:in `_app_views_layouts_application_home_html_haml__4328675822247688096_183774960'
app/controllers/home_controller.rb:3:in `index'
How to overcome this error? | 3 |
7,104,008 | 08/18/2011 07:45:49 | 569,466 | 01/09/2011 21:20:04 | 458 | 0 | i got error when i try to connect to my WebService | i got Error when i try to connect to my WebService (on Windows-XP)
this the error:
Server Error in '/WS_MyWebService' Application.
--------------------------------------------------------------------------------
Failed to access IIS metabase.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Web.Hosting.HostingEnvironmentException: Failed to access IIS metabase.
The process account used to run ASP.NET must have read access to the IIS metabase (e.g. IIS://servername/W3SVC). For information on modifying metabase permissions, please see http://support.microsoft.com/?kbid=267904.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[HostingEnvironmentException: Failed to access IIS metabase.]
System.Web.Configuration.MetabaseServerConfig.MapPathCaching(String siteID, VirtualPath path) +637
System.Web.Configuration.MetabaseServerConfig.System.Web.Configuration.IConfigMapPath2.MapPath(String siteID, VirtualPath vpath) +9
System.Web.Hosting.HostingEnvironment.MapPathActual(VirtualPath virtualPath, Boolean permitNull) +174
System.Web.Hosting.HostingEnvironment.MapPathInternal(VirtualPath virtualPath, Boolean permitNull) +51
System.Web.CachedPathData.GetConfigPathData(String configPath) +341
System.Web.CachedPathData.GetConfigPathData(String configPath) +234
System.Web.CachedPathData.GetApplicationPathData() +38
System.Web.CachedPathData.GetVirtualPathData(VirtualPath virtualPath, Boolean permitPathsOutsideApp) +8809743
System.Web.Configuration.RuntimeConfig.GetLKGRuntimeConfig(VirtualPath path) +117
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.3615; ASP.NET Version:2.0.50727.3618
thanks in advance | c# | web-services | null | null | null | 09/01/2011 11:20:34 | not a real question | i got error when i try to connect to my WebService
===
i got Error when i try to connect to my WebService (on Windows-XP)
this the error:
Server Error in '/WS_MyWebService' Application.
--------------------------------------------------------------------------------
Failed to access IIS metabase.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Web.Hosting.HostingEnvironmentException: Failed to access IIS metabase.
The process account used to run ASP.NET must have read access to the IIS metabase (e.g. IIS://servername/W3SVC). For information on modifying metabase permissions, please see http://support.microsoft.com/?kbid=267904.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[HostingEnvironmentException: Failed to access IIS metabase.]
System.Web.Configuration.MetabaseServerConfig.MapPathCaching(String siteID, VirtualPath path) +637
System.Web.Configuration.MetabaseServerConfig.System.Web.Configuration.IConfigMapPath2.MapPath(String siteID, VirtualPath vpath) +9
System.Web.Hosting.HostingEnvironment.MapPathActual(VirtualPath virtualPath, Boolean permitNull) +174
System.Web.Hosting.HostingEnvironment.MapPathInternal(VirtualPath virtualPath, Boolean permitNull) +51
System.Web.CachedPathData.GetConfigPathData(String configPath) +341
System.Web.CachedPathData.GetConfigPathData(String configPath) +234
System.Web.CachedPathData.GetApplicationPathData() +38
System.Web.CachedPathData.GetVirtualPathData(VirtualPath virtualPath, Boolean permitPathsOutsideApp) +8809743
System.Web.Configuration.RuntimeConfig.GetLKGRuntimeConfig(VirtualPath path) +117
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.3615; ASP.NET Version:2.0.50727.3618
thanks in advance | 1 |
3,915,662 | 10/12/2010 14:18:59 | 14,606 | 09/17/2008 01:27:48 | 27,934 | 1,263 | Help with iPhone sample code | I'm trying to build this iPhone sample:
http://trac.pjsip.org/repos/wiki/Getting-Started/iPhone
but I'm having trouble since I am new to both iPhone development and the Mac world. From the **Build Preparation** section, I've downloaded the source code, but step 2 here is to "set [my] config_site.h" to a particular value. Do I just double-click this file in Finder and change it there?
The next section (**Building PJSIP**) says to "Just run:" this:
$ cd /path/to/your/pjsip/dir
$ ./configure-iphone
$ make dep && make clean && make
but I don't have any idea what it means to "just run" something on a Mac. I also don't have any idea what path to use or how to get my downloaded source from Finder into a path location somewhere.
Help! | iphone | cocoa | ios | null | null | null | open | Help with iPhone sample code
===
I'm trying to build this iPhone sample:
http://trac.pjsip.org/repos/wiki/Getting-Started/iPhone
but I'm having trouble since I am new to both iPhone development and the Mac world. From the **Build Preparation** section, I've downloaded the source code, but step 2 here is to "set [my] config_site.h" to a particular value. Do I just double-click this file in Finder and change it there?
The next section (**Building PJSIP**) says to "Just run:" this:
$ cd /path/to/your/pjsip/dir
$ ./configure-iphone
$ make dep && make clean && make
but I don't have any idea what it means to "just run" something on a Mac. I also don't have any idea what path to use or how to get my downloaded source from Finder into a path location somewhere.
Help! | 0 |
4,773,534 | 01/23/2011 11:23:31 | 355,507 | 06/01/2010 14:20:21 | 542 | 31 | JQuery Address Plugin | I am using jQuery Address Plugin and I have the following code.
$.address.change(function(e) {
if (e.value == "/") {
$.address.value("/Login.html");
}
else {
$('#holder').load(e.value);
}
});
$('a').address(function() {
return $(this).attr('href').replace(/^#/, '');
});
The problem is that the **change** event always executes the **else** block whether the page is changed or not. It was working perfect before this day. | jquery | plugins | null | null | null | 11/26/2011 19:53:42 | too localized | JQuery Address Plugin
===
I am using jQuery Address Plugin and I have the following code.
$.address.change(function(e) {
if (e.value == "/") {
$.address.value("/Login.html");
}
else {
$('#holder').load(e.value);
}
});
$('a').address(function() {
return $(this).attr('href').replace(/^#/, '');
});
The problem is that the **change** event always executes the **else** block whether the page is changed or not. It was working perfect before this day. | 3 |
9,635,214 | 03/09/2012 13:58:58 | 1,246,717 | 03/03/2012 10:55:38 | 1 | 3 | VB.Net is Bitboard possible? | This is my first post :D<br>
My Questions are:<br>
1. Is is possible to implement bitboard in vb.net<br>
2. Any Tutorial/Reference to do bitboard in VB?<br>
i'm so confused at bitboard >.<
C# answers are acceptable cause it's not that hard to translate... | c# | .net | vb.net | null | null | null | open | VB.Net is Bitboard possible?
===
This is my first post :D<br>
My Questions are:<br>
1. Is is possible to implement bitboard in vb.net<br>
2. Any Tutorial/Reference to do bitboard in VB?<br>
i'm so confused at bitboard >.<
C# answers are acceptable cause it's not that hard to translate... | 0 |
2,233,876 | 02/10/2010 01:44:15 | 269,955 | 02/10/2010 01:44:15 | 1 | 0 | List of best books about software development process for non-developers (non technical business owners) | I am looking for a good book that explains software development to non developers. My goal is to educate business owners (non technical folks) on the software development process, its hurdles, problems, methods etc. The book should be written from a non programmer's perspective. I found in my software development career that if the business owners, stakeholders are knowledgeable about the software development process - projects tend to run much smoother. Please share your comments. Thanks! | books | null | null | null | null | 02/10/2010 01:57:44 | not a real question | List of best books about software development process for non-developers (non technical business owners)
===
I am looking for a good book that explains software development to non developers. My goal is to educate business owners (non technical folks) on the software development process, its hurdles, problems, methods etc. The book should be written from a non programmer's perspective. I found in my software development career that if the business owners, stakeholders are knowledgeable about the software development process - projects tend to run much smoother. Please share your comments. Thanks! | 1 |
9,439,382 | 02/24/2012 23:12:25 | 1,190,159 | 02/05/2012 03:25:20 | 27 | 0 | C++ while loops: Why No Output? | I am using a while(getline(cin, string)) loop to **enter input using the echo -e command** and not actually opening the exe. This is supposed to intake a string from echo and output the number of words and the number of unique words. My problem currently is I am not getting any output using echo, it's just blank.
int main() {
string line, word;
unsigned long n; //word length counter
vector<string> word_list;
set<string> unique_words;
while(getline(cin, line)) {
n = 0;
word = " ";
//in case there is no whitespace
if(line.find_first_of(' ') < 0 || line.find_first_of('\t') < 0) {
word_list.push_back(line);
unique_words.insert(line);
break;
}
//testing every element of the string: line
for(unsigned int i = 0; i != line.length(); i++) {
//as long as line[i] is not whitespace, concatenate with/insert into word
do {
word.insert(n, 1, line[i]);
n++;
}while(line[i] != ' ' || line[i] != '\t');
//if the current line[i] is whitespace AND the previous element was NOT whitespace, insert word into word_list and unique_words
if((line[i] == ' ' || line[i] == '\t')) && (line[i-1] != ' ') && (line[i-1] != '\t')) {
word_list.push_back(word);
unique_words.insert(word);
}
word = " ";
n = 0;
}
}
cout << word_list.size() << "\t" << unique_words.size() << endl;
return(0);
}
I suppose it has something to do with the if statement inside the for loop, also I am not sure if scanning '\t' instead of "\t" makes any difference in terms of detecting whitespace within the string.
An example of correct output:
$echo -e "hello hello" | ./prog
2(words) 1(unique words)
$echo -e "hello hello Bye\n hello" | ./prog
4(words) 2(unique words)
Help is greatly appreciated!! | c++ | string | homework | output | while-loops | 02/25/2012 22:54:10 | too localized | C++ while loops: Why No Output?
===
I am using a while(getline(cin, string)) loop to **enter input using the echo -e command** and not actually opening the exe. This is supposed to intake a string from echo and output the number of words and the number of unique words. My problem currently is I am not getting any output using echo, it's just blank.
int main() {
string line, word;
unsigned long n; //word length counter
vector<string> word_list;
set<string> unique_words;
while(getline(cin, line)) {
n = 0;
word = " ";
//in case there is no whitespace
if(line.find_first_of(' ') < 0 || line.find_first_of('\t') < 0) {
word_list.push_back(line);
unique_words.insert(line);
break;
}
//testing every element of the string: line
for(unsigned int i = 0; i != line.length(); i++) {
//as long as line[i] is not whitespace, concatenate with/insert into word
do {
word.insert(n, 1, line[i]);
n++;
}while(line[i] != ' ' || line[i] != '\t');
//if the current line[i] is whitespace AND the previous element was NOT whitespace, insert word into word_list and unique_words
if((line[i] == ' ' || line[i] == '\t')) && (line[i-1] != ' ') && (line[i-1] != '\t')) {
word_list.push_back(word);
unique_words.insert(word);
}
word = " ";
n = 0;
}
}
cout << word_list.size() << "\t" << unique_words.size() << endl;
return(0);
}
I suppose it has something to do with the if statement inside the for loop, also I am not sure if scanning '\t' instead of "\t" makes any difference in terms of detecting whitespace within the string.
An example of correct output:
$echo -e "hello hello" | ./prog
2(words) 1(unique words)
$echo -e "hello hello Bye\n hello" | ./prog
4(words) 2(unique words)
Help is greatly appreciated!! | 3 |
11,385,003 | 07/08/2012 17:08:54 | 1,024,882 | 11/02/2011 03:20:33 | 6 | 0 | Need assistance finding file sharing cloud for android | I am developing an app that will take a photo and upload it to the cloud and return a url link where the file is located, so I can send the url link to users via my own sms program.
I am looking for a simple file sharing program to use with a Java Api to use.
Here is link to a few: http://alternativeto.net/software/4shared/?platform=android
I was thinking of using cx.com but does not have java api.
The second choice is sugarsynch.
I would like some input. | android | null | null | null | null | 07/08/2012 18:24:17 | off topic | Need assistance finding file sharing cloud for android
===
I am developing an app that will take a photo and upload it to the cloud and return a url link where the file is located, so I can send the url link to users via my own sms program.
I am looking for a simple file sharing program to use with a Java Api to use.
Here is link to a few: http://alternativeto.net/software/4shared/?platform=android
I was thinking of using cx.com but does not have java api.
The second choice is sugarsynch.
I would like some input. | 2 |
10,190,207 | 04/17/2012 11:18:13 | 1,251,861 | 03/06/2012 10:01:51 | 179 | 25 | Is the thing I did the good one? | I'm a trainee in a little office. Due to some security issues, it won't be possible for me to test the app I developped from a remote computer before the end of the internship.
I think that the thing I did is good for a "normal" application, but won't work on a web server.
I need to create tasks, meeting requests,...
So, here is wat I've done :
Here is the view that submits a form
$(function () {
$('.datetime').datetimepicker({
dateFormat: 'dd.mm.yy'
});
});
<form action="" method="post" id="myform">
<input type="text" class="datetime" name="datetime" id=@datetime value="" />
<input type="submit" onclick="meetTel(@item.idContact, @Model.Opportunite.idOpportunite)" value="Rajouter à Outlook" />
<img src="../../Content/images/picto_info.png" alt="" title="Choisir une date et une heure. Une tâche sera rajoutée sur le compte outlook connecté sur ce PC"/>
</form>
Here is the script that sends data to the controller
<script type="text/javascript">
function meetTel(idCont, idOpp){
var dateTimeSelect = ("#datetime" + idCont);
var dateTime = $(dateTimeSelect).val();
$.ajax({
url: '@Url.Action("meetingTel")',
type: 'POST',
data: { idCont: idCont, idOpp: idOpp, dateTime: dateTime },
success: function(result){}
});
};
</script>
And here is the controller that creates a task :
<HttpPost()>
Sub meetingTel(idCont As Integer, idOpp As Integer, dateTime As String)
Dim OutlookApp As New Outlook.Application
Dim task As Outlook.TaskItem = Nothing
task = OutlookApp.CreateItem(Outlook.OlItemType.olTaskItem)
task.Subject = "Meeting candidat : " + (From a In db.contact Where a.idContact = idCont Select a.nom).FirstOrDefault().ToString() + " : " + (From a In db.contact Where a.idContact = idCont Select a.telephone).FirstOrDefault().ToString()
Dim StartDate As DateTime = dateTime
task.StartDate = dateTime
task.ReminderTime = dateTime
task.Save()
End Sub
Is the way I did it the good one? Am I going to get the result I already have when I use the server as client? If the thing I did is stupid, Is there a way I can fix this?
Almost all the app is based on VSTO... I hope that almost everything will work | vb.net | asp.net-mvc-3 | razor | vsto | null | 04/17/2012 11:38:36 | off topic | Is the thing I did the good one?
===
I'm a trainee in a little office. Due to some security issues, it won't be possible for me to test the app I developped from a remote computer before the end of the internship.
I think that the thing I did is good for a "normal" application, but won't work on a web server.
I need to create tasks, meeting requests,...
So, here is wat I've done :
Here is the view that submits a form
$(function () {
$('.datetime').datetimepicker({
dateFormat: 'dd.mm.yy'
});
});
<form action="" method="post" id="myform">
<input type="text" class="datetime" name="datetime" id=@datetime value="" />
<input type="submit" onclick="meetTel(@item.idContact, @Model.Opportunite.idOpportunite)" value="Rajouter à Outlook" />
<img src="../../Content/images/picto_info.png" alt="" title="Choisir une date et une heure. Une tâche sera rajoutée sur le compte outlook connecté sur ce PC"/>
</form>
Here is the script that sends data to the controller
<script type="text/javascript">
function meetTel(idCont, idOpp){
var dateTimeSelect = ("#datetime" + idCont);
var dateTime = $(dateTimeSelect).val();
$.ajax({
url: '@Url.Action("meetingTel")',
type: 'POST',
data: { idCont: idCont, idOpp: idOpp, dateTime: dateTime },
success: function(result){}
});
};
</script>
And here is the controller that creates a task :
<HttpPost()>
Sub meetingTel(idCont As Integer, idOpp As Integer, dateTime As String)
Dim OutlookApp As New Outlook.Application
Dim task As Outlook.TaskItem = Nothing
task = OutlookApp.CreateItem(Outlook.OlItemType.olTaskItem)
task.Subject = "Meeting candidat : " + (From a In db.contact Where a.idContact = idCont Select a.nom).FirstOrDefault().ToString() + " : " + (From a In db.contact Where a.idContact = idCont Select a.telephone).FirstOrDefault().ToString()
Dim StartDate As DateTime = dateTime
task.StartDate = dateTime
task.ReminderTime = dateTime
task.Save()
End Sub
Is the way I did it the good one? Am I going to get the result I already have when I use the server as client? If the thing I did is stupid, Is there a way I can fix this?
Almost all the app is based on VSTO... I hope that almost everything will work | 2 |
9,365,955 | 02/20/2012 17:54:12 | 1,188,470 | 02/03/2012 21:19:18 | 12 | 0 | Importing Classes from Separate Files | So I'm working on familiarizing myself with object oriented programming by messing around with classes in python. Below is a simple code I [tried] to implement in just the interpreter.
class Test(object):
def set_name(self, _name):
name = _name
def set_age(self, _age):
age = _age
def set_weight(self, _weight):
weight = _weight
def set_height(self, _height):
height = _height
When I start up python, I run the following commands:
>>>import Test
>>>Test.set_name("Sean")
and then I receive this traceback:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: 'module' object has no attribute 'set_name'
I am basing this all off of the official module documentation found [here][1].
[1]: http://docs.python.org/tutorial/modules.html#modules
I have read quite a bit of documentation on OOP, but I am still very new, so I'm sure there's still something going right over my head. What does that error mean?
Thanks in advance for any help. | python | class | import | module | null | null | open | Importing Classes from Separate Files
===
So I'm working on familiarizing myself with object oriented programming by messing around with classes in python. Below is a simple code I [tried] to implement in just the interpreter.
class Test(object):
def set_name(self, _name):
name = _name
def set_age(self, _age):
age = _age
def set_weight(self, _weight):
weight = _weight
def set_height(self, _height):
height = _height
When I start up python, I run the following commands:
>>>import Test
>>>Test.set_name("Sean")
and then I receive this traceback:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: 'module' object has no attribute 'set_name'
I am basing this all off of the official module documentation found [here][1].
[1]: http://docs.python.org/tutorial/modules.html#modules
I have read quite a bit of documentation on OOP, but I am still very new, so I'm sure there's still something going right over my head. What does that error mean?
Thanks in advance for any help. | 0 |
4,361,758 | 12/05/2010 22:47:49 | 213,871 | 11/18/2009 15:44:45 | 40 | 6 | Partition neighbor points given a euclidean distance delta | Given two points P,Q and a delta, I defined the equivalence relation ~=, where P ~= Q if `EuclideanDistance(P,Q)` <= delta. Now, given a set _S_ of _n_ points, in the example S = (A, B, C, D, E, F) and n = 6 (the fact points are actually endpoints of segments is negligible), is there an algorithm that has complexity better than O(n^2) in the average case to find a partition of the set (the representative element is unimportant)?
Attempts to find theoretical definitions of this problem were unsuccessful so far: k-means clustering, nearest neighbor search and others seems to me different problems. The picture shows what I need to do in my application.
Any hint? Thanks
![alt text][1]
[1]: http://i.stack.imgur.com/33bGu.png | algorithm | cluster-analysis | partitioning | spatial | euclidean-distance | null | open | Partition neighbor points given a euclidean distance delta
===
Given two points P,Q and a delta, I defined the equivalence relation ~=, where P ~= Q if `EuclideanDistance(P,Q)` <= delta. Now, given a set _S_ of _n_ points, in the example S = (A, B, C, D, E, F) and n = 6 (the fact points are actually endpoints of segments is negligible), is there an algorithm that has complexity better than O(n^2) in the average case to find a partition of the set (the representative element is unimportant)?
Attempts to find theoretical definitions of this problem were unsuccessful so far: k-means clustering, nearest neighbor search and others seems to me different problems. The picture shows what I need to do in my application.
Any hint? Thanks
![alt text][1]
[1]: http://i.stack.imgur.com/33bGu.png | 0 |
7,046,313 | 08/12/2011 21:03:26 | 473,625 | 10/12/2010 17:22:26 | 1,211 | 108 | How do you display and edit XML in a webpage? | I want to generate some XML, display it in a web page, and allow the user to edit the xml if they want.
Is there a control / library / commonly accepted technique that would achieve these goals ?
I've seen a couple possible solutions but nothing has stood out, so I turn to the StackOverflow community to guide me to the best possible solution.
I don't have any technology limitations set here however I would like to remain in the HTML/Javascript or .NET technologies if possible.
| c# | javascript | .net | xml | html5 | 08/13/2011 12:06:46 | off topic | How do you display and edit XML in a webpage?
===
I want to generate some XML, display it in a web page, and allow the user to edit the xml if they want.
Is there a control / library / commonly accepted technique that would achieve these goals ?
I've seen a couple possible solutions but nothing has stood out, so I turn to the StackOverflow community to guide me to the best possible solution.
I don't have any technology limitations set here however I would like to remain in the HTML/Javascript or .NET technologies if possible.
| 2 |
7,273,134 | 09/01/2011 16:08:53 | 766,263 | 05/23/2011 15:20:03 | 23 | 1 | Wrong "week of year" in Android | The number of "week of year" returned from a Date is wrong.
This is my code:
Calendar c = Calendar.getInstance();
c.setTime(my_date);
int num_week = c.get(Calendar.WEEK_OF_YEAR);
If my_date (type Date) is 01/01/2011, I supposed that "week of year" is 1. But it returned 52.
I try to test with these methods but I don't obtain anything:
c.setFirstDayOfWeek(6);
c.setMinimalDaysInFirstWeek(1)
If It's interesting, I'm from Spain, and our week begin on Monday.
Have I to do anything for obtain right results?
Thanks! | android | date | year | week | null | null | open | Wrong "week of year" in Android
===
The number of "week of year" returned from a Date is wrong.
This is my code:
Calendar c = Calendar.getInstance();
c.setTime(my_date);
int num_week = c.get(Calendar.WEEK_OF_YEAR);
If my_date (type Date) is 01/01/2011, I supposed that "week of year" is 1. But it returned 52.
I try to test with these methods but I don't obtain anything:
c.setFirstDayOfWeek(6);
c.setMinimalDaysInFirstWeek(1)
If It's interesting, I'm from Spain, and our week begin on Monday.
Have I to do anything for obtain right results?
Thanks! | 0 |
11,178,328 | 06/24/2012 14:35:48 | 1,478,178 | 06/24/2012 14:19:01 | 1 | 0 | changing iframe | Hi is it possible to strip some part of iframe embed code? Here is example
<iframe title="Video player" width="%%player_w%%" height="%%player_h%%" src="http://www.mydomain/vfplayer/play.php?url=http://vk.com/video166253103_162876280&captions=http://www.mydomain.com/undercoverbrothers.srt<as=rieisastqtbasvyj&image=http://mydomain.com/default.jpg" frameborder="0" allowfullscreen="true" id="VideoPlayer"></iframe>
I need to cut out this part : <as=rieisastqtbasvyj | java | php | javascript | iframe | null | 06/24/2012 21:52:53 | not a real question | changing iframe
===
Hi is it possible to strip some part of iframe embed code? Here is example
<iframe title="Video player" width="%%player_w%%" height="%%player_h%%" src="http://www.mydomain/vfplayer/play.php?url=http://vk.com/video166253103_162876280&captions=http://www.mydomain.com/undercoverbrothers.srt<as=rieisastqtbasvyj&image=http://mydomain.com/default.jpg" frameborder="0" allowfullscreen="true" id="VideoPlayer"></iframe>
I need to cut out this part : <as=rieisastqtbasvyj | 1 |
10,959,227 | 06/09/2012 07:27:21 | 1,105,489 | 12/19/2011 08:28:09 | 35 | 0 | How to distinguish whether a word is half-width or full-width? | Is is possible to tell whether a word is half-width and full-width?
Recently I'm dealing with texts with mixed languages, including Chinese, English, and even some emoticons.
I've been searching for this issue quite a lot, but the only thing I can find is "to replace full-width characters with half-width characters" rather than telling you how to determine whether the character is a half- or full-width word.
So, again, my question is: **Is is possible to tell whether a word is half-width and full-width?**
Thanks in advance!
| python | null | null | null | null | null | open | How to distinguish whether a word is half-width or full-width?
===
Is is possible to tell whether a word is half-width and full-width?
Recently I'm dealing with texts with mixed languages, including Chinese, English, and even some emoticons.
I've been searching for this issue quite a lot, but the only thing I can find is "to replace full-width characters with half-width characters" rather than telling you how to determine whether the character is a half- or full-width word.
So, again, my question is: **Is is possible to tell whether a word is half-width and full-width?**
Thanks in advance!
| 0 |
3,607,503 | 08/31/2010 08:59:27 | 328,558 | 04/29/2010 06:25:02 | 56 | 3 | EJB WebServices problem; "..does not contain operation meta data.." | I got an error as I mentioned above. My application has EJB WebServices, developing with MyEclipse and running on jboss4.2.2.GA.
I use Eclipse's Web Services Explorer to invoke a WSDL operation. When I enter the parameters for the wsdl and click **Go** to invoke, I am getting this error in the SOAP Response Envelope;
<faultstring>Endpoint {http://local.ws.myService}LocalServicePort does not contain operation meta data for: {http://local.ws.myService}getPaymentStatus</faultstring>
If you have an idea about this problem I would be glad to hear that.
Thanks in advance.
Baris | web-services | jboss | ejb-3.0 | null | null | null | open | EJB WebServices problem; "..does not contain operation meta data.."
===
I got an error as I mentioned above. My application has EJB WebServices, developing with MyEclipse and running on jboss4.2.2.GA.
I use Eclipse's Web Services Explorer to invoke a WSDL operation. When I enter the parameters for the wsdl and click **Go** to invoke, I am getting this error in the SOAP Response Envelope;
<faultstring>Endpoint {http://local.ws.myService}LocalServicePort does not contain operation meta data for: {http://local.ws.myService}getPaymentStatus</faultstring>
If you have an idea about this problem I would be glad to hear that.
Thanks in advance.
Baris | 0 |
5,089,141 | 02/23/2011 09:38:19 | 645,748 | 02/23/2011 09:36:06 | 1 | 0 | question about smarty | how to use smarty with the php??
i am just biggener.. | php | smart | null | null | null | 02/23/2011 09:41:15 | not a real question | question about smarty
===
how to use smarty with the php??
i am just biggener.. | 1 |
6,300,998 | 06/10/2011 01:13:21 | 339,843 | 05/13/2010 00:27:55 | 1,743 | 116 | Where can I get a XAML path for an eyeball? | I have one for a Star that looks like:
Data="M 61.3431396484375,0 C61.3431396484375,0 80.2991943359375,38.40919494628906 80.2991943359375,38.40919494628906 80.2991943359375,38.40919494628906 122.686279296875,44.56840515136719 122.686279296875,44.56840515136719 122.686279296875,44.56840515136719 92.01470947265625,74.46580505371094 92.01470947265625,74.46580505371094 92.01470947265625,74.46580505371094 99.25527954101562,116.68159484863281 99.25527954101562,116.68159484863281 99.25527954101562,116.68159484863281 61.3431396484375,96.75 61.3431396484375,96.75 61.3431396484375,96.75 23.430999755859375,116.68159484863281 23.430999755859375,116.68159484863281 23.430999755859375,116.68159484863281 30.67156982421875,74.46580505371094 30.67156982421875,74.46580505371094 30.67156982421875,74.46580505371094 0,44.56840515136719 0,44.56840515136719 0,44.56840515136719 42.3870849609375,38.40919494628906 42.3870849609375,38.40919494628906 42.3870849609375,38.40919494628906 61.3431396484375,0 61.3431396484375,0 z"
| c# | wpf | xaml | null | null | 06/10/2011 20:06:37 | too localized | Where can I get a XAML path for an eyeball?
===
I have one for a Star that looks like:
Data="M 61.3431396484375,0 C61.3431396484375,0 80.2991943359375,38.40919494628906 80.2991943359375,38.40919494628906 80.2991943359375,38.40919494628906 122.686279296875,44.56840515136719 122.686279296875,44.56840515136719 122.686279296875,44.56840515136719 92.01470947265625,74.46580505371094 92.01470947265625,74.46580505371094 92.01470947265625,74.46580505371094 99.25527954101562,116.68159484863281 99.25527954101562,116.68159484863281 99.25527954101562,116.68159484863281 61.3431396484375,96.75 61.3431396484375,96.75 61.3431396484375,96.75 23.430999755859375,116.68159484863281 23.430999755859375,116.68159484863281 23.430999755859375,116.68159484863281 30.67156982421875,74.46580505371094 30.67156982421875,74.46580505371094 30.67156982421875,74.46580505371094 0,44.56840515136719 0,44.56840515136719 0,44.56840515136719 42.3870849609375,38.40919494628906 42.3870849609375,38.40919494628906 42.3870849609375,38.40919494628906 61.3431396484375,0 61.3431396484375,0 z"
| 3 |
2,349,205 | 02/27/2010 22:38:35 | 157,872 | 08/17/2009 16:25:55 | 134 | 9 | Can't draw Histogram, 'x' must be numeric | I have a data file with this format:
Weight Industry Type
251,787 Kellogg h
253,9601 Kellogg a
256,0758 Kellogg h
....
I read the data and try to draw an histogram with this commands:
ce= read.table("file.txt", header= T)
we = ce[,1]
in = ce[,2]
ty = ce[,3]
hist(we)
But I get this error:
Error en hist.default(we) : 'x' must be numeric. What I need to do in order to draw histograms for my three variables ? | r | null | null | null | null | null | open | Can't draw Histogram, 'x' must be numeric
===
I have a data file with this format:
Weight Industry Type
251,787 Kellogg h
253,9601 Kellogg a
256,0758 Kellogg h
....
I read the data and try to draw an histogram with this commands:
ce= read.table("file.txt", header= T)
we = ce[,1]
in = ce[,2]
ty = ce[,3]
hist(we)
But I get this error:
Error en hist.default(we) : 'x' must be numeric. What I need to do in order to draw histograms for my three variables ? | 0 |
9,956,635 | 03/31/2012 14:17:24 | 1,094,640 | 12/12/2011 22:06:16 | 318 | 4 | List constructor does not work properly in java | I am trying to run the following code:
List<Integer> list = Arrays.asList(1,2,3);
ArrayList<Integer> val = new ArrayList<Integer>(list);
i know that i get the list in the first line but I ran it out of curiosity. To my disbelief, val list is empty after running of the above code, at least on my Eclipse Indigo, java 1.6 machine. Any ideas? | java | collections | null | null | null | 04/01/2012 10:09:53 | too localized | List constructor does not work properly in java
===
I am trying to run the following code:
List<Integer> list = Arrays.asList(1,2,3);
ArrayList<Integer> val = new ArrayList<Integer>(list);
i know that i get the list in the first line but I ran it out of curiosity. To my disbelief, val list is empty after running of the above code, at least on my Eclipse Indigo, java 1.6 machine. Any ideas? | 3 |
7,489,471 | 09/20/2011 17:50:32 | 752,684 | 05/13/2011 15:54:45 | 102 | 0 | Adding variables | Trying to open up a .txt file, read the number in that .txt file, add the value from $_POST['credits'] and then write that new number back to the .txt file. My code that I am using is below.
<?php
session_start();
$id = array();
$credits = $_POST['credits'];
//Include database connection details
require_once('config.php');
//Connect to mysql server
$link = mysql_connect(DB_HOST, DB_USER, DB_PASSWORD);
if(!$link) {
die('Failed to connect to server: ' . mysql_error());
}
//Select database
$db = mysql_select_db(DB_DATABASE);
if(!$db) {
die("Unable to select database");
}
//Create query
$query = mysql_query("SELECT * FROM `members` WHERE `member_id` IN (".mysql_real_escape_string(implode(',',$id)).")");
// display query results
while($row = mysql_fetch_array($query))
{
$base_path = '/var/www/vhosts/default/htdocs/Members/';
$path = $base_path . trim($row['login']) . '/Template/company_credits.txt' ;
$current_credits = (file_get_contents($path));
$updated_credits = ".$current_credits." + ".$credits.";
file_put_contents($path, $updated_credits);
}
mysql_close($link);
header("location: admin-index.php");
?>
Whatever $credits is equal to from the post, say 5, it doesn't add 5 to the .txt file value. Any help is appreciated! Thank you | php | sql | null | null | null | 11/11/2011 09:56:33 | not a real question | Adding variables
===
Trying to open up a .txt file, read the number in that .txt file, add the value from $_POST['credits'] and then write that new number back to the .txt file. My code that I am using is below.
<?php
session_start();
$id = array();
$credits = $_POST['credits'];
//Include database connection details
require_once('config.php');
//Connect to mysql server
$link = mysql_connect(DB_HOST, DB_USER, DB_PASSWORD);
if(!$link) {
die('Failed to connect to server: ' . mysql_error());
}
//Select database
$db = mysql_select_db(DB_DATABASE);
if(!$db) {
die("Unable to select database");
}
//Create query
$query = mysql_query("SELECT * FROM `members` WHERE `member_id` IN (".mysql_real_escape_string(implode(',',$id)).")");
// display query results
while($row = mysql_fetch_array($query))
{
$base_path = '/var/www/vhosts/default/htdocs/Members/';
$path = $base_path . trim($row['login']) . '/Template/company_credits.txt' ;
$current_credits = (file_get_contents($path));
$updated_credits = ".$current_credits." + ".$credits.";
file_put_contents($path, $updated_credits);
}
mysql_close($link);
header("location: admin-index.php");
?>
Whatever $credits is equal to from the post, say 5, it doesn't add 5 to the .txt file value. Any help is appreciated! Thank you | 1 |
7,358,939 | 09/09/2011 08:22:46 | 863,401 | 07/26/2011 12:11:38 | 7 | 0 | how do i Save a photo from the internet? | hi i created 1 apps on that app i am getting photos from flickr using json and viewing these photos as thumbnail and also slideshow , if suppose the user want to save some photos those from flickr how to do i was just doing these through NSDefaultManager bt dosen't work,
- (IBAction)saveImage {
NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);
NSString *documentsDirectory = [paths objectAtIndex:0];
NSString *savedImagePath = [documentsDirectory stringByAppendingPathComponent:@"savedImage.png"];
[imageData writeToFile:savedImagePath atomically:NO];
} | iphone | null | null | null | null | null | open | how do i Save a photo from the internet?
===
hi i created 1 apps on that app i am getting photos from flickr using json and viewing these photos as thumbnail and also slideshow , if suppose the user want to save some photos those from flickr how to do i was just doing these through NSDefaultManager bt dosen't work,
- (IBAction)saveImage {
NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);
NSString *documentsDirectory = [paths objectAtIndex:0];
NSString *savedImagePath = [documentsDirectory stringByAppendingPathComponent:@"savedImage.png"];
[imageData writeToFile:savedImagePath atomically:NO];
} | 0 |
11,008,076 | 06/13/2012 04:07:55 | 1,350,321 | 04/23/2012 01:35:20 | 1 | 1 | iOS Enterprise License for deployment to clients | The company that I work for develops a suite of workforce management software, which we then license and distribute within large organisations. The idea is to create a mobile component of the software suite to target iPhone and iPad. Originally we assumed that if we were to purchase an Enterprise Developer License from Apple we would be able deploy to our clients. From what I have read though, it would appear that you are only licensed to deploy the app to your organisation and not to your clients. Has anybody had any experience with something similar? What are the options? Do we have to deploy it through the appstore? or is there some way where we can control deployment to our clients?
Thanks
Jacob | iphone | ios | enterprise | iphone-developer-program | null | 06/13/2012 04:40:16 | off topic | iOS Enterprise License for deployment to clients
===
The company that I work for develops a suite of workforce management software, which we then license and distribute within large organisations. The idea is to create a mobile component of the software suite to target iPhone and iPad. Originally we assumed that if we were to purchase an Enterprise Developer License from Apple we would be able deploy to our clients. From what I have read though, it would appear that you are only licensed to deploy the app to your organisation and not to your clients. Has anybody had any experience with something similar? What are the options? Do we have to deploy it through the appstore? or is there some way where we can control deployment to our clients?
Thanks
Jacob | 2 |
9,093,786 | 02/01/2012 09:53:27 | 1,176,094 | 01/29/2012 05:33:18 | 21 | 3 | Having Pivot item as a directory in isolated storage | I want each pivot item to be one directory in isolated storage then load every file name into a listbox I find it quite confusing , can you guys help me with it?
Currently its all just showing in one pivot & for my app, user can actually create a pivot aka directory.
will it be possible to create a code in a way where i can i will load the directory based on the pivotitem name then load all item from that directory?
Thanks >.<
public partial class View2 : PhoneApplicationPage
{
public String selected;
public View2()
{
InitializeComponent();
LoadFromLocalStorage();
}
private void LoadFromLocalStorage()
{
try
{
using (IsolatedStorageFile store = IsolatedStorageFile.GetUserStoreForApplication())
{
//string[] fileNames = store.GetFileNames();
string[] fileNames = store.GetFileNames("./general/*.*");
var files = new ObservableCollection<string>();
foreach (string s in fileNames)
{
files.Add(s);
}
lbFiles.ItemsSource = files;
}
}
catch
{
MessageBox.Show("Capture an image first!");
}
}
private static string _first;
public string First
{
get
{
return _first;
}
}
private void lbFiles_Tap(object sender, System.Windows.Input.GestureEventArgs e)
{
selected = lbFiles.SelectedItem.ToString();
general item = new general();
item.viewimage(selected);
MessageBox.Show(selected);
_first = selected;
NavigationService.Navigate(new Uri("/View.xaml", UriKind.Relative));
}
} | c# | windows-phone-7 | null | null | null | null | open | Having Pivot item as a directory in isolated storage
===
I want each pivot item to be one directory in isolated storage then load every file name into a listbox I find it quite confusing , can you guys help me with it?
Currently its all just showing in one pivot & for my app, user can actually create a pivot aka directory.
will it be possible to create a code in a way where i can i will load the directory based on the pivotitem name then load all item from that directory?
Thanks >.<
public partial class View2 : PhoneApplicationPage
{
public String selected;
public View2()
{
InitializeComponent();
LoadFromLocalStorage();
}
private void LoadFromLocalStorage()
{
try
{
using (IsolatedStorageFile store = IsolatedStorageFile.GetUserStoreForApplication())
{
//string[] fileNames = store.GetFileNames();
string[] fileNames = store.GetFileNames("./general/*.*");
var files = new ObservableCollection<string>();
foreach (string s in fileNames)
{
files.Add(s);
}
lbFiles.ItemsSource = files;
}
}
catch
{
MessageBox.Show("Capture an image first!");
}
}
private static string _first;
public string First
{
get
{
return _first;
}
}
private void lbFiles_Tap(object sender, System.Windows.Input.GestureEventArgs e)
{
selected = lbFiles.SelectedItem.ToString();
general item = new general();
item.viewimage(selected);
MessageBox.Show(selected);
_first = selected;
NavigationService.Navigate(new Uri("/View.xaml", UriKind.Relative));
}
} | 0 |
8,765,855 | 01/06/2012 23:31:51 | 1,096,892 | 10/12/2011 19:29:32 | 448 | 1 | How to display a javascript variable into html | I just want to know how can I display a javascript variable into html?
Below is my javascript code:
var duration = <? echo $postduration; ?>;
(The variable above uses javascript to retrieve a php variable)
Thank you | javascript | html | null | null | null | null | open | How to display a javascript variable into html
===
I just want to know how can I display a javascript variable into html?
Below is my javascript code:
var duration = <? echo $postduration; ?>;
(The variable above uses javascript to retrieve a php variable)
Thank you | 0 |
9,839,912 | 03/23/2012 13:19:13 | 1,016,825 | 10/27/2011 15:42:26 | 13 | 0 | Connection from SharePoint to Word | On my SharePoint, I have a document library with meta tags.
If I start a document in Word, the tags are not selected by user.
Word always says "Currently unavailable" and the tooltip "You have to work with the server to view this property or to change".
In Excel, and on another computer on the same SharePoint, anything goes.
Please help me!
![enter image description here][1]
[1]: http://i.stack.imgur.com/dTW00.png | sharepoint | word | office | null | null | null | open | Connection from SharePoint to Word
===
On my SharePoint, I have a document library with meta tags.
If I start a document in Word, the tags are not selected by user.
Word always says "Currently unavailable" and the tooltip "You have to work with the server to view this property or to change".
In Excel, and on another computer on the same SharePoint, anything goes.
Please help me!
![enter image description here][1]
[1]: http://i.stack.imgur.com/dTW00.png | 0 |
11,298,434 | 07/02/2012 17:33:59 | 1,496,724 | 07/02/2012 17:24:08 | 1 | 0 | Migration from Android to iPhone | Good Afternoon,
We developed an Android app using PhoneGap, Jquery Mobile and we want it to be operational in iPhone.
i want to know how can i convert it and which tools should i use.
Thank you for you help.
Cordially, | objective-c | xcode | jquery-mobile | phonegap | null | 07/04/2012 02:29:56 | not a real question | Migration from Android to iPhone
===
Good Afternoon,
We developed an Android app using PhoneGap, Jquery Mobile and we want it to be operational in iPhone.
i want to know how can i convert it and which tools should i use.
Thank you for you help.
Cordially, | 1 |
6,904,783 | 08/01/2011 21:38:21 | 751,468 | 05/12/2011 22:17:43 | 317 | 4 | Ideas For Cron Apps? | I recently upgraded to a paid Web host, and love the new features. cPanel is great and there's a lot of features on there. One of them that I've always wanted to try is Cron or automated tasks I believe it's called. Considering I have 20 GB of bandwidth per month now along with a boatload of space, I think it would be nice to take advantage of all these new resources and make a Cron application.
Problem is, I don't know what to make. What I do know is that I want to make the most of my money count so I plan on using up as much bandwidth as possible, of course being sure not to exceed the 20 GB limit. I'm estimating I'll use about 500 MB of bandwidth per day for my Cron jobs, so I'm thinking of creating an application (PHP script probably) that's run every minute and very heavy.
Does anyone have any ideas on what I could potentially create? Something that's useful for me like email reminders, etc. | php | cron | bandwidth | null | null | 08/01/2011 21:40:22 | not constructive | Ideas For Cron Apps?
===
I recently upgraded to a paid Web host, and love the new features. cPanel is great and there's a lot of features on there. One of them that I've always wanted to try is Cron or automated tasks I believe it's called. Considering I have 20 GB of bandwidth per month now along with a boatload of space, I think it would be nice to take advantage of all these new resources and make a Cron application.
Problem is, I don't know what to make. What I do know is that I want to make the most of my money count so I plan on using up as much bandwidth as possible, of course being sure not to exceed the 20 GB limit. I'm estimating I'll use about 500 MB of bandwidth per day for my Cron jobs, so I'm thinking of creating an application (PHP script probably) that's run every minute and very heavy.
Does anyone have any ideas on what I could potentially create? Something that's useful for me like email reminders, etc. | 4 |
2,847,593 | 05/17/2010 08:31:33 | 102,200 | 05/06/2009 12:45:02 | 722 | 35 | Stack recommendations for small/medium-sized web application in Python | I'm looking for some recommendations for a python web application. We have some memory restrictions and we try to keep it small and lean.
We thought about using OSGI (and a python webserver) and build the rest ourself. We already have a template engine we'd like to use, but we are open for some suggestions regarding the whole request handling (the controller).
The application has to run in a single process and the requests have to be processed with multiple threads.
We've looked at django, but we are a not sure if it fits into our memory budget.
Your feedback is very welcome!
Cheers,
Reto
| python | osgi | null | null | null | null | open | Stack recommendations for small/medium-sized web application in Python
===
I'm looking for some recommendations for a python web application. We have some memory restrictions and we try to keep it small and lean.
We thought about using OSGI (and a python webserver) and build the rest ourself. We already have a template engine we'd like to use, but we are open for some suggestions regarding the whole request handling (the controller).
The application has to run in a single process and the requests have to be processed with multiple threads.
We've looked at django, but we are a not sure if it fits into our memory budget.
Your feedback is very welcome!
Cheers,
Reto
| 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.