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
11,629,847
07/24/2012 11:25:19
693,560
04/05/2011 09:40:08
1,303
8
How is this animation done?
I like the way this little animation is showed: https://gidsy.com/city/london/ At the very top left, when we mouse over the logo, the `Home` text is showed. How is this possible? I check the css and did not found. Thanks for your help.
jquery
html
css
null
null
07/24/2012 13:07:08
not a real question
How is this animation done? === I like the way this little animation is showed: https://gidsy.com/city/london/ At the very top left, when we mouse over the logo, the `Home` text is showed. How is this possible? I check the css and did not found. Thanks for your help.
1
9,976,380
04/02/2012 12:25:09
1,130,052
01/04/2012 13:42:08
469
10
Parsing datime in vb.net
Why this throws an exception and how to fix this one? Thanks ! ![enter image description here][1] [1]: http://i.stack.imgur.com/EWyIb.png
vb.net
datetime
null
null
null
04/03/2012 13:10:59
not a real question
Parsing datime in vb.net === Why this throws an exception and how to fix this one? Thanks ! ![enter image description here][1] [1]: http://i.stack.imgur.com/EWyIb.png
1
6,989,917
08/08/2011 23:48:39
883,432
08/08/2011 04:28:06
3
0
What is wrong with my Matlab code? Index out of bounds
I'm trying to read in a text file that contains GPGGA strings! But I get ??? Attempted to access Longitude(1); index out of bounds because numel(Longitude)=0. Error in ==> filter at 16 Location(:,i)=coordinates(Longitude(i),Latitude(i))'; filter.m clear all A=textread('C:\Users\myself\Desktop\2.txt','%s','headerlines',1); for i=1:30; n=2*i-1; A(i)=A(n); end b=A(1:30,:);%Read GPGGA String c=char(b);%Converted to an array of characters Latitude=c(:,17:24);%Extract Latitude Array Longitude=c(:,28:36);%Extract Longitude Array format long Latitude=str2num(Latitude)/100; Longitude=str2num(Longitude)/100; Location=zeros(2,30); for i=1:30 Location(:,i)=coordinates(Longitude(i),Latitude(i))'; x=Location(1,:); y=Location(2,:); %s=[s]'; end figure(1) t=1:1:30; plot(x,y,'+'); axis([842 852 962 972]); xlabel('xp position'); ylabel('yp position'); title('the track before kalman filtering'); Y=zeros(2,30); Y1=[y(1),0]; Y(:,1)=Y1; X=zeros(2,30); X1=[x(1),0]; X(:,1)=X1; A=[1 1 0 1]; %B=[1/2*(T)^2 T]'; H=[1 0]; C0=[0 0 0 1]; C=[C0 zeros(2,2*29)]; %Q=(0.001)^2; Q=(0.001)^2; R=10; % kalman algorithm ieration for n=1:30 i=(n-1)*2+1; K=C(:,i:i+1)*H'*inv(H*C(:,i:i+1)*H'+R); Y(:,n)=Y(:,n)+K*(Location(2,n)-H*Y(:,n)); Y(:,n+1)=A*Y(:,n); C(:,i:i+1)=(eye(2,2)-K*H)*C(:,i:i+1); C(:,i+2:i+3)=A*C(:,i:i+1)*A'+Q; %C(:,i+2:i+3)=A*C(:,i:i+1)*A'+B*Q*B'; end % the diagram of position after filtering X=zeros(2,30); X1=[x(1),0]; X(:,1)=X1; A1=[1 1 0 1]; %B=[1/2*(T)^2 T]'; H1=[1 0]; C0=[0 0 0 1]; CC=[C0 zeros(2,2*29)]; %Q=(0.001)^2; Q1=(0.001)^2; R1=10; % kalman algorithm ieration for m=1:30 ii=(m-1)*2+1; K=CC(:,ii:ii+1)*H1'*inv(H1*CC(:,ii:ii+1)*H1'+R1); X(:,m)=X(:,m)+K*(Location(1,m)-H1*X(:,m)); X(:,m+1)=A1*X(:,m); CC(:,ii:ii+1)=(eye(2,2)-K*H1)*CC(:,ii:ii+1); CC(:,ii+2:ii+3)=A1*CC(:,ii:ii+1)*A1'+Q1; %C(:,i+2:i+3)=A*C(:,i:i+1)*A'+B*Q*B'; end figure(2) t=0:1:30; xp=X(1,:); yp=Y(1,:); plot(xp,yp,'+'); axis([842 852 962 972]); xlabel('xp position'); ylabel('yp position'); title('the track after kalman filtering'); These are the contents of the text file 2.txt > $GPGGA,095836.5,5556.641380,N,00311.016376,W,1,08,1.1,89.1,M,48.0,M,,*73 > $GPGGA,095837.5,5556.641322,N,00311.015649,W,1,08,1.1,90.3,M,48.0,M,,*7A > $GPGGA,095838.5,5556.640691,N,00311.016904,W,1,08,1.1,91.5,M,48.0,M,,*7B > $GPGGA,095839.5,5556.640676,N,00311.015545,W,1,08,1.1,91.5,M,48.0,M,,*79 > $GPGGA,095840.5,5556.640075,N,00311.015346,W,1,09,1.0,92.8,M,48.0,M,,*79 > $GPGGA,095841.5,5556.640047,N,00311.015429,W,1,10,0.8,93.5,M,48.0,M,,*7A > $GPGGA,095842.5,5556.639860,N,00311.013943,W,1,10,0.8,94.5,M,48.0,M,,*7A I can't figure out why it is wrong?!!
matlab
filter
nmea
kalman
null
08/09/2011 07:57:36
too localized
What is wrong with my Matlab code? Index out of bounds === I'm trying to read in a text file that contains GPGGA strings! But I get ??? Attempted to access Longitude(1); index out of bounds because numel(Longitude)=0. Error in ==> filter at 16 Location(:,i)=coordinates(Longitude(i),Latitude(i))'; filter.m clear all A=textread('C:\Users\myself\Desktop\2.txt','%s','headerlines',1); for i=1:30; n=2*i-1; A(i)=A(n); end b=A(1:30,:);%Read GPGGA String c=char(b);%Converted to an array of characters Latitude=c(:,17:24);%Extract Latitude Array Longitude=c(:,28:36);%Extract Longitude Array format long Latitude=str2num(Latitude)/100; Longitude=str2num(Longitude)/100; Location=zeros(2,30); for i=1:30 Location(:,i)=coordinates(Longitude(i),Latitude(i))'; x=Location(1,:); y=Location(2,:); %s=[s]'; end figure(1) t=1:1:30; plot(x,y,'+'); axis([842 852 962 972]); xlabel('xp position'); ylabel('yp position'); title('the track before kalman filtering'); Y=zeros(2,30); Y1=[y(1),0]; Y(:,1)=Y1; X=zeros(2,30); X1=[x(1),0]; X(:,1)=X1; A=[1 1 0 1]; %B=[1/2*(T)^2 T]'; H=[1 0]; C0=[0 0 0 1]; C=[C0 zeros(2,2*29)]; %Q=(0.001)^2; Q=(0.001)^2; R=10; % kalman algorithm ieration for n=1:30 i=(n-1)*2+1; K=C(:,i:i+1)*H'*inv(H*C(:,i:i+1)*H'+R); Y(:,n)=Y(:,n)+K*(Location(2,n)-H*Y(:,n)); Y(:,n+1)=A*Y(:,n); C(:,i:i+1)=(eye(2,2)-K*H)*C(:,i:i+1); C(:,i+2:i+3)=A*C(:,i:i+1)*A'+Q; %C(:,i+2:i+3)=A*C(:,i:i+1)*A'+B*Q*B'; end % the diagram of position after filtering X=zeros(2,30); X1=[x(1),0]; X(:,1)=X1; A1=[1 1 0 1]; %B=[1/2*(T)^2 T]'; H1=[1 0]; C0=[0 0 0 1]; CC=[C0 zeros(2,2*29)]; %Q=(0.001)^2; Q1=(0.001)^2; R1=10; % kalman algorithm ieration for m=1:30 ii=(m-1)*2+1; K=CC(:,ii:ii+1)*H1'*inv(H1*CC(:,ii:ii+1)*H1'+R1); X(:,m)=X(:,m)+K*(Location(1,m)-H1*X(:,m)); X(:,m+1)=A1*X(:,m); CC(:,ii:ii+1)=(eye(2,2)-K*H1)*CC(:,ii:ii+1); CC(:,ii+2:ii+3)=A1*CC(:,ii:ii+1)*A1'+Q1; %C(:,i+2:i+3)=A*C(:,i:i+1)*A'+B*Q*B'; end figure(2) t=0:1:30; xp=X(1,:); yp=Y(1,:); plot(xp,yp,'+'); axis([842 852 962 972]); xlabel('xp position'); ylabel('yp position'); title('the track after kalman filtering'); These are the contents of the text file 2.txt > $GPGGA,095836.5,5556.641380,N,00311.016376,W,1,08,1.1,89.1,M,48.0,M,,*73 > $GPGGA,095837.5,5556.641322,N,00311.015649,W,1,08,1.1,90.3,M,48.0,M,,*7A > $GPGGA,095838.5,5556.640691,N,00311.016904,W,1,08,1.1,91.5,M,48.0,M,,*7B > $GPGGA,095839.5,5556.640676,N,00311.015545,W,1,08,1.1,91.5,M,48.0,M,,*79 > $GPGGA,095840.5,5556.640075,N,00311.015346,W,1,09,1.0,92.8,M,48.0,M,,*79 > $GPGGA,095841.5,5556.640047,N,00311.015429,W,1,10,0.8,93.5,M,48.0,M,,*7A > $GPGGA,095842.5,5556.639860,N,00311.013943,W,1,10,0.8,94.5,M,48.0,M,,*7A I can't figure out why it is wrong?!!
3
7,200,962
08/26/2011 06:44:39
905,523
08/22/2011 08:49:20
1
0
mobile website design for android phones
i want to design a website for android mobile phones using html.can any one please help me out. Where should i start? How to write css or should i recreate a new website for mobile phones?
android
null
null
null
null
08/26/2011 11:16:22
not a real question
mobile website design for android phones === i want to design a website for android mobile phones using html.can any one please help me out. Where should i start? How to write css or should i recreate a new website for mobile phones?
1
7,607,805
09/30/2011 08:27:24
972,705
09/30/2011 08:24:41
1
0
Flash As2 Image snapshot
Is there any approach to take the snapshot of a drawing created in pure AS2 flash coding ? I tried to use Bitmapdata and bridge but bitmap works in as3 and bridge combines two swf together and communicate with them. Is there a way of doing screenshot in as2 ?
flash
actionscript-2
null
null
null
null
open
Flash As2 Image snapshot === Is there any approach to take the snapshot of a drawing created in pure AS2 flash coding ? I tried to use Bitmapdata and bridge but bitmap works in as3 and bridge combines two swf together and communicate with them. Is there a way of doing screenshot in as2 ?
0
9,637,567
03/09/2012 16:29:13
1,259,697
03/09/2012 16:15:42
1
0
Learn iOS development (Already know Objective-C)
I want to start programming for iOS. I already have a solid footing in Objective-C, so I am not looking for a guide on Objective-C. I am NOT a beginner. Could any of you please point me in the right direction for tutorials on developing iOS apps, NOT for learning Objective-C? Thank you very much!
iphone
objective-c
ios
xcode
development
03/09/2012 23:13:24
not constructive
Learn iOS development (Already know Objective-C) === I want to start programming for iOS. I already have a solid footing in Objective-C, so I am not looking for a guide on Objective-C. I am NOT a beginner. Could any of you please point me in the right direction for tutorials on developing iOS apps, NOT for learning Objective-C? Thank you very much!
4
6,375,544
06/16/2011 16:45:24
801,944
06/16/2011 16:45:24
1
0
Javascript, How to get selected value of each drop down list present in column 1 of a 100 row table
I have a html table with 5 columns, column1 : Row Index Number starting from 1 column2 : select list with 4 values column3 : simple text column4 : simple text column5: two buttons which perform add or remove row. At run time, i want to get the selected / entered values for the first 4 columns in each row. Please help. I know a little of html and javascript. I want to achieve the above using html, javascript.
javascript
drop-down-menu
iteration
innerhtml
selectlist
01/12/2012 19:12:40
not a real question
Javascript, How to get selected value of each drop down list present in column 1 of a 100 row table === I have a html table with 5 columns, column1 : Row Index Number starting from 1 column2 : select list with 4 values column3 : simple text column4 : simple text column5: two buttons which perform add or remove row. At run time, i want to get the selected / entered values for the first 4 columns in each row. Please help. I know a little of html and javascript. I want to achieve the above using html, javascript.
1
6,028,537
05/17/2011 09:02:14
580,930
01/19/2011 05:01:10
1
0
How to save the images in particular folder my Application in windows form application using C#.net
How to save the image in particular folder of application in windows form application using C#.net.without using OpenFileDialog... Just Browse and Save ....images without Using openFilDailog......
c#
windows
image
forms
application
03/11/2012 14:45:37
not a real question
How to save the images in particular folder my Application in windows form application using C#.net === How to save the image in particular folder of application in windows form application using C#.net.without using OpenFileDialog... Just Browse and Save ....images without Using openFilDailog......
1
6,192,914
05/31/2011 20:04:59
771,861
05/26/2011 18:44:14
13
0
Spring beans injected into JSF Managed Beans
Problem Description: My injected Spring bean defined as a Managed-Property to a JSF backing bean is not being instantiated. Its always coming up null when I retreive the Managed-Bean. I have been fighting with this all day and it seems that JSF Managed Bean just won't read out of the applicationContext from Spring. I can manually pull out the bean by using the FacesContext in a backing bean and it finds the bean but when I try and inject it through the FacesConfig it always comes out null. I included my steps below how I integrated it. Any suggestions? ###Configuration JSF 1.2 Spring 3.0 Websphere 7.5 ( Which is eclipse 3.5 I think ) ##Web.xml Configuration Changes ###Spring Context Loader Listener <listener> <display-name>SpringListener</display-name> <icon> <small-icon>small.gif</small-icon> <large-icon>large.gif</large-icon> </icon> <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class> </listener> ### Context Config <context-param> <param-name>contextConfigLocation</param-name> <param-value> /WEB-INF/SpringConfig/SpringHelloWorld.xml </param-value> </context-param> ## FacesContext Changes ### Variable Resolver - AKA The Glue `<application><variable-resolver>org.springframework.web.jsf.DelegatingVariableResolver</variable-resolver></application> ` ###Managed Bean <managed-bean> <managed-bean-name>testData</managed-bean-name> <managed-bean-class>src.test.TestData</managed-bean-class> <managed-bean-scope>session</managed-bean-scope> <managed-property> <property-name>spring3HelloWorldBean</property-name> <value>#{Spring3HelloWorldBean}</value> </managed-property> </managed-bean> ###Spring.xml Config <bean id="spring3HelloWorldBean" class="src.test.Spring3HelloWorld" /> </beans> Thanks in advance
spring
configuration
null
null
null
null
open
Spring beans injected into JSF Managed Beans === Problem Description: My injected Spring bean defined as a Managed-Property to a JSF backing bean is not being instantiated. Its always coming up null when I retreive the Managed-Bean. I have been fighting with this all day and it seems that JSF Managed Bean just won't read out of the applicationContext from Spring. I can manually pull out the bean by using the FacesContext in a backing bean and it finds the bean but when I try and inject it through the FacesConfig it always comes out null. I included my steps below how I integrated it. Any suggestions? ###Configuration JSF 1.2 Spring 3.0 Websphere 7.5 ( Which is eclipse 3.5 I think ) ##Web.xml Configuration Changes ###Spring Context Loader Listener <listener> <display-name>SpringListener</display-name> <icon> <small-icon>small.gif</small-icon> <large-icon>large.gif</large-icon> </icon> <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class> </listener> ### Context Config <context-param> <param-name>contextConfigLocation</param-name> <param-value> /WEB-INF/SpringConfig/SpringHelloWorld.xml </param-value> </context-param> ## FacesContext Changes ### Variable Resolver - AKA The Glue `<application><variable-resolver>org.springframework.web.jsf.DelegatingVariableResolver</variable-resolver></application> ` ###Managed Bean <managed-bean> <managed-bean-name>testData</managed-bean-name> <managed-bean-class>src.test.TestData</managed-bean-class> <managed-bean-scope>session</managed-bean-scope> <managed-property> <property-name>spring3HelloWorldBean</property-name> <value>#{Spring3HelloWorldBean}</value> </managed-property> </managed-bean> ###Spring.xml Config <bean id="spring3HelloWorldBean" class="src.test.Spring3HelloWorld" /> </beans> Thanks in advance
0
708,230
04/02/2009 03:55:26
85,473
04/01/2009 03:51:23
1
0
PHP Addslashes adding double backslashes when escaping a single quote
Addslashes seems to be a bit confused. Given the following 2 lines of code $name = "Dave's test"; $newName = addslashes($name); I am *expecting* $newName to be **"Dave\'s test"** (my one single quote nicely escaped) However, what I'm *getting* is **"Dave\\\'s test"** (note the DOUBLE backslashes). This contradicts every bit of online documentation I can find on addslashes - and causing me a lot of grief. Any insights into why addslashes would be double up on the backslases are much appreciated. FYI: I'm Using PHP 5.2.6 under linux with magic quotes OFF.
php
null
null
null
null
01/11/2012 18:08:02
too localized
PHP Addslashes adding double backslashes when escaping a single quote === Addslashes seems to be a bit confused. Given the following 2 lines of code $name = "Dave's test"; $newName = addslashes($name); I am *expecting* $newName to be **"Dave\'s test"** (my one single quote nicely escaped) However, what I'm *getting* is **"Dave\\\'s test"** (note the DOUBLE backslashes). This contradicts every bit of online documentation I can find on addslashes - and causing me a lot of grief. Any insights into why addslashes would be double up on the backslases are much appreciated. FYI: I'm Using PHP 5.2.6 under linux with magic quotes OFF.
3
6,991,939
08/09/2011 05:55:39
644,437
03/04/2011 09:28:55
28
0
Perst DB for Androd?
Where can i download Perst DB for Android? is it Free for download? I was not able download from MCObject. is there any other way to download perst for android?
android
persistence
null
null
null
08/09/2011 09:37:12
off topic
Perst DB for Androd? === Where can i download Perst DB for Android? is it Free for download? I was not able download from MCObject. is there any other way to download perst for android?
2
5,505,392
03/31/2011 19:42:36
570,779
01/11/2011 04:34:25
1
0
How to search duplicate users in two files and then print those lines?
I have two files: FILE1 and FILE2: FILE1: user1 1.1.1.1 user2 2.2.2.2 user3 3.14.14.3 user4 4.4.4.4 user5 198.222.222.222 FILE2 user1 99.22.54.214 user66 45.22.88.88 user99 44.55.66.66 user4 8.8.8.8 user39 54.54.54.54 user2 2.2.2.2 OUTPUT FILE user1 1.1.1.1 user1 99.22.54.214 user2 2.2.2.2 user4 4.4.4.4 user4 8.8.8.8 I tried with a for loop but with particular succes.. Can anyone write me a code for this? Thx!
for-loop
awk
grep
null
null
null
open
How to search duplicate users in two files and then print those lines? === I have two files: FILE1 and FILE2: FILE1: user1 1.1.1.1 user2 2.2.2.2 user3 3.14.14.3 user4 4.4.4.4 user5 198.222.222.222 FILE2 user1 99.22.54.214 user66 45.22.88.88 user99 44.55.66.66 user4 8.8.8.8 user39 54.54.54.54 user2 2.2.2.2 OUTPUT FILE user1 1.1.1.1 user1 99.22.54.214 user2 2.2.2.2 user4 4.4.4.4 user4 8.8.8.8 I tried with a for loop but with particular succes.. Can anyone write me a code for this? Thx!
0
1,990,563
01/02/2010 03:59:27
148,195
07/31/2009 00:00:53
849
31
Rubygame on OS X
I'm playing around with Rubygame. I installed it with the Mac Pack, and now I have the rsdl executable. `rsdl game.rb` works fine, but when I chmod +x the rb file, add the shebang to rsdl (tried direct path and /usr/bin/env rsdl) and try to execute it (`./game.rb`), it starts to flicker between the Terminal and rsdl which is trying to open, and eventually gives up and gives a `bus error`. Anyone know what's causing that? I'm on Snow Leopard (10.6.2) if it makes a difference. Also, what would be the best way to bundle a ruby game into a double-clickable .app ? Thanks.
ruby
rubygame
osx
shebang
app-bundle
null
open
Rubygame on OS X === I'm playing around with Rubygame. I installed it with the Mac Pack, and now I have the rsdl executable. `rsdl game.rb` works fine, but when I chmod +x the rb file, add the shebang to rsdl (tried direct path and /usr/bin/env rsdl) and try to execute it (`./game.rb`), it starts to flicker between the Terminal and rsdl which is trying to open, and eventually gives up and gives a `bus error`. Anyone know what's causing that? I'm on Snow Leopard (10.6.2) if it makes a difference. Also, what would be the best way to bundle a ruby game into a double-clickable .app ? Thanks.
0
7,291,016
09/03/2011 03:41:07
754,865
05/15/2011 21:36:26
37
4
Matching words in strings
I have two strings of keywords $keystring1 = "tech,php,radio,love"; $keystring2 = "Mtn,huntung,php,tv,tech"; How do i do return keywords that common in both strings
php
null
null
null
null
null
open
Matching words in strings === I have two strings of keywords $keystring1 = "tech,php,radio,love"; $keystring2 = "Mtn,huntung,php,tv,tech"; How do i do return keywords that common in both strings
0
3,800,129
09/26/2010 22:43:03
449,692
09/16/2010 15:28:06
6
0
Rails3: Cloning already-validated object prevents clone being invalidated -- is this strange or normal?
In Rails (3.0) test code, I've cloned an object so I can clobber it for validation testing without changing the original. If I have called assert(original.valid?) _before_ cloning, then the clone passes the validates_presence_of test even after I have set member_id value to nil. The two tests below illustrate this. In test one, the clone is created _before_ the original ("contact") is validated. Clone correctly fails the validation when member_id is missing. Assertion C succeeds. In test two, the clone is created _after_ the original is validated. Even though clone.member_id is set to nil, it _passes_ the validation. In other words, assertion 2C fails. The _only_ difference between the tests is the order of the two lines: cloned = contact.clone assert(contact.valid?,"A") What is going on here? Is this normal Ruby behavior re: cloning that I just don't understand? test "clone problem 1" do contact = Contact.new(:member_id => 1) cloned = contact.clone assert(contact.valid?,"A") cloned.member_id = nil assert(!cloned.valid?,"C") end test "clone problem 2" do contact = Contact.new(:member_id => 1) assert(contact.valid?,"2A") cloned = contact.clone cloned.member_id = nil assert(!cloned.valid?,"2C") end
ruby-on-rails
ruby
unit-testing
validation
clone
null
open
Rails3: Cloning already-validated object prevents clone being invalidated -- is this strange or normal? === In Rails (3.0) test code, I've cloned an object so I can clobber it for validation testing without changing the original. If I have called assert(original.valid?) _before_ cloning, then the clone passes the validates_presence_of test even after I have set member_id value to nil. The two tests below illustrate this. In test one, the clone is created _before_ the original ("contact") is validated. Clone correctly fails the validation when member_id is missing. Assertion C succeeds. In test two, the clone is created _after_ the original is validated. Even though clone.member_id is set to nil, it _passes_ the validation. In other words, assertion 2C fails. The _only_ difference between the tests is the order of the two lines: cloned = contact.clone assert(contact.valid?,"A") What is going on here? Is this normal Ruby behavior re: cloning that I just don't understand? test "clone problem 1" do contact = Contact.new(:member_id => 1) cloned = contact.clone assert(contact.valid?,"A") cloned.member_id = nil assert(!cloned.valid?,"C") end test "clone problem 2" do contact = Contact.new(:member_id => 1) assert(contact.valid?,"2A") cloned = contact.clone cloned.member_id = nil assert(!cloned.valid?,"2C") end
0
10,571,394
05/13/2012 11:36:35
1,392,103
05/13/2012 11:28:45
1
0
Splitting a python list by a character in each element
I have a python list with elements which are a list containing a string of a letter and number and I was wondering how I could split the list into by the character at the start of the string without creating a statement for each character. So I want to split mylist into lists a,b, and c. mylist = [['a1'],['a2'],['c1'],['b1']] a = [['a1'],['a2']] b = [['b1']] c = [['c1']] It is important that I keep them as a list of lists (even though it's only a single element in each little list). Thanks
list
python-2.7
null
null
null
null
open
Splitting a python list by a character in each element === I have a python list with elements which are a list containing a string of a letter and number and I was wondering how I could split the list into by the character at the start of the string without creating a statement for each character. So I want to split mylist into lists a,b, and c. mylist = [['a1'],['a2'],['c1'],['b1']] a = [['a1'],['a2']] b = [['b1']] c = [['c1']] It is important that I keep them as a list of lists (even though it's only a single element in each little list). Thanks
0
4,923,742
02/07/2011 16:32:50
505,943
11/12/2010 15:47:40
32
4
Problem unmarshall with Xstream an attribute with name "class"
I have a node with a attribute name "*class*" . The input xml is : <Job class="com.test.jobImplementation"> <Priority>1</Priority> ...... </Job> The Java class which represent the xml is annotated with Xstream annotations is as follows : @XStreamAlias("Job") public static class Job { @XStreamAsAttribute @XStreamAlias("class") private String implementationClass; @XStreamAlias("Priority") private Integer priority } When I try to deserialize the xml, xstream fails returning an error unrelated to the problem. (e.g When I replace the attribute name "class" by "classs" works fine) . I know the "class" attribute is used whenever XStream can't tell from the XML and the field declaration exactly what type to use but In this case I can't modify the xml input and I have to process the attribute "class". Any workaround for unmarshall and xml attribute with name "class" with Xstream ? Thanks
xstream
unmarshall
null
null
null
null
open
Problem unmarshall with Xstream an attribute with name "class" === I have a node with a attribute name "*class*" . The input xml is : <Job class="com.test.jobImplementation"> <Priority>1</Priority> ...... </Job> The Java class which represent the xml is annotated with Xstream annotations is as follows : @XStreamAlias("Job") public static class Job { @XStreamAsAttribute @XStreamAlias("class") private String implementationClass; @XStreamAlias("Priority") private Integer priority } When I try to deserialize the xml, xstream fails returning an error unrelated to the problem. (e.g When I replace the attribute name "class" by "classs" works fine) . I know the "class" attribute is used whenever XStream can't tell from the XML and the field declaration exactly what type to use but In this case I can't modify the xml input and I have to process the attribute "class". Any workaround for unmarshall and xml attribute with name "class" with Xstream ? Thanks
0
8,940,179
01/20/2012 10:46:59
1,041,742
11/11/2011 13:04:09
431
13
NoClassDefFoundError when runnning a class
I am trying to run a class, but I get the following error: java.lang.NoClassDefFoundError: MyClass Caused by: java.lang.ClassNotFoundException: MyClass at java.net.URLClassLoader$1.run(URLClassLoader.java:202) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:190) at java.lang.ClassLoader.loadClass(ClassLoader.java:306) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) at java.lang.ClassLoader.loadClass(ClassLoader.java:247) Exception in thread "main" It happens, although the `main` method is in `MyClass` and I run directly this class. Why is this class not found, although I launch the program from it?
java
class
null
null
null
01/20/2012 15:30:41
too localized
NoClassDefFoundError when runnning a class === I am trying to run a class, but I get the following error: java.lang.NoClassDefFoundError: MyClass Caused by: java.lang.ClassNotFoundException: MyClass at java.net.URLClassLoader$1.run(URLClassLoader.java:202) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:190) at java.lang.ClassLoader.loadClass(ClassLoader.java:306) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) at java.lang.ClassLoader.loadClass(ClassLoader.java:247) Exception in thread "main" It happens, although the `main` method is in `MyClass` and I run directly this class. Why is this class not found, although I launch the program from it?
3
7,570,522
09/27/2011 14:07:49
203,686
11/05/2009 16:17:40
120
9
Oracle as JMS Server: Any Feedback?
We would select a queue server for a distributed architecture. Our DBA talked us about Oracle JMS Server? What is your feeling? I got feedback with servers like RabbitMQ/HornetMQ/ActiveMQ? How would you compare it to Oracle JMS?
oracle
jms
rabbitmq
mq
null
09/27/2011 21:04:00
not constructive
Oracle as JMS Server: Any Feedback? === We would select a queue server for a distributed architecture. Our DBA talked us about Oracle JMS Server? What is your feeling? I got feedback with servers like RabbitMQ/HornetMQ/ActiveMQ? How would you compare it to Oracle JMS?
4
2,973,556
06/04/2010 11:14:39
218,377
11/25/2009 07:31:11
648
4
elaborate urls with regex
i have a string that maybe contains text with links. I use these instructions for elaborate it: message = message.gsub(/http[s]?:\/\/[^\s]+/) do |m| replace_url(m) end if the string is `"http://www.youtube.com/watch?v=6zToqLlM8ms&amp;playnext_from=TL&videos=qpCvM5Ocr3M&feature=sub"` the instructions works. but if the string is `"hi my video is http://www.youtube.com/watch?v=6zToqLlM8ms&amp;playnext_from=TL&videos=qpCvM5Ocr3M&feature=sub"` doesn't works why? how can i do? thanks
ruby-on-rails
regex
string
null
null
null
open
elaborate urls with regex === i have a string that maybe contains text with links. I use these instructions for elaborate it: message = message.gsub(/http[s]?:\/\/[^\s]+/) do |m| replace_url(m) end if the string is `"http://www.youtube.com/watch?v=6zToqLlM8ms&amp;playnext_from=TL&videos=qpCvM5Ocr3M&feature=sub"` the instructions works. but if the string is `"hi my video is http://www.youtube.com/watch?v=6zToqLlM8ms&amp;playnext_from=TL&videos=qpCvM5Ocr3M&feature=sub"` doesn't works why? how can i do? thanks
0
10,179,837
04/16/2012 18:48:32
1,336,893
04/16/2012 17:18:18
1
0
Optimization of Algorithm
Here is the [link](https://www.interviewstreet.com/challenges/dashboard/#problem/4e14a0058572a) to the problem. The problem asks the number of solutions to the Diophantine equation of the form <i>1/x + 1/y = 1/z</i> (where <i>z = n!</i>). Rearranging the given equation clearly tells that the answer is the number of factors of <i>z<sup>2</sup></i>. So problem boils to find the number of factors of <i>n!<sup>2</sup></i>. My algorithm is as follows 1. Make a boolean look up table for all primes <= n using Sieve of Eratosthenes algorithm. 2. Iterate over all primes <i>P</i> <= <i>n</i> and find its exponent in <i>n!</i>. I did this using step function formula. Let the exponent be <i>K</i>, then the exponent of <i>P</i> in <i>n!<sup>2</sup></i> will be <i>2K</i>. 3. Using step 2 calculate number of factors with the standard formula. For the worst case input of <i>n = 10<sup>6</sup></i>, my c code gives answer in 0.56s. I guess the complexity is no way greater than <i>O(n lg n)</i>. But when I submitted the code on the site, I could pass only 3/15 test cases with the verdict on the rest as time limit exceeded. I need some hint for optimizing this algorithm.
c++
c
primes
equations
factors
04/17/2012 04:40:41
not a real question
Optimization of Algorithm === Here is the [link](https://www.interviewstreet.com/challenges/dashboard/#problem/4e14a0058572a) to the problem. The problem asks the number of solutions to the Diophantine equation of the form <i>1/x + 1/y = 1/z</i> (where <i>z = n!</i>). Rearranging the given equation clearly tells that the answer is the number of factors of <i>z<sup>2</sup></i>. So problem boils to find the number of factors of <i>n!<sup>2</sup></i>. My algorithm is as follows 1. Make a boolean look up table for all primes <= n using Sieve of Eratosthenes algorithm. 2. Iterate over all primes <i>P</i> <= <i>n</i> and find its exponent in <i>n!</i>. I did this using step function formula. Let the exponent be <i>K</i>, then the exponent of <i>P</i> in <i>n!<sup>2</sup></i> will be <i>2K</i>. 3. Using step 2 calculate number of factors with the standard formula. For the worst case input of <i>n = 10<sup>6</sup></i>, my c code gives answer in 0.56s. I guess the complexity is no way greater than <i>O(n lg n)</i>. But when I submitted the code on the site, I could pass only 3/15 test cases with the verdict on the rest as time limit exceeded. I need some hint for optimizing this algorithm.
1
8,358,711
12/02/2011 15:36:09
1,047,741
11/15/2011 14:11:57
94
7
Override class field's ToString() method
I'm wondering, is there any way to override `ToString()` method of the class field with type `byte[]`? I'm even not sure it's possible... Here is the sample code: public class Object { private byte[] _content; public byte[] Content { get { return _content; } internal set { _content = value; } } } Is it possible to override the way how `Object.Content.ToString()` method is called? The obvious method is popping out my head — create a wrapper around `byte[]` and override its `ToString()` but this looks ugly for me and I don't think it worth it. Is there any elegant way to solve this issue? Or work around it? Many thanks in advance!
c#
.net
oop
class
null
null
open
Override class field's ToString() method === I'm wondering, is there any way to override `ToString()` method of the class field with type `byte[]`? I'm even not sure it's possible... Here is the sample code: public class Object { private byte[] _content; public byte[] Content { get { return _content; } internal set { _content = value; } } } Is it possible to override the way how `Object.Content.ToString()` method is called? The obvious method is popping out my head — create a wrapper around `byte[]` and override its `ToString()` but this looks ugly for me and I don't think it worth it. Is there any elegant way to solve this issue? Or work around it? Many thanks in advance!
0
9,784,264
03/20/2012 09:34:35
1,222,697
02/21/2012 06:19:11
92
17
PHP create a dbf file format for export
I'm trying to create a dbf file format using php, for download But I dont know how to create a dbf file using php? Any suggestion would be appreciated
php
export
dbf
null
null
null
open
PHP create a dbf file format for export === I'm trying to create a dbf file format using php, for download But I dont know how to create a dbf file using php? Any suggestion would be appreciated
0
6,065,319
05/19/2011 21:59:02
659,832
03/15/2011 01:39:41
32
0
Why is this C# load form not working?
I am trying to get a value from a config file when the form loads it puts it in a Textbox. I am using Program.cs to get the value from the config file. Everything looks setup correctly but when I run the form no value is there. public form() { InitializeComponent(); string NewValue = Program.Value; Textbox.Text = NewValue; } This work of course public form() { InitializeComponent(); Textbox.Text = "1234"; }
c#
config
null
null
null
05/21/2011 21:38:35
too localized
Why is this C# load form not working? === I am trying to get a value from a config file when the form loads it puts it in a Textbox. I am using Program.cs to get the value from the config file. Everything looks setup correctly but when I run the form no value is there. public form() { InitializeComponent(); string NewValue = Program.Value; Textbox.Text = NewValue; } This work of course public form() { InitializeComponent(); Textbox.Text = "1234"; }
3
7,585,734
09/28/2011 15:36:48
843,337
07/13/2011 18:53:45
32
0
How to make the MapView a button (iPhone/iPad)?
I currently have a map view in my app that is locked so that the user can't interact with it (i.e. scroll, zoom etc.), however I want to make it into a UIButton. The idea being the the can press the map view and it will call a function, the same way pressing a UIButton does. I've had a look around online for ideas on how to achieve this but I haven't found anything yet. I tried making a UIButton over the top of the map view but I can't seem to make it invisible. I also tried linking an IBAction to the map view, however the option to link it doesn't appear in the connections inspector (as I expected to be honest - shot in the dark!). Is there any way to achieve this effect?
iphone
iphone-sdk-4.0
uibutton
mkmapview
null
null
open
How to make the MapView a button (iPhone/iPad)? === I currently have a map view in my app that is locked so that the user can't interact with it (i.e. scroll, zoom etc.), however I want to make it into a UIButton. The idea being the the can press the map view and it will call a function, the same way pressing a UIButton does. I've had a look around online for ideas on how to achieve this but I haven't found anything yet. I tried making a UIButton over the top of the map view but I can't seem to make it invisible. I also tried linking an IBAction to the map view, however the option to link it doesn't appear in the connections inspector (as I expected to be honest - shot in the dark!). Is there any way to achieve this effect?
0
7,500,149
09/21/2011 12:58:03
887,142
08/10/2011 03:58:28
221
1
Articles on the architecture of SaaS?
I'm on the brink of building my first large self-hosted application, but where I'd really like to move onto is building an SaaS application. One of the biggest hurdles in building my self-hosted application was figuring out the architecture behind it, and that'll only get more complex when I attempt to build an SaaS application. I'm wondering if anyone has any good articles on architecture of SaaS applications, covering stuff such as authentication and good database structuring, primarily tailored to PHP if possible? Any links or recommendations would be greatly appreciated!
php
saas
null
null
null
09/21/2011 15:07:20
not constructive
Articles on the architecture of SaaS? === I'm on the brink of building my first large self-hosted application, but where I'd really like to move onto is building an SaaS application. One of the biggest hurdles in building my self-hosted application was figuring out the architecture behind it, and that'll only get more complex when I attempt to build an SaaS application. I'm wondering if anyone has any good articles on architecture of SaaS applications, covering stuff such as authentication and good database structuring, primarily tailored to PHP if possible? Any links or recommendations would be greatly appreciated!
4
6,237,921
06/04/2011 16:25:43
590,329
01/26/2011 09:01:40
142
1
How can I make a login just like on wordpress.org?
The page I am talking about is this: http://wordpress.org/extend/plugins/ It is simple and perfect in my opinion. Can anyone help me?
wordpress
login-script
null
null
null
06/04/2011 20:03:34
not a real question
How can I make a login just like on wordpress.org? === The page I am talking about is this: http://wordpress.org/extend/plugins/ It is simple and perfect in my opinion. Can anyone help me?
1
1,576,791
10/16/2009 08:25:02
112,636
05/26/2009 15:34:50
14
4
What ORM frameworks for .NET and Oracle Do You Like Best?
What ORM frameworks for .NET and Oracle Do You Like Best?
.net
.net-3.5
orm
oracle
null
09/19/2011 12:11:46
not constructive
What ORM frameworks for .NET and Oracle Do You Like Best? === What ORM frameworks for .NET and Oracle Do You Like Best?
4
11,237,098
06/28/2012 01:50:33
1,296,840
03/27/2012 23:48:56
319
20
Win32 still best for Windows game development?
I'm looking to start a new project to work on in my free time that covers a lot of areas of Computer Science and I've decided on a game (most likely flight simulator or simple 2D side-scroller). Anyway, I do a lot of C#/Java development at work writing business applications so I'm looking to do a game in C++ (I have used C#/XNA for games previously). However, I'm trying to find a good framework for C++ game development. I have used Qt before but don't believe this is suitable for what I am trying to achieve. Is Win32 and OpenGL still the best for C++ game development? Also, I want to keep this pretty OO, any recommendations for wrapping the Win32 for game development? Or does OpenGL provide abstractions to help?
c++
null
null
null
null
06/28/2012 18:39:23
not constructive
Win32 still best for Windows game development? === I'm looking to start a new project to work on in my free time that covers a lot of areas of Computer Science and I've decided on a game (most likely flight simulator or simple 2D side-scroller). Anyway, I do a lot of C#/Java development at work writing business applications so I'm looking to do a game in C++ (I have used C#/XNA for games previously). However, I'm trying to find a good framework for C++ game development. I have used Qt before but don't believe this is suitable for what I am trying to achieve. Is Win32 and OpenGL still the best for C++ game development? Also, I want to keep this pretty OO, any recommendations for wrapping the Win32 for game development? Or does OpenGL provide abstractions to help?
4
2,556,976
03/31/2010 22:39:32
122,238
06/12/2009 19:20:53
94
7
Remove HSlider horizontal control line
Does anyone know how can the horizontal control line be removed or made invisible. What am trying to say is, I just want to show the drag-thumb and not the horizontal line. Is there a way to do so, with out using skins? Regards Zeeshan
flex
actionscript-3
null
null
null
null
open
Remove HSlider horizontal control line === Does anyone know how can the horizontal control line be removed or made invisible. What am trying to say is, I just want to show the drag-thumb and not the horizontal line. Is there a way to do so, with out using skins? Regards Zeeshan
0
11,551,963
07/18/2012 23:41:12
53,658
01/10/2009 10:28:02
1,839
37
Can synchronized blocks be faster than Atomics?
Suppose two following counter implementations: class Counter { private final AtomicInteger atomic = new AtomicInteger(0); private int i = 0; public void incrementAtomic() { atomic.incrementAndGet(); } public synchronized void increment() { i++; } } At first glance atomics should be faster and more scalable. And they are, I believe. But are they faster than `synchronized` blocks all the time? Or some situations exists when this rule is broken (e.g. SMP/Single CPU machine, different CPU ISA, OS'es etc.)?
java
concurrency
java.util.concurrent
null
null
null
open
Can synchronized blocks be faster than Atomics? === Suppose two following counter implementations: class Counter { private final AtomicInteger atomic = new AtomicInteger(0); private int i = 0; public void incrementAtomic() { atomic.incrementAndGet(); } public synchronized void increment() { i++; } } At first glance atomics should be faster and more scalable. And they are, I believe. But are they faster than `synchronized` blocks all the time? Or some situations exists when this rule is broken (e.g. SMP/Single CPU machine, different CPU ISA, OS'es etc.)?
0
11,029,162
06/14/2012 08:15:50
916,332
08/28/2011 10:52:24
130
3
PostgreSQL documentation as HTML: download from where?
I got the PDF docs from http://www.postgresql.org/docs/manuals/ but I need HTML. How can I get the same info as HTML? Only thing I could find was http://www.postgresql.org/docs/9.0/static/docguide-build.html but I would need some step-by-step instructions to "make my own", I am afraid... :( Thanks for your help, guys! :)
html
postgresql
documentation
null
null
06/14/2012 09:12:24
not a real question
PostgreSQL documentation as HTML: download from where? === I got the PDF docs from http://www.postgresql.org/docs/manuals/ but I need HTML. How can I get the same info as HTML? Only thing I could find was http://www.postgresql.org/docs/9.0/static/docguide-build.html but I would need some step-by-step instructions to "make my own", I am afraid... :( Thanks for your help, guys! :)
1
9,519,387
03/01/2012 15:54:06
782,104
06/03/2011 02:40:55
63
0
HTML Form element design and implementation
In my case, i would like to let the user select whether some information is publicize, and to what extent is publicize (Read only/ Editable) So , my idea is: First , public with checkbox, if the checkbox is clicked , then is editable for everyone if the checkbox is not clicked, then there will be a url link : named eg. select public to... if that link is clicked , there will be a popup box, every other user is listed and a selectbox (option:Read ,Edit) for each other users. The question are: 1)Is this design appropriate? 2)How to 'send' the result from popup box to the form ? Any help is appreciate . Thank you
php
javascript
html
null
null
null
open
HTML Form element design and implementation === In my case, i would like to let the user select whether some information is publicize, and to what extent is publicize (Read only/ Editable) So , my idea is: First , public with checkbox, if the checkbox is clicked , then is editable for everyone if the checkbox is not clicked, then there will be a url link : named eg. select public to... if that link is clicked , there will be a popup box, every other user is listed and a selectbox (option:Read ,Edit) for each other users. The question are: 1)Is this design appropriate? 2)How to 'send' the result from popup box to the form ? Any help is appreciate . Thank you
0
9,498,831
02/29/2012 12:04:00
1,240,174
02/29/2012 11:58:15
1
0
How to check if an ip-address is reachable in C for linux
I want to build a code which given an ip-address just prints the finalresult reachable or not. I guess we have to use ping command but am not able to correctly implement it.
c
linux
null
null
null
02/29/2012 18:50:50
not a real question
How to check if an ip-address is reachable in C for linux === I want to build a code which given an ip-address just prints the finalresult reachable or not. I guess we have to use ping command but am not able to correctly implement it.
1
4,084,461
11/03/2010 05:36:12
343,299
05/17/2010 17:28:58
8
0
Can't open GetBundles when clicking it in the Bundles menu in TextMate
I can install the GetBundles bundle, but when I click on it (Bundles > GetBundles > GetBundles), nothing happens. I've followed multiple guides, and they all lead me to the same situation. Here's an example of one such guide: <http://solutions.treypiepmeier.com/2009/02/25/installing-getbundles-on-a-fresh-copy-of-textmate/>
textmate
textmatebundles
bundles
null
null
null
open
Can't open GetBundles when clicking it in the Bundles menu in TextMate === I can install the GetBundles bundle, but when I click on it (Bundles > GetBundles > GetBundles), nothing happens. I've followed multiple guides, and they all lead me to the same situation. Here's an example of one such guide: <http://solutions.treypiepmeier.com/2009/02/25/installing-getbundles-on-a-fresh-copy-of-textmate/>
0
5,633,345
04/12/2011 09:51:54
703,800
04/12/2011 09:51:54
1
0
How to merge pdfs(Alive PDF) in flex3?
My flex application generates individual pdf documents based on individual selection criterion,but i need to merge those generated pdfs or is it possible to store individual pdfs temporarily then merge those into single pdf?
flex
null
null
null
null
null
open
How to merge pdfs(Alive PDF) in flex3? === My flex application generates individual pdf documents based on individual selection criterion,but i need to merge those generated pdfs or is it possible to store individual pdfs temporarily then merge those into single pdf?
0
5,429,572
03/25/2011 07:14:05
674,554
03/24/2011 08:36:56
1
1
Installing Android
I am having problems installing Android and I would really appreciate your help. My problem is similar to the thread http://stackoverflow.com/questions/1935659/installing-android-sdk howeve it seems there people believe it is a problem of Eclipse. It actually is not since when I run the Android SDK Manager(independent from Eclipse at all) the program cant find anything on the repository https://dl-ssl.google.com/android/eclipse Can anyone tell me what can I do? have they moved? that URL in a browser says 404 error! Thanks a lot in advance
android
installation
null
null
null
null
open
Installing Android === I am having problems installing Android and I would really appreciate your help. My problem is similar to the thread http://stackoverflow.com/questions/1935659/installing-android-sdk howeve it seems there people believe it is a problem of Eclipse. It actually is not since when I run the Android SDK Manager(independent from Eclipse at all) the program cant find anything on the repository https://dl-ssl.google.com/android/eclipse Can anyone tell me what can I do? have they moved? that URL in a browser says 404 error! Thanks a lot in advance
0
2,123,699
01/23/2010 15:51:51
257,446
01/23/2010 15:51:51
1
0
Where does my C++ compiler look to resolve my #includes?
this is a really basic question. I've been learning C++ and thus far I have only used the standard library. I have been including things like <code>&lt;iostream&gt;</code> and <vector> with no problems. Now I want to use Apache Xerces, so I've installed it on my machine (a Debian system) and am following a tutorial which says I need to include: #include <xercesc/sax2/SAX2XMLReader.hpp> but g++ says "error: xercesc/sax2/SAX2XMLReader.hpp: No such file or directory". Where is it looking? Do I need to give it more information? Thanks.
c++
null
null
null
null
null
open
Where does my C++ compiler look to resolve my #includes? === this is a really basic question. I've been learning C++ and thus far I have only used the standard library. I have been including things like <code>&lt;iostream&gt;</code> and <vector> with no problems. Now I want to use Apache Xerces, so I've installed it on my machine (a Debian system) and am following a tutorial which says I need to include: #include <xercesc/sax2/SAX2XMLReader.hpp> but g++ says "error: xercesc/sax2/SAX2XMLReader.hpp: No such file or directory". Where is it looking? Do I need to give it more information? Thanks.
0
5,576,676
04/07/2011 06:00:36
696,175
04/07/2011 06:00:36
1
0
What is adobe connect?
Please describe the feature of adobe connect?
adobe
connect
null
null
null
04/07/2011 06:43:33
off topic
What is adobe connect? === Please describe the feature of adobe connect?
2
11,502,378
07/16/2012 10:21:51
1,528,571
07/16/2012 10:14:14
1
0
How to parse information on website section for registered users only using php
I'v tried to change my headers using header() function both like curl_setopt() but my headers did not change. Is there any addition actions need to change my headers? If the section of website which I want to parse is only for registered users, they can keep cookies with auth-data. Do I need additional header information got from auth-cookie?
php
parsing
header
null
null
null
open
How to parse information on website section for registered users only using php === I'v tried to change my headers using header() function both like curl_setopt() but my headers did not change. Is there any addition actions need to change my headers? If the section of website which I want to parse is only for registered users, they can keep cookies with auth-data. Do I need additional header information got from auth-cookie?
0
3,295,889
07/21/2010 02:33:02
92,679
04/19/2009 05:23:14
269
14
How do I store keys for API's in Rails?
I have several api's that I am integrating with and need to call in various parts of my application. What is the way to store the keys, the user/password, or token information, say, a configuration file and then how do I call them for use in other parts of the application? Thanks.
ruby-on-rails
null
null
null
null
null
open
How do I store keys for API's in Rails? === I have several api's that I am integrating with and need to call in various parts of my application. What is the way to store the keys, the user/password, or token information, say, a configuration file and then how do I call them for use in other parts of the application? Thanks.
0
11,117,265
06/20/2012 10:09:01
1,468,791
06/20/2012 09:45:22
1
0
Opening / Using / Editing word docs or Excel sheets in a web browser
Good Day, i am fairly new to using forums, so help would be appreciated. I need to open word and excel type documents with a webrowser and save them through different versions For example like a school homework system. Version 1: Teacher will send a excel sheet full of math problems to complete. Version 2: Pupil will add his/her answers Version 3: Teacher needs an easy to use "marking tool" Any help with what suggested editors and marking tools are available?? Thanks in advance
asp.net
null
null
null
null
06/21/2012 13:47:10
not a real question
Opening / Using / Editing word docs or Excel sheets in a web browser === Good Day, i am fairly new to using forums, so help would be appreciated. I need to open word and excel type documents with a webrowser and save them through different versions For example like a school homework system. Version 1: Teacher will send a excel sheet full of math problems to complete. Version 2: Pupil will add his/her answers Version 3: Teacher needs an easy to use "marking tool" Any help with what suggested editors and marking tools are available?? Thanks in advance
1
1,588,200
10/19/2009 11:36:58
123,663
06/16/2009 12:26:25
73
1
ColdFusion MX career help.
I have been looking recently at ColdFusion MX , My simple little question is: I am a junior web developer , I know XHTML , CSS , MySQL and PHP to a reasonably good level. If i was too a learn ColdFusion MX and If I wanted to move into a Cold Fusion MX developer role in the future would this be a good job over being a PHP or ASP Developer. Basically is a ColdFusion MX developer in much demand ?
coldfusion
null
null
null
null
02/06/2012 01:13:22
off topic
ColdFusion MX career help. === I have been looking recently at ColdFusion MX , My simple little question is: I am a junior web developer , I know XHTML , CSS , MySQL and PHP to a reasonably good level. If i was too a learn ColdFusion MX and If I wanted to move into a Cold Fusion MX developer role in the future would this be a good job over being a PHP or ASP Developer. Basically is a ColdFusion MX developer in much demand ?
2
2,378,047
03/04/2010 09:21:22
162,569
08/25/2009 09:15:43
111
3
Correctly disposing user controls and child controls in C#
we are experiencing a few problems with the IDisposable pattern. In this case there is a user control 'ControlA' with a FlowLayoutPanel, which contains more usercontrols 'ControlB'. When calling Dispose(bool), I check if disposing if true, and if IsDisposed is false. I then try to explicitly dispose each ControlB in the FlowLayoutPanel's Controls collection. However, if does not loop through all controls, only 3 of 8, or 2 of 4. Dispose(bool disposing) { if (disposing) { if (!IsDisposed) { //unhook events etc. foreach(ControlB ctrl in flowlayoutpanel.Controls) //<-- there 8 controls ctrl.Dispose(); //<-- called 3 times only flp.Controls.Clear(); } } //make all members null } My quesitons are: 1. Why is this happening? 2. What are best practices and expereinces you guys had with disposing user controls and thei child controls? E.g. do you unsubscribe event handlers at all times, etc. Thanks!
.net-2.0
dispose
patterns
usercontrols
null
null
open
Correctly disposing user controls and child controls in C# === we are experiencing a few problems with the IDisposable pattern. In this case there is a user control 'ControlA' with a FlowLayoutPanel, which contains more usercontrols 'ControlB'. When calling Dispose(bool), I check if disposing if true, and if IsDisposed is false. I then try to explicitly dispose each ControlB in the FlowLayoutPanel's Controls collection. However, if does not loop through all controls, only 3 of 8, or 2 of 4. Dispose(bool disposing) { if (disposing) { if (!IsDisposed) { //unhook events etc. foreach(ControlB ctrl in flowlayoutpanel.Controls) //<-- there 8 controls ctrl.Dispose(); //<-- called 3 times only flp.Controls.Clear(); } } //make all members null } My quesitons are: 1. Why is this happening? 2. What are best practices and expereinces you guys had with disposing user controls and thei child controls? E.g. do you unsubscribe event handlers at all times, etc. Thanks!
0
4,702,007
01/15/2011 20:39:22
106,615
05/13/2009 20:13:18
802
9
experiences trying different programming paradigms
What programming paradigms did you try? How was it?
programming-languages
null
null
null
null
01/15/2011 20:51:21
not constructive
experiences trying different programming paradigms === What programming paradigms did you try? How was it?
4
10,294,578
04/24/2012 08:46:15
1,353,183
04/24/2012 08:27:56
1
0
jQuery validation custom rule
I made a custom rule for the jQuery validation plugin and I want it to be applied to a field that is not required. So, when I enter something in the field it should be checked but if it's empty it shouldn't be checked by the custom rule. If I don't set required to true and check this.optional(element) i get dependency-mismatch. Is there a way to do this?
jquery
validation
null
null
null
04/25/2012 11:15:01
not a real question
jQuery validation custom rule === I made a custom rule for the jQuery validation plugin and I want it to be applied to a field that is not required. So, when I enter something in the field it should be checked but if it's empty it shouldn't be checked by the custom rule. If I don't set required to true and check this.optional(element) i get dependency-mismatch. Is there a way to do this?
1
4,801,774
01/26/2011 05:57:32
385,680
07/07/2010 15:21:31
44
2
Ways to improve foll. Java code
Any ways to improve the foll. code block : <code> public class MyUnits { public static String MILLSECONDS = "milliseconds"; public static String SECONDS = "seconds"; public static String MINUTES = "minutes"; public static String HOURS = "hours"; public int quantity; public String units; public MyUnits(int quantity, String units) { this.quantity = quantity; this.units = units; } public String toString() { return (quantity + " " + units); } // Test code public static void main(String[] args) { System.out.println(new MyUnits(1, MyUnits.MILLSECONDS)); System.out.println(new MyUnits(2, MyUnits.SECONDS)); System.out.println(new MyUnits(3, MyUnits.MINUTES)); System.out.println(new MyUnits(4, MyUnits.HOURS)); } } </code> Any help will be appreciated.
java
null
null
null
null
01/26/2011 06:11:57
not a real question
Ways to improve foll. Java code === Any ways to improve the foll. code block : <code> public class MyUnits { public static String MILLSECONDS = "milliseconds"; public static String SECONDS = "seconds"; public static String MINUTES = "minutes"; public static String HOURS = "hours"; public int quantity; public String units; public MyUnits(int quantity, String units) { this.quantity = quantity; this.units = units; } public String toString() { return (quantity + " " + units); } // Test code public static void main(String[] args) { System.out.println(new MyUnits(1, MyUnits.MILLSECONDS)); System.out.println(new MyUnits(2, MyUnits.SECONDS)); System.out.println(new MyUnits(3, MyUnits.MINUTES)); System.out.println(new MyUnits(4, MyUnits.HOURS)); } } </code> Any help will be appreciated.
1
3,703,242
09/13/2010 18:22:09
390,622
07/13/2010 15:36:19
8
1
SplitView Controller Menu Overlay
I'm trying to create a menu overlay system on top of a split view application for the iPad. The menu overlay systems is suppose to support a few buttons, one of which will make the overlay disappear and show the SplitViewController. My application delegate is as follows: UIView *view = [[UIView alloc] init]; [view addSubview:[splitViewController view]]; [view addSubview:[mainMenu view]]; [window addSubview:view]; [window makeKeyAndVisible]; The UIViews are showing up, but in a very weird scattered manner with many interface features not responding. Any help? Thanks, CSwat
objective-c
xcode
uiview
uisplitviewcontroller
uiwindow
null
open
SplitView Controller Menu Overlay === I'm trying to create a menu overlay system on top of a split view application for the iPad. The menu overlay systems is suppose to support a few buttons, one of which will make the overlay disappear and show the SplitViewController. My application delegate is as follows: UIView *view = [[UIView alloc] init]; [view addSubview:[splitViewController view]]; [view addSubview:[mainMenu view]]; [window addSubview:view]; [window makeKeyAndVisible]; The UIViews are showing up, but in a very weird scattered manner with many interface features not responding. Any help? Thanks, CSwat
0
6,924,110
08/03/2011 09:12:01
749,906
05/12/2011 04:59:52
30
0
facebook like contacts autosuggestion ox jquery
I am looking for a jquery autosuggest plugin for my php website. I am looking for somewhat similar to the facebook which loads contacts as and when we type "@" Do you have any suggestions for that?
jquery
jquery-plugins
autosuggest
null
null
null
open
facebook like contacts autosuggestion ox jquery === I am looking for a jquery autosuggest plugin for my php website. I am looking for somewhat similar to the facebook which loads contacts as and when we type "@" Do you have any suggestions for that?
0
6,092,317
05/23/2011 02:35:03
765,298
05/23/2011 01:17:55
1
0
Using ncurses menu.h on Solaris 5.9 / C
I have a problem with using curses menu.h on Solaris 5.9 - this code generates a segfault : item_sub = (ITEM**)calloc(5, sizeof(ITEM*)); item_sub[0] = new_item("[DODAJ]", ""); item_sub[1] = new_item("[ZAPISZ]", ""); item_sub[2] = new_item("[OTWORZ]", ""); item_sub[3] = new_item("[SZUKAJ]", ""); item_sub[4] = NULL; menu_subK = new_menu((ITEM**)item_sub); set_menu_format(menu_subK, 1, 4); set_menu_win(menu_subK, wKontakt); set_menu_sub(menu_subK, derwin(wKontakt, 1, 39, LINES - 4, 1)); set_menu_mark(menu_subK, ""); menu_opts_off(menu_subK, O_NONCYCLIC); menu_opts_off(menu_subK, O_SHOWDESC); post_menu(menu_subK); The error happens on `post_menu(menu_subK);` Whole code is after `initscr();` and my compile command looks like that : `gcc -pedantic organizerC.c kontaktyC.c wydarzeniaC.c dodatkiC.c -lmenu -lform -lncurses -o organizerC` The error occurs also when I compile with `-lcurses`. Everything works on my Ubuntu 10, but unfortunately it has to work on aforementioned Solaris 5.9, as this is a requirement for all my class projects. I've tried google'ing about it but didn't get anywhere. I've checked contents of menu.h and it has `#include <curses.h>` but as I understood from my findings this should link to ncurses.h, right? I've also tried adding explicitly `#include <ncurses.h>`, `#include <ncurses/ncurses.h>` and other variations with `curses.h` with no luck... Are there Solaris-specific functions I need to use? Or should I change my compile command? Any help and/or directions of research is appreciated.
c
solaris
ncurses
null
null
null
open
Using ncurses menu.h on Solaris 5.9 / C === I have a problem with using curses menu.h on Solaris 5.9 - this code generates a segfault : item_sub = (ITEM**)calloc(5, sizeof(ITEM*)); item_sub[0] = new_item("[DODAJ]", ""); item_sub[1] = new_item("[ZAPISZ]", ""); item_sub[2] = new_item("[OTWORZ]", ""); item_sub[3] = new_item("[SZUKAJ]", ""); item_sub[4] = NULL; menu_subK = new_menu((ITEM**)item_sub); set_menu_format(menu_subK, 1, 4); set_menu_win(menu_subK, wKontakt); set_menu_sub(menu_subK, derwin(wKontakt, 1, 39, LINES - 4, 1)); set_menu_mark(menu_subK, ""); menu_opts_off(menu_subK, O_NONCYCLIC); menu_opts_off(menu_subK, O_SHOWDESC); post_menu(menu_subK); The error happens on `post_menu(menu_subK);` Whole code is after `initscr();` and my compile command looks like that : `gcc -pedantic organizerC.c kontaktyC.c wydarzeniaC.c dodatkiC.c -lmenu -lform -lncurses -o organizerC` The error occurs also when I compile with `-lcurses`. Everything works on my Ubuntu 10, but unfortunately it has to work on aforementioned Solaris 5.9, as this is a requirement for all my class projects. I've tried google'ing about it but didn't get anywhere. I've checked contents of menu.h and it has `#include <curses.h>` but as I understood from my findings this should link to ncurses.h, right? I've also tried adding explicitly `#include <ncurses.h>`, `#include <ncurses/ncurses.h>` and other variations with `curses.h` with no luck... Are there Solaris-specific functions I need to use? Or should I change my compile command? Any help and/or directions of research is appreciated.
0
11,287,369
07/02/2012 03:02:31
1,495,015
07/02/2012 02:42:33
1
0
Basic Python and Java Questions
I've just finished the text "Starting out with Python" and "Starting out with Java" and I was wondering if an experience Python and Java user could suggest further reading for more intermediate to advanced material. Secondly, I some questions about some code I've been looking at. 1. What does the @staticmethod and @property mean when it is written above a method definition in Python like the following? @staticmethod def methodName(parameter): Class_Name.CONSTANT_VARIABLE = parameter @property def methodName(parameter): Class_Name.CONSTANT_VARIABLE = parameter 2. Another question is in a method definition why would someone set the formal parameter "amount" equal to the constant PERMANENCE_INC in the formal parameter list? def increasePermanence(self, amount=PERMANENCE_INC): """ Increases the permanence of this synapse. """ self.permanence = min(1.0, self.permanence+amount) 3. Lastly, and probably the most stupid question is that I'm not really understand what the "self" parameter is in Python in the __init__ method. The previous texts I've been reading seem to just skip over it. Is "self" like the only possible object that can be created by the class or what? Sorry, for all the questions. I'm aspiring to become great at programming so any information/advice would help. THANKS!
java
python
methods
self
null
07/02/2012 06:21:54
not a real question
Basic Python and Java Questions === I've just finished the text "Starting out with Python" and "Starting out with Java" and I was wondering if an experience Python and Java user could suggest further reading for more intermediate to advanced material. Secondly, I some questions about some code I've been looking at. 1. What does the @staticmethod and @property mean when it is written above a method definition in Python like the following? @staticmethod def methodName(parameter): Class_Name.CONSTANT_VARIABLE = parameter @property def methodName(parameter): Class_Name.CONSTANT_VARIABLE = parameter 2. Another question is in a method definition why would someone set the formal parameter "amount" equal to the constant PERMANENCE_INC in the formal parameter list? def increasePermanence(self, amount=PERMANENCE_INC): """ Increases the permanence of this synapse. """ self.permanence = min(1.0, self.permanence+amount) 3. Lastly, and probably the most stupid question is that I'm not really understand what the "self" parameter is in Python in the __init__ method. The previous texts I've been reading seem to just skip over it. Is "self" like the only possible object that can be created by the class or what? Sorry, for all the questions. I'm aspiring to become great at programming so any information/advice would help. THANKS!
1
11,732,060
07/31/2012 01:50:47
1,508,213
07/07/2012 03:41:56
26
0
Perl Binary/PCAP regex
I have a pcap file for which I need to match on the string of "@^@GET /test/test.jpg" If I try to do a perl string regex it doesn't see the non-printable characters of @^@ and will not match. If I try using the hex version of \x5E to match the @ that is a no go as well. How can I conduct a regex match on a binary/pcap file to match against non-printable characters such as @^@ ? Thank you
regex
perl
binary
null
null
null
open
Perl Binary/PCAP regex === I have a pcap file for which I need to match on the string of "@^@GET /test/test.jpg" If I try to do a perl string regex it doesn't see the non-printable characters of @^@ and will not match. If I try using the hex version of \x5E to match the @ that is a no go as well. How can I conduct a regex match on a binary/pcap file to match against non-printable characters such as @^@ ? Thank you
0
5,479,001
03/29/2011 21:13:22
545,132
12/16/2010 17:55:49
263
11
Does this code do anything useful?
I was just wondering does this code do anything? int *n; while (n!=0) { n = &n; }
c++
c
null
null
null
03/29/2011 21:33:41
not a real question
Does this code do anything useful? === I was just wondering does this code do anything? int *n; while (n!=0) { n = &n; }
1
7,770,313
10/14/2011 15:58:51
283,598
03/01/2010 12:34:22
16
1
Unity3d app hides facebook dialog
I'm deploying a unity3d webplayer, and the new right panel (Ticker) in Facebook can prompt dialog in Like, and Recommend etc. However, those dialog gets cut off and hidden by the unity app. This seems like a known issue since early days, is there a good solution.
facebook
iframe
unity3d
null
null
null
open
Unity3d app hides facebook dialog === I'm deploying a unity3d webplayer, and the new right panel (Ticker) in Facebook can prompt dialog in Like, and Recommend etc. However, those dialog gets cut off and hidden by the unity app. This seems like a known issue since early days, is there a good solution.
0
6,190,656
05/31/2011 16:31:33
778,027
05/31/2011 16:31:33
1
0
For Spring MVC backend, what are the top 10 UI frameworks available?
My backend is fixed. Java Spring MVC. I would like to know what are the UI frameworks used by fellow developers with great success for ajax type webapplication I am familiar with only these two 1. JSP + HTML + JavaScript 2. GXT
java
ajax
web-applications
null
null
05/31/2011 17:04:32
off topic
For Spring MVC backend, what are the top 10 UI frameworks available? === My backend is fixed. Java Spring MVC. I would like to know what are the UI frameworks used by fellow developers with great success for ajax type webapplication I am familiar with only these two 1. JSP + HTML + JavaScript 2. GXT
2
3,901,619
10/10/2010 18:35:18
438,943
09/03/2010 12:24:07
44
1
How to comment lines in rails html.erb files ?
Am a newbie to rails , please let me know the way to comment out a single line and also to comment out a block of lines in *.html.erb files.
ruby-on-rails
ruby-on-rails-3
null
null
null
null
open
How to comment lines in rails html.erb files ? === Am a newbie to rails , please let me know the way to comment out a single line and also to comment out a block of lines in *.html.erb files.
0
5,697,754
04/18/2011 01:43:10
807,325
02/21/2011 17:08:44
235
1
What programming technologies does this web site use?
I am trying to learn some things from AJAX and jQuery, i believe that it is a basic knowledge a programmer must have. I am a self instructed so I am reading tutorials and examples to get in touch with these technologies as good as I can. I saw this page [www.soby.gr][1] that I guess uses a XML feed for the main content ( is a groupon like aggregator ). My question is what did they use for their menu on the left of the page. When you click/select an option, the content on main page changes based on the criteria the user clicked on. For example SPA will show only the deals having SPA. What I like is how fast the content is filtered. Can anyone give me some clues about how it is working and what technology is used for that fast content-changing? Thank you all. [1]: http://www.soby.gr
php
javascript
jquery
ajax
null
04/19/2011 01:53:52
not a real question
What programming technologies does this web site use? === I am trying to learn some things from AJAX and jQuery, i believe that it is a basic knowledge a programmer must have. I am a self instructed so I am reading tutorials and examples to get in touch with these technologies as good as I can. I saw this page [www.soby.gr][1] that I guess uses a XML feed for the main content ( is a groupon like aggregator ). My question is what did they use for their menu on the left of the page. When you click/select an option, the content on main page changes based on the criteria the user clicked on. For example SPA will show only the deals having SPA. What I like is how fast the content is filtered. Can anyone give me some clues about how it is working and what technology is used for that fast content-changing? Thank you all. [1]: http://www.soby.gr
1
2,540,433
03/29/2010 18:50:11
304,490
03/29/2010 18:43:14
1
0
Sql Server xml column with Entity Framework - how to keep insignificant whitespaces
Sql server 2005 (even 2008) strips the insignificant whitespaces by default. To keep one can use the CONVERT funtction with the last argument as '1' ([Ref. Article][1]). How can we do the same thing in Entity Framework? thanks [1]: http://blogs.msdn.com/denisruc/archive/2005/09/12/464145.aspx
xml
entity-framework
sql
sql-server-2008
null
null
open
Sql Server xml column with Entity Framework - how to keep insignificant whitespaces === Sql server 2005 (even 2008) strips the insignificant whitespaces by default. To keep one can use the CONVERT funtction with the last argument as '1' ([Ref. Article][1]). How can we do the same thing in Entity Framework? thanks [1]: http://blogs.msdn.com/denisruc/archive/2005/09/12/464145.aspx
0
5,671,853
04/15/2011 02:41:47
709,070
04/15/2011 02:41:47
1
0
javascript to jquery conversion
Is there a way to convert this javascript code to jquery? <script type="text/javascript" src="http://www.resursecrestine.ro/web-api-versetul-zilei"></script> joomla 1.6 doesn't take javascript
javascript
null
null
null
null
04/15/2011 03:05:00
not a real question
javascript to jquery conversion === Is there a way to convert this javascript code to jquery? <script type="text/javascript" src="http://www.resursecrestine.ro/web-api-versetul-zilei"></script> joomla 1.6 doesn't take javascript
1
11,297,459
07/02/2012 16:18:41
1,489,246
06/28/2012 16:39:13
1
0
php query display in multi columns of table
I need help to display php query in multi columns of one table, i have 16 records i want 4 display in 1st column other 4 in second and same in third and four thanks
php
mysql
html
null
null
07/02/2012 18:22:30
not a real question
php query display in multi columns of table === I need help to display php query in multi columns of one table, i have 16 records i want 4 display in 1st column other 4 in second and same in third and four thanks
1
4,651,732
01/10/2011 21:32:50
3,635
08/29/2008 16:13:11
425
21
Is an API available to query Deep links for Windows Phone 7 apps in the marketplace?
I have seen couple of Web sites that list Windows Phone 7 apps from the marketplace with deep links. Is an API available for the Windows Phone 7 Marketplace that allows me to query and maybe create a better Marketplace? Thanks in Advance
windows-phone-7
null
null
null
null
null
open
Is an API available to query Deep links for Windows Phone 7 apps in the marketplace? === I have seen couple of Web sites that list Windows Phone 7 apps from the marketplace with deep links. Is an API available for the Windows Phone 7 Marketplace that allows me to query and maybe create a better Marketplace? Thanks in Advance
0
9,572,741
03/05/2012 19:33:39
1,071,895
02/23/2011 09:09:40
1
0
java.security.AccessControlException: access denied on a signed applet
The error: java.security.AccessControlException: access denied (java.security.SecurityPermission authProvider.SunPKCS11-OpenSC-ProviderName) The applet which is used is signed. The provider is already installed. security.provider.9=sun.security.pkcs11.SunPKCS11 with /lib_path The applet code works with tomcat without any problem but when I have used this code in an applet to work in a html webpage I getting the security problems. Temporaly I have changed the policy file. Granting permissions to the directory where the applet is stored, the applet wich works with the html page. grant codeBase "file:/path/to/the/jarfile/*" { permission java.security.AllPermission; }; I have granted the PrivateKeyEntry alias which is used to sign the .jar file grant signedBy "mykey" { permission java.security.AllPermission; }; Anyway I'm getting the same exception Any suggestion?
java
security
applet
signed
accesscontrolexception
null
open
java.security.AccessControlException: access denied on a signed applet === The error: java.security.AccessControlException: access denied (java.security.SecurityPermission authProvider.SunPKCS11-OpenSC-ProviderName) The applet which is used is signed. The provider is already installed. security.provider.9=sun.security.pkcs11.SunPKCS11 with /lib_path The applet code works with tomcat without any problem but when I have used this code in an applet to work in a html webpage I getting the security problems. Temporaly I have changed the policy file. Granting permissions to the directory where the applet is stored, the applet wich works with the html page. grant codeBase "file:/path/to/the/jarfile/*" { permission java.security.AllPermission; }; I have granted the PrivateKeyEntry alias which is used to sign the .jar file grant signedBy "mykey" { permission java.security.AllPermission; }; Anyway I'm getting the same exception Any suggestion?
0
9,679,375
03/13/2012 06:35:57
969,188
09/28/2011 13:32:39
10
0
Run an exe from c sharp code
I have an exe file reference to a c sharp project.. I want to know the way to invoke tht exe from my code.
c#
.net
null
null
null
03/13/2012 07:08:04
not a real question
Run an exe from c sharp code === I have an exe file reference to a c sharp project.. I want to know the way to invoke tht exe from my code.
1
4,288,724
11/26/2010 21:46:47
51,816
01/05/2009 21:39:06
5,525
20
How to change the current line color in Visual Studio 2010?
Maybe it's trivial but I couldn't find an answer to it for several weeks. It's set to some light gray color which is very bothersome in a dark color theme. Any ideas how I can change this? Or even disable it if there is no way to change it.
c#
.net
visual-studio
null
null
null
open
How to change the current line color in Visual Studio 2010? === Maybe it's trivial but I couldn't find an answer to it for several weeks. It's set to some light gray color which is very bothersome in a dark color theme. Any ideas how I can change this? Or even disable it if there is no way to change it.
0
8,052,499
11/08/2011 15:04:58
1,088,313
01/19/2011 04:08:55
156
0
Setting a variable
Well I have a few questions and I like to make sure I am understanding what I am doing. So here it is I am working on a project and I am suppose to Create a variable called MinOrder and populate it with the smallest line item amount after discount for the Northwind CustomerNo ‘ALFKI’ (Careful: we’re dealing with currency here, so don’t just assume you’re going to use an int.) Output the final value of MinOrder. Now this is what I have: Use Northwind Declare @MinOrder money; Set @MinOrder = (Select MIN(UnitPrice) From [Order Details]); Select @MinOrder I notice that I didn't put in the ALFKI. Well I seen it said not use really use the int. I went and declare the minorder because it does with a variable and then I am taking that variable using it for the unitprice even though it says discount but when I try to put discount there it showed a red error. I am wounder if I should use another set to do the customerId = ALFKI or if I can throw it into this code. I know my code might be way off but thats why I am posting it so I can have an understanding when it comes to this only because it is a part of programming. Thanks
sql
homework
null
null
null
null
open
Setting a variable === Well I have a few questions and I like to make sure I am understanding what I am doing. So here it is I am working on a project and I am suppose to Create a variable called MinOrder and populate it with the smallest line item amount after discount for the Northwind CustomerNo ‘ALFKI’ (Careful: we’re dealing with currency here, so don’t just assume you’re going to use an int.) Output the final value of MinOrder. Now this is what I have: Use Northwind Declare @MinOrder money; Set @MinOrder = (Select MIN(UnitPrice) From [Order Details]); Select @MinOrder I notice that I didn't put in the ALFKI. Well I seen it said not use really use the int. I went and declare the minorder because it does with a variable and then I am taking that variable using it for the unitprice even though it says discount but when I try to put discount there it showed a red error. I am wounder if I should use another set to do the customerId = ALFKI or if I can throw it into this code. I know my code might be way off but thats why I am posting it so I can have an understanding when it comes to this only because it is a part of programming. Thanks
0
5,801,602
04/27/2011 09:00:10
726,869
04/27/2011 09:00:10
1
0
my proj is based on WSN.. its in MATLAB
i hav created a network.. i hav to calculate energy of all the nodes n this energy should get reduced as n when the node senses ..... plszz help me out in the energy part...
matlab
null
null
null
null
04/27/2011 12:21:09
not a real question
my proj is based on WSN.. its in MATLAB === i hav created a network.. i hav to calculate energy of all the nodes n this energy should get reduced as n when the node senses ..... plszz help me out in the energy part...
1
3,643,010
09/04/2010 16:08:47
357,743
06/03/2010 17:04:30
1
0
Get window position relative to the workspace it's placed on in PyGtk
I'm trying to improve minimize to tray feature of some application and I want to show window on tray icon click if it was minimized to tray or placed not on the current workspace. I encountered the problem that occurs when I try to show (un-minimize) the app's window that's visible on the workspace (let's say 'workspace 1') other than the current one ('workspace 2'). The problem is that staying on the workspace to the left of the current one the app's window has negative x coordinate, because window position is counted relative to current workspace. I'd like to get window's position relative to the workspace 1 (not current one) and show it at this point on workspace 2 (the current one). I'm doing smth like that right now to show window on the current workspace at the position same to the position it was on the previous workspace: # get desktop size ws_width, ws_height = gtk.gdk.get_default_root_window().get_size() # get position relative to current workspace x, y = window.get_position() # get position relative to the workspace the window is on x %= ws_width y %= ws_height window.move(x, y) window.show() but I don't like this workaround and not sure that this code wouldn't break smth on the desktops other than gnome. So I'll be grateful for any other solution of the problem as well as information about the situation on other linux desktops (e.g., do they count window position relative to the current workspace as gnome or not).
gtk
position
workspace
null
null
null
open
Get window position relative to the workspace it's placed on in PyGtk === I'm trying to improve minimize to tray feature of some application and I want to show window on tray icon click if it was minimized to tray or placed not on the current workspace. I encountered the problem that occurs when I try to show (un-minimize) the app's window that's visible on the workspace (let's say 'workspace 1') other than the current one ('workspace 2'). The problem is that staying on the workspace to the left of the current one the app's window has negative x coordinate, because window position is counted relative to current workspace. I'd like to get window's position relative to the workspace 1 (not current one) and show it at this point on workspace 2 (the current one). I'm doing smth like that right now to show window on the current workspace at the position same to the position it was on the previous workspace: # get desktop size ws_width, ws_height = gtk.gdk.get_default_root_window().get_size() # get position relative to current workspace x, y = window.get_position() # get position relative to the workspace the window is on x %= ws_width y %= ws_height window.move(x, y) window.show() but I don't like this workaround and not sure that this code wouldn't break smth on the desktops other than gnome. So I'll be grateful for any other solution of the problem as well as information about the situation on other linux desktops (e.g., do they count window position relative to the current workspace as gnome or not).
0
5,291,370
03/13/2011 18:14:55
53,261
01/09/2009 09:28:51
481
28
Which language to learn C++ or Python?
I am C# developer and I want to learn (new) second language. I have searched and read some articles on internet but I can't made up my mind between C++ and Python. I want to know, what benefit I will get from each of these languages in both technical and professional term. Thanks
c++
python
programming-languages
null
null
03/13/2011 18:26:10
not constructive
Which language to learn C++ or Python? === I am C# developer and I want to learn (new) second language. I have searched and read some articles on internet but I can't made up my mind between C++ and Python. I want to know, what benefit I will get from each of these languages in both technical and professional term. Thanks
4
10,799,718
05/29/2012 13:00:43
1,413,238
05/23/2012 17:18:05
1
0
Crop image off screen to use with turnjs
I'm developing a book view with http://www.turnjs.com/. Every page contains a single image. The image shows a photographed page of a real book. Unfortunately all the images have a transparent margin, which leads to wrong shadowing. How can I crop an image to place it in the book? Thanks!
javascript
jquery
css
null
null
null
open
Crop image off screen to use with turnjs === I'm developing a book view with http://www.turnjs.com/. Every page contains a single image. The image shows a photographed page of a real book. Unfortunately all the images have a transparent margin, which leads to wrong shadowing. How can I crop an image to place it in the book? Thanks!
0
4,884,676
02/03/2011 10:01:37
558,243
12/30/2010 12:03:40
330
33
Accessing parent DOM/function from within an Iframe embedded in Windows 7 gadget
I have the following issue, Im creating a windows 7 gadget, which uses Iframe to load content.I have full control on the contents of the Iframe, what I want to do is, call a function in the parent (windows 7 gadget html document), from within this Iframe, or even trigger a flyout from within the Iframe, when there is hover on a link or something. Any help is greatly appreciated. Thanks ![enter image description here][1] [1]: http://i.stack.imgur.com/gtxGl.png
javascript
jquery
iframe
parent
windows-desktop-gadgets
null
open
Accessing parent DOM/function from within an Iframe embedded in Windows 7 gadget === I have the following issue, Im creating a windows 7 gadget, which uses Iframe to load content.I have full control on the contents of the Iframe, what I want to do is, call a function in the parent (windows 7 gadget html document), from within this Iframe, or even trigger a flyout from within the Iframe, when there is hover on a link or something. Any help is greatly appreciated. Thanks ![enter image description here][1] [1]: http://i.stack.imgur.com/gtxGl.png
0
7,288,386
09/02/2011 19:30:55
925,894
09/02/2011 19:30:55
1
0
Why is there a segmentation fault 11?
Why is there a segmentation fault 11! #include <iostream> #include <fstream> using namespace std; string printMenu(); float processOrder(int inventory[],int prices[], int userChoice); int main() { int prices[14] = {1.50, 1.25, 2.25, 2.25, 2.50, 2.75, 2.75, 2.50, 1.00, 1.25, 1.25, 0.75, 1.00, 0.75}; int inventory[14]; for(int i = 0; i < 14; i++) inventory[i] = 5; cout <<printMenu()<<endl; int userChoice; float total = 0; do { cout <<"Enter the number next to the item that you would like to order"<<endl<< "enter -1 to see your total price."<<endl; cin >> userChoice; total += processOrder(inventory, prices, userChoice); }while(userChoice != 5); if(userChoice == -1) cout << "Your total is "<<total<<endl; return 0; } string printMenu() { string number; fstream file; file.open("menu.txt"); while(!file.eof()) { getline(file, number); cout<< number<<endl; } file.close(); } float processOrder(int inventory[], int prices[], int userChoice) { int numUnits = inventory[userChoice - 1] = 5; float price = prices[userChoice - 1]; cout << price; if(numUnits > 0) { inventory[userChoice - 1]--; return price; } else return price * 0; }
c++
null
null
null
null
09/02/2011 21:13:52
not a real question
Why is there a segmentation fault 11? === Why is there a segmentation fault 11! #include <iostream> #include <fstream> using namespace std; string printMenu(); float processOrder(int inventory[],int prices[], int userChoice); int main() { int prices[14] = {1.50, 1.25, 2.25, 2.25, 2.50, 2.75, 2.75, 2.50, 1.00, 1.25, 1.25, 0.75, 1.00, 0.75}; int inventory[14]; for(int i = 0; i < 14; i++) inventory[i] = 5; cout <<printMenu()<<endl; int userChoice; float total = 0; do { cout <<"Enter the number next to the item that you would like to order"<<endl<< "enter -1 to see your total price."<<endl; cin >> userChoice; total += processOrder(inventory, prices, userChoice); }while(userChoice != 5); if(userChoice == -1) cout << "Your total is "<<total<<endl; return 0; } string printMenu() { string number; fstream file; file.open("menu.txt"); while(!file.eof()) { getline(file, number); cout<< number<<endl; } file.close(); } float processOrder(int inventory[], int prices[], int userChoice) { int numUnits = inventory[userChoice - 1] = 5; float price = prices[userChoice - 1]; cout << price; if(numUnits > 0) { inventory[userChoice - 1]--; return price; } else return price * 0; }
1
5,389,195
03/22/2011 09:35:55
289,558
03/09/2010 10:36:30
35
2
How to create a calculator in PHP?
Please state the front-end HTML code as well the back-end PHP scripting code for it to function.
php
null
null
null
null
03/22/2011 09:42:40
not a real question
How to create a calculator in PHP? === Please state the front-end HTML code as well the back-end PHP scripting code for it to function.
1
10,456,220
05/04/2012 21:14:00
753,330
05/14/2011 05:31:56
3
0
How to convert String (0 to 255 only) into Binary [8 bits] using any built-in c++ function
Please illustrate me this program using a small example like converting, say 5 into 8 bits binary using built-in c++ funtion.
c++
null
null
null
null
05/16/2012 12:34:14
not a real question
How to convert String (0 to 255 only) into Binary [8 bits] using any built-in c++ function === Please illustrate me this program using a small example like converting, say 5 into 8 bits binary using built-in c++ funtion.
1
8,543,788
12/17/2011 09:21:19
1,043,339
11/12/2011 16:52:22
91
0
How can obtain age by birth date
I want get the exact age of the following date in var `$birth_date` by php, How is it? `$birth_date = 2011/12/16;` $birth_date => For example, this is my birth date.
php
php5
null
null
null
12/17/2011 11:34:08
not a real question
How can obtain age by birth date === I want get the exact age of the following date in var `$birth_date` by php, How is it? `$birth_date = 2011/12/16;` $birth_date => For example, this is my birth date.
1
7,794,834
10/17/2011 13:55:45
438,563
09/03/2010 02:23:38
341
22
Apt-get documentation and cows. Whats is this all about?
I was installing things in my new Ubuntu (11.10) using the terminal with `apt-get` command. In the middle of my tasks I took a look at apt-get documentation to see what `-y` means: $ sudo apt-get --help And after the parameters documentation there was a very enigmatic message: > apt-get has Super Cow Power I asked a friend about it and he couldn't tell me why it's there. He laughed and told me to execute this other command: $ sudo apt-get moo It produced the following output (ASCII art of a cow): (__) (oo) /------\/ / | || * /\---/\ ~~ ~~ ...."Have you mooed today?"... Now I ask you, whata hell is all this **Cow** thing in `apt-get` commands? Just for curiosity.
linux
apt-get
easter-eggs
null
null
10/17/2011 16:44:46
off topic
Apt-get documentation and cows. Whats is this all about? === I was installing things in my new Ubuntu (11.10) using the terminal with `apt-get` command. In the middle of my tasks I took a look at apt-get documentation to see what `-y` means: $ sudo apt-get --help And after the parameters documentation there was a very enigmatic message: > apt-get has Super Cow Power I asked a friend about it and he couldn't tell me why it's there. He laughed and told me to execute this other command: $ sudo apt-get moo It produced the following output (ASCII art of a cow): (__) (oo) /------\/ / | || * /\---/\ ~~ ~~ ...."Have you mooed today?"... Now I ask you, whata hell is all this **Cow** thing in `apt-get` commands? Just for curiosity.
2
374,239
12/17/2008 11:05:41
46,646
12/16/2008 12:26:29
3
0
switch in python
what is the reason why Python doesn't have switch statement ?
python
switch-statement
null
null
null
03/16/2012 01:18:25
not constructive
switch in python === what is the reason why Python doesn't have switch statement ?
4
10,362,530
04/28/2012 10:08:25
700,209
04/09/2011 18:46:34
146
2
Similarity between 2 polyline
For my final academic work I have developed a compression algorithm for GPS trajectories. I can estimate quality of the spatio-temporal compression by computing the [syncronized euclidean distance][1] (SED) between compressed and original trajectory and evaluate my algorithm's performance against well-known compression algorithm. A spatio-temporal algorithm, like mine, reduce the trajectory trying to mantein as much as possible temporal informations. Spatial algorithm (e.g. Douglas-Peucker algorithm) realize the compression refearing only to the spatial characteristics. What happen now? Considering a spatio-temporal aspect, my algorithm is better than DP. I can assure this by SED measurements. If I plot the three trajectories (original, mine and DP compressed), the trajectory compressed with DP has a better fitting with the original trajectory. The eye-only mesuraments don't satisfy my need. I need, indeed, an error metric that numerically demonstrate how DP algorithm is better than mine in spatial manner. So I could write: "Refearing to the spatio-temporal factor, my algorithm is better than DP, because have a SED factor less than DP's SED factor. Alas, simple spatial factor, awards DP algorithm cause his (name of the new metric) is better than mine". I have think of perpendicular euclidean distance, but I really don't know if thhis could be usefull, have you any idea? [1]: http://books.google.it/books?id=JShQJF23xBgC&lpg=PA11&ots=6LSfhq9nf1&dq=synchronized%20euclidean%20distance&hl=it&pg=PA11#v=onepage&q=synchronized%20euclidean%20distance&f=false
douglas-peucker
null
null
null
null
07/31/2012 02:34:53
off topic
Similarity between 2 polyline === For my final academic work I have developed a compression algorithm for GPS trajectories. I can estimate quality of the spatio-temporal compression by computing the [syncronized euclidean distance][1] (SED) between compressed and original trajectory and evaluate my algorithm's performance against well-known compression algorithm. A spatio-temporal algorithm, like mine, reduce the trajectory trying to mantein as much as possible temporal informations. Spatial algorithm (e.g. Douglas-Peucker algorithm) realize the compression refearing only to the spatial characteristics. What happen now? Considering a spatio-temporal aspect, my algorithm is better than DP. I can assure this by SED measurements. If I plot the three trajectories (original, mine and DP compressed), the trajectory compressed with DP has a better fitting with the original trajectory. The eye-only mesuraments don't satisfy my need. I need, indeed, an error metric that numerically demonstrate how DP algorithm is better than mine in spatial manner. So I could write: "Refearing to the spatio-temporal factor, my algorithm is better than DP, because have a SED factor less than DP's SED factor. Alas, simple spatial factor, awards DP algorithm cause his (name of the new metric) is better than mine". I have think of perpendicular euclidean distance, but I really don't know if thhis could be usefull, have you any idea? [1]: http://books.google.it/books?id=JShQJF23xBgC&lpg=PA11&ots=6LSfhq9nf1&dq=synchronized%20euclidean%20distance&hl=it&pg=PA11#v=onepage&q=synchronized%20euclidean%20distance&f=false
2
9,298,364
02/15/2012 17:39:37
593,934
01/28/2011 14:03:38
1
2
How to wipe Android device when device admin is deactivated?
In my application, which is a device admin, I need to wipe the entire device when the user tries to deactivate the admin function of the application. When the user goes to Settings / Security / Device admins and deactivates the admin app, first a dialog is presented "Do you want to deactivate". If the user says "yes", then another small dialog is presented, with the text provided by the application's AdminReceiver in onDisableRequested(). If the user then says "yes", I want to wipe the entire device. How to accomplish this? I tried everything, searched long for answers, found no real solutions. What I tried: - AdminReceiver has a function onDisable(). I tried to wipe the device in that function. However, it appears that onDisable() is called ***after*** the admin has been disabled. Thus the app cannot use the wipeData() function at all (a security exception is thrown). I have also verified that isAdminActive() returns false at that time. Official documentation does not say this clearly, but it seems that the admin is already disabled when onDisable() is called. Thus we have to wipe the device before that time. - AdminReceiver has a function onDisableRequested(), which returns CharSequence. I tried to put another alert box in that function. This crashes because an alert box cannot be called from a non-activity context, which seems to be what we have when we are in onDisableRequested(). - AdminReceiver has a function onReceive(), which gets called on any events. In this function, again, we are not in an activity context and cannot present our own dialogs. - I tried creating another activity from onReceive(). This works; during onReceive() when we get ACTION_DISABLE_ADMIN_REQUESTED, the admin is still active and we can wipe the device. However, the system still presents its own dialog asking the user whether to deactivate the admin. If the user says no to our dialog but yes to the system dialog, the admin will be deactivated and we will have failed to wipe the device. I tried the following, in my subclass of DeviceAdminReceiver: @Override public void onReceive(Context context, Intent intent) { // detect whether disabling is requested? if (intent.getAction().equals(ACTION_DEVICE_ADMIN_DISABLE_REQUESTED)) { confirmWipeDevice(context); } else { super.onReceive(context, intent); } } In other words, I do not call super.onReceive() if the action is to disable the admin. The function confirmWipeDevice() shows a different activity with a dialog. This does not show the system dialog for confirming the disabling of my admin app. However, this does not prevent the app from being actually disabled! It seems that the Android system does the following: - Send ACTION_DEVICE_ADMIN_DISABLE_REQUESTED to the AdminReceiver - Proceed with disabling the admin regardless of what the admin app wants to do - If the user cancels the disabling, fine; if not, the app is disabled. There is no way for the app to refuse being disabled, or to perform the device wipe upon disabling. The only solution so far is to wipe immediately without confirmation when the user wants to disable the admin app. In other words, I can call getManager().wipeData() immediately in onDisableRequested(). At that time, the admin is still active and this works. Is this correct? How to wipe the device when the user chooses to disable the admin app?
android
admin
null
null
null
null
open
How to wipe Android device when device admin is deactivated? === In my application, which is a device admin, I need to wipe the entire device when the user tries to deactivate the admin function of the application. When the user goes to Settings / Security / Device admins and deactivates the admin app, first a dialog is presented "Do you want to deactivate". If the user says "yes", then another small dialog is presented, with the text provided by the application's AdminReceiver in onDisableRequested(). If the user then says "yes", I want to wipe the entire device. How to accomplish this? I tried everything, searched long for answers, found no real solutions. What I tried: - AdminReceiver has a function onDisable(). I tried to wipe the device in that function. However, it appears that onDisable() is called ***after*** the admin has been disabled. Thus the app cannot use the wipeData() function at all (a security exception is thrown). I have also verified that isAdminActive() returns false at that time. Official documentation does not say this clearly, but it seems that the admin is already disabled when onDisable() is called. Thus we have to wipe the device before that time. - AdminReceiver has a function onDisableRequested(), which returns CharSequence. I tried to put another alert box in that function. This crashes because an alert box cannot be called from a non-activity context, which seems to be what we have when we are in onDisableRequested(). - AdminReceiver has a function onReceive(), which gets called on any events. In this function, again, we are not in an activity context and cannot present our own dialogs. - I tried creating another activity from onReceive(). This works; during onReceive() when we get ACTION_DISABLE_ADMIN_REQUESTED, the admin is still active and we can wipe the device. However, the system still presents its own dialog asking the user whether to deactivate the admin. If the user says no to our dialog but yes to the system dialog, the admin will be deactivated and we will have failed to wipe the device. I tried the following, in my subclass of DeviceAdminReceiver: @Override public void onReceive(Context context, Intent intent) { // detect whether disabling is requested? if (intent.getAction().equals(ACTION_DEVICE_ADMIN_DISABLE_REQUESTED)) { confirmWipeDevice(context); } else { super.onReceive(context, intent); } } In other words, I do not call super.onReceive() if the action is to disable the admin. The function confirmWipeDevice() shows a different activity with a dialog. This does not show the system dialog for confirming the disabling of my admin app. However, this does not prevent the app from being actually disabled! It seems that the Android system does the following: - Send ACTION_DEVICE_ADMIN_DISABLE_REQUESTED to the AdminReceiver - Proceed with disabling the admin regardless of what the admin app wants to do - If the user cancels the disabling, fine; if not, the app is disabled. There is no way for the app to refuse being disabled, or to perform the device wipe upon disabling. The only solution so far is to wipe immediately without confirmation when the user wants to disable the admin app. In other words, I can call getManager().wipeData() immediately in onDisableRequested(). At that time, the admin is still active and this works. Is this correct? How to wipe the device when the user chooses to disable the admin app?
0
3,193,996
07/07/2010 10:51:48
65,736
02/12/2009 20:22:29
2,044
92
Emulating/faking filesystem for testing C code?
I'm looking for the cross-platform way to test some features in my application which required access to the filesystem (to write and read binary data). In the real life my application running on Linux and store special data in `/usr/local/etc` directory. But main part of the application is cross-platform library and it should be tested both on Windows and Linux. Furthermore, I don't want for my tests to write/read data directly to `/usr/local/etc` because in that case it will break test isolation. So I'm thinking about replacing real access to the filesystem with special emulator of filesystem. Thus every test which required access to the filesystem can create new instance of vistual filesystem object and I can run tests in isolation, and properly support testing on Windows. I've tried to find some existing open/free implementation, but so far found none for C code. Any hints?
c
unit-testing
cross-platform
filesystems
null
null
open
Emulating/faking filesystem for testing C code? === I'm looking for the cross-platform way to test some features in my application which required access to the filesystem (to write and read binary data). In the real life my application running on Linux and store special data in `/usr/local/etc` directory. But main part of the application is cross-platform library and it should be tested both on Windows and Linux. Furthermore, I don't want for my tests to write/read data directly to `/usr/local/etc` because in that case it will break test isolation. So I'm thinking about replacing real access to the filesystem with special emulator of filesystem. Thus every test which required access to the filesystem can create new instance of vistual filesystem object and I can run tests in isolation, and properly support testing on Windows. I've tried to find some existing open/free implementation, but so far found none for C code. Any hints?
0
3,141,031
06/29/2010 13:24:46
264,165
02/02/2010 08:14:44
148
0
robots.txt parser java
i want to know how to parse the robots.txt in java. already any code is there? thanks in advance
java
parsing
robots.txt
null
null
null
open
robots.txt parser java === i want to know how to parse the robots.txt in java. already any code is there? thanks in advance
0
1,258,156
08/11/2009 02:09:28
152,360
08/07/2009 09:07:26
1
0
How will you define RESPECT for privacy in Programming?
Will you write in your code your source, even if it causes you to expand your codes..
ethics
null
null
null
null
08/11/2009 02:53:48
not a real question
How will you define RESPECT for privacy in Programming? === Will you write in your code your source, even if it causes you to expand your codes..
1
11,092,296
06/18/2012 23:02:22
875,317
08/02/2011 19:11:50
1,364
16
Should variables be explicitly or implicitly typed?
They say one should not go to sea with two chronometers, or wear two watches. You should either use one that's reliable, or three (or more) to let the "majority rule." So, should I install another code refactoring helper, or uninstall one of them? I have installed two, and they are bickering back and forth over this line of code: using (StreamReader file = new StreamReader(ChemicalMakeupOfEveryDropOfWaterInTheMississippi)) ...should be this instead: using (var file = new StreamReader(ChemicalMakeupOfEveryDropOfWaterInTheBigMuddy)) If I specify the type explicitly, the tool with a light bulb gutter icon tells me: "Use implicitly typed local variable declaration | use 'var'" If I acquiesce and allow it to convert the explicit to the implicit, another tool (the one with a pencil icon in the gutter) pipes up and says, "Specify type explicitly" and changes the 'var' back to 'StreamReader' I am stuck in an endless loop changing explicit to implicit and back again. My take on it is it doesn't really matter, but I throw this conundrum out to the wisdom of the StackOverflow crowd.
c#
variables
null
null
null
06/18/2012 23:08:14
not constructive
Should variables be explicitly or implicitly typed? === They say one should not go to sea with two chronometers, or wear two watches. You should either use one that's reliable, or three (or more) to let the "majority rule." So, should I install another code refactoring helper, or uninstall one of them? I have installed two, and they are bickering back and forth over this line of code: using (StreamReader file = new StreamReader(ChemicalMakeupOfEveryDropOfWaterInTheMississippi)) ...should be this instead: using (var file = new StreamReader(ChemicalMakeupOfEveryDropOfWaterInTheBigMuddy)) If I specify the type explicitly, the tool with a light bulb gutter icon tells me: "Use implicitly typed local variable declaration | use 'var'" If I acquiesce and allow it to convert the explicit to the implicit, another tool (the one with a pencil icon in the gutter) pipes up and says, "Specify type explicitly" and changes the 'var' back to 'StreamReader' I am stuck in an endless loop changing explicit to implicit and back again. My take on it is it doesn't really matter, but I throw this conundrum out to the wisdom of the StackOverflow crowd.
4
6,276,238
06/08/2011 08:41:15
697,744
04/07/2011 23:22:55
1
0
C++ argument that i need in my project
i write a program reads from a file, i want to get all characters of each string in the file & skip the symbols like (",'.) also skip space example: if the file contains I'm happy i need the program to print: "I" "m" "h" "a" "p" "p" "y" what should i write ??
visual-c++-2010-express
null
null
null
null
06/08/2011 08:57:00
not a real question
C++ argument that i need in my project === i write a program reads from a file, i want to get all characters of each string in the file & skip the symbols like (",'.) also skip space example: if the file contains I'm happy i need the program to print: "I" "m" "h" "a" "p" "p" "y" what should i write ??
1
10,862,648
06/02/2012 13:25:02
1,318,239
04/06/2012 20:51:57
139
0
jQuery .validate multiple file inputs (array name)
Only first file input is validated. Any suggestions how to fix this? I tried with the .each, like suggested somewhere, but it still doesnt work. Demo: **HTML:** <form method="post" action="<?php echo $_SERVER['PHP_SELF']."?".$_SERVER["QUERY_STRING"]; ?>" enctype="multipart/form-data" id="fnpMain"> <table class="ConTable"> <tr> <td>Photo 1:</td> <td> <input type="file" class="ipfile" name="pic[]" /> </td> </tr> <tr> <td>Photo 2:</td> <td> <input type="file" class="ipfile" name="pic[]" /> </td> </tr> <tr> <td>Photo 3:</td> <td> <input type="file" class="ipfile" name="pic[]" /> </td> </tr> </table> <input type="submit" name="sub" value="submit" /> </form> **JQ:** <script type="text/javascript"> $(document).ready(function(){ $("#fnpMain").validate( { rules:{ Telefon:{required:true, exactlength:9, digits:true} } }); $("input[type=file]").each(function(){ $(this).rules("add", { required:true, accept: "jpe?g" }); }); }); </script>
javascript
jquery
html
validation
null
06/04/2012 00:24:18
not a real question
jQuery .validate multiple file inputs (array name) === Only first file input is validated. Any suggestions how to fix this? I tried with the .each, like suggested somewhere, but it still doesnt work. Demo: **HTML:** <form method="post" action="<?php echo $_SERVER['PHP_SELF']."?".$_SERVER["QUERY_STRING"]; ?>" enctype="multipart/form-data" id="fnpMain"> <table class="ConTable"> <tr> <td>Photo 1:</td> <td> <input type="file" class="ipfile" name="pic[]" /> </td> </tr> <tr> <td>Photo 2:</td> <td> <input type="file" class="ipfile" name="pic[]" /> </td> </tr> <tr> <td>Photo 3:</td> <td> <input type="file" class="ipfile" name="pic[]" /> </td> </tr> </table> <input type="submit" name="sub" value="submit" /> </form> **JQ:** <script type="text/javascript"> $(document).ready(function(){ $("#fnpMain").validate( { rules:{ Telefon:{required:true, exactlength:9, digits:true} } }); $("input[type=file]").each(function(){ $(this).rules("add", { required:true, accept: "jpe?g" }); }); }); </script>
1
10,818,450
05/30/2012 14:34:28
404,376
07/28/2010 10:12:33
1
0
Gradle : Doesnt resolve Spring dependency from Maven Repository
I am trying to setup a new Java project using Gradle as the build tool. For this post, lets assume that the project needs to use Hibernate `[hibernate-core]` and Spring `[spring-core]`. build.gradle def localMavenRepo = "file://opt/m2/repository" allprojects { apply plugin: "java" repositories { maven { url localMavenRepo } } dependencies { compile "org.hibernate:hibernate-core:3.5.0-CR-2" compile "org.springframework:spring-core:3.0.5-RELEASE" } } When I run `gradle-build` I get the following: > FAILURE: Build failed with an exception. > * What went wrong: > Could not resolve all dependencies for configuration ':testRuntime'. > Could not find group:org.springframework, module:spring-core, version:3.0.5-RELEASE. > Required by: > :gradle_spring_bug:unspecified The puzzling part is that it finds the `hibernate-core` artifact in the repository but not the `spring-core` one. I am thinking that perhaps the Spring jar itself is to blame. Here is what I have tried so far: 1. Change the Maven repository. I am at work at the moment and we using a Maven Proxy repository. I have tried both local and remote repositories. Problem still exists. 2. Change the Spring version. I have tried different versions of the `spring-core` dependency (`3.0.1-RELEASE, 3.0.3-RELEASE`). Problem still exists. 3. Change the Spring artifact. I have tried the `org.springframework.spring-jdbc` and `org.springframework.security.spring-security-cas-client` artifacts as well. Problem still exists. 4. Verify that it is Spring by trying different artifacts. I have tried 'junit', 'hibernate-core', 'hibernate-validator', 'javaee-web-api'. Some with different versions. Pointing them to either local or remote repositories and they all work. What I haven't tried yet: 1. Change the version of Gradle I am using the latest version of Gradle `1.0-rc-3` 2. Try the Maven central repo Need to configure my proxy but that's my next step. However, I am not too optimistic that it will work. Would be great if somebody with the latest version of Gradle could try it out and let me know if they are experiencing the same issue.
spring
gradle
null
null
null
06/02/2012 18:50:44
too localized
Gradle : Doesnt resolve Spring dependency from Maven Repository === I am trying to setup a new Java project using Gradle as the build tool. For this post, lets assume that the project needs to use Hibernate `[hibernate-core]` and Spring `[spring-core]`. build.gradle def localMavenRepo = "file://opt/m2/repository" allprojects { apply plugin: "java" repositories { maven { url localMavenRepo } } dependencies { compile "org.hibernate:hibernate-core:3.5.0-CR-2" compile "org.springframework:spring-core:3.0.5-RELEASE" } } When I run `gradle-build` I get the following: > FAILURE: Build failed with an exception. > * What went wrong: > Could not resolve all dependencies for configuration ':testRuntime'. > Could not find group:org.springframework, module:spring-core, version:3.0.5-RELEASE. > Required by: > :gradle_spring_bug:unspecified The puzzling part is that it finds the `hibernate-core` artifact in the repository but not the `spring-core` one. I am thinking that perhaps the Spring jar itself is to blame. Here is what I have tried so far: 1. Change the Maven repository. I am at work at the moment and we using a Maven Proxy repository. I have tried both local and remote repositories. Problem still exists. 2. Change the Spring version. I have tried different versions of the `spring-core` dependency (`3.0.1-RELEASE, 3.0.3-RELEASE`). Problem still exists. 3. Change the Spring artifact. I have tried the `org.springframework.spring-jdbc` and `org.springframework.security.spring-security-cas-client` artifacts as well. Problem still exists. 4. Verify that it is Spring by trying different artifacts. I have tried 'junit', 'hibernate-core', 'hibernate-validator', 'javaee-web-api'. Some with different versions. Pointing them to either local or remote repositories and they all work. What I haven't tried yet: 1. Change the version of Gradle I am using the latest version of Gradle `1.0-rc-3` 2. Try the Maven central repo Need to configure my proxy but that's my next step. However, I am not too optimistic that it will work. Would be great if somebody with the latest version of Gradle could try it out and let me know if they are experiencing the same issue.
3
5,408,389
03/23/2011 16:19:50
215,282
11/20/2009 08:41:46
188
15
HHHHOOOWW? AVCaptureVideoPreviewLayer orientation changes during AVCaptureSession?
I have a viewCOntroller with may controls that has an AVCaptureVideoPreviewLayer as well. When orientation changes, everything goes wrong. What should I do? Any WORKING receipe? (I know that the question is a bit weird, but I'm really upset about it)
iphone
orientation
avcapturesession
null
null
06/25/2012 19:19:25
too localized
HHHHOOOWW? AVCaptureVideoPreviewLayer orientation changes during AVCaptureSession? === I have a viewCOntroller with may controls that has an AVCaptureVideoPreviewLayer as well. When orientation changes, everything goes wrong. What should I do? Any WORKING receipe? (I know that the question is a bit weird, but I'm really upset about it)
3
4,413,949
12/10/2010 22:40:17
52,749
01/08/2009 03:04:04
357
9
Using TagLib in Visual Studio 2010
**EDIT:** Yes, I have looked at [this post][1]. Unfortunately, it looks like the user ends up using MingW in the end. ---------- I am on **Windows 7**, 64-bit. I downloaded the most recent version of the TagLib code from the SVN repository. I am using revision **1202935**. I am trying to use TagLib in **Visual Studio 2010**. I have gotten TagLib to work with QtCreator/MingW, but I want to start learning the Windows API so I am starting from scratch in Visual Studio 2010 (C++ of course). In VS2010, I have build zlib (both statically and dynamically) and TagLib with and without zlib (both statically and dynamically). In other words, I have tried everything I can think of to get this to work. My ideal situation is that I use CMake to generate the VS2010 project files (there is an option for VS2010 64-bit. I **do not** choose this option) for TagLib. I would like them to be static libraries, so I enable ENABLE_STATIC, and I enable WITH_ASF, and WITH_MP4. I also direct TagLib to zlib using ZLIB_INCLUDE_DIR and ZLIB_LIBRARY (I am linking to the zlib.lib file that I previously built using VS2010). Note, I am using the CMake GUI. I then open up the generated project files in VS2010 and make three changes to the code so that it build in Visual Studio 2010 without error (*I put the fixes here for anyone else who had the same problem as I*). **apefooter.cpp** on line 192: std::bitset<32> flags(static_cast<unsigned long long>(data.mid(20, 4).toUInt(false))); **mpcproperties.cpp** on line 116: std::bitset<32> flags = static_cast<unsigned long long>(d->data.mid(8, 4).toUInt(false)); **mpegheader.cpp** on line 171: std::bitset<32> flags(static_cast<unsigned long long>(data.toUInt())); I then make then comment out lines 436 and 437 in **mpegfile.cpp**, because [I think it's a bug][2]. // ID3v2Tag(true); // ID3v1Tag(true); I then build the project in Release mode. It builds just fine. No errors (although there are a bunch of warnings). So I have generated **tag.lib**. I then created a test VS2010 project/solution to use TagLib. This is the only line I use TagLib. Just a test, mind you. TagLib::MPEG::File a("tests/other/blank.mp3"); - I added `TAGLIB_STATIC` to the preprocessor options (*Property Pages > Configuration Properties > C/C++ > Preprocessor > Preprocessor Definitions*) for all configurations (both Release and Debug builds) - I added every single darn header directory to *Property Pages > Configuration Properties > C/C++ > General > Additional Include Directories* - And finally I added zlib.lib and tag.lib to the additional dependencies (*Property Pages > Configuration Properties > Linker > Input > Additional Dependencies*) IN THAT ORDER "Whew! What a hassle! Now let's see if it works?" 1>vs_taglib_test.obj : error LNK2028: unresolved token (0A00001A) "public: virtual __clrcall TagLib::MPEG::File::~File(void)" (??1File@MPEG@TagLib@@$$FUAM@XZ) referenced in function "int __clrcall main(cli::array<class System::String ^ >^)" (?main@@$$HYMHP$01AP$AAVString@System@@@Z) 1>vs_taglib_test.obj : error LNK2028: unresolved token (0A00001B) "public: __clrcall TagLib::MPEG::File::File(class TagLib::FileName,bool,enum TagLib::AudioProperties::ReadStyle)" (??0File@MPEG@TagLib@@$$FQAM@VFileName@2@_NW4ReadStyle@AudioProperties@2@@Z) referenced in function "int __clrcall main(cli::array<class System::String ^ >^)" (?main@@$$HYMHP$01AP$AAVString@System@@@Z) 1>vs_taglib_test.obj : error LNK2019: unresolved external symbol "public: virtual __clrcall TagLib::MPEG::File::~File(void)" (??1File@MPEG@TagLib@@$$FUAM@XZ) referenced in function "int __clrcall main(cli::array<class System::String ^ >^)" (?main@@$$HYMHP$01AP$AAVString@System@@@Z) 1>vs_taglib_test.obj : error LNK2019: unresolved external symbol "public: __clrcall TagLib::MPEG::File::File(class TagLib::FileName,bool,enum TagLib::AudioProperties::ReadStyle)" (??0File@MPEG@TagLib@@$$FQAM@VFileName@2@_NW4ReadStyle@AudioProperties@2@@Z) referenced in function "int __clrcall main(cli::array<class System::String ^ >^)" (?main@@$$HYMHP$01AP$AAVString@System@@@Z) Can someone else try out what I'm doing here and point out my mistake? I tried to provide enough information for y'all to see what's happening. Thanks for reading! [1]: http://stackoverflow.com/questions/3878883/compiling-static-taglib-1-6-3-libraries-for-windows [2]: http://mail.kde.org/pipermail/taglib-devel/2010-December/001723.html
c++
visual-studio-2010
static-libraries
taglib
null
null
open
Using TagLib in Visual Studio 2010 === **EDIT:** Yes, I have looked at [this post][1]. Unfortunately, it looks like the user ends up using MingW in the end. ---------- I am on **Windows 7**, 64-bit. I downloaded the most recent version of the TagLib code from the SVN repository. I am using revision **1202935**. I am trying to use TagLib in **Visual Studio 2010**. I have gotten TagLib to work with QtCreator/MingW, but I want to start learning the Windows API so I am starting from scratch in Visual Studio 2010 (C++ of course). In VS2010, I have build zlib (both statically and dynamically) and TagLib with and without zlib (both statically and dynamically). In other words, I have tried everything I can think of to get this to work. My ideal situation is that I use CMake to generate the VS2010 project files (there is an option for VS2010 64-bit. I **do not** choose this option) for TagLib. I would like them to be static libraries, so I enable ENABLE_STATIC, and I enable WITH_ASF, and WITH_MP4. I also direct TagLib to zlib using ZLIB_INCLUDE_DIR and ZLIB_LIBRARY (I am linking to the zlib.lib file that I previously built using VS2010). Note, I am using the CMake GUI. I then open up the generated project files in VS2010 and make three changes to the code so that it build in Visual Studio 2010 without error (*I put the fixes here for anyone else who had the same problem as I*). **apefooter.cpp** on line 192: std::bitset<32> flags(static_cast<unsigned long long>(data.mid(20, 4).toUInt(false))); **mpcproperties.cpp** on line 116: std::bitset<32> flags = static_cast<unsigned long long>(d->data.mid(8, 4).toUInt(false)); **mpegheader.cpp** on line 171: std::bitset<32> flags(static_cast<unsigned long long>(data.toUInt())); I then make then comment out lines 436 and 437 in **mpegfile.cpp**, because [I think it's a bug][2]. // ID3v2Tag(true); // ID3v1Tag(true); I then build the project in Release mode. It builds just fine. No errors (although there are a bunch of warnings). So I have generated **tag.lib**. I then created a test VS2010 project/solution to use TagLib. This is the only line I use TagLib. Just a test, mind you. TagLib::MPEG::File a("tests/other/blank.mp3"); - I added `TAGLIB_STATIC` to the preprocessor options (*Property Pages > Configuration Properties > C/C++ > Preprocessor > Preprocessor Definitions*) for all configurations (both Release and Debug builds) - I added every single darn header directory to *Property Pages > Configuration Properties > C/C++ > General > Additional Include Directories* - And finally I added zlib.lib and tag.lib to the additional dependencies (*Property Pages > Configuration Properties > Linker > Input > Additional Dependencies*) IN THAT ORDER "Whew! What a hassle! Now let's see if it works?" 1>vs_taglib_test.obj : error LNK2028: unresolved token (0A00001A) "public: virtual __clrcall TagLib::MPEG::File::~File(void)" (??1File@MPEG@TagLib@@$$FUAM@XZ) referenced in function "int __clrcall main(cli::array<class System::String ^ >^)" (?main@@$$HYMHP$01AP$AAVString@System@@@Z) 1>vs_taglib_test.obj : error LNK2028: unresolved token (0A00001B) "public: __clrcall TagLib::MPEG::File::File(class TagLib::FileName,bool,enum TagLib::AudioProperties::ReadStyle)" (??0File@MPEG@TagLib@@$$FQAM@VFileName@2@_NW4ReadStyle@AudioProperties@2@@Z) referenced in function "int __clrcall main(cli::array<class System::String ^ >^)" (?main@@$$HYMHP$01AP$AAVString@System@@@Z) 1>vs_taglib_test.obj : error LNK2019: unresolved external symbol "public: virtual __clrcall TagLib::MPEG::File::~File(void)" (??1File@MPEG@TagLib@@$$FUAM@XZ) referenced in function "int __clrcall main(cli::array<class System::String ^ >^)" (?main@@$$HYMHP$01AP$AAVString@System@@@Z) 1>vs_taglib_test.obj : error LNK2019: unresolved external symbol "public: __clrcall TagLib::MPEG::File::File(class TagLib::FileName,bool,enum TagLib::AudioProperties::ReadStyle)" (??0File@MPEG@TagLib@@$$FQAM@VFileName@2@_NW4ReadStyle@AudioProperties@2@@Z) referenced in function "int __clrcall main(cli::array<class System::String ^ >^)" (?main@@$$HYMHP$01AP$AAVString@System@@@Z) Can someone else try out what I'm doing here and point out my mistake? I tried to provide enough information for y'all to see what's happening. Thanks for reading! [1]: http://stackoverflow.com/questions/3878883/compiling-static-taglib-1-6-3-libraries-for-windows [2]: http://mail.kde.org/pipermail/taglib-devel/2010-December/001723.html
0
6,952,322
08/05/2011 06:31:25
610,833
02/10/2011 04:54:00
81
14
what happens when mailing limit for the day is crossed?
I want to know what happens when my account limit for the day is over. Are the mail shooted after that queued for the next day or discarded?
smtp
sendmail
actionmailer
sendgrid
null
08/27/2011 01:39:05
off topic
what happens when mailing limit for the day is crossed? === I want to know what happens when my account limit for the day is over. Are the mail shooted after that queued for the next day or discarded?
2
6,278,807
06/08/2011 12:39:13
505,893
11/12/2010 14:59:00
1,659
72
Why every IDE has different keyboard shortcuts for debugging?
Every developer knows the **5 basic operations** that IDEs allow to perform during a **debug**: 1. step into 2. step over 3. step return 4. resume 5. terminate (according to Eclipse vocabulary) Now take a look to the **keyboard shortcuts** assigned to them, in some IDEs taken as examples: - Eclipse: 1. F5 2. F6 3. F7 4. F8 5. Ctrl+F2 - Borland C++ Builder 5: 1. F7 2. F8 3. Shift+F8 4. F9 5. Ctrl+F2 - Visual Studio 2010: 1. F11 2. F10 3. Shift+F11 4. F5 5. Shift+F5 It's a mess... I usually develop with all of them (and more) and I can never remember the correct buttons... So the question is: **why these configurations are nowhere near standardized?** Is there a project to standardize them? **How do you deal with this daily issue?** Changing the configuration for each IDE? In this case which "standard" configuration do you choose? Many thanks!
visual-studio
eclipse
debugging
ide
keyboard-shortcuts
06/08/2011 13:08:33
not a real question
Why every IDE has different keyboard shortcuts for debugging? === Every developer knows the **5 basic operations** that IDEs allow to perform during a **debug**: 1. step into 2. step over 3. step return 4. resume 5. terminate (according to Eclipse vocabulary) Now take a look to the **keyboard shortcuts** assigned to them, in some IDEs taken as examples: - Eclipse: 1. F5 2. F6 3. F7 4. F8 5. Ctrl+F2 - Borland C++ Builder 5: 1. F7 2. F8 3. Shift+F8 4. F9 5. Ctrl+F2 - Visual Studio 2010: 1. F11 2. F10 3. Shift+F11 4. F5 5. Shift+F5 It's a mess... I usually develop with all of them (and more) and I can never remember the correct buttons... So the question is: **why these configurations are nowhere near standardized?** Is there a project to standardize them? **How do you deal with this daily issue?** Changing the configuration for each IDE? In this case which "standard" configuration do you choose? Many thanks!
1
11,649,433
07/25/2012 12:13:28
1,551,517
07/25/2012 12:04:00
1
0
Drupal form ajax executes wrong callback function
I have a form with two buttons. One traditional and one using ajax: function taxonomy_pivot_user_form(){ $form['submit_button'] = array( '#type' => 'submit', '#value' => t('Process'), '#ajax' => array( 'callback' => 'taxonomy_privot_ajax_callback', 'wrapper' => 'replace_area', ), ); $form['excel_export'] = array( '#type' => 'image_button', '#src' => drupal_get_path('module', "taxonomy_pivot") . '/images/excel.png', '#value' => t('Excel Export'), '#submit' => array('taxonomy_privot_excel_callback'), //'#executes_submit_callback' => false, ); return $form; } If I have just the first button the method "taxonomy_privot_ajax_callback" is called properly and the correct result is returned. If the second button is added, the second one works as desired, but the first one seems to call also the #submit of the second button. function taxonomy_privot_excel_callback($form, $form_state){ return taxonomy_privot_ajax_callback($form, $form_state, "excel"); } function taxonomy_privot_ajax_callback($form, $form_state, $op = "table"){ dd($op); } $op has the value "excel" for both buttons. Can you help me and show what is wrong with my form definition?
ajax
drupal
null
null
null
07/25/2012 14:46:27
off topic
Drupal form ajax executes wrong callback function === I have a form with two buttons. One traditional and one using ajax: function taxonomy_pivot_user_form(){ $form['submit_button'] = array( '#type' => 'submit', '#value' => t('Process'), '#ajax' => array( 'callback' => 'taxonomy_privot_ajax_callback', 'wrapper' => 'replace_area', ), ); $form['excel_export'] = array( '#type' => 'image_button', '#src' => drupal_get_path('module', "taxonomy_pivot") . '/images/excel.png', '#value' => t('Excel Export'), '#submit' => array('taxonomy_privot_excel_callback'), //'#executes_submit_callback' => false, ); return $form; } If I have just the first button the method "taxonomy_privot_ajax_callback" is called properly and the correct result is returned. If the second button is added, the second one works as desired, but the first one seems to call also the #submit of the second button. function taxonomy_privot_excel_callback($form, $form_state){ return taxonomy_privot_ajax_callback($form, $form_state, "excel"); } function taxonomy_privot_ajax_callback($form, $form_state, $op = "table"){ dd($op); } $op has the value "excel" for both buttons. Can you help me and show what is wrong with my form definition?
2
10,519,461
05/09/2012 15:43:22
1,382,141
05/08/2012 13:04:53
1
0
Sharing a tweet in Android
I'm developing an Android Application and I want to publish a tweet in twitter. My problem is that I don't know how I do to create a tweet in an android app. I searched for information and I find two possible libraries that may be good for tweet content, the libraries are JTwitter and Twitter4J. When I search the information too people say that OAuth it's difficult, and I don't understand nothing of the OAuth. If it's possible I want to share an image with the tweet, the image can be a Bitmao object? And, how I do to insert in the predeterminated tweet this image? Thanks for the time spended
android
twitter
twitter-oauth
twitter4j
jtwitter
null
open
Sharing a tweet in Android === I'm developing an Android Application and I want to publish a tweet in twitter. My problem is that I don't know how I do to create a tweet in an android app. I searched for information and I find two possible libraries that may be good for tweet content, the libraries are JTwitter and Twitter4J. When I search the information too people say that OAuth it's difficult, and I don't understand nothing of the OAuth. If it's possible I want to share an image with the tweet, the image can be a Bitmao object? And, how I do to insert in the predeterminated tweet this image? Thanks for the time spended
0
10,682,375
05/21/2012 09:09:30
506,901
11/13/2010 18:23:47
179
0
Wireless problems in Ubuntu Lucid Lynx 10.04
After one of the updates I made in Ubuntu Lucid Lynx, I started having problems with my wireless connection. Namely, the wireless icon in the top right corner is always with an exclamation mark and no wireless connections are shown (wireless disabled). I tried following the steps from http://ubuntuforums.org/showthread.php?t=943848 starting with 10), and it worked for a couple of days (even then the wireless icon had the exclamation mark), but the problem is back. The file I opened with 10), as in the above, has =true. Could you please help me with this?
ubuntu
ubuntu-10.04
null
null
null
05/22/2012 12:59:24
off topic
Wireless problems in Ubuntu Lucid Lynx 10.04 === After one of the updates I made in Ubuntu Lucid Lynx, I started having problems with my wireless connection. Namely, the wireless icon in the top right corner is always with an exclamation mark and no wireless connections are shown (wireless disabled). I tried following the steps from http://ubuntuforums.org/showthread.php?t=943848 starting with 10), and it worked for a couple of days (even then the wireless icon had the exclamation mark), but the problem is back. The file I opened with 10), as in the above, has =true. Could you please help me with this?
2
7,234,628
08/29/2011 19:06:01
645,607
03/05/2011 00:32:55
106
5
starting a rails app and confused
Okay ive read the ruby on rails tutorial book, and i felt like i was learning it. But when i finished i wanna start my own practice project but i cant seem to think of how to start the app. Are the controller names plural and capitalized? is a model name singular? the book showed that the password hashing and stuff was done in a helper file, but i thought that stuff was done in the model? i just need some direction on how to start the app skeleton i guess please help!
ruby-on-rails
mvc
null
null
null
08/29/2011 20:22:24
not a real question
starting a rails app and confused === Okay ive read the ruby on rails tutorial book, and i felt like i was learning it. But when i finished i wanna start my own practice project but i cant seem to think of how to start the app. Are the controller names plural and capitalized? is a model name singular? the book showed that the password hashing and stuff was done in a helper file, but i thought that stuff was done in the model? i just need some direction on how to start the app skeleton i guess please help!
1
7,352,071
09/08/2011 17:23:25
773,896
05/28/2011 00:09:03
1
0
Creating an "Invite Friends" Tab on Fan Page in iFrame
I've found many online tutorials about how to create an FBML tab on a fan page that lets fans invite their friends to the page, but all of these tutorials are outdated because it became impossible to create new FBML taps after March 11th. So I'm wondering now how to create an "invite friends" tab on my facebook fan page NOT using FBML. I know the "send" button has been cited, but it doesn't really work the same way. Is the "invite friends" application extinct?
application
fbml
facebook-user-support
null
null
null
open
Creating an "Invite Friends" Tab on Fan Page in iFrame === I've found many online tutorials about how to create an FBML tab on a fan page that lets fans invite their friends to the page, but all of these tutorials are outdated because it became impossible to create new FBML taps after March 11th. So I'm wondering now how to create an "invite friends" tab on my facebook fan page NOT using FBML. I know the "send" button has been cited, but it doesn't really work the same way. Is the "invite friends" application extinct?
0
3,284,406
07/19/2010 19:39:58
344,769
05/19/2010 05:58:50
2,057
154
A nonce for each function or one for all AJAX calls?
I'm using nonces as WordPress uses them. It's an extra security measure, a hash that is being sent to the server that changes within ever few hours. If that hash is not there, the request is invalidated. The page I am working on has *many* AJAX calls (about 20 or so). Right now, I have a difference unique nonce for each one. Is that necessary? Should I just keep it with one generic "AJAX" nonce used for all the requests?
javascript
jquery
ajax
wordpress
nonce
null
open
A nonce for each function or one for all AJAX calls? === I'm using nonces as WordPress uses them. It's an extra security measure, a hash that is being sent to the server that changes within ever few hours. If that hash is not there, the request is invalidated. The page I am working on has *many* AJAX calls (about 20 or so). Right now, I have a difference unique nonce for each one. Is that necessary? Should I just keep it with one generic "AJAX" nonce used for all the requests?
0
9,528,484
03/02/2012 05:32:28
960,526
09/23/2011 06:23:03
322
16
Email attachment open in application?
I am not sure whether it is applicable or not in an Android? I had received an email with an attached .CSV file...Now when I will click on that attachment then It could give me an option to open this attachment in xyz application..I want to implement this only on .csv attached file. Please give me some hint that Is it possible ?? Thanks..
android
null
null
null
null
null
open
Email attachment open in application? === I am not sure whether it is applicable or not in an Android? I had received an email with an attached .CSV file...Now when I will click on that attachment then It could give me an option to open this attachment in xyz application..I want to implement this only on .csv attached file. Please give me some hint that Is it possible ?? Thanks..
0
8,924,060
01/19/2012 09:58:34
634,042
02/25/2011 11:39:47
509
13
Is there any major difference when we compare the efficiency of VB.NET and C#?
For example, when the codes are compiled, will VB.NET tend to be slower than C#? Or are there any major features in VB.NET / C# that we cannot find in the other language?
c#
vb.net
null
null
null
01/19/2012 10:21:27
not constructive
Is there any major difference when we compare the efficiency of VB.NET and C#? === For example, when the codes are compiled, will VB.NET tend to be slower than C#? Or are there any major features in VB.NET / C# that we cannot find in the other language?
4
10,907,906
06/06/2012 03:44:12
1,435,615
06/04/2012 16:45:19
1
0
linux Wget command to save complete webpage?
linux Wget command to save complete webpage? (like save as option on firefox, chrome). i'm unable to get exact command. Could u help to find out a way? I went thru many websites but unable to find suitable one for my requirement?. i would like to set a cronjob to save all these page to do automate? Thanks in advance. Rajkumar
linux
null
null
null
null
06/06/2012 03:54:31
off topic
linux Wget command to save complete webpage? === linux Wget command to save complete webpage? (like save as option on firefox, chrome). i'm unable to get exact command. Could u help to find out a way? I went thru many websites but unable to find suitable one for my requirement?. i would like to set a cronjob to save all these page to do automate? Thanks in advance. Rajkumar
2
1,705,008
11/10/2009 00:55:24
154,011
08/10/2009 22:09:01
125
9
simple proof that GUID is not unique
I'd like to proof that a GUID is not unique in a simple test program. I expected this to run four hours but it's not working. how can I do? BigInteger begin = new BigInteger((long)0); BigInteger end = new BigInteger("340282366920938463463374607431768211456",10); //2^128 for(begin; begin<end; begin++) Console.WriteLine(System.Guid.NewGuid().ToString()); Using c#
guid
c#
null
null
null
04/26/2012 10:14:26
not constructive
simple proof that GUID is not unique === I'd like to proof that a GUID is not unique in a simple test program. I expected this to run four hours but it's not working. how can I do? BigInteger begin = new BigInteger((long)0); BigInteger end = new BigInteger("340282366920938463463374607431768211456",10); //2^128 for(begin; begin<end; begin++) Console.WriteLine(System.Guid.NewGuid().ToString()); Using c#
4
9,063,323
01/30/2012 11:42:25
614,026
02/12/2011 07:28:17
1
0
how do I exclude MS Word created junky chars in regEx with php
i read the MS Word document with $text = fread($filename, $filesize); then when I echo the $text it has some chars that browser cannot display properly and outputs some junky chars. I think regEx would help. Can anybody help with it?
php
regex
ms-word
null
null
null
open
how do I exclude MS Word created junky chars in regEx with php === i read the MS Word document with $text = fread($filename, $filesize); then when I echo the $text it has some chars that browser cannot display properly and outputs some junky chars. I think regEx would help. Can anybody help with it?
0