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,746,727 | 01/05/2012 17:19:34 | 770,719 | 10/07/2009 09:06:24 | 11 | 1 | Dropbox API via cron | I've written a simple webapp that reads from dropbox folder. It works from the browser. Now I want to automate with a cron job. With a cron, it stops at redirect.
How can the dropbox api calls (file read) be automated through cron?
Thank you,
Joseph | python | dropbox | dropbox-api | null | null | 01/06/2012 16:14:38 | not a real question | Dropbox API via cron
===
I've written a simple webapp that reads from dropbox folder. It works from the browser. Now I want to automate with a cron job. With a cron, it stops at redirect.
How can the dropbox api calls (file read) be automated through cron?
Thank you,
Joseph | 1 |
9,454,474 | 02/26/2012 15:49:32 | 1,192,521 | 02/06/2012 14:38:59 | 14 | 0 | Show 1 where IP of sites are same | My site shows statistics of sites , now what i want do is that wherever some sites IP's are same beside them it should show 1 , IP's are to bought from gethostbyname() e.g
if sites1 IP = 123.432.123.2
and sites2 IP is also = 123.432.123.2
then beside them it should show 1 this should happen to all sites with same IPs | php | ip | null | null | null | 02/27/2012 03:26:24 | not a real question | Show 1 where IP of sites are same
===
My site shows statistics of sites , now what i want do is that wherever some sites IP's are same beside them it should show 1 , IP's are to bought from gethostbyname() e.g
if sites1 IP = 123.432.123.2
and sites2 IP is also = 123.432.123.2
then beside them it should show 1 this should happen to all sites with same IPs | 1 |
2,380,055 | 03/04/2010 14:37:29 | 77,538 | 03/13/2009 04:01:51 | 1,389 | 59 | Queue Priority in CruiseControl.NET | In my build configuration I have multiple project queues:
Queue1, Queue2, ... Queue(N)
I want to configure the build where I can set the priority of when each queue builds:
Queue1 = Priority of 2, Queue2 = Priority of 1 ...
which produces the queues being built in the following order:
Queue2, Queue1 ...
How can I accomplish this in CruiseControl.NET?
| cruisecontrol.net | continuous-integration | null | null | null | null | open | Queue Priority in CruiseControl.NET
===
In my build configuration I have multiple project queues:
Queue1, Queue2, ... Queue(N)
I want to configure the build where I can set the priority of when each queue builds:
Queue1 = Priority of 2, Queue2 = Priority of 1 ...
which produces the queues being built in the following order:
Queue2, Queue1 ...
How can I accomplish this in CruiseControl.NET?
| 0 |
10,328,279 | 04/26/2012 06:28:21 | 1,103,966 | 12/17/2011 22:40:47 | 371 | 5 | Are the old days of code injection over? | I was wondering since all updated operating systems guard against stack and heap type overflows via ASLR, Canary Checks, and other such methods, are memory corruption exploits still prevalent? Given that the administrator of the system is competent and protects the system from brute force or libc attacks, I honestly can't see many other ways. They only thing that I can possibly imagine for someone to attack a system is to overwrite function pointers on the stack but thats about it. Maybe if someone found a clever way of predicting random numbers, the schemes that rely on random results could be defeated, however it seems unlikely. It seems the only way to exploit someone else's system given now a days is to trick root or the admin into installing your software. Are the old days of code injection over? I'm at this from the perspective of breaking updated protected systems. | security | stackoverflow | buffer-overflow | code-injection | shellcode | 04/30/2012 04:37:15 | not constructive | Are the old days of code injection over?
===
I was wondering since all updated operating systems guard against stack and heap type overflows via ASLR, Canary Checks, and other such methods, are memory corruption exploits still prevalent? Given that the administrator of the system is competent and protects the system from brute force or libc attacks, I honestly can't see many other ways. They only thing that I can possibly imagine for someone to attack a system is to overwrite function pointers on the stack but thats about it. Maybe if someone found a clever way of predicting random numbers, the schemes that rely on random results could be defeated, however it seems unlikely. It seems the only way to exploit someone else's system given now a days is to trick root or the admin into installing your software. Are the old days of code injection over? I'm at this from the perspective of breaking updated protected systems. | 4 |
5,342,817 | 03/17/2011 17:27:29 | 664,765 | 03/17/2011 16:55:58 | 1 | 0 | Implementing Audio Steganography using WAVE files | Can anyone help me out in the method to read WAVE file for implementing LSB based audio steganography? I want to hide text behind WAVE file. I plan to use JAVA. | java | audio | steganography | wave | null | 03/21/2011 12:09:35 | not a real question | Implementing Audio Steganography using WAVE files
===
Can anyone help me out in the method to read WAVE file for implementing LSB based audio steganography? I want to hide text behind WAVE file. I plan to use JAVA. | 1 |
912,583 | 05/26/2009 20:29:37 | 108,561 | 05/18/2009 01:35:15 | 3 | 0 | Class Design for delegate, outlets, and mouse events | Here's a simplification:
I have an application with several buttons. If it is the first time the application is launching, I want to do some special things. In my AppController class, which is a delegate of NSApp, I use the delegate method -applicationDidFinishLaunching: to perform the test. After I've detected that it is the first time, I first want to access some IBOutlets. Then, I'd like to be able to get mouse events for each button, so that I can do other things.
I can't figure out want to do with the classes. I'd like to make a new class (FirstLaunch) for the first launch, but I'm not sure what to call from AppDelegate. Also, to get mouse events, shouldn't I be a sublass of the buttons, and considering that I have multiple buttons, I'm confused. I could probably tackle these issues one-by-one, but taken all together, they're confusing me.
Broken down, I need to access & manipulate IBOutlets I have set in IB, determine when buttons are clicked (and which button was clicked). I'd like to be able to do this from another class so as to not clutter up the AppDelegate.
Thanks for the help! | objective-c | cocoa | null | null | null | null | open | Class Design for delegate, outlets, and mouse events
===
Here's a simplification:
I have an application with several buttons. If it is the first time the application is launching, I want to do some special things. In my AppController class, which is a delegate of NSApp, I use the delegate method -applicationDidFinishLaunching: to perform the test. After I've detected that it is the first time, I first want to access some IBOutlets. Then, I'd like to be able to get mouse events for each button, so that I can do other things.
I can't figure out want to do with the classes. I'd like to make a new class (FirstLaunch) for the first launch, but I'm not sure what to call from AppDelegate. Also, to get mouse events, shouldn't I be a sublass of the buttons, and considering that I have multiple buttons, I'm confused. I could probably tackle these issues one-by-one, but taken all together, they're confusing me.
Broken down, I need to access & manipulate IBOutlets I have set in IB, determine when buttons are clicked (and which button was clicked). I'd like to be able to do this from another class so as to not clutter up the AppDelegate.
Thanks for the help! | 0 |
4,762,828 | 01/21/2011 19:14:13 | 179,736 | 09/27/2009 11:27:55 | 4,254 | 51 | What's better to use for Django? | Django-rest or Django Pistons?
What's better plugin for API stuff? | python | django | null | null | null | 01/22/2011 09:38:35 | not constructive | What's better to use for Django?
===
Django-rest or Django Pistons?
What's better plugin for API stuff? | 4 |
2,111,660 | 01/21/2010 18:07:17 | 256,053 | 01/21/2010 18:07:17 | 1 | 0 | Changing your online repositiory from another computer | I created an online repository on github.com I was adding/removing/modifying files on that repository normally from a computer i was using. Now, i am using a different computer and i do not have the original local repository that was stored on the other computer i was using. So, I created a folder whose name is the same as the name of the repository and i put the files inside that folder along with git of-course. What I wanted to do is to modify my online repository but i have problems in doing that. Mainly that i could not push. git it gives an error back which i could not resolve. I searched online on how to resolve the problem. Of-course i found solutions but non-of them worked. What one should do in-order to modify an an online repository form another computer? | git | online | repository | computer | null | null | open | Changing your online repositiory from another computer
===
I created an online repository on github.com I was adding/removing/modifying files on that repository normally from a computer i was using. Now, i am using a different computer and i do not have the original local repository that was stored on the other computer i was using. So, I created a folder whose name is the same as the name of the repository and i put the files inside that folder along with git of-course. What I wanted to do is to modify my online repository but i have problems in doing that. Mainly that i could not push. git it gives an error back which i could not resolve. I searched online on how to resolve the problem. Of-course i found solutions but non-of them worked. What one should do in-order to modify an an online repository form another computer? | 0 |
1,205,662 | 07/30/2009 10:07:59 | 77,993 | 03/14/2009 05:26:56 | 547 | 0 | Calling an SSIS package using a Web Application | How do you call an SSIS package using a Web Application? I'm using SQL Server 2005. I prefer a solution in C#2.0 above. Any help will be greatly appreciated. Thanks in advance. | .net | asp.net | ssis | sql-server-2005 | c# | null | open | Calling an SSIS package using a Web Application
===
How do you call an SSIS package using a Web Application? I'm using SQL Server 2005. I prefer a solution in C#2.0 above. Any help will be greatly appreciated. Thanks in advance. | 0 |
1,053,496 | 06/27/2009 19:51:11 | 122,961 | 06/15/2009 07:50:25 | 69 | 6 | Generic Question: Thoughts on soft keyboard UI for mobile devices | Yo, so I was curious about your thoughts about your preferences on soft keyboards for mobile devices. Are there any particularly innovative ones that you like?
By the way, my ulterior motive for asking this question was to look up one particular instance that I heard about, oh 10-ish months ago. Basically, you type with your finger constantly on the keyboard. Based on your direction changes and speed, the keyboard is supposed to be a much better predictor of keys. I'd really appreciate it if you
Pardon me for using this as a search for information, but it apparently made a much smaller smash in the gadget news sources, and implementations haven't come out yet. | mobile | user-interface | keyboard | null | null | 07/17/2012 04:15:08 | not constructive | Generic Question: Thoughts on soft keyboard UI for mobile devices
===
Yo, so I was curious about your thoughts about your preferences on soft keyboards for mobile devices. Are there any particularly innovative ones that you like?
By the way, my ulterior motive for asking this question was to look up one particular instance that I heard about, oh 10-ish months ago. Basically, you type with your finger constantly on the keyboard. Based on your direction changes and speed, the keyboard is supposed to be a much better predictor of keys. I'd really appreciate it if you
Pardon me for using this as a search for information, but it apparently made a much smaller smash in the gadget news sources, and implementations haven't come out yet. | 4 |
4,189,672 | 11/15/2010 22:52:50 | 23,893 | 09/30/2008 19:08:02 | 1,333 | 102 | What's the best POCO status tracking strategy? (EF) | So I was reading about Entity Framework and based on my agile development scenario I decided to go with POCO objects.
But now I'm having some extra problems I don't know how to get away with.
I'm working with RIA services and Silverlight so when I'm going to Save an object of the server side I have to attach the object to an `ObjectContext`. The thing is that I must then change the `ObjectState` to Added or Modified.
So my question is what's the best approach to really know what state to change it to. I saw in [Julia Lerman][1]'s book that she uses a `State` attribute in her POCO objects and she takes care managing that state on the client side before sending the object to the server. That state then is used to change the real EntitySate once attached.
I've also seen other samples where the Insert implementation checks on the Key of the Entity (object) to know whether it is new or not. For example, if `ProjectId` in my Project entity is 0 (zero) I know it has to be a new object.
To be honest I don't like any of those approaches because in both cases my developers have to do some extra-work to actually save the object.
I'd like the know pros and cons of both solutions and hopefully a new (better) solution I'm still not seing.
[1]:http://www.learnentityframework.com/ | entity-framework | entity-framework-4 | poco | ria-services | wcf-ria-services | null | open | What's the best POCO status tracking strategy? (EF)
===
So I was reading about Entity Framework and based on my agile development scenario I decided to go with POCO objects.
But now I'm having some extra problems I don't know how to get away with.
I'm working with RIA services and Silverlight so when I'm going to Save an object of the server side I have to attach the object to an `ObjectContext`. The thing is that I must then change the `ObjectState` to Added or Modified.
So my question is what's the best approach to really know what state to change it to. I saw in [Julia Lerman][1]'s book that she uses a `State` attribute in her POCO objects and she takes care managing that state on the client side before sending the object to the server. That state then is used to change the real EntitySate once attached.
I've also seen other samples where the Insert implementation checks on the Key of the Entity (object) to know whether it is new or not. For example, if `ProjectId` in my Project entity is 0 (zero) I know it has to be a new object.
To be honest I don't like any of those approaches because in both cases my developers have to do some extra-work to actually save the object.
I'd like the know pros and cons of both solutions and hopefully a new (better) solution I'm still not seing.
[1]:http://www.learnentityframework.com/ | 0 |
10,875,322 | 06/04/2012 01:15:01 | 1,434,204 | 06/04/2012 01:02:22 | 1 | 0 | Redirecting a php submit form | In the following php script Dreamweaver is giving me a syntax error every time I add the redirect header:
header('Location: thankyou.htm');
The info is sent to my email address with no problem but the client is not redirected to the thankyou.htm page. Does not matter whether or not I enter the full url. Sincerely appreciate any help. Please keep explanation simple - THANK YOU!!
PLEASE SEE BELOW...
<?php
$senderName = $_POST['name'];
$senderEmail = $_POST['email'];
$sendToEmail = "wildlifeart@heathersoos.ca";
$emailMessage = $_POST['message'];
$recipient = "$sendToEmail";
$headers = "From: $senderEmail ";
$message = "From: $senderName, \nEmail Address: $senderEmail\nMessage: $emailMessage";
$message = StripSlashes($message);
mail($recipient, "Heather's Artwork", $message, $headers)
header('Location: thankyou.htm');
?> | php | null | null | null | null | null | open | Redirecting a php submit form
===
In the following php script Dreamweaver is giving me a syntax error every time I add the redirect header:
header('Location: thankyou.htm');
The info is sent to my email address with no problem but the client is not redirected to the thankyou.htm page. Does not matter whether or not I enter the full url. Sincerely appreciate any help. Please keep explanation simple - THANK YOU!!
PLEASE SEE BELOW...
<?php
$senderName = $_POST['name'];
$senderEmail = $_POST['email'];
$sendToEmail = "wildlifeart@heathersoos.ca";
$emailMessage = $_POST['message'];
$recipient = "$sendToEmail";
$headers = "From: $senderEmail ";
$message = "From: $senderName, \nEmail Address: $senderEmail\nMessage: $emailMessage";
$message = StripSlashes($message);
mail($recipient, "Heather's Artwork", $message, $headers)
header('Location: thankyou.htm');
?> | 0 |
5,725,269 | 04/20/2011 03:48:02 | 425,756 | 08/19/2010 21:05:39 | 1,022 | 50 | Official way to write xcode | You might think this is a dumb question but I think its appropriate and covers a programming topic.
Is the official way to write Xcode, XCode, xcode or what? I have seen it writting numerous ways and wan't to be sure that I use it correctly.
Any help?
| xcode | spelling | null | null | null | 04/20/2011 04:07:36 | off topic | Official way to write xcode
===
You might think this is a dumb question but I think its appropriate and covers a programming topic.
Is the official way to write Xcode, XCode, xcode or what? I have seen it writting numerous ways and wan't to be sure that I use it correctly.
Any help?
| 2 |
2,042,301 | 01/11/2010 14:09:22 | 248,095 | 01/11/2010 14:09:22 | 1 | 0 | Template engines | Are there any for purposes other than web? e.g. for use in script generators, c++ code generators or other related, generic operations.
Thanks,
B | template | engine | null | null | null | 01/11/2010 14:33:02 | not a real question | Template engines
===
Are there any for purposes other than web? e.g. for use in script generators, c++ code generators or other related, generic operations.
Thanks,
B | 1 |
3,702,626 | 09/13/2010 16:56:34 | 325,400 | 04/25/2010 13:55:38 | 114 | 10 | Using LINQ to XML to traverse an HTML table | So I can easily use LINQ to XML to traverse a properly set-up XML document. But I'm having some issues figuring out how to apply it to an HTML table. Here is the setup:
<table class='inner' width='100%'>
<tr>
<th>
Area
</th>
<th>
Date
</th>
<th>
ID
</th>
<th>
Name
</th>
<th>
Email
</th>
<th>
Zip Code
</th>
<th>
Type
</th>
<th>
Amount
</th>
</tr>
<tr>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
</tr>
<tr>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
</tr>
</table>
Essentially, there can be an endless number of rows, I want to be able to go row-by-row to check the data accordingly. Can anyone point me in the right direction? Should I be using tools other than LINQ for this? | c# | html | xml | linq | linq-to-xml | null | open | Using LINQ to XML to traverse an HTML table
===
So I can easily use LINQ to XML to traverse a properly set-up XML document. But I'm having some issues figuring out how to apply it to an HTML table. Here is the setup:
<table class='inner' width='100%'>
<tr>
<th>
Area
</th>
<th>
Date
</th>
<th>
ID
</th>
<th>
Name
</th>
<th>
Email
</th>
<th>
Zip Code
</th>
<th>
Type
</th>
<th>
Amount
</th>
</tr>
<tr>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
</tr>
<tr>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
<td>
Data
</td>
</tr>
</table>
Essentially, there can be an endless number of rows, I want to be able to go row-by-row to check the data accordingly. Can anyone point me in the right direction? Should I be using tools other than LINQ for this? | 0 |
1,599,342 | 10/21/2009 07:55:46 | 83,905 | 03/28/2009 03:01:11 | 350 | 23 | how to show google maps using uiwebview with zooming in uiwebview? | as we all know that driving direction is not supported in mapkit.so i think i can show driving direction in webview.i am showing google maps in uiwebview,but it shows the whole site i just want to show only map part with some zoom so that it looks like original maps application of iphone.also i don't know if this breaks the apple's Human Interface Guidelines(HIG) Rules,tell me if it is | iphone-sdk-3.0 | xcode | objective-c | uiwebview | google-maps | null | open | how to show google maps using uiwebview with zooming in uiwebview?
===
as we all know that driving direction is not supported in mapkit.so i think i can show driving direction in webview.i am showing google maps in uiwebview,but it shows the whole site i just want to show only map part with some zoom so that it looks like original maps application of iphone.also i don't know if this breaks the apple's Human Interface Guidelines(HIG) Rules,tell me if it is | 0 |
11,688,888 | 07/27/2012 13:36:25 | 1,542,233 | 07/21/2012 05:48:28 | 8 | 0 | shopping cart in with jquery | I Have tried to get how many products are there in a the below shopping cart but i was unable to get so kindly help me
http://jsfiddle.net/makotosan/bkw5p/5/
| javascript | null | null | null | null | 08/01/2012 02:55:30 | too localized | shopping cart in with jquery
===
I Have tried to get how many products are there in a the below shopping cart but i was unable to get so kindly help me
http://jsfiddle.net/makotosan/bkw5p/5/
| 3 |
4,089,900 | 11/03/2010 17:37:38 | 477,955 | 10/16/2010 14:13:49 | 13 | 0 | Engine Scripting and Class Structure | I've started to code a 2d JRPG engine in C#/XNA and i have some questions about class structure and game events.
In a 'game maker' type environment you have a game script which runs events and so on based on user input. This is usually not OO and has no reference to classes and so on.
Now in my own engine what is the best way to code game events?
Suppose you interact with an NPC on screen, how would that event be handled in an OO language? I assume I would have an event within the character class and I assume that event would be assigned to in the section which loads the map but where would that event be linked to? Which class would contain the event logic?
class Character {
...
public delegate void InteractionEventHandler(object sender, EventArgs e);
...
public event InteractionEventHandler Interact;
...
}
class Map {
public Map(){
...
//add a new character to the NPC collection
newchar.Interact += ???
...
}
}
| c# | xna | null | null | null | null | open | Engine Scripting and Class Structure
===
I've started to code a 2d JRPG engine in C#/XNA and i have some questions about class structure and game events.
In a 'game maker' type environment you have a game script which runs events and so on based on user input. This is usually not OO and has no reference to classes and so on.
Now in my own engine what is the best way to code game events?
Suppose you interact with an NPC on screen, how would that event be handled in an OO language? I assume I would have an event within the character class and I assume that event would be assigned to in the section which loads the map but where would that event be linked to? Which class would contain the event logic?
class Character {
...
public delegate void InteractionEventHandler(object sender, EventArgs e);
...
public event InteractionEventHandler Interact;
...
}
class Map {
public Map(){
...
//add a new character to the NPC collection
newchar.Interact += ???
...
}
}
| 0 |
7,330,778 | 09/07/2011 08:18:05 | 908,875 | 08/24/2011 04:23:36 | 1 | 0 | how to sent mail to "user created" folder instead of "Sent" folder, when the mail was sent using webdav,c# to exchange 2003 server | i have created one application which will send and receive mails, so in that application when i send any mail then it should go to "user created" folder instead of "sent" folder of exchange server2003.
I mean it should directly navigate to "user created" folder from the "outbox", it should not go to "sent" folder from "outbox".
| c# | webdav | exchange-2003 | null | null | null | open | how to sent mail to "user created" folder instead of "Sent" folder, when the mail was sent using webdav,c# to exchange 2003 server
===
i have created one application which will send and receive mails, so in that application when i send any mail then it should go to "user created" folder instead of "sent" folder of exchange server2003.
I mean it should directly navigate to "user created" folder from the "outbox", it should not go to "sent" folder from "outbox".
| 0 |
2,978,550 | 06/05/2010 00:20:43 | 113,416 | 05/27/2009 21:38:41 | 133 | 1 | How to embed a user control (with a form) into SharePoint 2007? | I have a user control with a form, and I am trying to embed it in sharepoint 2007... I am getting an error about having two server-side forms on one page. This is crazy! Surely I can write a user control with a form and embed it in sharepoint??
Thanks. | sharepoint | null | null | null | null | null | open | How to embed a user control (with a form) into SharePoint 2007?
===
I have a user control with a form, and I am trying to embed it in sharepoint 2007... I am getting an error about having two server-side forms on one page. This is crazy! Surely I can write a user control with a form and embed it in sharepoint??
Thanks. | 0 |
6,574,572 | 07/04/2011 17:43:33 | 140,939 | 07/19/2009 11:32:11 | 390 | 30 | Best proven ways to improve search performance | We are working on a website like www.justdial.com .
Every State has Districts which have Cities which have Categories and subcategories.
Kindly suggest proven ways to improve performance. | sql-server | null | null | null | null | 07/04/2011 19:21:01 | not a real question | Best proven ways to improve search performance
===
We are working on a website like www.justdial.com .
Every State has Districts which have Cities which have Categories and subcategories.
Kindly suggest proven ways to improve performance. | 1 |
9,299,683 | 02/15/2012 19:11:21 | 488,350 | 10/27/2010 04:35:40 | 105 | 8 | List of identifiers of ActionScript 3.0 in Adobe Flash | I`m looking for a list of identifiers of ActionScript 3.0 . In Adobe Flash, it is possible to change the identifier`s color. I want to do the same in notepad++ in langs.xml file. All I need is the list and it seems hard to find one. | actionscript-3 | list | adobe | notepad++ | identifier | null | open | List of identifiers of ActionScript 3.0 in Adobe Flash
===
I`m looking for a list of identifiers of ActionScript 3.0 . In Adobe Flash, it is possible to change the identifier`s color. I want to do the same in notepad++ in langs.xml file. All I need is the list and it seems hard to find one. | 0 |
7,804,497 | 10/18/2011 08:38:04 | 812,746 | 06/23/2011 17:32:02 | 16 | 0 | run for loop limited iterations in python | I have an extremely large list of objects and I need to find all that have the identical attribute (any_object.any_attribute) and then append them to a new list. So I have pre-sorted them and run a binary search algo.
I have found the object with the matching attribute but the problem is that there are more than one such objects (they are neighbours) but I can't figure out a clean way of running a loop on these contiguous objects so that they all can be appended. My code is pasted below.
low = 0
high = len(sortedObjects)
while low < high:
mid = (low + high)/2
if sortedObjects[mid].attr < desired_attr:
low = mid + 1
elif sortedSamples[mid].attr > desired_attr:
high = mid
else:
newList.append(sortedObjects[mid])
break
So I need to write some new code in the last else block which would iterate over all the objects with the same attributes and append them. Sounds like a for loop would be needed but is it possible to run a for loop for limited iterations, like in C?
I do not want to iterate over the whole list as that would be slower and one of the requirements of this script is that it has to be fast and efficient. It will be run on really large sets of data and we are looking at execution times of 10-12 hrs. Thanks in advance! | python | for-loop | null | null | null | null | open | run for loop limited iterations in python
===
I have an extremely large list of objects and I need to find all that have the identical attribute (any_object.any_attribute) and then append them to a new list. So I have pre-sorted them and run a binary search algo.
I have found the object with the matching attribute but the problem is that there are more than one such objects (they are neighbours) but I can't figure out a clean way of running a loop on these contiguous objects so that they all can be appended. My code is pasted below.
low = 0
high = len(sortedObjects)
while low < high:
mid = (low + high)/2
if sortedObjects[mid].attr < desired_attr:
low = mid + 1
elif sortedSamples[mid].attr > desired_attr:
high = mid
else:
newList.append(sortedObjects[mid])
break
So I need to write some new code in the last else block which would iterate over all the objects with the same attributes and append them. Sounds like a for loop would be needed but is it possible to run a for loop for limited iterations, like in C?
I do not want to iterate over the whole list as that would be slower and one of the requirements of this script is that it has to be fast and efficient. It will be run on really large sets of data and we are looking at execution times of 10-12 hrs. Thanks in advance! | 0 |
1,503,140 | 10/01/2009 10:26:09 | 108,677 | 05/18/2009 09:16:11 | 1 | 5 | webcam access using opencv with processing in an applet or application | I made a small sketch with processing using opencv to face detect and track. But when I export as an application and start it nothing happens, same as an applet. First I exported the applet and thought this must be a security issue, and struggled with some hack for processing to sign your java applet.
http://processing.org/hacks/hacks:signapplet
With no luck I thought I would atleast be able to run it as an application but no success.
Anyone know what to do? | processing | sign | applet | opencv | null | null | open | webcam access using opencv with processing in an applet or application
===
I made a small sketch with processing using opencv to face detect and track. But when I export as an application and start it nothing happens, same as an applet. First I exported the applet and thought this must be a security issue, and struggled with some hack for processing to sign your java applet.
http://processing.org/hacks/hacks:signapplet
With no luck I thought I would atleast be able to run it as an application but no success.
Anyone know what to do? | 0 |
9,437,402 | 02/24/2012 20:15:46 | 1,224,398 | 02/21/2012 21:21:02 | 13 | 0 | How to extract the substring for each column of a file in bash? | Given a text file named file like this:
AAA 3/4 2/2 3/5
BBB 3/4 2/3 3/3 6/7
CCC 4/4 7/9
What should I do to get just the numerator of each fraction? like following:
AAA 3 2 2
BBB 3 2 3 6
CCC 4 7
Thank you. | bash | extract | null | null | null | null | open | How to extract the substring for each column of a file in bash?
===
Given a text file named file like this:
AAA 3/4 2/2 3/5
BBB 3/4 2/3 3/3 6/7
CCC 4/4 7/9
What should I do to get just the numerator of each fraction? like following:
AAA 3 2 2
BBB 3 2 3 6
CCC 4 7
Thank you. | 0 |
10,733,947 | 05/24/2012 08:39:22 | 226,256 | 12/07/2009 10:28:39 | 109 | 11 | Space Between Elements in BoxLayout(or any other Layout) LWUIT | I'm having problems removing all spaces and gaps between placed elements in the BoxLayout in LWUIT, i tried
Container toolbar = new Container(new BoxLayout(BoxLayout.X_AXIS));
toolbar.getStyle().setPadding(0, 0, 0, 0);
toolbar.getStyle().setMargin(0, 0, 0, 0);
with no luck, there is always a small gap between placed elements. How can I do this?
Appreciate the help. | lwuit | null | null | null | null | null | open | Space Between Elements in BoxLayout(or any other Layout) LWUIT
===
I'm having problems removing all spaces and gaps between placed elements in the BoxLayout in LWUIT, i tried
Container toolbar = new Container(new BoxLayout(BoxLayout.X_AXIS));
toolbar.getStyle().setPadding(0, 0, 0, 0);
toolbar.getStyle().setMargin(0, 0, 0, 0);
with no luck, there is always a small gap between placed elements. How can I do this?
Appreciate the help. | 0 |
10,994,014 | 06/12/2012 09:38:32 | 1,029,279 | 11/04/2011 07:54:16 | 13 | 1 | trouble with Nivo slider (stays on one slide) | I have Nivo slider installed and I am using Drupal 7 with http://drupal.org/project/boldy. I installed Nivo slider, and I created a /sites/all/libraries/nivo-sider folder, extracting the js nivo slider libraries there. I have Nivo implemented in my theme in the recommended area for slider. There are 6 slides and it wont cycle. It does the transition and thats it, it renders the same image over and over. Any pointers would be appreciated. I would also be interested in a better banner component if Nivo is not the best choice.
| drupal | nivoslider | null | null | null | 06/13/2012 12:57:31 | off topic | trouble with Nivo slider (stays on one slide)
===
I have Nivo slider installed and I am using Drupal 7 with http://drupal.org/project/boldy. I installed Nivo slider, and I created a /sites/all/libraries/nivo-sider folder, extracting the js nivo slider libraries there. I have Nivo implemented in my theme in the recommended area for slider. There are 6 slides and it wont cycle. It does the transition and thats it, it renders the same image over and over. Any pointers would be appreciated. I would also be interested in a better banner component if Nivo is not the best choice.
| 2 |
6,230,357 | 06/03/2011 17:11:46 | 688,927 | 04/02/2011 13:07:26 | 68 | 6 | Error in data-binding database to web form,(VS2010 Ultimate)(SQL CE) | i am a beginner in making website, i learned things at msdn only, but now when i try to make a very simple Website, i am having this error
"Unable to find the requested .Net Framework Data Provider. It may not be installed."
http://i.stack.imgur.com/RV5qY.jpg
steps followed to create the web site > New WebSite>Empty Website>Add new WebForm>Dragged The GridView on the page >Added new data source(sdf format).
The test query runs fine, but when i try to run the webPage, i am having this error, i have spent the whole previous day searching for a solution(but they seem to be valid no more, or are for older versions).
I am using Vs2010 ultimate, got sqlServer compact edition 2008 SP2 installed.
Here is the Web.config file :
<configuration>
<connectionStrings>
<add name="ConnectionString" connectionString="Data Source=C:\Users\TarunG\Documents\Visual Studio 2010\WebSites\WebSite1\App_Data\Database1.sdf"
providerName="System.Data.SqlServerCe.Client.3.5" />
</connectionStrings>
<system.web>
<compilation debug="true" targetFramework="4.0"></compilation>
</system.web>
</configuration>
The database contains only one Table - Result1.
The default.aspx file :
<body>
<form id="form1" runat="server">
<div>
</div>
<asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False"
DataKeyNames="Roll No." DataSourceID="SqlDataSource1">
<Columns>
<asp:BoundField DataField="Roll No." HeaderText="Roll No." ReadOnly="True"
SortExpression="Roll No." />
<asp:BoundField DataField="Category" HeaderText="Category"
SortExpression="Category" />
<asp:BoundField DataField="Rank" HeaderText="Rank" SortExpression="Rank" />
<asp:BoundField DataField="Registration No." HeaderText="Registration No."
SortExpression="Registration No." />
<asp:BoundField DataField="Name" HeaderText="Name" SortExpression="Name" />
</Columns>
</asp:GridView>
<asp:SqlDataSource ID="SqlDataSource1" runat="server"
ConnectionString="<%$ ConnectionStrings:ConnectionString %>"
ProviderName="<%$ ConnectionStrings:ConnectionString.ProviderName %>"
SelectCommand="SELECT * FROM [Result1]"></asp:SqlDataSource>
</form>
</body>
------------------------------------------------------------------------
machine.config :
<add name="SQL Server Compact Edition Data Provider" invariant="System.Data.SqlServerCe" description=".NET Framework Data Provider for Microsoft SQL Server Compact Edition" type="System.Data.SqlServerCe.SqlCeProviderFactory, System.Data.SqlServerCe, Version=9.0.242.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91"/>
<add name="Odbc Data Provider" invariant="System.Data.Odbc" description=".Net Framework Data Provider for Odbc" type="System.Data.Odbc.OdbcFactory, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<add name="OleDb Data Provider" invariant="System.Data.OleDb" description=".Net Framework Data Provider for OleDb" type="System.Data.OleDb.OleDbFactory, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<add name="OracleClient Data Provider" invariant="System.Data.OracleClient" description=".Net Framework Data Provider for Oracle" type="System.Data.OracleClient.OracleClientFactory, System.Data.OracleClient, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<add name="SqlClient Data Provider" invariant="System.Data.SqlClient" description=".Net Framework Data Provider for SqlServer" type="System.Data.SqlClient.SqlClientFactory, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<add name="Microsoft SQL Server Compact Data Provider" invariant="System.Data.SqlServerCe.3.5" description=".NET Framework Data Provider for Microsoft SQL Server Compact" type="System.Data.SqlServerCe.SqlCeProviderFactory, System.Data.SqlServerCe, Version=3.5.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91"/>
<add name="MySQL Data Provider" invariant="MySql.Data.MySqlClient" description=".Net Framework Data Provider for MySQL" type="MySql.Data.MySqlClient.MySqlClientFactory, MySql.Data, Version=6.3.6.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" />
<add name="Microsoft SQL Server Compact Data Provider" invariant="System.Data.SqlServerCe.3.5" description=".NET Framework Data Provider for Microsoft SQL Server Compact" type="System.Data.SqlServerCe.SqlCeProviderFactory, System.Data.SqlServerCe, Version=3.5.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91"/>
-------------------------------------------------------------------------------------------------
Any Help will be greatly appreciated, I am completely exhausted searching the thing on my own.
| .net | sql-server | asp.net-mvc | visual-studio-2010 | data-binding | null | open | Error in data-binding database to web form,(VS2010 Ultimate)(SQL CE)
===
i am a beginner in making website, i learned things at msdn only, but now when i try to make a very simple Website, i am having this error
"Unable to find the requested .Net Framework Data Provider. It may not be installed."
http://i.stack.imgur.com/RV5qY.jpg
steps followed to create the web site > New WebSite>Empty Website>Add new WebForm>Dragged The GridView on the page >Added new data source(sdf format).
The test query runs fine, but when i try to run the webPage, i am having this error, i have spent the whole previous day searching for a solution(but they seem to be valid no more, or are for older versions).
I am using Vs2010 ultimate, got sqlServer compact edition 2008 SP2 installed.
Here is the Web.config file :
<configuration>
<connectionStrings>
<add name="ConnectionString" connectionString="Data Source=C:\Users\TarunG\Documents\Visual Studio 2010\WebSites\WebSite1\App_Data\Database1.sdf"
providerName="System.Data.SqlServerCe.Client.3.5" />
</connectionStrings>
<system.web>
<compilation debug="true" targetFramework="4.0"></compilation>
</system.web>
</configuration>
The database contains only one Table - Result1.
The default.aspx file :
<body>
<form id="form1" runat="server">
<div>
</div>
<asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False"
DataKeyNames="Roll No." DataSourceID="SqlDataSource1">
<Columns>
<asp:BoundField DataField="Roll No." HeaderText="Roll No." ReadOnly="True"
SortExpression="Roll No." />
<asp:BoundField DataField="Category" HeaderText="Category"
SortExpression="Category" />
<asp:BoundField DataField="Rank" HeaderText="Rank" SortExpression="Rank" />
<asp:BoundField DataField="Registration No." HeaderText="Registration No."
SortExpression="Registration No." />
<asp:BoundField DataField="Name" HeaderText="Name" SortExpression="Name" />
</Columns>
</asp:GridView>
<asp:SqlDataSource ID="SqlDataSource1" runat="server"
ConnectionString="<%$ ConnectionStrings:ConnectionString %>"
ProviderName="<%$ ConnectionStrings:ConnectionString.ProviderName %>"
SelectCommand="SELECT * FROM [Result1]"></asp:SqlDataSource>
</form>
</body>
------------------------------------------------------------------------
machine.config :
<add name="SQL Server Compact Edition Data Provider" invariant="System.Data.SqlServerCe" description=".NET Framework Data Provider for Microsoft SQL Server Compact Edition" type="System.Data.SqlServerCe.SqlCeProviderFactory, System.Data.SqlServerCe, Version=9.0.242.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91"/>
<add name="Odbc Data Provider" invariant="System.Data.Odbc" description=".Net Framework Data Provider for Odbc" type="System.Data.Odbc.OdbcFactory, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<add name="OleDb Data Provider" invariant="System.Data.OleDb" description=".Net Framework Data Provider for OleDb" type="System.Data.OleDb.OleDbFactory, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<add name="OracleClient Data Provider" invariant="System.Data.OracleClient" description=".Net Framework Data Provider for Oracle" type="System.Data.OracleClient.OracleClientFactory, System.Data.OracleClient, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<add name="SqlClient Data Provider" invariant="System.Data.SqlClient" description=".Net Framework Data Provider for SqlServer" type="System.Data.SqlClient.SqlClientFactory, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<add name="Microsoft SQL Server Compact Data Provider" invariant="System.Data.SqlServerCe.3.5" description=".NET Framework Data Provider for Microsoft SQL Server Compact" type="System.Data.SqlServerCe.SqlCeProviderFactory, System.Data.SqlServerCe, Version=3.5.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91"/>
<add name="MySQL Data Provider" invariant="MySql.Data.MySqlClient" description=".Net Framework Data Provider for MySQL" type="MySql.Data.MySqlClient.MySqlClientFactory, MySql.Data, Version=6.3.6.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" />
<add name="Microsoft SQL Server Compact Data Provider" invariant="System.Data.SqlServerCe.3.5" description=".NET Framework Data Provider for Microsoft SQL Server Compact" type="System.Data.SqlServerCe.SqlCeProviderFactory, System.Data.SqlServerCe, Version=3.5.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91"/>
-------------------------------------------------------------------------------------------------
Any Help will be greatly appreciated, I am completely exhausted searching the thing on my own.
| 0 |
5,261,108 | 03/10/2011 14:31:42 | 328,968 | 04/29/2010 14:12:54 | 1,147 | 69 | List fonts used by a Word Document (faster method) | I am working on process for validating documents to make sure that they meet corporate standards. One of the steps is to make sure that the Word document does not use non-approved fonts.
I have the following stub of code, which works:
Dim wordApplication As Word.ApplicationClass = New Word.ApplicationClass()
Dim wordDocument As Word.Document = Nothing
Dim fontList As New List(Of String)()
Try
wordDocument = wordApplication.Documents.Open(FileName:="document Path")
'ive also tried using a for loop with an integer counter, no change in speed'
For Each c As Word.Range In wordDocument.Characters
If Not fontList.Contains(c.Font.Name) Then
fontList.Add(c.Font.Name)
End If
Next
But this is **incredibly** slow! Incredibly slow = 2500 characters/minute (I timed it with StopWatch). Most of my files are around 6,000 words/30,000 characters (about 25 pages). But there are some documents that are in the 100's of pages...
Is there a faster way of doing this? I have to support Office 2003 format files, so the OpenXML SDK isn't an option. | vb.net | word | office-interop | null | null | null | open | List fonts used by a Word Document (faster method)
===
I am working on process for validating documents to make sure that they meet corporate standards. One of the steps is to make sure that the Word document does not use non-approved fonts.
I have the following stub of code, which works:
Dim wordApplication As Word.ApplicationClass = New Word.ApplicationClass()
Dim wordDocument As Word.Document = Nothing
Dim fontList As New List(Of String)()
Try
wordDocument = wordApplication.Documents.Open(FileName:="document Path")
'ive also tried using a for loop with an integer counter, no change in speed'
For Each c As Word.Range In wordDocument.Characters
If Not fontList.Contains(c.Font.Name) Then
fontList.Add(c.Font.Name)
End If
Next
But this is **incredibly** slow! Incredibly slow = 2500 characters/minute (I timed it with StopWatch). Most of my files are around 6,000 words/30,000 characters (about 25 pages). But there are some documents that are in the 100's of pages...
Is there a faster way of doing this? I have to support Office 2003 format files, so the OpenXML SDK isn't an option. | 0 |
730,508 | 04/08/2009 15:25:06 | 31,770 | 10/27/2008 11:43:50 | 358 | 8 | Software to manage user stories | Is there a good freeware / open-source tool to manage user stories in terms of capturing and tracking stories that are currently being developed? | extreme-programming | agile-software | null | null | null | 04/22/2012 14:37:03 | not constructive | Software to manage user stories
===
Is there a good freeware / open-source tool to manage user stories in terms of capturing and tracking stories that are currently being developed? | 4 |
7,520,688 | 09/22/2011 19:57:26 | 281,839 | 02/26/2010 06:30:28 | 348 | 3 | Long text distrubed table row hight, how to manage it? | I am showing data into html table which has many columns in it. Table layout remains ok if there is small amount of data but if data in any of columns is more layout got disturbed. I have tried to fixed column sizes but even then if more data come, it disturbed table.
Can you please suggest me how it should be managed ? I want to fix sizes of columns so that even large amount of data comes column widths should remain fixed and even it should not doubled the data in rows. What is should do is if more amount of data comes it should shows the data which can be in that width of column.
| asp.net | html | css | null | null | 09/23/2011 17:57:12 | not a real question | Long text distrubed table row hight, how to manage it?
===
I am showing data into html table which has many columns in it. Table layout remains ok if there is small amount of data but if data in any of columns is more layout got disturbed. I have tried to fixed column sizes but even then if more data come, it disturbed table.
Can you please suggest me how it should be managed ? I want to fix sizes of columns so that even large amount of data comes column widths should remain fixed and even it should not doubled the data in rows. What is should do is if more amount of data comes it should shows the data which can be in that width of column.
| 1 |
11,668,838 | 07/26/2012 12:00:42 | 1,538,526 | 07/19/2012 16:24:44 | 24 | 0 | Regarding Abstract factory design pattern in java | Please explain me the concept of abstarct factory as I want to understand the concept of abstract factory design pattern , I HAVE DONE LOT OF googling and I came to analysyis is that The abstract factory pattern is a creational design pattern. An abstract factory is a factory that returns factories. | java | design-patterns | null | null | null | 07/27/2012 02:04:17 | not constructive | Regarding Abstract factory design pattern in java
===
Please explain me the concept of abstarct factory as I want to understand the concept of abstract factory design pattern , I HAVE DONE LOT OF googling and I came to analysyis is that The abstract factory pattern is a creational design pattern. An abstract factory is a factory that returns factories. | 4 |
10,930,922 | 06/07/2012 11:28:06 | 812,297 | 06/23/2011 13:22:56 | 48 | 0 | How can I call url from webview? | In my application I want to display text in web view & when click on webview link should be open. How can I do this?
In web view I want to display text like :
Name:xxxx
Address : xxxxx
Internet : WWW.google.com
Email : xyz@gmail.com
When I tap on link
Thanks in advance.
| android | null | null | null | null | 06/07/2012 16:18:43 | not a real question | How can I call url from webview?
===
In my application I want to display text in web view & when click on webview link should be open. How can I do this?
In web view I want to display text like :
Name:xxxx
Address : xxxxx
Internet : WWW.google.com
Email : xyz@gmail.com
When I tap on link
Thanks in advance.
| 1 |
3,003,494 | 06/09/2010 06:22:11 | 273,212 | 02/11/2010 02:04:56 | 171 | 4 | Regarding Shell variable | I need to call another shell script testarg.sh within my main script. This script testarg.sh has arguments ARG1 ,ARG2, ARG3. I need to call up the below way
./testarg.sh -ARG1 <value> -ARG2 <value> -ARG3
ARG1 and ARG3 argument Variables are mandatory ones. If its not passed to the main script then i quit. ARG2 is an optional one. If the ARG2 variable is not set with value or it's not defined then i need not pass it from main script.So i need to call up the below way
./testarg.sh -ARG1 <VALUE1> -ARG3
If the value exist for the ARG2 Varibale then i need to call the below way
./testarg.sh -ARG1 <VALUE1> -ARG2 <VALUE2> -ARG3
Do i need to have a if else statement for checking the ARG2 variable is empty or null. Is there any other way to do it.
| linux | shell | unix | null | null | null | open | Regarding Shell variable
===
I need to call another shell script testarg.sh within my main script. This script testarg.sh has arguments ARG1 ,ARG2, ARG3. I need to call up the below way
./testarg.sh -ARG1 <value> -ARG2 <value> -ARG3
ARG1 and ARG3 argument Variables are mandatory ones. If its not passed to the main script then i quit. ARG2 is an optional one. If the ARG2 variable is not set with value or it's not defined then i need not pass it from main script.So i need to call up the below way
./testarg.sh -ARG1 <VALUE1> -ARG3
If the value exist for the ARG2 Varibale then i need to call the below way
./testarg.sh -ARG1 <VALUE1> -ARG2 <VALUE2> -ARG3
Do i need to have a if else statement for checking the ARG2 variable is empty or null. Is there any other way to do it.
| 0 |
11,344,836 | 07/05/2012 12:57:48 | 971,116 | 09/29/2011 12:30:18 | 21 | 0 | minimizing arrays using javascript | I have two arrays like
var count=new Array("1","2","3","4","5","18","20","30","30");
var device=new Array("1","2","3","3","3","4","4","5","6");
var count=new Array("1","2","5","20","30","30");
var device=new Array("1","2","3","4","5","6");
and i want to make above first 2 lines of code in next 2 lines of code is it possible. If possible, please help me | javascript | jquery | html | null | null | 07/05/2012 13:31:22 | not a real question | minimizing arrays using javascript
===
I have two arrays like
var count=new Array("1","2","3","4","5","18","20","30","30");
var device=new Array("1","2","3","3","3","4","4","5","6");
var count=new Array("1","2","5","20","30","30");
var device=new Array("1","2","3","4","5","6");
and i want to make above first 2 lines of code in next 2 lines of code is it possible. If possible, please help me | 1 |
11,373,626 | 07/07/2012 08:51:02 | 1,503,582 | 07/05/2012 09:49:37 | 3 | 0 | API Twitter + PHP + JSON_decode | Trying to do something with the api of twitter, i got a problem... i use this url:
https://api.twitter.com/1/statuses/oembed.json?id=<id_of_tweet>&align=center
i do file_get_contents to get the json and insert to BD, before insert, i see the json have slashes and can do json_decode, but, once the string was inserted, the slashes disappear! then i cant do json_decode when the query from sql, what can i do??
thank you! | php | json | api | twitter | null | null | open | API Twitter + PHP + JSON_decode
===
Trying to do something with the api of twitter, i got a problem... i use this url:
https://api.twitter.com/1/statuses/oembed.json?id=<id_of_tweet>&align=center
i do file_get_contents to get the json and insert to BD, before insert, i see the json have slashes and can do json_decode, but, once the string was inserted, the slashes disappear! then i cant do json_decode when the query from sql, what can i do??
thank you! | 0 |
10,292,323 | 04/24/2012 05:42:33 | 821,986 | 06/29/2011 21:34:48 | 331 | 4 | Rewrite parts of old content to target new ads? | I have a website with a lot of visitors, but very poorly targeted ads. 90% of traffic comes from alt text in images. The theme is celebrities. Here's my question:
Can I change / add / rewrite content to target new types of ads; content as old as 6 + months?
As of now, the posts are merely short snippets on a little bit about each celebrity; the images (alt text) bring the traffic. I would want to rewrite content on each page to use a lot of plastic surgery related keywords. This would obviously target a niche and much higher paying ads.
*Since the traffic isn't really coming from the text to begin with:*
- Would this cause a loss in traffic?
- Would this target new ads and if so how long would it take for
changes to take place? | html | optimization | seo | keywords | adsense | 04/25/2012 12:13:25 | off topic | Rewrite parts of old content to target new ads?
===
I have a website with a lot of visitors, but very poorly targeted ads. 90% of traffic comes from alt text in images. The theme is celebrities. Here's my question:
Can I change / add / rewrite content to target new types of ads; content as old as 6 + months?
As of now, the posts are merely short snippets on a little bit about each celebrity; the images (alt text) bring the traffic. I would want to rewrite content on each page to use a lot of plastic surgery related keywords. This would obviously target a niche and much higher paying ads.
*Since the traffic isn't really coming from the text to begin with:*
- Would this cause a loss in traffic?
- Would this target new ads and if so how long would it take for
changes to take place? | 2 |
1,835,976 | 12/02/2009 21:35:00 | 21,499 | 09/24/2008 05:41:57 | 895 | 33 | What is a sensible prime for hashcode calculation? | Eclipse 3.5 has a very nice feature to generate Java hashCode() functions. It would generate for example (slightly shortened:)
class HashTest {
int i;
int j;
public int hashCode() {
final int prime = 31;
int result = prime + i;
return prime * result + j;
}
}
This seems fine but for the choice 31 for the prime. It is probably taken from the [hashCode implementation of Java String][1], which was used for performance reasons that are long gone after the introduction of hardware multipliers. Here you have many hashcode collisions for small values of i and j: for example (0,0) and (-1,31) have the same value. I think that is a Bad Thing(TM), since small values occur often. For String.hashCode you'll also find many short strings with the same hashcode, for instance "Ca" and "DB". If you take a large prime, this problem disappears if you choose the prime right.
So my question: what is a good prime to choose? What criteria do you apply to find it?
[1]: http://stackoverflow.com/questions/299304/why-does-javas-hashcode-in-string-use-31-as-a-multiplier | hashcode | java | primes | null | null | null | open | What is a sensible prime for hashcode calculation?
===
Eclipse 3.5 has a very nice feature to generate Java hashCode() functions. It would generate for example (slightly shortened:)
class HashTest {
int i;
int j;
public int hashCode() {
final int prime = 31;
int result = prime + i;
return prime * result + j;
}
}
This seems fine but for the choice 31 for the prime. It is probably taken from the [hashCode implementation of Java String][1], which was used for performance reasons that are long gone after the introduction of hardware multipliers. Here you have many hashcode collisions for small values of i and j: for example (0,0) and (-1,31) have the same value. I think that is a Bad Thing(TM), since small values occur often. For String.hashCode you'll also find many short strings with the same hashcode, for instance "Ca" and "DB". If you take a large prime, this problem disappears if you choose the prime right.
So my question: what is a good prime to choose? What criteria do you apply to find it?
[1]: http://stackoverflow.com/questions/299304/why-does-javas-hashcode-in-string-use-31-as-a-multiplier | 0 |
7,596,350 | 09/29/2011 11:00:37 | 811,785 | 06/23/2011 07:50:59 | 2,863 | 247 | What are the security risks in using cross-domain XMLHttpRequest? | In many places I've seen people have talked about the Cross-Domain XMLHttpRequest, which is not possible, due to some **security reasons**. However, I haven't found a post indicating what those **security reasons** actually are?
People have mentioned that JSONP is one of the good alternatives. Another alternative would be to use `Origin` and `Access-Control-Allow-Origin` headers.
However, I just want to know what security problems can be raised due to cross-domain XMLHttpRequest usage? | ajax | security | xmlhttprequest | cross-domain | null | null | open | What are the security risks in using cross-domain XMLHttpRequest?
===
In many places I've seen people have talked about the Cross-Domain XMLHttpRequest, which is not possible, due to some **security reasons**. However, I haven't found a post indicating what those **security reasons** actually are?
People have mentioned that JSONP is one of the good alternatives. Another alternative would be to use `Origin` and `Access-Control-Allow-Origin` headers.
However, I just want to know what security problems can be raised due to cross-domain XMLHttpRequest usage? | 0 |
7,950,282 | 10/31/2011 05:36:42 | 861,739 | 07/25/2011 14:14:47 | 37 | 9 | Open Excel sheet in share point page/webpart itself | In share point 2010, I would like to have an excel sheet(2007) in sharepoint site, where the Excel sheet should be displayed in the site itself (Possibly a webpart).
**And the users should able to edit the excel sheet from webpart itself** (No need to open the Excel sheet in seperate MS Excel). I meant adding new rows of data and editing existing the rows.
I come across various posts regarding the above issue, [like this][1].
[1]: http://www.learningsharepoint.com/2010/10/25/create-excel-web-access-web-part-in-sharepoint-2010-tutorial/
How ever I am unable to get the category 'Office Client Applications' under insert webparts.
Please help me on this.
Can anyone please give me a suitable link or tips for achieving the above?
Many Thanks !! | excel | sharepoint | sharepoint2010 | null | null | null | open | Open Excel sheet in share point page/webpart itself
===
In share point 2010, I would like to have an excel sheet(2007) in sharepoint site, where the Excel sheet should be displayed in the site itself (Possibly a webpart).
**And the users should able to edit the excel sheet from webpart itself** (No need to open the Excel sheet in seperate MS Excel). I meant adding new rows of data and editing existing the rows.
I come across various posts regarding the above issue, [like this][1].
[1]: http://www.learningsharepoint.com/2010/10/25/create-excel-web-access-web-part-in-sharepoint-2010-tutorial/
How ever I am unable to get the category 'Office Client Applications' under insert webparts.
Please help me on this.
Can anyone please give me a suitable link or tips for achieving the above?
Many Thanks !! | 0 |
9,680,638 | 03/13/2012 08:37:12 | 108,105 | 05/16/2009 09:32:00 | 5,279 | 179 | Can I set a custom function that will alter the color of a display list in OpenGL? | I have geometry stored in a display list, but I'd like to be able to draw the same display list with different "tints" on them. For example, if I had a black and white skull in a display list, I'd like to set a red tint and draw a skull, then set a blue tint and draw the skull.
If I can get the RGBA values I know exactly how to transform them, but I'm not sure where I can intercept them. Currently the display lists do not contain textures, but they probably will in the future so it would be good if the answer works with or without textures. | opengl | blending | displaylist | null | null | null | open | Can I set a custom function that will alter the color of a display list in OpenGL?
===
I have geometry stored in a display list, but I'd like to be able to draw the same display list with different "tints" on them. For example, if I had a black and white skull in a display list, I'd like to set a red tint and draw a skull, then set a blue tint and draw the skull.
If I can get the RGBA values I know exactly how to transform them, but I'm not sure where I can intercept them. Currently the display lists do not contain textures, but they probably will in the future so it would be good if the answer works with or without textures. | 0 |
1,621,697 | 10/25/2009 18:50:12 | 196,270 | 10/25/2009 18:39:14 | 1 | 0 | Getting Stack overflow with GNU CLisp (Windows) | I'm getting "Program stack overflow RESET" message while running my program. So I set added a counter to see how many times I'm recursively calling the main function in my program. Turns out that it is around 30,000 times and the data I'm stacking are lists of length around 10 elements, which I think are not so many. My question is whether this amount of recursive call and memory usage are common or not, or is it more likely that I'm doing something wrong? I checked the resource manager of vista and found the memory only grew for like 1MB for lisp.exe process. And how do I adjust the stack overflow limit of CLisp? | common-lisp | clisp | stackoverflow | null | null | null | open | Getting Stack overflow with GNU CLisp (Windows)
===
I'm getting "Program stack overflow RESET" message while running my program. So I set added a counter to see how many times I'm recursively calling the main function in my program. Turns out that it is around 30,000 times and the data I'm stacking are lists of length around 10 elements, which I think are not so many. My question is whether this amount of recursive call and memory usage are common or not, or is it more likely that I'm doing something wrong? I checked the resource manager of vista and found the memory only grew for like 1MB for lisp.exe process. And how do I adjust the stack overflow limit of CLisp? | 0 |
2,587,424 | 04/06/2010 18:49:09 | 156,888 | 08/15/2009 10:55:56 | 126 | 21 | Three20 monotouch/btouch examples? | Does anyone know of any examples or tutorials working with the three20 btouch dll?
I have no idea where to start!
w://
| monotouch | three20 | iphone | null | null | 09/14/2011 07:53:19 | too localized | Three20 monotouch/btouch examples?
===
Does anyone know of any examples or tutorials working with the three20 btouch dll?
I have no idea where to start!
w://
| 3 |
9,509,456 | 03/01/2012 01:38:09 | 1,241,613 | 03/01/2012 01:23:44 | 1 | 0 | Java (conditional operators) | ***Here is the deal. I am working on a project for my into to Java class. I am familiar with a few other languages so I do understand basic coding. However, I am very much so a java noob. Please forgive me if this is a very simple problem to solve.
I have written the program several time but talking with my professor he is not satisfied. The program I have written perform exactly what is required but not in the way he wants.
I will first display the programming assignment then the code I have written. I understand how to write the control class but I am having problem with the object class.***
**Here is my programming assignment:**
Write a program to control a bread machine. You should ask the user to specify:
The type of bread (white or sweet),
The size of the loaf (normal or double), and
The manner of baking (automatic or manual).
The following table details the time chart for the machine for each bread type. Since we don't really have a bread machine to control, you should instead display an output line for each step of the process. If the loaf size is double, increase the baking time by 50%. If baking is manual, stop after the loaf-shaping cycle and instruct the user to remove the dough for manual baking.
Operation White Bread Sweet Bread
-------------------------- -------------------------- --------------------------
Primary kneading 15 minutes 20 minutes
Primary rising 60 minutes 60 minutes
Secondary kneading 18 minutes 32 minutes
Loaf shaping 2 seconds 2 seconds
Final rising 80 minutes 80 minutes
Baking 45 minutes 35 minutes
Cooling 40 minutes 40 minutes
Specific Instructions
Your program will consist of 2 classes: a control class (named BreadControl) and an object class (named BreadMachine).
When you begin, create the outlines of the 2 classes.
Initially, the BreadControl class should include the class definition and the main method definition (just the signatures, braces, and class and method comments). This class requires only a single method, which is main().
The BreadMachine class should "represent" a bread machine. Begin with the class definition and definitions for any methods that might appear obvious (although this may change as you work through this). This class will have multiple methods, including both public and private methods that work together to solve the problem of managing a BreadMachine.
Working top down, develop the algorithms that you will need to accomplish this program. You should work this out in externally to the java program (in pseudocode, for example). Determine the major tasks first. Then work out the subtasks that each will need to accomplish. There should be multiple methods in the BreadMachine class. (Some should be public, and others should be private.)
For example, each step of the bread making process should be in its own method. As you work, think about the variables, variable types, constants, and object references you will need to make this work. Declare these variables, constants, and references at the beginning of the BreadMachine class. If you are including constants, declare them together at the end of the declarations section.
The BreadMachineclass should have no System.out.println() [or print()] statements. Nor should the BreadMachineclass have need of a Scanner or Keyboard.
Create a user-interface for your program. This should be in the BreadControl class. (All user interaction should be here). Provide an attractive greeting and then ask the user
What type of bread they intend to make,
Whether they are making a double loaf, and
Whether they are going to manually bake the bread.
An example of what the input should look like can be found in this document.
Using these values, create the BreadMachine object and run its starting method (I would recommend starting with a method called bake() that returned the String to be printed.)
The values sent to the BreadMachine should be stored in that object as instance (class or global) variables. You should use boolean variables (true/false) to store the double loaf and manual bake values.
Once you are certain that your algorithms are correct (desk check this first!), enter it into your java program into the appropriate method(s).
The BreadMachine object should return a String that details the steps followed to bake the type of bread required.
***Here is the code for my method. Be aware that this is the format required of me, So please do not say I could do it in a much different way. I am simply trying to figure out why this does not work since I did a majority of this with my professor:***
public class BreadMachine
{
private double time;
private String manner;
private String result;
private String size;
private String type;
/**
*
*Constructor
*
*
*
*/
public BreadMachine ( String t, String s, String m )// constructor
{
manner = m;
size = s;
type = t;
} // end constructor
// instantations
public String bakeBread()
{
result = doStageOne();
result += doStageTwo();
return result;
}
//---------------- private methods -------------------
/**
*
*
*
*
*/
private String doStageOne()
{
result = doPrimaryKneading();
result += doPrimaryRising();
result += doSecondaryKneading();
result += doShaping();
return result;
}
private String doPrimaryKneading()
{
time = type == ('w') ? 15 : 20;
result = "Primary Kneading (" + time + "minutes )";
}
private String doPrimaryRising()
{
time = 60;
result = "Primary Rising (" + time + "minutes )";
}
private String doSecondaryKneading()
{
time = type == ('w') ? 18 : 32;
result = "Secondary Kneading (" + time + "minutes)";
}
private String doShaping()
{
time = 2;
result = "Shaping (" + time + "seconds)";
}
private String doStageTwo()
{
String result;
result = doFinalRising();
result += doBaking();
result += doCooling();
return result;
}
private String doFinalRising()
{
if ( isManual() )
{
result = "Remove for Manual Baking";
}
else
{
time = 80;
result = "Final Rising (" + time + "minutes)";
}
}
private boolean isManual()
{
boolean response = false;
if ( method.CharAt == 'm')
response = true;
return response;
}
private String doBaking()
{
if ( isDouble())
{
time = type == 'w' ? 67.5 : 52.5 ;
result = "Shaping (" + time + "minutes)";
}
else{
time = type == 'w' ? 45 : 35;
}
result = "Shaping (" + time + "minutes)";
}
private boolean isDouble()
{
boolean response = false;
if ( method.CharAt == 'd')
response = true;
return response;
}
private String doCooling()
{
time = 40;
result = "Cooling (" + time + "minutes)";
}
}
| java | null | null | null | null | 03/01/2012 01:44:45 | too localized | Java (conditional operators)
===
***Here is the deal. I am working on a project for my into to Java class. I am familiar with a few other languages so I do understand basic coding. However, I am very much so a java noob. Please forgive me if this is a very simple problem to solve.
I have written the program several time but talking with my professor he is not satisfied. The program I have written perform exactly what is required but not in the way he wants.
I will first display the programming assignment then the code I have written. I understand how to write the control class but I am having problem with the object class.***
**Here is my programming assignment:**
Write a program to control a bread machine. You should ask the user to specify:
The type of bread (white or sweet),
The size of the loaf (normal or double), and
The manner of baking (automatic or manual).
The following table details the time chart for the machine for each bread type. Since we don't really have a bread machine to control, you should instead display an output line for each step of the process. If the loaf size is double, increase the baking time by 50%. If baking is manual, stop after the loaf-shaping cycle and instruct the user to remove the dough for manual baking.
Operation White Bread Sweet Bread
-------------------------- -------------------------- --------------------------
Primary kneading 15 minutes 20 minutes
Primary rising 60 minutes 60 minutes
Secondary kneading 18 minutes 32 minutes
Loaf shaping 2 seconds 2 seconds
Final rising 80 minutes 80 minutes
Baking 45 minutes 35 minutes
Cooling 40 minutes 40 minutes
Specific Instructions
Your program will consist of 2 classes: a control class (named BreadControl) and an object class (named BreadMachine).
When you begin, create the outlines of the 2 classes.
Initially, the BreadControl class should include the class definition and the main method definition (just the signatures, braces, and class and method comments). This class requires only a single method, which is main().
The BreadMachine class should "represent" a bread machine. Begin with the class definition and definitions for any methods that might appear obvious (although this may change as you work through this). This class will have multiple methods, including both public and private methods that work together to solve the problem of managing a BreadMachine.
Working top down, develop the algorithms that you will need to accomplish this program. You should work this out in externally to the java program (in pseudocode, for example). Determine the major tasks first. Then work out the subtasks that each will need to accomplish. There should be multiple methods in the BreadMachine class. (Some should be public, and others should be private.)
For example, each step of the bread making process should be in its own method. As you work, think about the variables, variable types, constants, and object references you will need to make this work. Declare these variables, constants, and references at the beginning of the BreadMachine class. If you are including constants, declare them together at the end of the declarations section.
The BreadMachineclass should have no System.out.println() [or print()] statements. Nor should the BreadMachineclass have need of a Scanner or Keyboard.
Create a user-interface for your program. This should be in the BreadControl class. (All user interaction should be here). Provide an attractive greeting and then ask the user
What type of bread they intend to make,
Whether they are making a double loaf, and
Whether they are going to manually bake the bread.
An example of what the input should look like can be found in this document.
Using these values, create the BreadMachine object and run its starting method (I would recommend starting with a method called bake() that returned the String to be printed.)
The values sent to the BreadMachine should be stored in that object as instance (class or global) variables. You should use boolean variables (true/false) to store the double loaf and manual bake values.
Once you are certain that your algorithms are correct (desk check this first!), enter it into your java program into the appropriate method(s).
The BreadMachine object should return a String that details the steps followed to bake the type of bread required.
***Here is the code for my method. Be aware that this is the format required of me, So please do not say I could do it in a much different way. I am simply trying to figure out why this does not work since I did a majority of this with my professor:***
public class BreadMachine
{
private double time;
private String manner;
private String result;
private String size;
private String type;
/**
*
*Constructor
*
*
*
*/
public BreadMachine ( String t, String s, String m )// constructor
{
manner = m;
size = s;
type = t;
} // end constructor
// instantations
public String bakeBread()
{
result = doStageOne();
result += doStageTwo();
return result;
}
//---------------- private methods -------------------
/**
*
*
*
*
*/
private String doStageOne()
{
result = doPrimaryKneading();
result += doPrimaryRising();
result += doSecondaryKneading();
result += doShaping();
return result;
}
private String doPrimaryKneading()
{
time = type == ('w') ? 15 : 20;
result = "Primary Kneading (" + time + "minutes )";
}
private String doPrimaryRising()
{
time = 60;
result = "Primary Rising (" + time + "minutes )";
}
private String doSecondaryKneading()
{
time = type == ('w') ? 18 : 32;
result = "Secondary Kneading (" + time + "minutes)";
}
private String doShaping()
{
time = 2;
result = "Shaping (" + time + "seconds)";
}
private String doStageTwo()
{
String result;
result = doFinalRising();
result += doBaking();
result += doCooling();
return result;
}
private String doFinalRising()
{
if ( isManual() )
{
result = "Remove for Manual Baking";
}
else
{
time = 80;
result = "Final Rising (" + time + "minutes)";
}
}
private boolean isManual()
{
boolean response = false;
if ( method.CharAt == 'm')
response = true;
return response;
}
private String doBaking()
{
if ( isDouble())
{
time = type == 'w' ? 67.5 : 52.5 ;
result = "Shaping (" + time + "minutes)";
}
else{
time = type == 'w' ? 45 : 35;
}
result = "Shaping (" + time + "minutes)";
}
private boolean isDouble()
{
boolean response = false;
if ( method.CharAt == 'd')
response = true;
return response;
}
private String doCooling()
{
time = 40;
result = "Cooling (" + time + "minutes)";
}
}
| 3 |
8,363,323 | 12/02/2011 22:10:25 | 860,947 | 07/25/2011 05:25:48 | 6 | 1 | Need Core Requirements and Considerations for Internet Appliction | I'm developing this list as a checklist for complex application development for my start-up consulting business. This list is focused on web development atm, but I believe for the most part, it applies to application programming in general.
I'm asking for the community to contribute and critique my list, I'll be updating the list as I get more suggestions from the community.
For example:
- Security and Stability
- Authentication(Login)
- Password Reset
- Hashed and Salted Passwords
- Authorization(Role Based Access)
- XSS Prevention
- Dual Firewall(public facing/private facing for database)
- SQL Injection
- Data Integrity
- Data Redundancy
.
- Scalability
- Clustering
- Caching
- Import/Export
- Reporting(Performance[speed]and Usage[page hits])
.
- Testing
- Load Testing
- Unit Testing
- Performance Testing
- Error Logging
.
- Others
- Localization
- Configuration Management
- Searching
- Reporting(according to business need) | design | web-applications | architecture | null | null | 12/03/2011 17:57:12 | off topic | Need Core Requirements and Considerations for Internet Appliction
===
I'm developing this list as a checklist for complex application development for my start-up consulting business. This list is focused on web development atm, but I believe for the most part, it applies to application programming in general.
I'm asking for the community to contribute and critique my list, I'll be updating the list as I get more suggestions from the community.
For example:
- Security and Stability
- Authentication(Login)
- Password Reset
- Hashed and Salted Passwords
- Authorization(Role Based Access)
- XSS Prevention
- Dual Firewall(public facing/private facing for database)
- SQL Injection
- Data Integrity
- Data Redundancy
.
- Scalability
- Clustering
- Caching
- Import/Export
- Reporting(Performance[speed]and Usage[page hits])
.
- Testing
- Load Testing
- Unit Testing
- Performance Testing
- Error Logging
.
- Others
- Localization
- Configuration Management
- Searching
- Reporting(according to business need) | 2 |
11,563,838 | 07/19/2012 15:11:38 | 2,959 | 08/26/2008 09:00:33 | 10,596 | 209 | WebView in Cocoa not rendering | In my window controller, I have this:
- (void)windowDidLoad {
[super windowDidLoad];
NSLog(@"webView = %@", webView);
[[webView mainFrame] loadRequest:
[NSURLRequest requestWithURL:
[NSURL URLWithString:@"http://www.apple.com/"]]];
}
My understanding is that should make the webView in my window now download and render Apple's home page. But all I see in a white panel. What am I missing?
(I've checked that webView is not null; NSLog shows something like "webView = <WebView: 0x10be7c3b0>")
| objective-c | osx | cocoa | null | null | null | open | WebView in Cocoa not rendering
===
In my window controller, I have this:
- (void)windowDidLoad {
[super windowDidLoad];
NSLog(@"webView = %@", webView);
[[webView mainFrame] loadRequest:
[NSURLRequest requestWithURL:
[NSURL URLWithString:@"http://www.apple.com/"]]];
}
My understanding is that should make the webView in my window now download and render Apple's home page. But all I see in a white panel. What am I missing?
(I've checked that webView is not null; NSLog shows something like "webView = <WebView: 0x10be7c3b0>")
| 0 |
7,036,185 | 08/12/2011 06:07:19 | 891,196 | 08/12/2011 06:01:41 | 1 | 0 | Free OCR SDK for .net which can extract text,tables with format and images into Office word document | I want to have a free OCR SDK which can extract text, tables with data and images from scanned document files (.tiff,.png etc) and store into Office Word document file.
Please help me to short out this issue. I have already done extracting text only from images using MODI but could not get the way using MODI how to extract tables and images and store into Office Word Document file.
Please.... Please...
Thanks
Laxman
| c# | null | null | null | null | 06/05/2012 23:27:49 | not constructive | Free OCR SDK for .net which can extract text,tables with format and images into Office word document
===
I want to have a free OCR SDK which can extract text, tables with data and images from scanned document files (.tiff,.png etc) and store into Office Word document file.
Please help me to short out this issue. I have already done extracting text only from images using MODI but could not get the way using MODI how to extract tables and images and store into Office Word Document file.
Please.... Please...
Thanks
Laxman
| 4 |
4,461,130 | 12/16/2010 13:17:40 | 429,396 | 08/24/2010 10:36:41 | 25 | 0 | Django: what is the most appropriate way to provide administrators with the ability to change small snippets of text | Using Django, what is the most appropriate way to provide administrators with the ability to change small snippets of text, for example in one of my sites there is a small piece of text on the front page I would like the administrator to be able to easily change in the backend, however I do not want to create a whole new app or model because then they would be able to create more than one area of text in this way, but I only want it to show up in one place on the homepage.
Any advice? | django | django-models | django-admin | null | null | null | open | Django: what is the most appropriate way to provide administrators with the ability to change small snippets of text
===
Using Django, what is the most appropriate way to provide administrators with the ability to change small snippets of text, for example in one of my sites there is a small piece of text on the front page I would like the administrator to be able to easily change in the backend, however I do not want to create a whole new app or model because then they would be able to create more than one area of text in this way, but I only want it to show up in one place on the homepage.
Any advice? | 0 |
9,965,519 | 04/01/2012 15:17:06 | 1,306,439 | 04/01/2012 15:09:07 | 1 | 0 | Is it possible that an OS written by java? | We know Windows Linux Mac OS is written by C/C++
Do you think it is possible that someday an OS is written by JAVA? | java | null | null | null | null | 04/01/2012 15:19:40 | not constructive | Is it possible that an OS written by java?
===
We know Windows Linux Mac OS is written by C/C++
Do you think it is possible that someday an OS is written by JAVA? | 4 |
1,124,712 | 07/14/2009 11:08:20 | 20,400 | 09/22/2008 12:12:36 | 3,979 | 157 | Good tool for system design in Java/Eclipse? | Does anyone know of a good tool for laying out class diagrams and the like for eclipse?
Preferably soemthing that will let me draw up the relationships between the classes/interfaces and will then generate stub code for me to fill in.
I've just been handed a 288 page API doc and told to implement it in Java and I want to make sure I have a good design before I start writing code. | java | eclipse | oop | null | null | null | open | Good tool for system design in Java/Eclipse?
===
Does anyone know of a good tool for laying out class diagrams and the like for eclipse?
Preferably soemthing that will let me draw up the relationships between the classes/interfaces and will then generate stub code for me to fill in.
I've just been handed a 288 page API doc and told to implement it in Java and I want to make sure I have a good design before I start writing code. | 0 |
8,150,058 | 11/16/2011 10:22:50 | 494,050 | 11/01/2010 20:45:06 | 15 | 0 | Erlyvideo configuration file | I am going to use Erlyvideo to turn an RTSP stream into an RTMP steam, making it possible to pick it up in Adobe Flash. However, I'm having some problems finding the right way to configure it. What's the simplest way to modify the .conf file to achieve this? | flash | erlang | rtsp | rtmp | null | 11/17/2011 15:57:32 | off topic | Erlyvideo configuration file
===
I am going to use Erlyvideo to turn an RTSP stream into an RTMP steam, making it possible to pick it up in Adobe Flash. However, I'm having some problems finding the right way to configure it. What's the simplest way to modify the .conf file to achieve this? | 2 |
11,294,943 | 07/02/2012 13:43:13 | 1,263,746 | 03/12/2012 09:28:43 | 49 | 1 | Apache sudoers access | I am making a system call from php which is
`sudo /usr/bin/perl -pi -e 's/foo/bar/g' /tmp/newxml.xml`;
which works fine in php cli. But would not work in php via browser, because apache does not have required execution permissions. How do I make apache a sudoer to allow to run only /usr/bin/perl ?
I understand that will have to edit /etc/sudoers to do this, but I am not sure how its to be done. Any pointers?
I am running RHEL 5.5 | php | perl | apache | rhel | sudoers | 07/02/2012 15:25:43 | off topic | Apache sudoers access
===
I am making a system call from php which is
`sudo /usr/bin/perl -pi -e 's/foo/bar/g' /tmp/newxml.xml`;
which works fine in php cli. But would not work in php via browser, because apache does not have required execution permissions. How do I make apache a sudoer to allow to run only /usr/bin/perl ?
I understand that will have to edit /etc/sudoers to do this, but I am not sure how its to be done. Any pointers?
I am running RHEL 5.5 | 2 |
9,681,574 | 03/13/2012 09:41:15 | 256,405 | 01/22/2010 04:02:40 | 918 | 19 | Arranged/ordered checkbox for a one-to-many relationship in CoreData | In Xcode's data model inspector, when a relationship is selected, there is checkbox a between labels "Arranged" and "Ordered". CoreData works with sets, so what exactly does it mean in this context? | ios | xcode | core-data | null | null | null | open | Arranged/ordered checkbox for a one-to-many relationship in CoreData
===
In Xcode's data model inspector, when a relationship is selected, there is checkbox a between labels "Arranged" and "Ordered". CoreData works with sets, so what exactly does it mean in this context? | 0 |
10,976,371 | 06/11/2012 08:03:18 | 1,435,556 | 06/04/2012 16:11:42 | 35 | 0 | How to restore the information_schema database with a backup | I have a backup from a WAMP server MYSQL database from home and I need to install it on my work WAMP setup.
Here is the phpmyadmin message:
SQL query:
--
-- Database: `information_schema`
--
CREATE DATABASE `information_schema` DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci;
MySQL said:
#1044 - Access denied for user 'root'@'localhost' to database 'information_schema'
The information_schema database appears to be locked and the restore fails in phpmyadmin. In the MYSQL Workbench it carries on through the backup ignoring the "access denied" messages but crashes halfway through.
I have tried removeing the database_schema lines in the sql file but it just looks like a mess of text and can't figure out how to remove it.
Another thing is will I actually need it? Or can I remove it. I'm not too sure what information is stored there.
Thank you. | php | mysql | phpmyadmin | wamp | information-schema | null | open | How to restore the information_schema database with a backup
===
I have a backup from a WAMP server MYSQL database from home and I need to install it on my work WAMP setup.
Here is the phpmyadmin message:
SQL query:
--
-- Database: `information_schema`
--
CREATE DATABASE `information_schema` DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci;
MySQL said:
#1044 - Access denied for user 'root'@'localhost' to database 'information_schema'
The information_schema database appears to be locked and the restore fails in phpmyadmin. In the MYSQL Workbench it carries on through the backup ignoring the "access denied" messages but crashes halfway through.
I have tried removeing the database_schema lines in the sql file but it just looks like a mess of text and can't figure out how to remove it.
Another thing is will I actually need it? Or can I remove it. I'm not too sure what information is stored there.
Thank you. | 0 |
7,837,674 | 10/20/2011 14:43:14 | 824,904 | 05/05/2011 12:44:47 | 128 | 1 | javascript simple while loop not looping through array.(should be easy) | Ok so this is my dumb problem. im here learning and...ive been looking at this for a while and i dont understand. i have an array with some values that are fed via an object. like so:
function blogObj(name,date,user_entry){
this.names = name;
this.dates = date;
this.blog_entry = user_entry;
this.propsComb = this.names + this.dates + this.blog_entry;
}
var blogRun = [
new blogObj("name ", "something ", "something "),
new blogObj("name ", "something ", "something "),
new blogObj("name ", "something ", "something "),
new blogObj("name ", "something ", "something "),
new blogObj("name ", "something ", "something "),
];
var i=0;
var mssgs = "";
now when i loop through it like this with this doc.write to test:
function hmm(){
while(i < blogRun.length){
mssgs = blogRun[i].propsComb + '<br/>';
document.write(mssgs);
i++;
}
}
i get all the values i need which are name something something x5 as per the loop and the values of the array. so essentially it works.
now when i replace the `"document.write(mssgs)"` with
document.getElementById('showMore').innerHTML = mssgs;
making it this
function hmm(){
while(i < blogRun.length){
mssgs = blogRun[i].propsComb + '<br/>';
//document.write(mssgs);
document.getElementById('showMore').innerHTML = mssgs;
i++;
}
}
it only shows me the last value of the array. it doesnt loop for the rest of the arrays values.
all im doing is replacing the .write with getElementById etc..
any ideas? thank you in advance.
| javascript | null | null | null | null | null | open | javascript simple while loop not looping through array.(should be easy)
===
Ok so this is my dumb problem. im here learning and...ive been looking at this for a while and i dont understand. i have an array with some values that are fed via an object. like so:
function blogObj(name,date,user_entry){
this.names = name;
this.dates = date;
this.blog_entry = user_entry;
this.propsComb = this.names + this.dates + this.blog_entry;
}
var blogRun = [
new blogObj("name ", "something ", "something "),
new blogObj("name ", "something ", "something "),
new blogObj("name ", "something ", "something "),
new blogObj("name ", "something ", "something "),
new blogObj("name ", "something ", "something "),
];
var i=0;
var mssgs = "";
now when i loop through it like this with this doc.write to test:
function hmm(){
while(i < blogRun.length){
mssgs = blogRun[i].propsComb + '<br/>';
document.write(mssgs);
i++;
}
}
i get all the values i need which are name something something x5 as per the loop and the values of the array. so essentially it works.
now when i replace the `"document.write(mssgs)"` with
document.getElementById('showMore').innerHTML = mssgs;
making it this
function hmm(){
while(i < blogRun.length){
mssgs = blogRun[i].propsComb + '<br/>';
//document.write(mssgs);
document.getElementById('showMore').innerHTML = mssgs;
i++;
}
}
it only shows me the last value of the array. it doesnt loop for the rest of the arrays values.
all im doing is replacing the .write with getElementById etc..
any ideas? thank you in advance.
| 0 |
9,469,886 | 02/27/2012 18:04:45 | 352,707 | 05/14/2010 06:24:01 | 234 | 0 | Integrate google+ in iphone? | Is it possibele to share data on google plus from the application same as facebook and twitter.?
Please help me for this query | iphone | null | null | null | null | 02/27/2012 20:57:56 | not a real question | Integrate google+ in iphone?
===
Is it possibele to share data on google plus from the application same as facebook and twitter.?
Please help me for this query | 1 |
2,456,496 | 03/16/2010 17:07:35 | 72,136 | 02/28/2009 05:19:19 | 774 | 47 | programicly tigger a Copy or paste in c# | I have a program that I'm working on that register global hotkeys
I would like to use that ability to trigger highlighted text or data to be copied to the clipboard and then read from the clipboard into a variable in my program
which i will later use in reverse to paste it back out.
(example ctrl+1 copys to quque #1 and alt+1 pasts what is in quque 1)
thanks so much. | copy-paste | c# | .net | null | null | null | open | programicly tigger a Copy or paste in c#
===
I have a program that I'm working on that register global hotkeys
I would like to use that ability to trigger highlighted text or data to be copied to the clipboard and then read from the clipboard into a variable in my program
which i will later use in reverse to paste it back out.
(example ctrl+1 copys to quque #1 and alt+1 pasts what is in quque 1)
thanks so much. | 0 |
11,708,848 | 07/29/2012 11:26:20 | 336,752 | 05/09/2010 18:10:01 | 82 | 5 | Github workflow for single developer | I would like some feedback on my git workflow because this is my first use of it and despite reading various articles and Stack Overflow questions, I'm not sure that my process is correct. This is my current workflow (note that I am using the Github for Windows application for all of my git interactions):
1. Decide what the next feature is that I'm going to implement.
2. Create a branch with a suitably descriptive name for the feature. I do this by clicking on the branch button in Github for Windows and typing a new name.
3. Write some code.
4. Commit those changes to my new branch.
5. Write some more code.
6. Commit those changes to my new branch.
7. I've finished implementing the feature so I want to merge my changes back to the master branch. So I click on the 'manage' button underneath the branch heading.
8. Merge the new branch into the master branch.
9. Delete the new branch.
I am quite happy with the process up until step 7 at which point I am a little confused. I think my confusion lies in the fact that I'm trying to use the Github for Windows application rather than using the command line. The application does seem to make things easier but there is a bit of a disconnect in my understanding between some of the commands/instructions I see mentioned and the actions you would take in the application.
Let me ask some specific questions:
1. Is my workflow actually correct? If not, what is wrong with it and how can I improve it?
2. Should I be "publishing" my changes to the new branch? My understanding is that this is the equivalent of doing `git push` at the command line. Is that true? If so I think I would only want to do that when I am either finished implementing the feature or it is in a decent state?
3. Should I be deleting the branch when I have merged it into the master branch or should it be left around forever?
4. Do I need to publish the master branch when I have completed the merge or is this implicit?
5. I am sometimes unable to perform the merge and get this error message:
> Unable to merge
>
> Failed to merge 'test' into 'master'. You might need to open a shell and debug the state of this repo.
When this occurred before, I was able to change to the master branch and merge the new branch into the master branch however that no longer works. No matter which branch I am in, I cannot merge the two branches. Both are in sync and I've published all the changes from my test branch. What should I be typing in the shell to find out why I can't merge the branches?
For reference, these are the main links that have prompted my process:
1. [Scott Chacon on the workflow at Gitub][1]
2. [Git workflow for a single developer on a local repository][2]
3. [Git workflow for a single user][3]
[1]: http://scottchacon.com/2011/08/31/github-flow.html]
[2]: http://stackoverflow.com/questions/4056372/git-workflow-for-a-single-developer-on-a-local-repository
[3]: http://stackoverflow.com/questions/3007352/git-workflow-for-single-user | git | github | workflow | github-for-windows | null | null | open | Github workflow for single developer
===
I would like some feedback on my git workflow because this is my first use of it and despite reading various articles and Stack Overflow questions, I'm not sure that my process is correct. This is my current workflow (note that I am using the Github for Windows application for all of my git interactions):
1. Decide what the next feature is that I'm going to implement.
2. Create a branch with a suitably descriptive name for the feature. I do this by clicking on the branch button in Github for Windows and typing a new name.
3. Write some code.
4. Commit those changes to my new branch.
5. Write some more code.
6. Commit those changes to my new branch.
7. I've finished implementing the feature so I want to merge my changes back to the master branch. So I click on the 'manage' button underneath the branch heading.
8. Merge the new branch into the master branch.
9. Delete the new branch.
I am quite happy with the process up until step 7 at which point I am a little confused. I think my confusion lies in the fact that I'm trying to use the Github for Windows application rather than using the command line. The application does seem to make things easier but there is a bit of a disconnect in my understanding between some of the commands/instructions I see mentioned and the actions you would take in the application.
Let me ask some specific questions:
1. Is my workflow actually correct? If not, what is wrong with it and how can I improve it?
2. Should I be "publishing" my changes to the new branch? My understanding is that this is the equivalent of doing `git push` at the command line. Is that true? If so I think I would only want to do that when I am either finished implementing the feature or it is in a decent state?
3. Should I be deleting the branch when I have merged it into the master branch or should it be left around forever?
4. Do I need to publish the master branch when I have completed the merge or is this implicit?
5. I am sometimes unable to perform the merge and get this error message:
> Unable to merge
>
> Failed to merge 'test' into 'master'. You might need to open a shell and debug the state of this repo.
When this occurred before, I was able to change to the master branch and merge the new branch into the master branch however that no longer works. No matter which branch I am in, I cannot merge the two branches. Both are in sync and I've published all the changes from my test branch. What should I be typing in the shell to find out why I can't merge the branches?
For reference, these are the main links that have prompted my process:
1. [Scott Chacon on the workflow at Gitub][1]
2. [Git workflow for a single developer on a local repository][2]
3. [Git workflow for a single user][3]
[1]: http://scottchacon.com/2011/08/31/github-flow.html]
[2]: http://stackoverflow.com/questions/4056372/git-workflow-for-a-single-developer-on-a-local-repository
[3]: http://stackoverflow.com/questions/3007352/git-workflow-for-single-user | 0 |
3,397,303 | 08/03/2010 14:08:49 | 409,732 | 08/03/2010 14:06:08 | 1 | 0 | Quote ticker in C# | I want to make a Quote Ticker Control in C#
in which Live data should be come from stock exchange
How i will do it
Thanks | c# | null | null | null | null | 08/04/2010 15:37:20 | not a real question | Quote ticker in C#
===
I want to make a Quote Ticker Control in C#
in which Live data should be come from stock exchange
How i will do it
Thanks | 1 |
8,046,292 | 11/08/2011 05:22:46 | 376,870 | 06/26/2010 08:30:05 | 13 | 0 | How to secure Windows machine in LAN for PHP running on APACHE? | I have installed my PHP scripts which runs over Apache server in a Windows machine in my office LAN network. It is an internal contest application. Now I want to secure the machine from all sort of intrusions and I would like to log all the intruder's details and what sort of intrusion they have tried. Is it possible to implement through code or is there any existing tool to implement these functions?
I know that there are options to get external user's data like $_SERVER['REMOTE_ADDR'], $_SERVER['HTTP_REFERER'], $_SERVER['HTTP_USER_AGENT']. I have a little script for tracking these details. And many of the ports are closed and I am running an AV in it for the purpose. These data will not be enough to get the intrusion type that they have attempted. I want to make the system more secure from all sort of vulnerability and attacks. Can any one point me to a right tool? | php | windows | security | apache | lan | 11/08/2011 15:31:55 | off topic | How to secure Windows machine in LAN for PHP running on APACHE?
===
I have installed my PHP scripts which runs over Apache server in a Windows machine in my office LAN network. It is an internal contest application. Now I want to secure the machine from all sort of intrusions and I would like to log all the intruder's details and what sort of intrusion they have tried. Is it possible to implement through code or is there any existing tool to implement these functions?
I know that there are options to get external user's data like $_SERVER['REMOTE_ADDR'], $_SERVER['HTTP_REFERER'], $_SERVER['HTTP_USER_AGENT']. I have a little script for tracking these details. And many of the ports are closed and I am running an AV in it for the purpose. These data will not be enough to get the intrusion type that they have attempted. I want to make the system more secure from all sort of vulnerability and attacks. Can any one point me to a right tool? | 2 |
6,518,390 | 06/29/2011 09:25:38 | 804,516 | 06/18/2011 12:50:52 | 17 | 0 | Passing a value and store it in database using Javascript + PHP? | I have an idea to pass a certain value from a page using javascript/jQuery to a php page , the php page will process it then store it in mysql database.
For example:
When a person click a button , the button will execute a function which gets that person's username then send it to a PHP page to process it . The PHP will then store the collected data in a mysql database.
I saw some sites using JSON to do it .
I'm just wondering anyone have any idea that can give me a headstart? | php | javascript | jquery | json | null | 06/30/2011 04:36:27 | not a real question | Passing a value and store it in database using Javascript + PHP?
===
I have an idea to pass a certain value from a page using javascript/jQuery to a php page , the php page will process it then store it in mysql database.
For example:
When a person click a button , the button will execute a function which gets that person's username then send it to a PHP page to process it . The PHP will then store the collected data in a mysql database.
I saw some sites using JSON to do it .
I'm just wondering anyone have any idea that can give me a headstart? | 1 |
10,163,664 | 04/15/2012 16:09:20 | 678,855 | 03/27/2011 11:18:30 | 526 | 9 | BradLarsons GPUImage Example / IOS 4.1 Building problems / Compile is OK but nothing builds on iphone | I have Xcode 4.3.2 SDK 5.1
My Iphone is 3GS IOS 4.1
Project compiles well but nothing happens.
In this http://stackoverflow.com/questions/4198676/warning-iphone-apps-should-include-an-armv6-architecture-even-with-build-config/6833556#6833556 topic guys are talking about armv versions. My project has also only armv7 so I thought that was the problem.
What I did is the following.
Changed deployment target of the project to 4.1
![enter image description here][1]
Also changed to 4.1 in the frameworks target
![enter image description here][2]
Then I manually changed architectures to have both armv6 and armv7.
But it did nothing.
Then I continued to read the topic I've post link above and changed the plist file of project to add second item to array of required device cappabilities.
![enter image description here][3]
[1]: http://i.stack.imgur.com/VLCV4.jpg
[2]: http://i.stack.imgur.com/hXYOu.jpg
[3]: http://i.stack.imgur.com/qAadR.jpg
But still I have no luck. Nothing happens on my Iphone when I build this project. Please help! | iphone | ios | xcode | frameworks | build | 04/17/2012 14:42:33 | too localized | BradLarsons GPUImage Example / IOS 4.1 Building problems / Compile is OK but nothing builds on iphone
===
I have Xcode 4.3.2 SDK 5.1
My Iphone is 3GS IOS 4.1
Project compiles well but nothing happens.
In this http://stackoverflow.com/questions/4198676/warning-iphone-apps-should-include-an-armv6-architecture-even-with-build-config/6833556#6833556 topic guys are talking about armv versions. My project has also only armv7 so I thought that was the problem.
What I did is the following.
Changed deployment target of the project to 4.1
![enter image description here][1]
Also changed to 4.1 in the frameworks target
![enter image description here][2]
Then I manually changed architectures to have both armv6 and armv7.
But it did nothing.
Then I continued to read the topic I've post link above and changed the plist file of project to add second item to array of required device cappabilities.
![enter image description here][3]
[1]: http://i.stack.imgur.com/VLCV4.jpg
[2]: http://i.stack.imgur.com/hXYOu.jpg
[3]: http://i.stack.imgur.com/qAadR.jpg
But still I have no luck. Nothing happens on my Iphone when I build this project. Please help! | 3 |
6,071,094 | 05/20/2011 11:12:15 | 584,224 | 01/21/2011 09:26:38 | 1 | 3 | Wix Shortcut Arguments Issues | I have a strange issue with Wix
I'm creating a shortcut to a config tool for a windows service.
I want to pass the config file for the windows service as an argument to the config tool.
Thus I have a component that installs the windows service, this works fine and another one that installs the config tool.
The shortcut code is below:
<File Id="fil0DE18380EE50C7D59BD8D5360D499796" Source="$(var.proj.TargetDir)\ConfigurationTool.exe" >
<Shortcut Id="LaunchConfigTool" WorkingDirectory="WINDOWSSERVICE" Arguments="[#fil21620445E80831C7F56986614D268A22]"
Name="Service Configuration Tool" Directory="ProgramMenuDir" Advertise="yes"/>
</File>
This does not work, namely, the shortcut fails to launch the config tool. However, the snippet below works fine. Needless to say that the reference above refers to service.exe.config.
<File Id="fil0DE18380EE50C7D59BD8D5360D499796" Source="$(var.proj.TargetDir)\ConfigurationTool.exe" >
<Shortcut Id="LaunchConfigTool" WorkingDirectory="WINDOWSSERVICE" Arguments="service.exe.config"
Name="Service Configuration Tool" Directory="ProgramMenuDir" Advertise="yes"/>
</File>
I logged the installer actions to a file and both have the following output
MSI (s) (BC:1C) [11:32:27:947]: Executing op: ShortcutCreate(Name=tcet7-ht|Service Configuration Tool,Feature=ProductFeature,Component={B9ED30DE-087D-393E-950B-C67877E51B8A}[~]2,,Arguments=C:\Program Files\Housekeeping\Windows Service\service.exe.config,WorkingDir=C:\Program Files\Housekeeping\Windows Service\,,,,,,,,,)
Any ideas with the reference is not working?
TIA | wix | shortcut | null | null | null | null | open | Wix Shortcut Arguments Issues
===
I have a strange issue with Wix
I'm creating a shortcut to a config tool for a windows service.
I want to pass the config file for the windows service as an argument to the config tool.
Thus I have a component that installs the windows service, this works fine and another one that installs the config tool.
The shortcut code is below:
<File Id="fil0DE18380EE50C7D59BD8D5360D499796" Source="$(var.proj.TargetDir)\ConfigurationTool.exe" >
<Shortcut Id="LaunchConfigTool" WorkingDirectory="WINDOWSSERVICE" Arguments="[#fil21620445E80831C7F56986614D268A22]"
Name="Service Configuration Tool" Directory="ProgramMenuDir" Advertise="yes"/>
</File>
This does not work, namely, the shortcut fails to launch the config tool. However, the snippet below works fine. Needless to say that the reference above refers to service.exe.config.
<File Id="fil0DE18380EE50C7D59BD8D5360D499796" Source="$(var.proj.TargetDir)\ConfigurationTool.exe" >
<Shortcut Id="LaunchConfigTool" WorkingDirectory="WINDOWSSERVICE" Arguments="service.exe.config"
Name="Service Configuration Tool" Directory="ProgramMenuDir" Advertise="yes"/>
</File>
I logged the installer actions to a file and both have the following output
MSI (s) (BC:1C) [11:32:27:947]: Executing op: ShortcutCreate(Name=tcet7-ht|Service Configuration Tool,Feature=ProductFeature,Component={B9ED30DE-087D-393E-950B-C67877E51B8A}[~]2,,Arguments=C:\Program Files\Housekeeping\Windows Service\service.exe.config,WorkingDir=C:\Program Files\Housekeeping\Windows Service\,,,,,,,,,)
Any ideas with the reference is not working?
TIA | 0 |
3,070,105 | 06/18/2010 13:42:31 | 66,593 | 02/15/2009 08:10:45 | 240 | 3 | Required Explanation for a program in C | I am reading the book by kerninghan Ritchie Edition 2.... It contains a code function on getch(), ungetch(), getop()......... I am not able to understand the stuff..... and I feel that it is bit incomplete also...... I am posting the question here... Please give few examples to make this code look pretty easier...... If there is any correction in the programm,, then please let know.... Thankss.....
#include <stdio.h>
#include <ctype.h>
#define BUFSIZE 100
char buf[BUFSIZE]; /* buffer for ungetch */
int bufp = 0; /* next free position in buf */
int getch(void) /* get a (possibly pushed-back) character */
{
return (bufp > 0) ? buf[--bufp] : getchar();
}
void ungetch(int c) /* push character back on input */
{
if(bufp >= BUFSIZE)
printf(" ungetch too many characters\n");
else
buf[bufp++] = c;
}
/* getop: get next character or numeric operand */
int getop(char s[])
{
int i, c;
while ((s[0] = c = getch()) == ' ' || c == '\t');
s[1] = '\0';
if(!isdigit(c) && c != '.')
return c; /* not a number */
i=0;
if(isdigit(c)) /* collect integer part */
while(isdigit([s++i] = c = getch()));
if(c == '.') /* collect fractional part */
while(isdigit(s[++i] = c = getch()));
s[i] = '\0';
if (c != EOF)
ungetch(c);
}
| c | null | null | null | null | 06/20/2010 03:22:14 | not a real question | Required Explanation for a program in C
===
I am reading the book by kerninghan Ritchie Edition 2.... It contains a code function on getch(), ungetch(), getop()......... I am not able to understand the stuff..... and I feel that it is bit incomplete also...... I am posting the question here... Please give few examples to make this code look pretty easier...... If there is any correction in the programm,, then please let know.... Thankss.....
#include <stdio.h>
#include <ctype.h>
#define BUFSIZE 100
char buf[BUFSIZE]; /* buffer for ungetch */
int bufp = 0; /* next free position in buf */
int getch(void) /* get a (possibly pushed-back) character */
{
return (bufp > 0) ? buf[--bufp] : getchar();
}
void ungetch(int c) /* push character back on input */
{
if(bufp >= BUFSIZE)
printf(" ungetch too many characters\n");
else
buf[bufp++] = c;
}
/* getop: get next character or numeric operand */
int getop(char s[])
{
int i, c;
while ((s[0] = c = getch()) == ' ' || c == '\t');
s[1] = '\0';
if(!isdigit(c) && c != '.')
return c; /* not a number */
i=0;
if(isdigit(c)) /* collect integer part */
while(isdigit([s++i] = c = getch()));
if(c == '.') /* collect fractional part */
while(isdigit(s[++i] = c = getch()));
s[i] = '\0';
if (c != EOF)
ungetch(c);
}
| 1 |
6,936,170 | 08/04/2011 04:27:08 | 798,770 | 06/15/2011 01:55:55 | 35 | 0 | css for all tags of a class | How can I specify css for all td tags of a table of a certain class?
I tried this:
.myclass td {padding: 1px;}
But it doesn't work. The html is:
<table class="myclass"><tr><td>foo
| html | css | null | null | null | 01/06/2012 12:49:23 | not a real question | css for all tags of a class
===
How can I specify css for all td tags of a table of a certain class?
I tried this:
.myclass td {padding: 1px;}
But it doesn't work. The html is:
<table class="myclass"><tr><td>foo
| 1 |
11,480,907 | 07/14/2012 03:58:21 | 841,720 | 07/12/2011 22:57:36 | 1 | 0 | Apache reverse proxy for several Jenkins CI and Nexus Maven repositories | New Note 130
Hello,
I am trying to setup a front-end (reverse proxy) for several Nexus and Jenkins CI servers using Apache httpd and need some help. We have URLs like-
> abc.internal.net:8080/
> def.internal.net:9000/jenkins/
> ghi.internal.net:8080/jenkins/
> jkl.internal.net:8081/nexus/
> foo.internal.net/nexus/
I would like each of these to be setup behind the FE reverse proxy so as to have something like-
> scm.internal.net/abc-jenkins/
> scm.internal.net/def-jenkins/
> scm.internal.net/ghi-jenkins/
> scm.internal.net/jkl-nexus/
> scm.internal.net/foo-nexus/
Some of the services use root context. Could these be forced into arbitrary web context?
I have very limited knowledge of Apache httpd so some real configs would help immensely. Most of these services need URL, content and CSS fixing in the response. If this could be done without changing the existing web context on the severs that these services are running, that would be awesome.
Also, I need soft landing on these changes so legacy URL continue to work for few weeks as developers and automation transition to the new scheme. Is this asking for too much?
Thanks in advance. | apache2 | jenkins | httpd | reverse-proxy | nexus | null | open | Apache reverse proxy for several Jenkins CI and Nexus Maven repositories
===
New Note 130
Hello,
I am trying to setup a front-end (reverse proxy) for several Nexus and Jenkins CI servers using Apache httpd and need some help. We have URLs like-
> abc.internal.net:8080/
> def.internal.net:9000/jenkins/
> ghi.internal.net:8080/jenkins/
> jkl.internal.net:8081/nexus/
> foo.internal.net/nexus/
I would like each of these to be setup behind the FE reverse proxy so as to have something like-
> scm.internal.net/abc-jenkins/
> scm.internal.net/def-jenkins/
> scm.internal.net/ghi-jenkins/
> scm.internal.net/jkl-nexus/
> scm.internal.net/foo-nexus/
Some of the services use root context. Could these be forced into arbitrary web context?
I have very limited knowledge of Apache httpd so some real configs would help immensely. Most of these services need URL, content and CSS fixing in the response. If this could be done without changing the existing web context on the severs that these services are running, that would be awesome.
Also, I need soft landing on these changes so legacy URL continue to work for few weeks as developers and automation transition to the new scheme. Is this asking for too much?
Thanks in advance. | 0 |
10,637,715 | 05/17/2012 14:31:08 | 1,176,872 | 01/29/2012 19:49:13 | 43 | 1 | Salvage a nice mobile phone to learn embedded programming? | I have a Galaxy S II with a wrecked screen. I was wondering if the internals could be salvaged as a tool to teach myself embedded programming. I know C and enough x86_64 ASM that I would be comfortable taking on ARM assembly.
What would the development environment / set up be like?
Would I use the USB connection or is there a more direct way to connect the phone to the computer?
Would I need to prepare the phone in some way?
Let's say I wanted to write a boot loader for it, are there any good resources of where to start?
Is the phone too much of a black box, should I get a board with more documentation than that?
Or alternatively, why this is a terrible idea. Would all the drivers be too difficult to deal with if I wanted to use things like the camera?
Thanks for the help. I have no idea where to start a project like this. | c | operating-system | embedded | arm | phone | 05/18/2012 06:36:36 | off topic | Salvage a nice mobile phone to learn embedded programming?
===
I have a Galaxy S II with a wrecked screen. I was wondering if the internals could be salvaged as a tool to teach myself embedded programming. I know C and enough x86_64 ASM that I would be comfortable taking on ARM assembly.
What would the development environment / set up be like?
Would I use the USB connection or is there a more direct way to connect the phone to the computer?
Would I need to prepare the phone in some way?
Let's say I wanted to write a boot loader for it, are there any good resources of where to start?
Is the phone too much of a black box, should I get a board with more documentation than that?
Or alternatively, why this is a terrible idea. Would all the drivers be too difficult to deal with if I wanted to use things like the camera?
Thanks for the help. I have no idea where to start a project like this. | 2 |
8,345,755 | 12/01/2011 17:37:23 | 879,664 | 08/05/2011 00:03:11 | 669 | 13 | Object assignment in Ruby | Coming from a c++ background I'm curious about object assignment in Ruby. What considerations (if any) should be made for the following object assignments:
class MyClass
attr_accessor :a, :b
def initialize(a, b)
@a = a
@b = b
end
def some_method
puts "#{self.a} #{self.b}"
end
end
m = MyClass.new("first", "last")
n = MyClass.new("pizza", "hello")
q = n
q.some_method | ruby | object | instance-variables | copy-assignment | null | 12/02/2011 19:18:55 | not constructive | Object assignment in Ruby
===
Coming from a c++ background I'm curious about object assignment in Ruby. What considerations (if any) should be made for the following object assignments:
class MyClass
attr_accessor :a, :b
def initialize(a, b)
@a = a
@b = b
end
def some_method
puts "#{self.a} #{self.b}"
end
end
m = MyClass.new("first", "last")
n = MyClass.new("pizza", "hello")
q = n
q.some_method | 4 |
8,807,518 | 01/10/2012 17:18:20 | 603,588 | 02/04/2011 18:05:34 | 88 | 5 | RESTful web service and delta updates - advantages and disadvantages | Our front-end developers have requested that the RESTful Java web services to support delta queries. The use case for this is to handle periodic ajax refresh of the screen to bring in new data (deltas). I can see a few advantages of this:
- Makes front-end logic simple (i.e. no complicated deduping logic)
- Reduce network traffic (i.e. response size is smaller)
However, there are some concern as well:
- supporting delta will require the service to be stateful, which impact scalability
- heavy use of caching (results cached per user per query, to determine the delta)
- heavy processing on the server
My questions are:
- Are there additional advantages to this approach?
- What's a good implementation to for delta queries that would
eliminate some of the disadvantages (you can assume we are welling to
drastically refactor our code)
- Does the benefit justify the trade-off? | java | ajax | gui | null | null | 02/05/2012 04:51:17 | not constructive | RESTful web service and delta updates - advantages and disadvantages
===
Our front-end developers have requested that the RESTful Java web services to support delta queries. The use case for this is to handle periodic ajax refresh of the screen to bring in new data (deltas). I can see a few advantages of this:
- Makes front-end logic simple (i.e. no complicated deduping logic)
- Reduce network traffic (i.e. response size is smaller)
However, there are some concern as well:
- supporting delta will require the service to be stateful, which impact scalability
- heavy use of caching (results cached per user per query, to determine the delta)
- heavy processing on the server
My questions are:
- Are there additional advantages to this approach?
- What's a good implementation to for delta queries that would
eliminate some of the disadvantages (you can assume we are welling to
drastically refactor our code)
- Does the benefit justify the trade-off? | 4 |
1,816,530 | 11/29/2009 19:42:06 | 148,968 | 08/01/2009 13:58:15 | 349 | 21 | Using Haml with Catalyst framework | Is it possible to use Haml instead of a templating engine with the Catalyst web framework? | haml | catalyst | perl | frameworks | null | null | open | Using Haml with Catalyst framework
===
Is it possible to use Haml instead of a templating engine with the Catalyst web framework? | 0 |
6,091,223 | 05/22/2011 22:23:12 | 765,122 | 05/22/2011 19:46:55 | 3 | 0 | Trying to insert values into a table cell, some values coming out to undefined | I want to have array values populate a table when I run the program and it all works fine except that 3 of the arrays I had have to be combined into different rows for one column. Basically what happens is the index value keeps coming out to undefined and it messes up the whole program. If any clarification is needed please ask and I'll try my best to explain further.
// constants
var colCount = 7;
var rowCount = 7;
// input data
var id = new Array("1022", "1112", "1230", "554", "1355", "1600");
var title = new Array("Prof.", "Prof.", "Prof.", "Prof.", "Asst. Prof.", "Asst. Prof.");
var name = new Array("Catherine Adler", "Michael Li", "Maria Sanchez", "Robert Hope", "Wayne Li", "Kate Howard");
var position = new Array("Department Chair", "Asst. Chair", "TA Supervisor");
var er = new Array(2, 3, 1, 2, 1, 3);
var yoe = new Array(18, 12, 10, 23, 8, 5);
var cs = new Array(85000, 70000, 62000, 55000, 50000, 45000);
// make a special column.
var complicatedName;
for (index = 0; index < rowCount; index++)
{
complicatedName[index] = title[index]+' '+name[index]+' '+position[index];
}
colCount = colCount - 2
// create the column array.
var collist = [id,complicatedName,er,yoe,cs];
// make the table.
function tableCreate() {
for (rownum = 1; rownum <= rowCount; rownum++) {
document.write("<tr>");
for (colnum = 1; colnum <= colCount; colnum++) {
document.write("<td>" + (collist[(colnum-1)])[(rownum-1)] + "</td>");
}
document.write("</tr>");
}
}
| javascript | html | null | null | null | 05/22/2011 22:37:12 | too localized | Trying to insert values into a table cell, some values coming out to undefined
===
I want to have array values populate a table when I run the program and it all works fine except that 3 of the arrays I had have to be combined into different rows for one column. Basically what happens is the index value keeps coming out to undefined and it messes up the whole program. If any clarification is needed please ask and I'll try my best to explain further.
// constants
var colCount = 7;
var rowCount = 7;
// input data
var id = new Array("1022", "1112", "1230", "554", "1355", "1600");
var title = new Array("Prof.", "Prof.", "Prof.", "Prof.", "Asst. Prof.", "Asst. Prof.");
var name = new Array("Catherine Adler", "Michael Li", "Maria Sanchez", "Robert Hope", "Wayne Li", "Kate Howard");
var position = new Array("Department Chair", "Asst. Chair", "TA Supervisor");
var er = new Array(2, 3, 1, 2, 1, 3);
var yoe = new Array(18, 12, 10, 23, 8, 5);
var cs = new Array(85000, 70000, 62000, 55000, 50000, 45000);
// make a special column.
var complicatedName;
for (index = 0; index < rowCount; index++)
{
complicatedName[index] = title[index]+' '+name[index]+' '+position[index];
}
colCount = colCount - 2
// create the column array.
var collist = [id,complicatedName,er,yoe,cs];
// make the table.
function tableCreate() {
for (rownum = 1; rownum <= rowCount; rownum++) {
document.write("<tr>");
for (colnum = 1; colnum <= colCount; colnum++) {
document.write("<td>" + (collist[(colnum-1)])[(rownum-1)] + "</td>");
}
document.write("</tr>");
}
}
| 3 |
6,426,582 | 06/21/2011 14:03:02 | 255,575 | 01/21/2010 07:58:28 | 730 | 65 | Suggession on Line Chart | I have a requirement to create Chart like this :
http://sourceforge.net/projects/ecgtoolkit-cs/
I have to be very specific on how much data it needs to display per unit in graph. I can do it using manual Drawing, but is there any easy way to build this without doing it manually?
I am thinking about the alternatives.
Thanks in advance. | c# | .net | winforms | line | charts | null | open | Suggession on Line Chart
===
I have a requirement to create Chart like this :
http://sourceforge.net/projects/ecgtoolkit-cs/
I have to be very specific on how much data it needs to display per unit in graph. I can do it using manual Drawing, but is there any easy way to build this without doing it manually?
I am thinking about the alternatives.
Thanks in advance. | 0 |
8,159,824 | 11/16/2011 22:43:33 | 841,414 | 07/12/2011 19:29:04 | 40 | 0 | Commentor get remove comment options only on their comment PHP/MySql | So I have this table and two sql statements. I want to give commentor 3 from the first query, the ability to remove their comment by using $CommentorProfOwnerOpts, which appears in the comments part being pulled out from the second query.
What happens now is that commentor 2 also gets the $CommentorProfOwnerOpts, when only commentor 3 should get them and ONLY on their comment.
comment_id | comment_title | commentor_id | profile_owner_id
-------------------------------------------------------------
4 Title 1 2 1
5 Title 2 3 1
//Commentor 3
$commentor = mysql_query("SELECT commentor_id, comment_id FROM comments WHERE commentor_id=3 AND profile_owner_id=1");
$count = mysql_num_rows($commentor);
if ($count > 0) {
while($row = mysql_fetch_array($commentor)){
$commID = $row["comment_id"];
$CommentorProfOwnerOpts = '<span id="remove-'.$commID.'">Remove Comment</span>';
}
And here are the comments:
//All Comments for profile owner 1
$comments = mysql_query("SELECT comment_id, comment_title FROM comments WHERE profile_owner_id=1");
while($row = mysql_fetch_array($comments)){
$comment_id = $row["comment_id"];
$comment_title = $row["comment_title"];
$CommentorProfOwnerOpts = '<span id="remove-'.$comment_ID.'">Remove Comment</span>';
$comments .= '<div id="$comment_id" class="comments">
'.$comment_title.'
'.$CommentorProfOwnerOpts.'
</div>'
}
The issue is that I can't figure out how to have each commentor get the remove option $CommentorProfOwnerOpts, appear only for their own comment, and not on another comment. How can I fix this? | php | mysql | select | comments | null | null | open | Commentor get remove comment options only on their comment PHP/MySql
===
So I have this table and two sql statements. I want to give commentor 3 from the first query, the ability to remove their comment by using $CommentorProfOwnerOpts, which appears in the comments part being pulled out from the second query.
What happens now is that commentor 2 also gets the $CommentorProfOwnerOpts, when only commentor 3 should get them and ONLY on their comment.
comment_id | comment_title | commentor_id | profile_owner_id
-------------------------------------------------------------
4 Title 1 2 1
5 Title 2 3 1
//Commentor 3
$commentor = mysql_query("SELECT commentor_id, comment_id FROM comments WHERE commentor_id=3 AND profile_owner_id=1");
$count = mysql_num_rows($commentor);
if ($count > 0) {
while($row = mysql_fetch_array($commentor)){
$commID = $row["comment_id"];
$CommentorProfOwnerOpts = '<span id="remove-'.$commID.'">Remove Comment</span>';
}
And here are the comments:
//All Comments for profile owner 1
$comments = mysql_query("SELECT comment_id, comment_title FROM comments WHERE profile_owner_id=1");
while($row = mysql_fetch_array($comments)){
$comment_id = $row["comment_id"];
$comment_title = $row["comment_title"];
$CommentorProfOwnerOpts = '<span id="remove-'.$comment_ID.'">Remove Comment</span>';
$comments .= '<div id="$comment_id" class="comments">
'.$comment_title.'
'.$CommentorProfOwnerOpts.'
</div>'
}
The issue is that I can't figure out how to have each commentor get the remove option $CommentorProfOwnerOpts, appear only for their own comment, and not on another comment. How can I fix this? | 0 |
11,515,747 | 07/17/2012 03:44:46 | 1,516,428 | 07/11/2012 02:11:53 | 1 | 0 | How can I know the targets of JVM configuration? | How can I know the targets of JVM configuration? I know how to set JVM for my server, which can be done by command 'java -Xmx3550m -Xms3550m -Xmn2g -Xss128k'. But what's command can to see what it is like? | java | jvm | null | null | null | null | open | How can I know the targets of JVM configuration?
===
How can I know the targets of JVM configuration? I know how to set JVM for my server, which can be done by command 'java -Xmx3550m -Xms3550m -Xmn2g -Xss128k'. But what's command can to see what it is like? | 0 |
11,373,840 | 07/07/2012 09:29:55 | 1,505,722 | 07/06/2012 04:11:42 | 1 | 0 | creating a project | To whom it may concern,
I am currently following the steps in the book "android app development for dummies", and I have reached the part where I need to create a new project. The problem I am having is that my window is different to the one in the book so I can not follow the steps in the book as my window is different.
My window says "android application project" and in the book it says "android project" and so when i click on it to proceed, my next window is different to the one in the book.
Does anyone know why this is? and how i may be able to fix it?
regards | android | null | null | null | null | 07/07/2012 09:41:32 | not a real question | creating a project
===
To whom it may concern,
I am currently following the steps in the book "android app development for dummies", and I have reached the part where I need to create a new project. The problem I am having is that my window is different to the one in the book so I can not follow the steps in the book as my window is different.
My window says "android application project" and in the book it says "android project" and so when i click on it to proceed, my next window is different to the one in the book.
Does anyone know why this is? and how i may be able to fix it?
regards | 1 |
8,866,558 | 01/15/2012 00:21:22 | 1,149,378 | 01/14/2012 14:52:30 | 1 | 0 | Make a button activate an HTML code | Another question!! What I would like to accomplish today is making a button activate an html code. For example, lets take a code to make snow appear on the page. At first, the page doesn't have snow falling, but the code is in the page. Then the visitor clicks on the button and snow starts falling on the page. That's what I want it to do. Thanks! | html | button | onclick | snowfall | null | 01/16/2012 02:55:05 | too localized | Make a button activate an HTML code
===
Another question!! What I would like to accomplish today is making a button activate an html code. For example, lets take a code to make snow appear on the page. At first, the page doesn't have snow falling, but the code is in the page. Then the visitor clicks on the button and snow starts falling on the page. That's what I want it to do. Thanks! | 3 |
4,450,706 | 12/15/2010 14:02:44 | 542,866 | 12/15/2010 03:40:16 | 1 | 0 | C# How to create Matrix of PictureBoxes | How to create Matrix of PictureBoxes | c# | null | null | null | null | 12/16/2010 02:45:56 | not a real question | C# How to create Matrix of PictureBoxes
===
How to create Matrix of PictureBoxes | 1 |
4,972,565 | 02/11/2011 18:15:57 | 508,628 | 11/15/2010 18:46:05 | 1 | 0 | Process.WaitForExit not waiting | I have the following code and the WaitForExit method is not waiting. It just runs the command and moves on to the next statement. The command is to unintall an application and the parms are for the uninstall command. The uninstall runs fine but I need the uninstall to finish before moving on...it's not blocking.
ProcessStartInfo startInfo = new ProcessStartInfo();
startInfo.FileName = commandName;
startInfo.Arguments = parms;
Process process = Process.Start(startInfo);
process.WaitForExit(); | c#-2.0 | null | null | null | null | null | open | Process.WaitForExit not waiting
===
I have the following code and the WaitForExit method is not waiting. It just runs the command and moves on to the next statement. The command is to unintall an application and the parms are for the uninstall command. The uninstall runs fine but I need the uninstall to finish before moving on...it's not blocking.
ProcessStartInfo startInfo = new ProcessStartInfo();
startInfo.FileName = commandName;
startInfo.Arguments = parms;
Process process = Process.Start(startInfo);
process.WaitForExit(); | 0 |
9,238,460 | 02/11/2012 06:58:44 | 629,576 | 02/23/2011 05:17:50 | 1 | 1 | OS and Systems Programming | As part of my course project I have to create process as OS Simulator, which should do basic process creation and context switching. I need to implement the simulation program as a Unix process ( should develop as C/C++ program for obvious reasons) . I am noobie in systems programming, any quick pointers or references to get a start on this would be highly appreciated. | c++ | c | linux | operating-system | null | 02/11/2012 11:30:32 | not a real question | OS and Systems Programming
===
As part of my course project I have to create process as OS Simulator, which should do basic process creation and context switching. I need to implement the simulation program as a Unix process ( should develop as C/C++ program for obvious reasons) . I am noobie in systems programming, any quick pointers or references to get a start on this would be highly appreciated. | 1 |
6,220,848 | 06/02/2011 21:56:49 | 656,925 | 08/12/2010 02:22:36 | 351 | 3 | Why aren't parent constructors being called? | I added in `parent::__construct();` to the constructors of table and bookmark in order to get this code to work. Why are they not called automatically?
If I create an object of type bookmark `$obj_ref_bo = new bookmark();` should not bookmark also create objects from each of its parent classes (besides abstract classes).
The call chain is
bookmark->table->database(abstract)->single_connect
/*single_connect*/
class single_connect
{
protected static $_db_pointer = NULL;
private function __construct()
{
$this->_db_pointer = mysql_connect(DB_HOST, DB_USER, DB_PASS);
mysql_select_db(DB_DATABASE);
}
public static function get_connection()
{
if(self::$_db_pointer == NULL)
{
return new self();
}
else
{
echo "Error:only one connection";
}
}
}
/*database*/
abstract class database
{
protected function __construct()
{
single_connect::get_connection();
}
static protected function query($query)
{
$result = mysql_query($query) or die(mysql_error());
return $result;
}
}
/*table*/
class table extends database
{
public $_protected_arr=array();
protected function __construct()
{
parent::__construct();
self::protect();
}
protected function protect()
{
foreach($_POST as $key => $value)
{
$this->_protected_arr[$key] = mysql_real_escape_string($value);
}
}
}
/*bookmark*/
class bookmark extends table
{
function __construct()
{
parent::__construct();
$this->start();
}
function start()
{
if(self::test())
{
self::insert();
}
else
{
return 1;
}
}
function test()
{
if(self::test_empty())
{
return 1;
}
else
{
return 0;
}
}
function test_empty()
{
if(text::test_empty($this->_protected_arr))
{
return 1;
}
else
{
return 0;
}
}
function insert()
{
$url = $this->_protected_arr['url'];
$title = $this->_protected_arr['title'];
$email = $_SESSION['email'];
database::query("INSERT INTO bo VALUES ('$title', '$url', '$email')");
}
} | php | class | object | hierarchy | null | null | open | Why aren't parent constructors being called?
===
I added in `parent::__construct();` to the constructors of table and bookmark in order to get this code to work. Why are they not called automatically?
If I create an object of type bookmark `$obj_ref_bo = new bookmark();` should not bookmark also create objects from each of its parent classes (besides abstract classes).
The call chain is
bookmark->table->database(abstract)->single_connect
/*single_connect*/
class single_connect
{
protected static $_db_pointer = NULL;
private function __construct()
{
$this->_db_pointer = mysql_connect(DB_HOST, DB_USER, DB_PASS);
mysql_select_db(DB_DATABASE);
}
public static function get_connection()
{
if(self::$_db_pointer == NULL)
{
return new self();
}
else
{
echo "Error:only one connection";
}
}
}
/*database*/
abstract class database
{
protected function __construct()
{
single_connect::get_connection();
}
static protected function query($query)
{
$result = mysql_query($query) or die(mysql_error());
return $result;
}
}
/*table*/
class table extends database
{
public $_protected_arr=array();
protected function __construct()
{
parent::__construct();
self::protect();
}
protected function protect()
{
foreach($_POST as $key => $value)
{
$this->_protected_arr[$key] = mysql_real_escape_string($value);
}
}
}
/*bookmark*/
class bookmark extends table
{
function __construct()
{
parent::__construct();
$this->start();
}
function start()
{
if(self::test())
{
self::insert();
}
else
{
return 1;
}
}
function test()
{
if(self::test_empty())
{
return 1;
}
else
{
return 0;
}
}
function test_empty()
{
if(text::test_empty($this->_protected_arr))
{
return 1;
}
else
{
return 0;
}
}
function insert()
{
$url = $this->_protected_arr['url'];
$title = $this->_protected_arr['title'];
$email = $_SESSION['email'];
database::query("INSERT INTO bo VALUES ('$title', '$url', '$email')");
}
} | 0 |
5,856,195 | 05/02/2011 10:45:31 | 532,054 | 12/06/2010 09:40:12 | 6 | 0 | [objective c] formatting negative currency amount | I have trouble formatting negative amounts. I have defined the following formatter :
NSNumberFormatter *nf = [[NSNumberFormatter alloc] init];
[nf setNumberStyle:NSNumberFormatterCurrencyStyle];
[nf setNegativeFormat:@"-¤#,##0.00"];
In an environment using an en_US locale, parsing the string @"-$244.32" returns a correct NSNumber object. However, parsing the string @"-€244.32" with a fr_FR locale returns nil.
Do you have any ideas ?
Thanks | numbers | format | currency | negative | nsnumberformatter | null | open | [objective c] formatting negative currency amount
===
I have trouble formatting negative amounts. I have defined the following formatter :
NSNumberFormatter *nf = [[NSNumberFormatter alloc] init];
[nf setNumberStyle:NSNumberFormatterCurrencyStyle];
[nf setNegativeFormat:@"-¤#,##0.00"];
In an environment using an en_US locale, parsing the string @"-$244.32" returns a correct NSNumber object. However, parsing the string @"-€244.32" with a fr_FR locale returns nil.
Do you have any ideas ?
Thanks | 0 |
11,355,715 | 07/06/2012 04:09:38 | 1,505,665 | 07/06/2012 03:30:53 | 1 | 0 | How to send data between 2 things | I want to send a string between a injected DLL in a different process and my application.But I do not know how.Can someone give me a link to learn how to do this?I googled and google and googled but couldn't find anything...
I program in delphi. | delphi | data | exchange | null | null | 07/06/2012 15:38:47 | not a real question | How to send data between 2 things
===
I want to send a string between a injected DLL in a different process and my application.But I do not know how.Can someone give me a link to learn how to do this?I googled and google and googled but couldn't find anything...
I program in delphi. | 1 |
6,230,455 | 06/03/2011 17:19:49 | 783,092 | 06/03/2011 17:19:49 | 1 | 0 | Code Of Java script | Please any one tell me about the following.
if we create two fields in a form in html and with the help of Java script. when i write value in one field that should copy to the second field automatically | java | null | null | null | null | 06/03/2011 17:23:40 | not a real question | Code Of Java script
===
Please any one tell me about the following.
if we create two fields in a form in html and with the help of Java script. when i write value in one field that should copy to the second field automatically | 1 |
9,814,629 | 03/22/2012 00:00:57 | 1,521,828 | 03/21/2012 06:06:36 | 1 | 1 | Animated GIF in IE 8 stopping | I need to diplay a spin gif. I was following this link http://stackoverflow.com/questions/780560/animated-gif-in-ie-stopping
and the solution given to break up your GIF to say 10 images. I tried that however its not giving me the right results either on IE8 or Chrome17.
Only half of the frames gets displayed on both IE8 and chrome. However when i right click on spinner image on IE8 it starts showing the image correctly till the time rightclick pop up is open on the image. Any help on this issue would be appreciated.
Thanks. | javascript | internet-explorer | gif | null | null | null | open | Animated GIF in IE 8 stopping
===
I need to diplay a spin gif. I was following this link http://stackoverflow.com/questions/780560/animated-gif-in-ie-stopping
and the solution given to break up your GIF to say 10 images. I tried that however its not giving me the right results either on IE8 or Chrome17.
Only half of the frames gets displayed on both IE8 and chrome. However when i right click on spinner image on IE8 it starts showing the image correctly till the time rightclick pop up is open on the image. Any help on this issue would be appreciated.
Thanks. | 0 |
6,576,309 | 07/04/2011 21:46:27 | 800,737 | 06/16/2011 03:16:00 | 57 | 2 | Product page says "out of stock" even though SKU at 50 | I've created a catalog with about 10 products and I've made sure each of them have a SKU of at least 50.
Yet, when I go to an individual product's page, it tells me that the product is out of stock - which makes no sense whatsoever to me.
Anyone know what might be causing this? | magento | null | null | null | null | 07/05/2011 03:23:06 | off topic | Product page says "out of stock" even though SKU at 50
===
I've created a catalog with about 10 products and I've made sure each of them have a SKU of at least 50.
Yet, when I go to an individual product's page, it tells me that the product is out of stock - which makes no sense whatsoever to me.
Anyone know what might be causing this? | 2 |
11,443,316 | 07/12/2012 00:01:39 | 1,477,508 | 06/24/2012 00:23:40 | 8 | 0 | Sequential and running in one thread time difference c++ | Here is my source code for testing multithread performance in C++. Please tell me why is time about 5x smaller for ONE thread running(WaitForMultipleObject()) then first sequential performance. I expect almost same result for sequential performance and running with only one thread. Thanks
http://pastebin.com/EeJ5qW03 | c++ | multithreading | null | null | null | 07/12/2012 23:00:41 | not a real question | Sequential and running in one thread time difference c++
===
Here is my source code for testing multithread performance in C++. Please tell me why is time about 5x smaller for ONE thread running(WaitForMultipleObject()) then first sequential performance. I expect almost same result for sequential performance and running with only one thread. Thanks
http://pastebin.com/EeJ5qW03 | 1 |
8,336,247 | 12/01/2011 03:36:19 | 1,074,670 | 12/01/2011 03:18:45 | 1 | 0 | How does a typical HTTP connection redirect to VPN tunnel? | For l2tp tunneling, it uses PPPoX. However, a typical HTTP connection will create with AF_INET. So, how the connection will be redirected to the PPPoX?
I suspect two points:
1. in socket_create
2. ip forwarding
But, after looking at data path and source code, I don't think my guess is right. Anybody has some idea? | http | redirect | vpn | tunnel | null | 12/01/2011 04:19:11 | off topic | How does a typical HTTP connection redirect to VPN tunnel?
===
For l2tp tunneling, it uses PPPoX. However, a typical HTTP connection will create with AF_INET. So, how the connection will be redirected to the PPPoX?
I suspect two points:
1. in socket_create
2. ip forwarding
But, after looking at data path and source code, I don't think my guess is right. Anybody has some idea? | 2 |
4,556,288 | 12/29/2010 17:30:25 | 461,872 | 09/29/2010 14:48:35 | 33 | 3 | PDF Cross Reference Streams | I'm developing a PDF parser/writer, but I'm stuck at generating cross reference streams.
My program reads [this][1] file and then removes its linearization, and decompresses all objects in object streams. Finally it builds the PDF file and saves it.
This works really well when I use the normal cross reference & trailer, as you can see in [this][2] file.
When I try to generate a cross reference stream object instead (which results in [this][3] file, Adobe Reader can't view it.
Has anyone experience with PDF's and can help me search what the Problem is?
Note that the cross reference is the ONLY difference between file 2 and file 3. The first 34127 bytes are the same.
If someone needs the content of the decoded reference stream, download [this][4] file and open it in a HEX editor. I've checked this reference table again and again but I could not find anything wrong. But the dictionary seems to be OK, too.
Thanks so much for your help!!!
[1]: http://files.flashfan.ch/source.pdf
[2]: http://files.flashfan.ch/resultnormal.pdf
[3]: http://files.flashfan.ch/resultstream.pdf
[4]: http://files.flashfan.ch/decoded.txt | pdf | object | stream | cross-reference | null | null | open | PDF Cross Reference Streams
===
I'm developing a PDF parser/writer, but I'm stuck at generating cross reference streams.
My program reads [this][1] file and then removes its linearization, and decompresses all objects in object streams. Finally it builds the PDF file and saves it.
This works really well when I use the normal cross reference & trailer, as you can see in [this][2] file.
When I try to generate a cross reference stream object instead (which results in [this][3] file, Adobe Reader can't view it.
Has anyone experience with PDF's and can help me search what the Problem is?
Note that the cross reference is the ONLY difference between file 2 and file 3. The first 34127 bytes are the same.
If someone needs the content of the decoded reference stream, download [this][4] file and open it in a HEX editor. I've checked this reference table again and again but I could not find anything wrong. But the dictionary seems to be OK, too.
Thanks so much for your help!!!
[1]: http://files.flashfan.ch/source.pdf
[2]: http://files.flashfan.ch/resultnormal.pdf
[3]: http://files.flashfan.ch/resultstream.pdf
[4]: http://files.flashfan.ch/decoded.txt | 0 |
9,233,188 | 02/10/2012 18:55:24 | 1,202,724 | 02/10/2012 18:46:33 | 1 | 0 | Non Deterministic Push-Down Automata Simulation | Develop an application system to simulate a Non-Deterministic Push-Down Automata(NPDA).
1) Input to your NPDA is a set of s-grammar rules of the form A => aX where X N * recorded in a text file named productions.txt.
2) Number of rules in the rule set should be at least five.
3) The left Non-terminal of the first rule in your set of productions is assumed to be the start symbol of the grammar.
4) All terminals are assumed to be single lower case characters from the range a..z.
5) All non-terminals are assumed to be single upper case characters from the range A..Z.
Your NPDA should be able to accept any string of characters from the alphabet A…Za..z and to respond to the give string as below.
1) Print the word Reject if the string is not in the language.
2) Print the word Accept followed by the derivation steps if the string is in the language.
any one can give better NPDA for this question(set of grammar rules ) | compiler-theory | null | null | null | null | null | open | Non Deterministic Push-Down Automata Simulation
===
Develop an application system to simulate a Non-Deterministic Push-Down Automata(NPDA).
1) Input to your NPDA is a set of s-grammar rules of the form A => aX where X N * recorded in a text file named productions.txt.
2) Number of rules in the rule set should be at least five.
3) The left Non-terminal of the first rule in your set of productions is assumed to be the start symbol of the grammar.
4) All terminals are assumed to be single lower case characters from the range a..z.
5) All non-terminals are assumed to be single upper case characters from the range A..Z.
Your NPDA should be able to accept any string of characters from the alphabet A…Za..z and to respond to the give string as below.
1) Print the word Reject if the string is not in the language.
2) Print the word Accept followed by the derivation steps if the string is in the language.
any one can give better NPDA for this question(set of grammar rules ) | 0 |
4,264,481 | 11/24/2010 07:44:16 | 518,459 | 11/24/2010 07:44:16 | 1 | 0 | webcam related question | is it possible to make our own webcam in c#? | c# | null | null | null | null | 11/24/2010 08:27:33 | not a real question | webcam related question
===
is it possible to make our own webcam in c#? | 1 |
4,607,119 | 01/05/2011 17:25:37 | 185,433 | 10/07/2009 07:12:41 | 3 | 0 | Virtualbox USB driver problem for Windows Mobile 6.5 HD2 | I try to connect my Windows Mobile Device (Hd2) with VirtalBox using MacOS as the host (10.6.5) and Windows 7 as the guest.
The device shows up as HTC Generic Serial and Windows tries to install it as "PocketPC USB Sync" and fails to install the driver.
According to forums with people that have similar problems you should turn off "advanced network functionality" (I think I did this.. have swedish menus) and blacklist drivers in linux (no idea how to do).
Anyone has any good ideas? Will it be easier if I run Windows as a host?
/Br Johannes | usb | virtualbox | htc-hd2 | null | null | 08/21/2011 11:54:46 | off topic | Virtualbox USB driver problem for Windows Mobile 6.5 HD2
===
I try to connect my Windows Mobile Device (Hd2) with VirtalBox using MacOS as the host (10.6.5) and Windows 7 as the guest.
The device shows up as HTC Generic Serial and Windows tries to install it as "PocketPC USB Sync" and fails to install the driver.
According to forums with people that have similar problems you should turn off "advanced network functionality" (I think I did this.. have swedish menus) and blacklist drivers in linux (no idea how to do).
Anyone has any good ideas? Will it be easier if I run Windows as a host?
/Br Johannes | 2 |
4,302,907 | 11/29/2010 10:38:06 | 491,096 | 10/29/2010 09:15:58 | 52 | 1 | Custom image for NING network users provided by an admin | I'm working on a NING network and I wish to develop small application so that I can put a photograph/GIF/animation on "MY PAGE" page - different for each member. It should work simply like: admin puts in the desired username and the bond towards the image file. Member can't be able to remove or modify this image.
Thanks in advance! | php | ning | null | null | null | null | open | Custom image for NING network users provided by an admin
===
I'm working on a NING network and I wish to develop small application so that I can put a photograph/GIF/animation on "MY PAGE" page - different for each member. It should work simply like: admin puts in the desired username and the bond towards the image file. Member can't be able to remove or modify this image.
Thanks in advance! | 0 |
9,866,885 | 03/26/2012 05:10:06 | 1,292,215 | 03/26/2012 05:05:15 | 1 | 0 | not giving sum of the row | its accepting the input and in the second part i performing the row sum of the each row.and it s giving undefined as the resultant sum of the row
<html>
<head>
<script type ="text/javascript">
var myArray = new Array(3);
for (var i = 0; i < 3; i++) {
myArray[i] = new Array(3);
for (var j = 0; j < 3; j++) {
myArray[i][j]=prompt("element"," ");
}
}
for(i=0;i<4;i++)
{
sum=0;
for(j=0;j<4;j++)
{
document.write(myArray[i][j]);
sum+=myArray[i][j];
}
document.write("sum of"+ i+ "row"+sum);
}
</script>
</head>
</html>
| javascript | null | null | null | null | 03/27/2012 12:48:29 | not a real question | not giving sum of the row
===
its accepting the input and in the second part i performing the row sum of the each row.and it s giving undefined as the resultant sum of the row
<html>
<head>
<script type ="text/javascript">
var myArray = new Array(3);
for (var i = 0; i < 3; i++) {
myArray[i] = new Array(3);
for (var j = 0; j < 3; j++) {
myArray[i][j]=prompt("element"," ");
}
}
for(i=0;i<4;i++)
{
sum=0;
for(j=0;j<4;j++)
{
document.write(myArray[i][j]);
sum+=myArray[i][j];
}
document.write("sum of"+ i+ "row"+sum);
}
</script>
</head>
</html>
| 1 |
5,927,249 | 05/08/2011 11:51:00 | 223,367 | 12/02/2009 23:52:01 | 2,083 | 6 | What are some good techniques at debugging javascript? | So I use JavaScript fairly regularly and I was wondering if there were any good tips or tricks in debugging javascript....Like for example I have a good one I use fairly regularly.
In my code i would do something like this
window.p = $(this);
and in the console I can do my filtering like this
window.p.next("li").find("a").val();
or whatever i need to do...but this makes it easy to debug a specific spot in the code and I know there has got to me many tips and tricks out there....thanks in advance
Also i looked at this [question][1] and though its helpful i was looking more for techniques like my above ...
[1]: http://stackoverflow.com/questions/1739221/what-is-a-good-javascript-debugging-tool | javascript | jquery | debugging | null | null | 05/08/2011 12:15:50 | not a real question | What are some good techniques at debugging javascript?
===
So I use JavaScript fairly regularly and I was wondering if there were any good tips or tricks in debugging javascript....Like for example I have a good one I use fairly regularly.
In my code i would do something like this
window.p = $(this);
and in the console I can do my filtering like this
window.p.next("li").find("a").val();
or whatever i need to do...but this makes it easy to debug a specific spot in the code and I know there has got to me many tips and tricks out there....thanks in advance
Also i looked at this [question][1] and though its helpful i was looking more for techniques like my above ...
[1]: http://stackoverflow.com/questions/1739221/what-is-a-good-javascript-debugging-tool | 1 |
6,210,638 | 06/02/2011 05:05:38 | 777,163 | 05/31/2011 06:20:04 | 5 | 0 | working of fork in c language | Thanks to all of you for helping me.
Now I have a problem in understanding the** working of fork system call**.
I write a code which is following :
code :`#include<stdio.h>
int main()
{
int a, b;
b=fork();
printf("\nmy name is manish\n");
printf("\n my name is anil\n");
printf("\n the value of b = %d",b);
}`
The output of this code is following :
**my name is manish
my name is anil
my name is manish
my name is anil
the value of b = 2244 the value of b = 0manish.yadav@ws40-man-lin:~$**
Now I don't understand why the output is like this ?
After that i just add a line to my code and output is completely different.
my code is following:
code:`int main()
{
int a, b;
b=fork();
printf("\nmy name is manish\n");
printf("\n my name is anil\n");
printf("\nmy name is sunil\n");
printf("\n the value of b = %d",b);
}'
when i run the code the output is following
**my name is manish
my name is anil
my name is sunil
the value of b = 2389my name is manish
my name is anil
my name is sunil
the value of b = 0**
Now I'm totally confused about the working of fork() call.
my question are following:
1. How fork works ?
2. Where the control goes after the fork call?
3. Can any body explain why the outputs of codes written in problem ?
4. why the out put of b occurring at different places means in first code
the output of b =2260 is just before the output b=o while the value of
b=2389 is not just before the b=0 ?
Please explain me the working of fork in the code written in the problem so that I can learn it properly .
| c | fork | forking | system-programming | null | 06/08/2011 13:24:28 | not a real question | working of fork in c language
===
Thanks to all of you for helping me.
Now I have a problem in understanding the** working of fork system call**.
I write a code which is following :
code :`#include<stdio.h>
int main()
{
int a, b;
b=fork();
printf("\nmy name is manish\n");
printf("\n my name is anil\n");
printf("\n the value of b = %d",b);
}`
The output of this code is following :
**my name is manish
my name is anil
my name is manish
my name is anil
the value of b = 2244 the value of b = 0manish.yadav@ws40-man-lin:~$**
Now I don't understand why the output is like this ?
After that i just add a line to my code and output is completely different.
my code is following:
code:`int main()
{
int a, b;
b=fork();
printf("\nmy name is manish\n");
printf("\n my name is anil\n");
printf("\nmy name is sunil\n");
printf("\n the value of b = %d",b);
}'
when i run the code the output is following
**my name is manish
my name is anil
my name is sunil
the value of b = 2389my name is manish
my name is anil
my name is sunil
the value of b = 0**
Now I'm totally confused about the working of fork() call.
my question are following:
1. How fork works ?
2. Where the control goes after the fork call?
3. Can any body explain why the outputs of codes written in problem ?
4. why the out put of b occurring at different places means in first code
the output of b =2260 is just before the output b=o while the value of
b=2389 is not just before the b=0 ?
Please explain me the working of fork in the code written in the problem so that I can learn it properly .
| 1 |
9,316,712 | 02/16/2012 18:15:31 | 8,741 | 09/15/2008 16:46:16 | 5,413 | 100 | How to shift development of an existing MVC3 app to a TDD approach? | I have a fairly large MVC3 application, of which I have developed a small first phase without unit testing. I know it's a bit irresponsible to say this, but it hasn't really been necessary so far, with very simple CRUD operations, but I would like to move toward a TDD approach going forward.
I have basically completed phase 1, where members can register as authors and create course modules. Now I have more complex phases to implement where consumers of the courses and their trainees must register and complete courses, with academic progress tracking, author feedback and financial implications. I feel it would be unwise to proceed without a solid unit testing strategy, and based on past experience I feel TDD would be quite suitable here.
Are there any known procedures for 'converting' a development effort to TDD, and for introducing unit tests to already written code? I don't need kindergarten level step by step stuff, but general strategic guidance.
*BTW, I have included the web-development and MVC tags on this question as I believe these fields of development can significant influence on the unit testing requirements of project artefacts. If you disagree and wish to remove any of them, please be so kind as to leave a comment saying why.* | asp.net-mvc | asp.net-mvc-3 | unit-testing | tdd | null | null | open | How to shift development of an existing MVC3 app to a TDD approach?
===
I have a fairly large MVC3 application, of which I have developed a small first phase without unit testing. I know it's a bit irresponsible to say this, but it hasn't really been necessary so far, with very simple CRUD operations, but I would like to move toward a TDD approach going forward.
I have basically completed phase 1, where members can register as authors and create course modules. Now I have more complex phases to implement where consumers of the courses and their trainees must register and complete courses, with academic progress tracking, author feedback and financial implications. I feel it would be unwise to proceed without a solid unit testing strategy, and based on past experience I feel TDD would be quite suitable here.
Are there any known procedures for 'converting' a development effort to TDD, and for introducing unit tests to already written code? I don't need kindergarten level step by step stuff, but general strategic guidance.
*BTW, I have included the web-development and MVC tags on this question as I believe these fields of development can significant influence on the unit testing requirements of project artefacts. If you disagree and wish to remove any of them, please be so kind as to leave a comment saying why.* | 0 |
2,029,058 | 01/08/2010 16:36:37 | 170,934 | 09/09/2009 15:34:47 | 36 | 8 | ASP.NET MVC 2 Drop Down List In Place of Master List Grid | Instead of a grid with an 'Edit' link in each row, I'd like to use a drop down list and a single 'Edit' button. What's the cleanest way to make that button direct to /Edit/{id}(i.e. the ddl selected value)? Using onclick with window.location is way too ugly, super ugly if I have to account for the url base being http://approot/ or http://approot/controllername/ since it's on the Index view. | asp.net-mvc | c#-3.0 | null | null | null | null | open | ASP.NET MVC 2 Drop Down List In Place of Master List Grid
===
Instead of a grid with an 'Edit' link in each row, I'd like to use a drop down list and a single 'Edit' button. What's the cleanest way to make that button direct to /Edit/{id}(i.e. the ddl selected value)? Using onclick with window.location is way too ugly, super ugly if I have to account for the url base being http://approot/ or http://approot/controllername/ since it's on the Index view. | 0 |
5,259,847 | 03/10/2011 12:53:36 | 322,378 | 04/21/2010 14:18:51 | 101 | 5 | retreiving values from a for loop and dynamically adding them to a JSON in an array | So I have a for-loop which returns for each result record a
id
Name
StartDate
EndDate
here it is the for-loop below >
for (var i = 0; i < data.d.results.length; i++) {
}
So at the end depending on how many records returned I am going to have a few of these.
What I do want to do is as these records are created dynamically in the loop add them to a json object of mine
jsonObject= [{
id: 0, name: Name1, series: [{ start: Startdate1, end: Enddate1 }],
id: 1, name: Name2, series: [{ start: Startdate2, end: Enddate2 }],
id: 2, name: Name3, series: [{ start: Startdate3, end: Enddate3 }],
}];
So through the loop the id's 1 get added within the object, then 2 then 3.
I've been reading up on the .push method but not sure how I structure this one. | jquery | json | for-loop | null | null | null | open | retreiving values from a for loop and dynamically adding them to a JSON in an array
===
So I have a for-loop which returns for each result record a
id
Name
StartDate
EndDate
here it is the for-loop below >
for (var i = 0; i < data.d.results.length; i++) {
}
So at the end depending on how many records returned I am going to have a few of these.
What I do want to do is as these records are created dynamically in the loop add them to a json object of mine
jsonObject= [{
id: 0, name: Name1, series: [{ start: Startdate1, end: Enddate1 }],
id: 1, name: Name2, series: [{ start: Startdate2, end: Enddate2 }],
id: 2, name: Name3, series: [{ start: Startdate3, end: Enddate3 }],
}];
So through the loop the id's 1 get added within the object, then 2 then 3.
I've been reading up on the .push method but not sure how I structure this one. | 0 |
3,281,253 | 07/19/2010 13:06:39 | 395,836 | 07/19/2010 13:06:39 | 1 | 0 | How to replace strings in C, just using stdio.h??? Help, please!!! | i need to create a small program: user enter 1st string ex: I'm a beautiful girl
then he needs to replace for example 'beautiful' to 'clever'
can use just stdio.h and pointers as well
help me, pls!!!
| c | pointers | null | null | null | 07/19/2010 14:05:24 | not a real question | How to replace strings in C, just using stdio.h??? Help, please!!!
===
i need to create a small program: user enter 1st string ex: I'm a beautiful girl
then he needs to replace for example 'beautiful' to 'clever'
can use just stdio.h and pointers as well
help me, pls!!!
| 1 |
9,319,186 | 02/16/2012 21:16:18 | 251,047 | 01/14/2010 20:31:25 | 497 | 12 | Fire postback onkeypress | There is a textbox and a gridview inside an updatepanel. I want the gridview to be refreshed as the user types in the textbox. i wrote the gridview binding code in the textbox_textchanged() event.
this works only on onblur. How do i make this work onkeypress. like google search.
| asp.net | null | null | null | null | 02/18/2012 03:49:40 | not a real question | Fire postback onkeypress
===
There is a textbox and a gridview inside an updatepanel. I want the gridview to be refreshed as the user types in the textbox. i wrote the gridview binding code in the textbox_textchanged() event.
this works only on onblur. How do i make this work onkeypress. like google search.
| 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.