Posts

Showing posts from January, 2014

Africa and the Commonwealth of Nations

Africa and the Commonwealth of Nations 1.Africa and the Commonwealth of Nations - About.com African History Description:18 countries in Africa are currently part of the Commonwealth of Nations (with Zimbabwe having departed in 2003). 2.Commonwealth of Nations - Wikipedia, the free encyclopedia Description:The Commonwealth of Nations, commonly known as the Commonwealth (formerly, the British Commonwealth is an intergovernmental organisation of 53 member states that were ... 3.Member states of the Commonwealth of Nations - Wikipedia, the ... Description:The Commonwealth of Nations is a voluntary association of 53 independent sovereign states ... South Africa, the Irish Free State, and Dominion of Newfoundland, ... 4.Home | Commonwealth of Nations Description:MINING: Commonwealth nations rank in the top tier of producers of gold, diamonds, platinum and other metals. ... Africa; Americas; Asia; Europe; Pacific. About Us. 5.Alphabetical

This Day in African History: July 01

This Day in African History: July 01 1.This Day in African History: July 01 Description:A chronicle of events in African history on 1 July ... 1942, 1 July - World War II: North Africa Hampered by sandstorms, General Erwin Rommel's PanzerArmee Afrika ... 2.On this day, 01 January, in African-American history ... Description:It was on 2 March 1807 that the US Congress passed an act abolishing the international slave trade, but it was not to take effect until this day, 01 January 1808. 3.This Day in African History: January 01 Description:A chronicle of events in African history on 1 January. ... 1935, 1 January Italian colonies of Tripoli, Cyrenaica and Fezzan are merged to form Libya. 4.This day in African-American History - 01 January - National ... Description:This day in African-American History - 01 January. See also. Community; Shirley Chisholm; ... This day in Black History - 01 January 2012 image created by Faydra Deon 5

Sauer Commission and Report

Sauer Commission and Report 1.Sauer Commission and Report - About.com African History Description:Definition: The Sauer Report became the ideological framework upon which Apartheid was enacted. It was prepared for the opposition Herenigde Nasionale Party (HNP ... 2.Sauer Commission - Wikipedia, the free encyclopedia Description:The Sauer Commission (South Africa), was created in 1947 largely in response to the Fagan Commission. It was appointed by the Herenigde Nasionale Party and favoured ... 3.Sauer Commission and Report - About.com African History Description:24-03-2011 · Prepared for the opposition Herenigde Nasionale Party in advance of the 1948 general election as a policy document, the Sauer Report became the ideological 4.Fagan Commission - Wikipedia, the free encyclopedia Description:The Native Laws Commission, commonly known as the Fagan Commission, was appointed by the government of South Africa in 1946 to investigate changes t

Guinea-Bissau -- A Very Short History of Guinea-Bissau

Guinea-Bissau -- A Very Short History of Guinea-Bissau 1.Guinea-Bissau -- A Very Short History of Guinea-Bissau Description:A Very Short History of Guinea-Bissau. By Alistair Boddy-Evans. Definition: 2.Country History - Guinea-Bissau - About.com African History Description:A Very Short History of Guinea-Bissau ... A chronology of important events in the history of Guinea-Bissau given by year (and for more recent events by month also). 3.Guinea-Bissau - Wikipedia, the free encyclopedia Description:Guinea-Bissau, officially the ... Guinea-Bissau has a history of political instability since gaining independence, ... but remains short: ... 4.Guinea-Bissau - A short history lesson - what do you know ... Description:Guinea-Bissau - A short history ... From the very start, the people of Guinea-Bissau belived in what they were ... Guinea-Bissau remained ... 5.History - Guinea-Bissau | Centre for Intercultural Learning Description:... so

Undefined variable error in php while updating value from android -

Image
i trying update field in database getting undefined variable error php page... my code is: intent myintent = getintent(); //mdate = intent.getstringextra("mdate"); //toast.maketext(getapplicationcontext(), mdate.tostring(), toast.length_long).show(); title=(edittext)findviewbyid(r.id.edittext1); bundle extras = getintent().getextras(); if(extras != null){ mtitle = extras.getstring("title"); stime = extras.getstring("mtime"); sdate = extras.getstring("mdate"); cvenue = extras.getstring("venue"); } title.settext(mtitle); title.setfocusable(false); cdate=(edittext)findviewbyid(r.id.edittext2); cdate.settext(sdate); cdate.setfocusable(false); venue=(edittext)findviewbyid(r.id.edittext4); venue.settext(cvenue); venue.setfocusable(false); ctime=(edittext)findviewbyid(r.id.edittext3); ctime.settext(stime); ctime.setfocusable(false); fdate=

javascript - Changing the background color of a :before element based on a php variable -

i'm trying change background color of :before element php variable. variable neatly returns hex code #123456. tried piece of jquery/javascript working, isn't. know i'm doing wrong? <script> $(document).ready(function(){ $('#tpl-contact:before').css("background", "<?=$scolor;?>"); }); </script> try not using jquery that. html , css should suffice. another way find out how works step step, e.g. does: $('#tpl-contact:before').css("background", "#123456"); already want do? if yes, continue, if not, have excluded php culprit. way. the question "how access style properties of pseudo-elements jquery?" might have additional pointers well.

object - JavaScript and square bracket notation -

i new in java script. in both of books: http://www.larryullman.com/books/modern-javascript-develop-and-design , http://www.packtpub.com/object-oriented-javascript/book both authors saying notation: object[unknownyetproperty] should work when have object , variable objects future property. problem 2 others notation works object['unknownyetproperty'] , object.unknownyetproperty not first one. var a1 = 'spring'; var a2 = 'autumn'; var a3 = 'summer'; var object = { propertya1 : a1, // according books should work :-/ propertya2 : a2, propertya3 : a3 } console.log(object[propertya1] + ' ' + object['propertya2'] + ' ' + object.propertya3); the working example: http://jsfiddle.net/cachaito/p78le could explain me? propertyal doesn't exist. reason string literal , dot notation work because correctly accessing properties of object. in first one, trying access object[undefined] because propertya1 is

sql server - Copy One Column value of one table into column of another table -

i have product table , location table in sql server 2008. want insert productid of product table productid column of location table using sql script. , insert other columns value of location table static,but productid column value want insert product table using sql script. please me? without knowing table structure, , assuming field1 varchar , field2 int can this: insert locationtable (productid, field1, field2) select productid, 'field1', 10 producttable ....

python - Having Qt.CustomizeWindowHint with Icon -

on winxp pythonxy , according qtdesigner etc. have small app qmainwindow calls modal qdialog. ensure close() action performed pushbutton provide, removed min/max/close titlebar mydialog.setwindowflags(qt.customizewindowhint | qt.dialog | qt.windowtitlehint) . first of have rather strange have provide qt.dialog flag well, otherwise dialog not show. in contrast main window shows when providing qt.customizewindowhint only. my main problem, however, set icon. on main window mymain.seticon(myicon) works fine. if dialog gets additional flag qt.windowminimizebuttonhint shows max/close disabled, can set icon well. in principle ok, want avoid closing [x] button. nevertheless, not satisfying. how set icon no min/max/close in titlebar? on forum found, e.g. thread seticon in win7 , seems hande win7 problems. furthermore, ctypes not seem have ctypes.windll.shell32 (python3 ?). there hasicon missing , have use before can seticon(qicon) ?

java - Error using persist() -

i have code: user.setfirstname(requ.getparameter("nombre")); user.setlastname(requ.getparameter("apellidos")); user.setemailaddress(requ.getparameter("email")); user.persist(); and i'm getting error: validation failed classes [com.springsource.marshall.domain.user] during persist time groups [javax.validation.groups.default, ] list of constraint violations:[ constraintviolationimpl{interpolatedmessage='no puede ser null', propertypath=emailaddress, rootbeanclass=class com.springsource.marshall.domain.user, messagetemplate='{javax.validation.constraints.notnull.message}'} constraintviolationimpl{interpolatedmessage='no puede ser null', propertypath=password, rootbeanclass=class com.springsource.marshall.domain.user, messagetemplate='{javax.validation.constraints.notnull.message}'} constraintviolationimpl{interpolatedmessage='no puede ser null', propertypath=firstname, rootbean

java - Constant interpreted as expression in QueryDSL -

i have following query: dateexpression<date> enddateplus7 = datetemplate.create(date.class, "date_add({0},interval {1} day)", buy.enddate, expressions.constant(7)); booleanexpression exp = ad.brandsurveytype.ne(brandsurveytype.none).and((buy.status.eq(newbuystatus.closed).and(buy.enddate.after(enddateplus7))).not()); query.where(exp); when looking query string generated, querydsl interprets "7" constant expression evaluated , following error produced: line 4:113: unexpected token: ? @ org.hibernate.hql.internal.antlr.hqlbaseparser.identprimary(hqlbaseparser.java:4016) @ org.hibernate.hql.internal.antlr.hqlbaseparser.primaryexpression(hqlbaseparser.java:859) @ org.hibernate.hql.internal.antlr.hqlbaseparser.atom(hqlbaseparser.java:3390) @ org.hibernate.hql.internal.antlr.hqlbaseparser.unaryexpression(hqlbaseparser.java:3168) @ org.hibernate.hql.internal.antlr.hqlbaseparser.multiplyexpression(hqlbaseparser.java:3040) @ org.hibe

Is it possible to have the Windows Azure emulator open the browser to a URL other than 127.0.0.1 -

Image
simple question lots of meaning/discussion behind!!! is possible have windows azure emulator open browser url other 127.0.0.1 , port 81? follow steps change 127.0.0.1 desire ip compute emulator settings: go %program files%\microsoft sdks\windows azure\emulator\devfabric take backup of “devfc.exe.config” if goes can revert back. change following settings desired ip address range , subnet: <add key="startipaddress" value="192.168.0.20"/> (this can ip address on machine) <add key="endipaddress" value=”192.168.0.40" /> <add key="vippoolstartipaddress" value="127.0.0.1" /> <add key="vippoolendipaddress" value="127.0.0.255" /> <add key="defaultgateway" value="192.168.0.1" /> <add key="subnetmask" value="255.255.255.0" /> save config file. restart compute emulator. storage emulator settings: go

javascript - React to 303 status code in jquery ( Prevent from redirecting) -

when send requests server, 303 response come, followed requested response in combination 200 status code. funny thing see on developer console's network view. when checking statuscode , response of $.ajax() request, there response of second request, 200 http status code. the problem seems second request being cached (though 200 status code), , need non-cachable. therefore i'd intervene forwarding process occurs http 303 status code. i'd jquery function check status code, send request explicit headers, tell server not cache response. well, don't know how this, since (as mentioned above) jquery.ajax method respond forwarded request's response , status code (200). can me? edit 10.3.4 303 see other the response request can found under different uri , should retrieved using method on resource. method exists allow output of post-activated script redirect user agent selected resource. new uri not substitute reference requested resource. 303

jquery - Weird issue in IE7 Only not in any other browser -

it simple html , have jquery-ui(1.10) , jquery (1.9.1) . works fine in ie8,9 ,firefox , in chrome in ie 7 html has below. have no idea , piece of code not there when see html in ie8,9 , firefox , chrome sizzle-1367496452938="[object object] and all div tags injected this jquery191030626454110549073="6" here part of html this.anyone knows issue is? <html sizzle-1367496167699="[object object]"> <div class="container" id="container2" sizzle-1367496452938="[object object]"> <div class="arrow-left" id="wppanelstatus" style="width: 1%;" jquery191030626454110549073="6"/> update not using sizzle javascript selector library this jquery uses attach event handlers etc in ie. it's called expando. it's string 'jquery' + timestamp (in essence unique value). and jquery depends on sizzle using it.... you

c# - Custom HtmlHelper for a dropdownlist shows all the values as plain text instead of building a dropdownlist -

i have tried build custom dropdownlist using method here: http://blog.platformular.com/2011/12/16/country-drop-down-html-helper-for-asp-net-mvc/ basically, helper loads html file, populates dropdownlist based on information found in file. but rather building dropdownlist, app shows data in view way: country: <select name="countrycode" id="countrycode"><option value="">please select</option><option value="af" >afghanistan</option><option value="al" >albania</option><option value="dz" >algeria</option><option value="as" >american samoa</option><option value="ad" >andorra</option><option value="ao" >angola</option><option value="ai" >anguilla</option><option value="aq" >antarctica</option><option value="ag" >antigua , barbuda</option>&

java - org.scribe.exceptions.OAuthException: Response body is incorrect. Can't extract token and secret from this: 'Invalid request token' -

hi can someon me code goes great till point token accesstoken = service.getaccesstoken(requesttoken, verifier); after error error com.opensymphony.xwork2.interceptor.exceptionmappinginterceptor- response body incorrect. can't extract token , secret this: 'invalid request token' org.scribe.exceptions.oauthexception: response body incorrect. can't extract token , secret this: 'invalid request token' new in java , scribes import org.scribe.builder.*; import org.scribe.builder.api.*; import org.scribe.model.*; import org.scribe.oauth.*; import com.opensymphony.xwork2.actionsupport; public class signintwitter extends actionsupport { private static final long serialversionuid = -4223895098942228518l; private static final string protected_resource_url = "https://api.twitter.com/1/statuses/update.json"; public string execute() { oauthservice service = new servicebuilder().provider(twitterapi.class) .apikey("xxxxxxxxxxxxxxxxx&quo

Why to opt for dynamic_cast in C++ -

this question has answer here: regular cast vs. static_cast vs. dynamic_cast [duplicate] 8 answers consider below code: #include <iostream> using namespace std; class base{ int i; public: virtual bool basetrue() {return true;} base(int i) {this->i=i;} int get_i() {return i;} }; class derived : public base{ int j; public: derived(int i,int j) : base(i) {this->j=j;} int get_j() {return j;} }; int main() { base *bp; derived *pd,dob(5,10); bp = &dob; //we trying cast base class pointer derived class pointer cout << bp->get_i() << endl; cout << ((derived *)bp)->get_j() << endl;**//here1** pd=dynamic_cast<derived*> (bp); **//here2** // if base class not polymorphic //throw error //error: cannot dynamic_cast `bp' (of type `clas

css - how to format the border radius in groupbox XUL -

i have 1 groupbox control in xul: <xul:groupbox id="gblogin" style="margin-top:50px;-moz-border-radius:10px;"> <xul:caption label="log in" style="color:red;font-size:20px;" /> <xul:hbox style="margin-left:340px;margin-right:280px;"> </xul:hbox> </xul:groupbox> but -moz-border-radius property not working in xul application. taking default border-radius. how can achieve this?

Optimizing database inserts java -

i relatively new java , database , therefore asking code optimization. have around 20 text files comma separated values.each text files has around 10000 lines based on the 3rd value in each line, insert data different tables. each time check 3rd value , use different methods save data. code follows. please tell me if proper way operation. in advance. public void readsave() throws sqlexception { file dir = new file("c:\\users\\log"); string url = config.db_url; string user= config.db_username; string password= config.db_password; con= drivermanager.getconnection(url, user, password); con.setautocommit(false); string currentline; if (!dir.isdirectory()) throw new illegalstateexception(); (file file : dir.listfiles()) { bufferedreader br; try { br = new bufferedreader(new filereader(file)); while ((currentline = br.readline()) != null) { list<string> values = arrays.a

java - Jackrabbit RMI lucene conflict -

i wish integrate jackrabbit 2.x in application versioning of data. my application has dependency on lucene 2.9.1 the problem jackrabbit dependent on higher version of lucene ( 3.6 ) , result can not place jackrabbit-core jar in same classpath application conflicts lucene jars. seeing prefer not implement webdav client thought using rmi implementation, however, see jackrabbit-rmi jar dependent on jackrabbit-core , lucene. is there way work around use jackrabbit rmi in application? or there other solution allow me use jackrabbit without upgrading lucene jars? you try using jarjar repackage newer lucene package , use there.

How can I use SQL to find records where say an author has multiple books with different page counts? -

say have table of books columns author_name, book_name, , page_count. how write sql find me instance author has written multiple books , @ least 2 books same author have different page counts? i've managed retrieve list of authors multiple books by select author_name books group author_name having count(book_name) > 1 which believe that, how check each book compare page counts? you can try this: select author_name books group author_name having count(distinct page_count) > 1 this doesn't multiple books, because if there multiple page counts, there multiple books. for performance reasons, use this: select author_name books group author_name having min(page_count) <> max(page_count) usually, count(distinct) more expensive doing min() , max() . if want list of books, join list. here example using in subquery: select b.* books b b.author in (select author_name books group author_name

jQuery Dialogs wont stay in container div when opened -

i'm working code open multiple dialogs in cascading fashion in desktop type environment. issue keeping dialogs opening outside container "#desktop" div. have tried containment option, using positioning option at: , within: no luck. can set draggable option div #desktop , stays in div correctly. have fiddle setup testing here . here code far: var dialogoffset = { top: 10, left: 200 }; $('button').click(function () { var parent = $('#desktop'); var parentpos = parent.offset(); var parentindex = $('#desktop').index(parent); var numdialogs = $('.dlg' + parentindex).length; var dialogtop = parentpos.top + dialogoffset.top + numdialogs * 30; var dialogposition = [parentpos.left + dialogoffset.left + numdialogs * 30, dialogtop]; $('<div class="dlg' + parentindex + '"></div>').dialog({ position: dialogposition, width: 250, close: function () {

java - Where to put resources for ClientBundle in GWT? -

i want keep static resources out of class tree, have them in src/main/resources tree. though should found using same path java class, like: package my.path.to; class resourcebundle extends clientbundle { @source("src/main/resources/my/path/to/resourcebundle/myicon.png") imageresource myicon(); } do have write @source path reference them? or can somehow tell clientbundle in same dir java class, in resources? by default in same directory java class. typically put graphics in sub package of resorces package. keeps java clean , separated , don't have absolute path. believe ../ relative path works if wanted way seems more clean me put images in sub package of resources. com.vf.client.resources com.vf.client.resources.images com.vf.client.resources.css /** * draggable cursor icon. * * <br /> * example * * <img src="images/cursordragarrowsmall.png" /> * @return imageresource */ @source("images/cursordragarrows

Looping through a csv file to insert data to MySQL using php mysqli prepared statements -

ok i'll start code: include('connect.php'); // prepared statement, prepare if (!($stmt = $mysqli->prepare("insert funddata(ticker, pricedate, price) values (?, ?, ?)"))) { echo "prepare failed: (" . $mysqli->errno . ") " . $mysqli->error; } //bind parameters query $csvdata = array("","",""); //initialise $csvdata array $pricedate = date($csvdata[1]); $stmt -> bind_param("ssd", $csvdata[0], $pricedate, $csvdata[2]); $file_handle = fopen($csvfile, "r"); while (!feof($file_handle) ) { $csvdata = fgetcsv($file_handle, 1024); $pricedate = date($csvdata[1]); echo $csvdata[0] . "; " . $pricedate . "; ". $csvdata[2] . "<br/>"; //run insert statement $stmt->execute(); } fclose($file_handle); this fails insert data database table, although result in load of blank rows being inserted. the csv d

javascript - error when compiling action tag in a button with handlebars.js -

i've code in template: <button type="submit" id="button_login" class="common_button" {{action "login" email password }}>accedi</button> when compile error: uncaught error: parse error on line 22: ...mon_button" {{action="" "login"="" email -----------------------^ expecting 'close', 'data', 'string', 'integer', 'boolean', 'id', 'sep', got 'equals' handlebars-1.0.0-rc.3.js:286 does know why?? in advance!

cruisecontrol.net - Can I check for modifications on a different path to the one that is checked out? -

i have project sourcecontrol block has trunk url value. i use intervaltrigger modification exists property. i'd build if there modifications in sub path of trunk url, know how might that? please check following post, think it's related: how customize buildcondition="ifmodificationexists" on cruisecontrolnet build? and there's filtered source control block should need: http://cruisecontrolnet.org/projects/ccnet/wiki/filtered

android - How to attach database file to an app -

i have been given task of writing app displays information stored within sql-lite database file (which i've been given) - i'm wondering how arrange database file ends in right location on users device. somehow compile in apk? imho, best solution use sqliteassethelper , provides support required scenario.

html - Vertically and Horizontally Aligning in CSS -

i'm having trouble getting form align both vertically , horizontally. i don't mind if doesn't support ie--i plan on implementing ie detection script tell user use different browser--but support firefox , chrome must. here have: html <!doctype html> <head> <link rel="stylesheet" type="text/css" href="global.css"> <link rel="stylesheet" type="text/css" href="index.css"> </head> <body> <div id="wrapper"> <div id="logo_div"> <img src="../images/logo.png" id="logo"> </div> <div id="login"> <form name="searchform" action="checklogin.php" method="post" id="login_form"> <br> user name : <input type="text" name="myusername" size="16

How can this number be converted into bit in c++? -

i wish convert numbers 0x030c30c3 , 0x09249249 bit. how can that? the binary representation can accessed , manipulated through std::bitset : std::bitset<32> var(0x030c30c3); std::cout << var; // binary representation

c++ - Define const object in a header file -

i have question concerning const keyword in c++. have following class: foot.h class foot { public: foot (bool isrightfoot); const vector internfootaxis; const vector externfootaxis; bool isrightfoot; private: body* body; } where vector class implementing basic r^3 vector operations. internfootaxis denotes vector goes center of foot (represented body object - class representing physical object) big toe. externfootaxis denotes vector goes center of foot little toe. i want initial value of internfootaxis , externfootaxis const (because applying operators @ each iteration in graphical display main loop vectors change inner state of vector). unfortunately, values of internfootaxis(t=0) , externfootaxis(t=0) depends if considering left or right foot, therefore need declare values inside constructor of foot , not outside class. technically want following foot.cpp foot::foot(bool isrightfoot) { body = new body(); if (isrightfoot) { internfoot

c - Doxygen document possible parameter values -

currently c-code function declaration documented follows /** fubar function *@param[in] val1 first input variable *@param[in] val2 second input variable */ void foo (int val1, int val2); but parameters can except numbers within range, e.g., 0-500 is possible document other part of parameter description? maybe shows separately in produced documentation? e.g. in latex-produced pdf table produced cell parameter type (int) direction (in) , name (var1/var2). there way of having table cell 0-500? your best bet may table in detail section. doxygen supports html commands inside documentation, , table generated in pdf looks decent. /** * @brief fubar function * @param[in] val1 first input variable * @param[in] val2 second input variable * * <table> * <tr><td>type</td><td>direction</td><td>name</td><td>value range</td></tr> * <tr><td>int</td><td>in&l