Posts

How can I display just a portion of an image in HTML/CSS? -

let's want way display the center 50x50px of image that's 250x250px in html. how can that. also, there way css:url() references? i'm aware of clip in css, seems work when used absolute positioning. one way set image want display background in container (td, div, span etc) , adjust background-position sprite want.

msbuild - Best build process solution to manage build versions -

i run rather complex project several independent applications. these use couple of shared components. have source tree looking below. my project application a shared1 shared2 application b application c all applications have own msbuild script builds project , shared resources needs. run these builds on cruisecontrol controlled continuous integration build server. when applications deployed deployed on several servers distribute load. means it’s extremely important keep track of build/revision deployed on each of different servers (we need have current version in dll version, example “1.0.0.68”). it’s equally important able recreate revision/build been built able roll if didn’t work out intended (o yes, happends ...). today we’re using sourcesafe source control possible change if present reasons (ss it’s working ok so far). another principle try follow it’s code been build , tested integration server deploy further. "crusiecontrol build labels" sol...

Session management in Azure application -

link texti developed simple cloud application default webrole , implemented following steps. 1.created new cloud service application 1 default webrole1 2. extracted “ aspproviders.dll” , added reference current webrole1. 3. added new web form existing web role , named login.aspx 4. design page of login.aspx edit below 5. below line added in page load event of default.aspx response.write("hello, " + server.htmlencode(user.identity.name)); 6. edited web.config following changes ................. <!--below lines added avoid error occured related insecure end points connection --> ................. ................. ................ ................ ................. <sessionstate ...

hardware - What's your experience with Flash drives? -

emc marketing solid state flash drives , project thinking moving direction in future. have experience replacing traditional disk storage flash drives? besides price, have experienced downsides technology? i've used machines solid state drives in place of conventional hard drives. there seems no real benefit. think faster; not. think they'd consume less power, doesn't seem case either. the major downside have finite number of available writes. continually writing disk (as operating systems do) wear ssd out faster conventional drive.

c# - Any type mapping with different Id types -

i'm working on event-planning application contacts in phone book. avoiding public virtual , protected stuff, contact class looks like: class contact { //... int32 id { get; private set; } //primary key; string name { get; private set; } //... } a customer asked me handle both own phone book , application's one. thought extract icontact interface contact , , add class internalcontact (this name sucks, know), implementing same interface. problem customer's db uses assigned string primary key, contact ''s id type , internalcontact 's id type different. possible map invitation.contact property using <any> type mapping, id types different? thanks in advance, giulio not sure if asking create classes: interface icontact<t> { t id { get; } } public class contact : icontact<int> { public int id { get; private set; } } public class internalcontact : icontact<string> { public string id { get...

objective c - problem with logging in twitter through my iphone application -

i creating music application in integrating twitter in application when user clicks on particular song , click on twitter tab login page of twitter should displayed. after entering username , password should directed page can enter comment , post it.the problem when click on twitter tab login page diplayed when enter username , password , click on submit not redirect me page can post comment. here code: (ibaction) submit: (id) sender { // g=text3.text.integervalue; u=text1.text; p=text2.text; int flag; nslog(@"username,%d",u); //if((u!=@"") || (p!=@"")) //if((text1.text.length >= 20 && range.length !=0) ||(text2.text.length >= 8 && range.length!=0)) if([text1.text length] != 0 || [text2.text length]!=0) { twitterrequest * t = [[twitterrequest alloc] init]; t.username =[nsstring stringwithformat: @"%@",u]; //nsstring *username=[nsstring stringwithformat:@"%d",u]; t.password= [n...

c++ - C++0x: iterating through a tuple with a function -

i have function named _push can handle different parameters, including tuples, , supposed return number of pushed elements. for example, _push(5) should push '5' on stack (the stack of lua ) , return 1 (because 1 value pushed), while _push(std::make_tuple(5, "hello")) should push '5' , 'hello' , return 2. i can't replace _push(5, "hello") because use _push(foo()) , want allow foo() return tuple. anyway can't manage make work tuples: template<typename... args, int n = sizeof...(args)> int _push(const std::tuple<args...>& t, typename std::enable_if<(n >= 1)>::type* = nullptr) { return _push<args...,n-1>(t) + _push(std::get<n-1>(t)); } template<typename... args, int n = sizeof...(args)> int _push(const std::tuple<args...>& t, typename std::enable_if<(n == 0)>::type* = nullptr) { return 0; } let's want push tuple<int,bool> . how expect work: _pu...