Posts

ios - Subview's sublayers overlapping higher subviews -

Image
i have issue: i'm creating uiview returned method, , part fine, i've noticed when add sublayers 1 of subviews, layers overlap subviews higher in hierarchy (textview , imageview) sublayers added testviewcopy appearing on top of these subviews, , aren't supposed to. have no idea what's going on here cause this. code: - (void)makeshareimages { uiview *shareview = [self shareview]; uiview *testviewcopy = [shareview viewwithtag:0]; nsuinteger currentindex = 1; (nsdictionary *sub in self.array) { nsarray *lastarray = [sub objectforkey:@"lastarray"]; (nsdictionary *dict in lastarray) { @autoreleasepool { currentindex ++; circlelayer *layer = [[circlelayer alloc]init]; layer.portrait = [[dict objectforkey:@"portrait"]boolvalue]; layer.frame = testviewcopy.bounds; [testviewcopy.layer addsublayer:l...

gmail - Gamil logged me in when i give my email address without dot or with dot? -

i don't know whether ask question in stack overflow appropriate or not. sorry if question not fulfilling rules. my google mail account shakil.cph@gmail.com my question before login when entering mail address without dot mean shakilcph@gmail.com logged me in shakil.cph@gmail.com. reason. https://support.google.com/mail/answer/10313?hl=en gmail doesn't recognize dots characters within usernames, can add or remove dots gmail address without changing actual destination address; they'll go inbox, , yours. ... you can see if try sign in username, adding or removing dot it. you'll still go account. a note using google apps: one last thing: google apps does recognize dots. if you'd have dot in username, please ask domain administrator add preferred username nickname.

jquery - display different item from a list on click of a button in MVC Mobile -

i have list of customers in customers list. list<customer> customers= getcustomer("new york"); i want display each customer item in mvc view on click of left , right buttons , save customer @ end. my mvc view below | leftbutton | 1 of 5 |rightbutton| customer: michael address: 123 park ave, new york rating: 4 phone: 123456 |buttonsave| |buttonremove| i hope explained properly, should approach thing done in mvc partial page updates. here 1 possible solution: create partial view show single customer record. model: public static customer getcustomerinfo(int customerid) { using (var db = new dbcontext()) { return db.customers .where(c => c.customerid == customerid) .firstordefault(); } } view: <label><b>customer:</b> @viewbag.customer.name</label><br> <label><b>address:</b>...

python - What is the relationship between virtualenv and pyenv? -

i learned how use virtualenv , virtualenvwrapper in workflow i've seen pyenv mentioned in few guides can't seem understanding of pyenv , how different/similar virtualenv. pyenv better/newer replacement virtualenv or complimentary tool? if latter differently , how 2 (and virtualenvwrapper if applicable) work together? pyenv , virtualenv different tools work in different ways different things: pyenv bash extension - not work on windows - intercepts calls python, pip, etc., direct them 1 of several of system python tool-chains. have libraries have installed in selected python version available - such users have switch between different versions of python. virtualenv , pure python works everywhere, makes copy of, optionally specific version of, python , pip local activate environment may or may not include links current system tool-chain, if not can install known subset of libraries environment. such better testing , deployment know exactly libraries, @ vers...

html - How does css checkbox hack work? -

i came across switch toggle button created using css. known checkbox hack. for doesn't know checkbox css hack is, please read here https://css-tricks.com/the-checkbox-hack/ i tried out , working fine. didn't understand how working because not clicking on checkbox. so have 2 questions how working ? instead of absolute positioning tried display: none; still worked. method have drawbacks? the way works using <label> element. input element can (and should) have label. can tell browser label belongs label using for attribute, referring input's name : <input name="myname" /> <label for="myname">label</label> whenever click label, focuses input (or in case of checkboxes, toggles it). the label , checkbox don't have near each other. add few hidden checkboxes @ start or end of document , place labels anywhere on page, , they'd still focus input. hiding checkbox through display: none cause bug...

html - Border-radius and IOS select fields -

Image
i experiencing problem height , border-radius of select fields in ios. first, border-radius. specified border-radius select fields image below demonstrates: for reason, border-radius settings ignored on iphone. i'm not sure if ipad produces same result don't have 1 test. according few posts " remove border radius select tag in bootstrap 3 " solution found set border-radius 0, want border-radius. shall do? second, height. height of selects not matching height when viewing site desktop browser. set min-height helped it's still under required height. what can missing? note, following css rules applied select fields: -webkit-tap-highlight-color: rgba(0,0,0,0); -webkit-appearance: none; -moz-appearance: none; appearance: none;

sql - Join same table twice for count in different columns -

i have 2 tables a +----+-------+ | id | user | +----+-------+ | 1 | user1 | | 2 | user2 | | 3 | user3 | +----+-------+ b +----+--------+------+ | id | userid | type | +----+--------+------+ | 1 | 1 | | | 2 | 1 | b | | 3 | 1 | c | | 4 | 2 | | | 5 | 2 | b | | 6 | 2 | c | | 7 | 3 | | | 8 | 3 | c | +----+--------+------+ userid fk table a.id i'm trying count of each type , type permutations below single sql query. (e.g count a^b means number of users has type , b) +---------+---------+---------+-----------+-----------+-----------+-------------+ | count | count b | count c | count a^b | count a^c | count b^c | count a^b^c | +---------+---------+---------+-----------+-----------+-----------+-------------+ | 3 | 2 | 3 | 2 | 3 | 2 | 2 | +---------+---------+---------+-----------+-----------+-----------+-------------+ or separate query each permutatio...