Posts

jsp - How to loop the value stored in session? -

sorry interrupt of you. i have question session. in case, need check session has stored value or not. if session not null, want loop value comparison. now, use if statement check last record of book id repetitive or not. but don't know how use loop check there book id repetitive or not. would 1 provide advice me acheive goal? many thanks. here source code: <%@ page contenttype="text/html; charset=big5"%> <%@ page import="java.io.*" %> <%@ page import="java.sql.*" %> <%@ page import ="javax.sql.*" %> <%@ page import="java.util.*" %> <%@ page import="java.lang.*"%> <%! public class bookinfo { private string id; private string name; private int count; public bookinfo(string id, string name, int count) { this.id = id; this.name = name; this.count = count; } public string ...

android - Image sd card path from intent gallery -

i starting gallery through intent otherwise giving problem display gallery in grid view. want actual sd card path of image selection gallery, opened intent. here code.. intent photopickerintent = new intent(intent.action_get_content); photopickerintent.settype("image/jpg"); photopickerintent.putextra(intent.extra_stream, uri.parse("file:///sdcard/pictures/image.jpg")); startactivityforresult(photopickerintent, 1); protected void onactivityresult(int requestcode, int resultcode, intent intent) { super.onactivityresult(requestcode, resultcode, intent); if (resultcode == result_canceled) { showtoast(this,"activity cancelled"); return; } else if(resultcode == result_ok) { system.out.println("requestcode--"+requestcode); system.out.println("resultcode--"+resultcode); system.out.println("data--"+intent.g...

python - What is the trick in this website? -

i can access webpage in firefox browser: http://www.ip-adress.com/ip_tracer/74.82.190.99 can information ip. however, when fetch using python, there errors: import urllib f = urllib.urlopen("http://www.ip-adress.com/ip_tracer/74.82.190.99") print f.read() i error: <!doctype html public "-//ietf//dtd html 2.0//en"> <html><head> <title>403 forbidden</title> </head><body> <h1>forbidden</h1> <p>you don't have permission access /ip_tracer/74.82.190.99 on server.</p> </body></html> i take page's source code: <form action="/ip_tracer/" method="post"> <div> <input id="ipqry" name="qry" type="text" value="74.82.190.99" size="18" maxlength="255" onclick="cleanup(this)"> <input type="submit" value="track ip, host or website" onclick="progress...

iphone - Ads providers for mobile application -

i monetize free mobile application of ads. what mobile ad solutions available on market? have dedicated sdk android or iphone? only solution know admob. are there solutions dedicated central european market? there many avaliable like: admob greystrip mobclix and iphone iad

.net - WPF Editable ComboBox Text Search Behavior -

i have combobox binded entity observablecollection on itemssource. this: key desc1 desc2 c0001 mydesc mydesc d0001 mydesc mydesc a0001 mydesc mydesc the combobox defined: <combobox iseditable=true displaymemberpath="key" selectedvaluepath="key" itemssource="{binding path=mylist, mode=oneway}" /> now have problem... if type character on empty editable textbox of combobox, first element "startswith" typed character matched. so, if type "c", selecteditem element "c0001"...and avoid this! i different search logic find selecteditem based on full text typed. in way: text typed selecteditem c null c0 null c00 null c000 null c0001 [c0001, mydesc, mydesc] ok! is possible? how can do? this behaviour has been combos in windows. if want this, you're better off search field , pickable list of results. ...

ASP.Net calculate City from ZIP? -

i have user registration. in this, of course, user must enter zip. now make way in city calculate zip. the idea have myself database-table (or txt-file) , in table / file city. is best / fastest way or there another? hosting database 1 possibility, use service on cloud. here's 1 such service .

Easier way to run a Java application from Maven? -

if have understood correctly, need type run project maven: mvn compile mvn exec:java -dexec.mainclass="com.foo.bar.blah.main" is there way can make simpler? optimally do mvn run 1) create new profile called "run" (or name of choice) <profiles> <profile> <id>run</id> 2) set profile's default goal "verify" (or can choose "install", choosing phase after compile ensure code automatically compiled before running class) <profiles> <profile> <id>run</id> <build> <defaultgoal>verify</defaultgoal> 3) add exec-maven-plugin profile (see this ), configure run in 'verify' phase. <execution> <phase>test</phase> 4) can run class using following: mvn -prun