Posts

Showing posts from September, 2010

How can I get to WIFI Direct Screen by code in Android? -

this thread answered question going wifi setting screen. however, direct user wifi direct screen when exists on device. how can that? there no standard intent structure go settings screen related wifi direct.

cmake - Bad Reloc Address using MinGW -

i use mingw on windows 7 64bit. i used google test netbeans (followed bo qian instruction: http://www.youtube.com/watch?v=ts2ctf11k1u&feature=c4-overview-vl&list=pl5jc9xfgsl8gyes7nh-1yqljjdtvifssh&hd=1 ) , worked correctly. tried link google mock (with google test inside) project. used cmake , cmakelists.txt file: cmake_minimum_required(version 2.8) project(fs_report) include_directories(${project_source_dir}) set(cmake_cxx_flags_debug "-g -wall -std=c++11") set(google_mock gmock-1.6.0) add_subdirectory(${google_mock}) include_directories(${project_source_dir}/${google_mock}/include) include_directories(${project_source_dir}/${google_mock}/gtest/include) add_subdirectory(source) enable_testing() file(make_directory ${project_binary_dir}/tests) set(testnames aircraft airport exception flightlevel flightnumber pilotid registration remarks route) foreach(test ${testnames}) add_executable(tests/${test}.test tests/${test}test.c

algorithm - In-place QuickSort in Python -

i had implement quicksort algorithm homework in language of choice , chose python. during lectures, we've been told quicksort memory efficient because works in-place; i.e., has no additional copies of parts of input array recursions. with in mind, tried implement quicksort algorithm in python, shortly afterwards realized in order write elegant piece of code have pass parts of array function while recursing. since python creates new lists each time this, have tried using python3 (because supports nonlocal keyword). following commented code. def quicksort2(array): # create local copy of array. arr = array def sort(start, end): # base case condition if not start < end: return # make known inner function work on arr # outer definition nonlocal arr = start + 1 j = start + 1 # choosing pivot first element of working part # part of arr pivot = arr[start] # start partit

php - Adding a class to the last listed item -

i list latest 5 events on 1 section of website. , every time item listed, has divider @ bottom. want add last last <li> divider disappear on last item. so changed <li class="clearfix"> <li class="clearfix last"> . how can it? fyi, <?php $icounterli++; ($icounterli==5)? 'last':''; ?> wont work because may have less 5 upcoming events time time. thanks! <?php $get_latest_events = get_latest_events(5); if(count($get_latest_events) > 0) { foreach($get_latest_events $eventdata) { $entity_data = node_load($eventdata->entity_id); $event_start_date = check_isset_start_date($entity_data,'event_calendar_date','und'); if($event_start_date !='') { $explode_event_date = explode(" ",$event_start_date); $explode_event_day = strtotime($explode_event_date[0]); $explode_event_time = $explode_event_date[1]; $event_start_day1 = strf

ruby on rails - Nested Routes alternative -

i having problems nesting resources. want find out if there better way of doing things. i have to-do list application 3 resources user, list , task. each user has his/her own todo list. my question how else can set associations , routes prevent me nesting 3 layer deep in route file. resources :users resources :list resources :task end end end i want prevent that. cheers since user can see her/his own lists , tasks, don't have nest these resources. define them separately in routes file: resources :users resources :lists resources :tasks end and retrieve current user authentication framework: class listscontroller < applicationcontroller def index @lists = current_user.lists end end

ios - Cannot determine when UIImageView frames are equal -

i have 2 layers. bottom layer consists of hidden uiimageview s, upper layer consists of visible uiimageview s. when frames of bottom layer uiimageview s equal frames of upper layer uiimageview s, have see in nslog . the problem boolean method called nstimer returns true immediately, see nslog . want see nslog when corresponding frames equal each other. this code: - (void)checktheframes { bool allequals = [self isequalframes]; if (allequals) { nslog(@"all frames equal"); [allposcorrecttimer invalidate]; } } -(bool)isequalframes { for(int = 0; < arrayimg.count; i++ ){ uiimageview *imageview1 = arrayimg[i]; uiimageview *imageview2 = hiddenfieldview[i]; if (!cgrectequaltorect(imageview1.frame, imageview2.frame)) { return no; } } return yes; } is there way solve issue? i think whats wrong you're comparing xs , ys too... maybe should go further frame.size , compare th

loops - JSP varStatus javax.el.PropertyNotFoundException: Property status is not found on type -

i'm having problem objects list index: my jsp: <c:choose> <c:when test="${empty findattributes}"> <h1 align="center">attributes empty</h1> </c:when> <c:otherwise> <table align="center" border="1" id="resulttable"> <c:foreach items="${findattributes}" var="findattributesvar" varstatus="status"> <tr> <td align="center">${findattributesvar.status.index.formdescriptionlist.status.status.institutions.nameofinstitution}</td> <td align="center">${findattributesvar.status.index.formdescriptionlist.status.status.institutiontype.typeofinstitution}</td> <td al

osx - Project window -> no directory tree lines -

i'm working on mac , every time project grows find myself wasting time on finding correct folder in complex directory tree. i'm used https://netbeans.org/images_www/v6/9/screenshots/ruby.png now got http://wiki.netbeans.org/wiki/images/9/96/scalaeditor_080729_scala.png is because of macos? because cant find solution either. you using non-standard theme? default aqua-theme (on macos) should http://www.jug-bb.de/wp-content/uploads/2009/05/netbeans67beta_osx.jpg

scala - Filter matching and non-matching elements into different halves of a tuple -

is there simple , efficient way perform following in scala? val elements = list(1, 2, 3, 4, 5, 6) val (odd, even) = elements.filter(_ % 2 == 0) i aware of groupby , works constant number of groups can extracted separate values. list.partition want: val (even, odd) = elements.partition(_ % 2 == 0) note works 2 final groups.

c++ indexing values from a .txt file and reorder them in a new file with a different structure -

i'm still c++ beginner, didn't myself find solution problems below. i have 2 problems: i want load , index values file input.txt structured follows: (x) (y) [colorname1, colorname2, colorname3, colorname4] [density1, density2, density3, density4] i create 10 vector containers, don't know how "explain" program how find position of data structure of file... example: (notice same 'colorname' , example: 'pink' , can appear @ colorname3 or colorname2 , or anywhere in 4 colorname positions) this data structure of input.txt file: 1 23 ['pinkwa', 'gb', 'pink', 'tuwa'][ 0.20078624 0.72376615 0.06735505 0.00809256] 1 24 ['pinkwa', 'gb', 'pink', 'tuwa'][ 0.19900636 0.72874652 0.06998165 0.00226546] 1 25 ['or0a', 'pink', 'pinkwa', 'gb'][ 0.00155317 0.07161603 0.19596207 0.73086873] 1 26 ['or0a', 'pink&

user interface - Given a grid, subdivide into n pieces of different shapes and sizes algorithm -

there's game ios, unblock me , takes given grid/board , subdivides grid blocks of different sizes , shapes. could give me push algorithm accomplish such task like? given grid, subdivide grid smaller pieces, blocks in unblock me include squares rectangles. still want figure out myself i'm having trouble getting started. edit: also ideally solution leave no empty space within original grid, have been subdivided in such way spots being used given # of subdivisions. you can have few standard block sizes , defined grid size. instance, going unblock me example: grid_size can 4*4, block_size1 can 3*1, block_size2 can 2*1 etc. can define, or alternatively take input, number of blocks want in grid. use dynamic programming or recursive backtracking fill in grid these many blocks.

Ruby: uncompress zlib-wrapped deflate data -

in ruby, have buffer containing data compressed zlib compress2() method. found no way decompress data using zlib functionality in ruby standard library supports data created deflate or data in gzip format. how can achieve equivalent of uncompress() in ruby, preferably without resorting creating custom c-extension? edit: i found solution. after fiddling around window_bits argument inflate constructor without success, understood zlib prefixes compressed data four-byte header. removed header , worked charm: data[0..3] = '' data = zlib::inflate.inflate(data) the documentation indicates ruby inflate class decompress output of compress2(), in zlib format. tried it, , works fine. compressed data may not making on ruby intact.

XHR status returns 0 in ajax call to a django generic view -

this totally weird because don't know why returning error when replicated same code 1 section another, change title of generic views (updateview) , never execute function return form edit single customer, that's code: urls from django.conf.urls import patterns, include, url django.contrib.staticfiles.urls import staticfiles_urlpatterns . import views . import forms . import invoice urlpatterns = patterns('', url(r'^pedidos/',views.pedidoslistview.as_view(),name="pedidos_list"), url(r'^pedidos/add',views.add_pedido, name="pedido_add"), url(r'^pedidos/edit/(?p<pedido_id>\d+)',views.edit_pedido, name="pedido_edit"), url(r'^pedidos/delete/(?p<pedido_id>\d+)',views.delete_pedido, name="pedido_delete"), url(r'^pedido/(?p<pk>\d+)',forms.detailpedido.as_view(), name="pedido_detail"), url(r'^pedido-pdf/(?p<pk>\d+)',invoice.de

c# - Best data structure for representing English-verb-forms-like information -

update : have formulated question in abstract terms, way less illustrative. please don't downvote being specific. i need come data structure keep information english verb forms. in cases verb can in 1 of 4 forms: base, present participle, past participle , past simple, example: take taking taken took it's seemingly easy define 4 types each form , on it. there few exceptions ruin simple idea. present single third person form, in our example "he/she/it takes". copular verb "to be" has multiple irregular forms in present tense: "am", "is", "are" , "was" , "were" in past tense verbs "may" don't inflect in present single third person form: "she may". what data structure efficient, accurate yet unambiguous representing such information (with exceptional cases) given following requirements have met: for arbitrary form answer question conjugations form represents for

c# 4.0 - Trying to enumerate over a deserialized list throws an exception -

i know exception has been addressed billion times situation different (i think). anyway, using protobuf - net save , load objects. i've got list of objects i'm trying deserialize keeps breaking saying (here comes): collection modified; enumeration operation may not execute. again, i've seen question asked 50 times here i'm sorry 50 times here's code: public void load(){ using (var file = file.exists(application.startuppath + @"\testfile.scn") ? file.openread("testfile.scn") : null){ if (file != null){ this._tlpgrid.controls.clear(); this.scenes = serializer.deserialize<list<graphicspanel>>(file); foreach(graphicspanel gp in this._lgpscenes) this.addscene(gp); } } } why throwing exception , proper way go if i'm doing wrong? edit

python - I'm having trouble accessing midi files in a different folder -

my code, vincible.py, located in c:\users\nick\desktop\vincible and i'm trying access midi files located in c:\users\nick\desktop\vincible\audio i've put together: #!c:\python33\python.exe import sys, pygame, os.path print("loading...") pygame.mixer.pre_init(44100, -16, 2, 2048) try: pygame.mixer.music.load(os.path.join('audio', 'title.midi')) pygame.mixer.music.load(os.path.join('audio', 'dun1.midi')) pygame.mixer.music.load(os.path.join('audio', 'dun2.midi')) pygame.mixer.music.load(os.path.join('audio', 'dun3.midi')) pygame.mixer.music.load(os.path.join('audio', 'dun4.midi')) pygame.mixer.music.load(os.path.join('audio', 'dun5.midi')) pygame.mixer.music.load(os.path.join('audio', 'dun6.midi')) pygame.mixer.music.load(os.path.join('audio', 'echostheme')) pygame.mixer.music.load(o

javascript - Preset Options in Object and see if it doesn't exist in allowed properties -

i trying make preset list of options allowed in object list. here code var = function(cmd, options){ var objlist = [options.search ,options.demand]; if(!(options in objlist)){ console.warn('not allowed * in options property'); } }; or should do var = function(cmd, options){ var objlist = [search , demand]; if(!(options in objlist)){ console.warn('not allowed option in options property'); } }; basically want set search , demand allowed options in options property later can do a('cmd',{ search:'', demand:function() { alert('hello'); }, //warn next option not allowed quote: function() { alert('quote of user'); } }); if having trouble understanding asking please ask , best explain bit more. maybe writing better? var = function(cmd, options){ options = { theme: function(color) { $('body').css('backgroundcolor',color); },

stdout - Can't figure out why perl prints out newline and then data instead of vice versa -

well, code pretty simple. should print content + \n result somehow reversed. here code: #!/usr/bin/perl -w use strict; $founds; while (<>){ $$founds{$2} = $& while m/([a-z]{3})([a-z])([a-z] {3})/g; } print sort keys %$founds, "\n"; and result is: (here newline) abcdefghijklmnopqrstuvwxyz hope happens configurations (if want download file used on code go here ) anyway, know it? p.s: regex doesn't allow newline characters, it's unlikely problem belongs it. the reason newline first include in sort due lack of parentheses. instead: print sort(keys %{$founds}), "\n"; the newline comes first coincidence (or rather, virtue of being whitespace character amongst non-whitespace). for clarification: my %found = ( foo => 1, bar => 1 ); # keys returns "foo", "bar" print sort keys %found, "\n"; # sort gets "foo", "bar"

Range() in python 2.7 v. 3 -

just wondering how same functionality out of range() in python 2.7 in version 3? in python 2.7: >>> range(5) [0, 1, 2, 3, 4] in python 3: >>> range(5) range(0, 5) i need list looks 1 above, restricted using python3 assignment... thanks much! simply this: list(range(5)) => [0, 1, 2, 3, 4] in python 3, range() returns iterable of objects, it's easy convert list, shown above.

python - Django datetime expression -

hello using django , collecting datetime via start_date = models.datetimefield('start date', blank=true) end_date = models.datetimefield('end date', blank=true) i have report start date , report end date. i wish retrieve time taken report by, taking end_date , subtracting end date , rounding nearest day def report_days(self): return self.end_date - self.start_date currently python shell returns this >>> a.report_days() datetime.timedelta(2, 65020, 613435) django represents datetimefields python datetime objects, result of subtraction datetime.timedelta object. number of full days, can do: delta = self.end_date - self.pub_date return delta.days this counts full days, though. round nearest full day, can like: delta = self.end_date - self.pub_date if delta.seconds / 3600 >= 12: return delta.days + 1 # round else: return delta.days # round down for more information, see: http://docs.python.org/2/library/datetime.

In the Go programming language, is it possible to obtain a variable's type as a string? -

i'm unfamiliar go programming language, , i've been trying find way type of variable string. far, haven't found works. i've tried using typeof(variablename) obtain variable's type string, doesn't appear valid. does go have built-in operator can obtain variable's type string, similar javascript's typeof operator or python's type operator? //trying print variable's type string: package main import "fmt" func main() { num := 3 fmt.println(typeof(num)) //i expected print "int", typeof appears invalid function name. } there's typeof function in reflect package: package main import "fmt" import "reflect" func main() { num := 3 fmt.println(reflect.typeof(num)) } this outputs: int update: updated question specifying want type string. typeof returns type , has name method returns type string. so typestr := reflect.typeof(num).name() update 2: more

javascript - Second request recives the first one that was still processing -

i have request system 2 unrelated functions making requests server. problem response not correct let me explain happening step step: a background function makes request server server processes task 1 second unrelated background function makes request server client recieves response of task 1 second function recieves response first function. first function never gets response. now don't know how solve it, know need distinguish them separately theres no conflictions here. this current code handles request stuff: function call_back(result,func){ if(typeof(func) != 'undefined' || func != false){ func(result); } else { return false; } } function caller(url,cfunc){ if (window.xmlhttprequest) { xmlhttp=new xmlhttprequest(); } else { xmlhttp=new activexobject("microsoft.xmlhttp"); } xmlhttp.onreadystatechange=cfun

android - Comparing pixel colors in a selected region -

canvas.drawcircle((float)(mymidpoint.x - myeyesdistance/2.0), mymidpoint.y, (float)30.0, mypaint); canvas.drawcircle((float)(mymidpoint.x + myeyesdistance/2.0), mymidpoint.y, (float)30.0, mypaint); the image shows eyes detected using canvas. how pixel colors in circled region can compare preset values , tell whether eye open or not? see image in link .

javascript - How to use setTimeout with every item in an array? -

in following: ko.utils.arrayforeach(cards, function (card) { settimeout(function () { observabledata().savecard(card); }, 1000); }); this supposed waiting 1 second every card in array, waits 1 second , blasts through array. how can achieve expected behavior? you need increment timeouts var idx = 1; ko.utils.arrayforeach(cards, function (card) { settimeout(function () { observabledata().savecard(card); }, (idx++) * 1000); }); since arrayforeach doesn't giving index of item, need maintain separate index

python - Loopless program to remove duplicate elements in a sorted array -

i want write loopless program (probably using comprehension) remove duplicate elements in sorted array in python (and efficiently too). since list sorted - meaning duplicates grouped, can use itertools.groupby >>> testlist = [1, 1, 1, 2, 3, 3, 4, 4, 5, 6, 7, 8, 8, 9] >>> itertools import groupby >>> [k k, g in groupby(testlist)] [1, 2, 3, 4, 5, 6, 7, 8, 9] this more efficient (in memory , time) converting set , sorting. has advantage of needing compare equality, works ok unhashable items too.

python 2.7 - I am running a bottle.py baesd web service in google app engine.But how can i connect it to GAE database NOSql -

i running webservice in localhost in system. have connected mysql.and working fine. when comes googleappengine how can connect nosql. this code: import bottle import webapp2 bottle import route, run, template import mysqldb, mysqldb.cursors bottle import route, template, request ,debug google.appengine.ext.webapp.util import run_wsgi_app db = mysqldb.connect(user="root", passwd="root", db="delhipoc" , host='127.0.0.1') cur = db.cursor() def main(): debug(true) run_wsgi_app(bottle.default_app()) @route('/hai/<name>') def show(name): print "the name \n",name cur.execute('select * poc_people') print "i in show \n" row in cur.fetchall() : print row[0] data = row[0] print "hai \n",row[0] return template('<b></br></br></br>hello{{name}}</br></br></br>{{data}} </b>!',name=name,data=data)

loops - Match data entered with data in the database CAKEPHP -

i stuck @ loop function of cakephp. logic need compare data entered users data in table. have 2 tables, 1 bookings , 1 inventories_bookings . below coding doesnot work. help! thanks public function add2() { if ($this->request->is('post')) { foreach ($invbook $invenbook) { if ($this->request->data['booking']['bookings_location'] == $invenbook['inventoriesbooking']['test']) { $this->session->setflash(__('the booking cannot created')); $this->redirect(array('action' => 'add2')); debug($this->request->data['booking']['bookings_location'] == $invenbook['inventoriesbooking']['test']); } } $this->booking->create(); $invbook = $this->booking->inventoriesbooking->find('list',array('fields' => array(

oracle - InvalidOperationException with ExecuteOracleScalar() -

i need select value database: string attrident = ""; oraclecommand sel_attr = new oraclecommand(@" select identifier_ tbl_a_custom_form_base_attr templateuuid in( select uuid tbl_a_custom_form_template parentuuid =:projid) , identifier_ in ('xxx', 'yyy', 'zzz')", conn); sel_attr.parameters.add("projid", oracletype.nvarchar).value = id; sel_attr.commandtype = commandtype.text; attrident = convert.tostring(sel_attr.executeoraclescalar()); but got invalidoperationexception in attrident = convert.tostring(sel_attr.executeoraclescalar()); what's i'm doing wrong?

wpf controls - WPF dataGrid super Header for multiple columns -

Image
i want header multiple columns in wpf datagrid . tried header template display header 1 column. below xaml have tried: <datagrid> <datagrid.columns> <datagridtextcolumn> <datagridtextcolumn.headertemplate> <datatemplate> <stackpanel> <textblock>column 1</textblock> <textblock>xyz</textblock> </stackpanel> </datatemplate> </datagridtextcolumn.headertemplate> </datagridtextcolumn> <datagridtextcolumn header="header" /> </datagrid.columns> </datagrid> i attaching expected result screen shoot: <grid width="auto"> <grid.rowdefinitions> <rowdefinition />

php - An Array written in top of dropdown in magento -

i adding select field in form , getting available records database, slight problem there written array in top of drop down, want remove it. foreach ($data $columns) { $datacol[] = array( "value" => $columns->getcatid(), "label" => $columns->getcategory(),); } /* category */ $fieldset->addfield('cat_id', 'select', array( 'label' => mage::helper('news')->__('category'), 'class' => 'required-entry', 'required' => true, 'name' => 'cat_id', 'values' => array( array( 'value' => $datacol, 'label' => mage::helper('news')->__($datacol), ), ) ));

How to include a certain javascript file after <body> tag -

i'm getting error typeerror: document.body null in javascript. and solution found here. problem how can load specific javascript file(where error come from) after <body> ? or add window.onload = function() file? and especially, how tell path of javascript file app? i know how include every file application.js , trigger before <body> load since mention application.js assume you're using rails? in case, use javascript_include_tag include file in application.html.erb before closing </body> tag.

zope - how to import one project(.zexp file) to another project? -

can 1 tell how solve typeerror:('object.__new__(x): x not type object (classobj)', <function _reconstructor @ 0xb766fa04>, (<class datetime.datetime.datetime @ 0x9382d4c>, <type 'object'>, none)) while importing 1 project(for ex. brundelre3.zexp file) in zmi. i tried importing project(brundelre3.zexp) in zmi under / ->import/export (tab)-> import file name ->ownership-> selected radio button of retain existing ownership information-> import (button) worked before not working . can tell whats reason error. i can make wild guesses, need debug it: perhaps have created type has name clashes built-in.

php - export table data in csv formate and store in folder -

how in php ? i wan't export table data in csv file , store csv file in backup folder. for using : $query = "select * `login_details`"; $file_name = "login_details"; $sql_csv = mysql_query($query) or die("error: " . mysql_error()); //replace line appropriate db abstraction layer header("content-type:text/octect-stream"); $done = header("content-disposition:attachment;filename=$filename"); while($row = mysql_fetch_row($sql_csv)) { print '"' . stripslashes(implode('","',$row)) . "\"\n"; } thanks. you must open file write (handle) use http://php.net/manual/en/function.fopen.php use created handle write string http://php.net/manual/en/function.fputcsv.php close handle when done(see doc fopen) use fclose() for example: //you code data sql $handle = fopen('full path store (you can use ftp etd)', 'w'); // see mode while($row = mysql_fetch_row($

qt - How to change value of QProgressBar in QTreeWidgetItem? -

i'm receiving signal parametres (current, total) , each time i'm suppose alter value of progressbar inside qtreewidgetitem. source code. have: qmap<qxmpptransferjob*, transferitemwidget*> widget_map; and add here new items void mainwindow::additem(qxmpptransferjob *job) { qtreewidgetitem *item = new qtreewidgetitem(ui->treewidget); widget_map[job] = new transferitemwidget; widget_map[job]->filenamelabel->settext(job->filename()); widget_map[job]->barejidlabel->settext(job->jid()); ui->treewidget->setitemwidget(item,0,widget_map[job]); } and each time when receive signal there implemented following slot: void mainwindow::progress(qint64 &current, qint64 &total) { qxmpptransferjob *job = (qxmpptransferjob*)qobject::sender(); widget_map[job]->progressbar->setmaximum(total); widget_map[job]->progressbar->setvalue(current); } progressbar isn't changing value remains same? can

Kill Camera App Programmatically on Android -

i looking creating location aware security app whereby camera disabled if phone moves designated location. able disable , enable camera using device administrator class , calling setcameradisabled disable camera. however, problem encountering if setcameradisable method called when camera running, camera app doesn't close. camera app disabled on next launch. such wondering there way me kill camera process before calling setcameradisabled method. in advance. try android.os.process.killprocess(android.os.process.mypid());

Nodejs and php in same environment in aws Elastic beanstalk -

i have application have both nodejs , php codes. nodejs used run several scripts required application. how deploy such application using aws elastic beanstalk? there 2 ways accomplish amazon beanstalk recommended way#1: use configuration file install nodejs. configuration file scripts executed during beanstalk ec2 instances start up. legacy way#2: customizing elastic beanstalk ami install nodejs , fill custom ami id in beanstalk environment setting. references: 1. customizing , configuring aws elastic beanstalk environments 2. using custom amis

ios - iTunes error like "You do not have enough access privilege for this operation" -

when trying put ipad hd app itunes testing in ipad device got alert "you not have enough access privilege operation ".how resolve issue?please me. see link . may reason why not able upload app. some intruder have tried access apple developers account information. that's why apple developers' site down maintenance. wait until finished maintenance.

c - How to encrypt data using RSA, with SHA-256 as hash function and MGF1 as mask generating function? -

i doing experiments cryptography. have public key of receiver , want encrypt data , pass receiver. i want use rsaes-oaep algorithm. sha-256 hash function , mgf1 mask generation function. i want using openssl. found function rsa_public_encrypt() function can specify padding. 1 of padding option available rsa_pkcs1_oaep_padding eme-oaep defined in pkcs #1 v2.0 sha-1 , mgf1 . they using sha-1. i want reconfigure function use sha256 hash function ans mgf1 hash function. how can ? openssl uses definitions pkcs #1 v2.0 , default eme-oaep sha-1 , mgf1 . if need use sha-256 , you'll need encoding yourself. isn't terribly difficult however, see pkcs #1 v2.2 pdf page 18 details.

php - How to display monthwise and week wise records in case of following scenario? -

i'm using php , mysql in website. there 1 table in database named users . has 2 fields viz. user_reg_date(bigint(12)) , user_last_login(bigint(12)) . these 2 fields store date in unix timestamp format. whole table structure follows: user_id varchar(32) user_title enum('mr', 'ms', 'mrs') user_first_name varchar(50) user_last_name varchar(50) user_name varchar(100) user_password varchar(50) user_email varchar(150) user_dob date user_hybridauth_p_name varchar(100) user_hybridauth_p_uid varchar(100) user_reg_date bigint(12) user_status enum('enable', 'disable') user_subscription enum('lifetime', 'period') user_update_date bigint(12) user_last_login bigint(12) user_last_activity bigint(12) user_created_staff_id varchar(32) user_updated_staff_id varchar(32) user_registered_type enum('online', 'manual') now want display record counts i.e. count of users user

Sitecore Package upload error -

i trying install sitecore package dev staging environment, have used package designer create package, when try upload package on staging site results in following error: the file exists.<br> i have tried uploading package created using sitecore rocks plugin results in same error. installing package using installation wizard , uploading package , not overwriting existing files. kindly, help! this error occurs if windows temp has more 65k files. when cleared files issue got resolved.

math - how to interpret multiple venn diagram -

Image
could 1 explain logic behind multiple venn diagram explaining these numbers represent in picture. thanx in advance. the number in each location represents number of items can there , else. for example there 1 item both s , r , not in e or r . there 2 items in s , r , , e , not in r . there 3 items in e , r , not in s or r . four items in r , else etc. conveniently enough, because of categories mutually exclusive, can find number of items in arbitrary category adding sub-categories make up. for example, number of items in s , r total 1+9+2+8 = 20

java - Design User Interface by tools for desktop applications -

Image
i had given make design looks in java desktop application. so tools used make design in java? any appreciated new in designing software this. the 1 i'm using window builder pro. simple, efficient , easy install eclipse plugin. give check @ link: https://developers.google.com/java-dev-tools/wbpro/ for graph parth should try jgraph. used many times , worked it. jgraph: http://www.jgraph.com/

Need help on debugging of vb6 code that is used in .net application -

my .net application using vb6 controls , libraries. can not debug vb6 code through .net application. can me out, how can debug vb6 code using s user control in .net application. i not sure can or not, have gotten ideas following link : if double-click project in solution explorer , go debug tab you'll see option says "start external program." select option , type in "c:\program files\microsoft visual studio\vb6.exe." (with quotes). after that, put full path .vbp file in command line arguments (also quotes around it). when run vs fire vb6, , debugger's attached. can set , hit breakpoints in normal way you're used to. alternately can using tools->attach process, find first approach easier. set once , don't have worry again. one thing watch if hit stop in vs2005, vb6 program exit without prompting save, if make changes in vb6 project make sure click save before pressing f5 (in vb6). h

javascript - how to change the text(selected) color using jquery in spectrum colorpicker -

i new web development, have problem regarding spectrum colorpicker, using spectrum colorpicker in project, working when used background not working when i'm using text, when pick color spectrum colorpicker, color of text changes initial color not updating same initialise in script. problem in script. please me in solving problem. here following code. <label>textcolor</label> <input type='color' id="full"/ > <script type="text/javascript"> $(document).ready(function(){ $("#full").spectrum({ showinput: true, classname: "full-spectrum", showinitial: true, showpalette: true, showselectionpalette: true, localstoragekey: "full", maxpalettesize: 10, preferredformat: "hex", move: function (full) { }, show: function (full) { }, beforeshow: function (full) { }, hide: function (full) { }, change: function(full) { $(&q

How can I tell if SQLite is installed properly on Linux? -

i'm using web hosting service on shared account. have mysql, need use sqlite joomla extension called sobipro. how can tell if sqlite installed , working on linux? sqlite embedded database, i.e., compiled directly application uses it. in case, sqlite must enabled in php configuration. sobipro documentation says: sqlite can supported directly via sqlite extension or through php data objects extension . to check php extensions, use get_loaded_extensions or <?php phpinfo(info_modules); ?> .

jar - Cannot set the properties of eclipse blackberry plugin -

i have installed blackberry plugin eclipse here .however when try edit preferences eclispe gives error , think found problem don't know how fix it.the problem caused by: java.lang.illegalargumentexception: no enum constant com.qnx.tools.bbt.core.sdk.iblackberrytabletsdkdescriptor.iregistry.impl.priority.hİgh, converts capital İ -is turkish character- enum value high. is there way fix it.my system win 7 64 bit turkish. session data log; eclipse.buildid=m20120208-0800 java.version=1.7.0_25 java.vendor=oracle corporation bootloader constants: os=win32, arch=x86, ws=win32, nl=tr_tr command-line arguments: -os win32 -ws win32 -arch x86 full error log ; java.lang.exceptionininitializererror @ net.rim.ajde.ui.preferences.androidpreferencepage.getdefaultsshkeypath(androidpreferencepage.java:232) @ net.rim.ajde.preferences.preferenceinitializer.initializedefaultpreferences(preferenceinitializer.java:60) @ org.eclipse.core.internal.preferences.preferenceserviceregi