Posts

windows - Clang's equivalent to GCC's -mwindows -

i know how instruct gcc (using the -mwindows flag ) generate pe using image_subsystem_windows_gui instead of image_subsystem_windows_cui windows subsystem . does clang offer equivalent flag? if not, how can change generated executable's windows subsystem (preferable using open source software)? try with -wl,--subsystem,windows there native , console , posix available use.

php - convert a string into array and get values from that array -

i stored array {"10":"10","14":"14","16":"16","25":"25"} string in data base, right tried number above string. tried explode , str_replace can't data, can please me. this json object have decode json_decode , take values array_values : $values = array_values(json_decode($string, true));

html - IMG in <li> to dynamically scale down as the browser window and/or screen resolution is smaller? -

i have logo in navbar, want resize automatically screen sixe/resolution changes. please see code below: tried img css, doesn't seem work. img { max-width: 100%; height: auto; width: auto\9; /* ie8 */ } <ul class="s5_1"> <div> <li>img src="assets/img/logoonly.jpg"></li> </div> <br/> <br/> <br/> <br/> <br/> <ul style="float:right;list-style-type:none;"> <li><a class="active style2" href="index.html">home |</a></li> <li><a href="about.html"> | </a></li> <li><a href="vission.html"> vision | </a></li> <li class="dropdown"> <a href="#" class="dropbtn"> products | </a> ...

Crystal Reports: why is memo-type field truncated at 255 characters? -

i'm working in crystal reports xi (11.5.12.1838) running on remote windows system , accessed via citrix. data coming blackbaud raiser's edge export. i have 2 different custom reports need display note (from raiser's edge) can of length. in both cases, database line dragged , dropped field in report. it's set grow no maximum. in 1 report, works; in other, not, truncates text @ 255 characters (or perhaps bytes: rtf version cut off earlier in text). the criteria reports different (one reporting on single constituent, other [which doesn't work] on constituents connected specific individual). however, don't know enough might cause problem narrow down aspects of report configuration need adjustment. any ideas? i'll note in broken report field grows correctly , type 'memo' -- grows enough hold 255 characters , stops. edit: no, formula fields aren't involved. can't split string in database. edit 2: thank suggestions. database up-to-date...

c++ - Error is generated with the sort method while sorting the values inside a vector -

when compiling below code using g++ in debian machine, following errors generated...can pls me why error are? tried commenting sort line error dissappears our task requires sorting done can possible solution code: #include <iostream> #include <vector> #include <algorithm> using namespace std; // here simple struct struct mystruct { int num; // define operator < bool operator <(const mystruct& rhs) { return (num < rhs.num); } }; int main() { vector<mystruct> myvector; // let size 5. myvector.resize(5); // push 5 instances of mystruct num ranging // 5 1 mystruct teststruct; int = 0; (i = 0; < 5; ++i) { teststruct.num = 5 - i; myvector[i] = teststruct; } // sort vector sort(myvector.begin(), myvector.end()); // try display num each element. sorted (i = 0; < 5; ++i) { cout << myvector[i].num << '\n'; } return 0; } output...

python - Not getting Exact result in pandas -

df=pandas.dataframe(processed_data_format, columns=["file_name", "innings", "over","ball", "individual ball", "runs","batsman", "wicket_status","bowler_name","fielder_name"]) = {'runs':['sum'],'ball':['sum'],'file_name':['unique']} t = df.groupby('batsman').agg(a) after running code getting result like ['younis khan', array(['225245', '225247'], dtype=object), 113, 121] but result like ['younis khan', 2 , 113, 121] instead of array(['225245', '225247'], dtype=object) need count of file name

php - How to echo JSON doubly nested object literal w/ proper "headers" -

Image
i'm trying echo json object literal includes every row in database table. as standard methods found in many other similar questions looked at, i'm fetching every row , encoding so: $con=mysqli_connect("localhost","username","pass","markers");//markers db table name $result = mysqli_query($con,"select * markers"); $rows = array(); while($r = mysqli_fetch_array($result)) { $rows[] = $r //or: $rows[] = array('data' => $r); } echo json_encode($rows); similarly question php: can't encode json multiple rows or mysql table json , i want echo json object looks this: { "data1": // how "data1"? { name: john smith, title: mr, description: man } } { "data2":{ // how "data2"? name:bob smith, title: mr, description: guy } } exc...