Search Results

Search found 377 results on 16 pages for 'saif khan'.

Page 11/16 | < Previous Page | 7 8 9 10 11 12 13 14 15 16  | Next Page >

  • My map callouts don't display the image when clicked

    - by Neelam Khan
    I am developing an iPhone application for a university project and I'm new to iPhone development. I have looked through Apple's MapCallouts code but it doesn't seem feasible to implement it. So far my code displays a map, drops annotations, displays the title and it displays the right call out button. But this is where I encounter problems. When I press on the callout button, it displays a blank view controller but it should display a different image for every callout that's tapped and this isn't happening so far. I have added my code below: - (void)mapView:(MKMapView *)mapView annotationView:(MKAnnotationView *)view calloutAccessoryControlTapped:(UIControl *)control { //NSUInteger tag = ((UIButton *)control).tag; if (self.detailController==nil) { DetailViewController* detailViewController = [[DetailViewController alloc] init]; [self.navigationController pushViewController:detailViewController animated:YES]; } // self.detailController.tag =1; //to identify image required // self.detailController.tag = tag; [self.navigationController pushViewController:detailController animated:YES]; }

    Read the article

  • Where are the menu,header,footer loaded in an MVC structures

    - by Saif Bechan
    I am creating an framework in PHP, and i am using and MVC structure. My link look something like this: mydomain.com/controller/action So this link loads a controller, which loads the needed action. Now my page needs a header, footer, and it has a menu which is in the database. Where do i load all these things. Is this the job of the controller, or the job of the model.

    Read the article

  • Can this package be recompiled

    - by Saif Bechan
    Hello I asked this question to superuser but I did not get a good question there and i really need the answer. I know some of you here can answer this question. I have installed nginx via yum. Now I want to add a module, but I have to compile the source again and include the the new module. But i can't find the source. Does someone know what I have to do to recompile the source and get the module in.

    Read the article

  • how to load image from file using MFC

    - by Sweety Khan
    **my browse button code is void CFileOpenDlg::OnBnClickedButton1() { // TODO: Add your control notification handler code here CFileDialog dlg(TRUE); int result=dlg.DoModal(); if(result==IDOK) { path=dlg.GetPathName(); UpdateData(FALSE); } } and this is the code for loading an image from resource but tht does not work for loading an image from file. i know LoadImage(); is used for this but how? how can i edit this code to load image from file. Plzz help..... void CFileOpenDlg::OnBnClickedButton2() { // TODO: Add your control notification handler code here CRect r; CBitmap* m_bitmap; CDC dc, *pDC; BITMAP bmp; m_bitmap = new CBitmap(); m_bitmap-LoadBitmapW(IDB_BITMAP1); m_bitmap-GetBitmap(&bmp); pDC = this-GetDC(); dc.CreateCompatibleDC(pDC); dc.SelectObject(m_bitmap); pDC-BitBlt(200, 200, bmp.bmWidth, bmp.bmHeight, &dc,0 , 0, SRCCOPY); m_bitmap-DeleteObject(); m_bitmap-Detach(); } waiting for reply........**

    Read the article

  • Making span clickable after prepend in jQuery

    - by Saif Bechan
    I have a DIV where some code is presented. When I hover on this DIV I want to present a button that toggles the comments inside the code block. So far I have this: $('.code-block').hover( function(){ $(this).prepend('<span class="code-block-control">toggle comments</span>'); }, function(){ $('.code-block-control',this).remove(); } ); $('.code-block-control').click( function(){ $('.comment').toggle(); } ); The span is presented when I hover over the code block. But when I click the span that is created nothing happens. Even if I change the click function to a simple alert nothing happens. Anyone have any idea on how to fix this.

    Read the article

  • Are there any e-commerce websites that use NoSQL databases

    - by Saif Bechan
    I have read a lot lately about 'NoSQL' databases such as CouchDB, MongoDB etc. Most of the websites I have seen using this are mainly text based websites such as The New York Times and Source forge. I was wondering if you could apply this to websites where payment is a huge issue. I am thinking of the following issues: How well can you secure the data Do these system provide an easy backup/restore machanism How are transactions handled commit/rollback I have read the following articles that cover some aspects: Can I do transactions and locks in CouchDB? Pros/Cons of document based database vs relational database In these posts the aspect of transactions if covered. However the questions of security and backups is not covered. Can someone shed some light on this subject? And if possible, does anyone know of some e-commerce websites that have successfully implemented the document based database.

    Read the article

  • Using CASE Statements in LEFT OUTER JOIN in SQL

    - by s khan
    I've got a scenario where I want to switch on two different tables in an outer join. It goes something like this:- select mytable.id, yourtable.id from mytable left outer join (case when mytable.id = 2 then table2 yourtable on table1.id = table2.id else table3 yourtable on table1.id = table3.id end) ...but it doesn't work. Any suggestions?

    Read the article

  • Proper way of naming your Java Google App Engine Project

    - by Saif Bechan
    I am starting out with Google's App Engine in Java. I have seen the tutorial video but I do not understand the naming of the project package. It is going to be a guestbook, that's why the name is guestbook, I understand that part. But after that I see package name. 1)Is that something you import into the project, or is is something you create. I have seen this a lot in projects, something like com.xxx.xxx. 2)How do you name this type of thing or is this an import. I have looked at another tutorial there they take the naming to a whole new level. The name of both the project and the package is de.vogella.gae.java.todo. 3)What does this mean in java terms. 4)Maybe one of you can help me with this specific project I want to start. I want to create a Google App project that for now only serves static files. I will leave the project empty and just put all my static files in the war directory of the project. I want the domain name to be mydomainstatic

    Read the article

  • Getting random record from database with group by

    - by Saif Bechan
    Hello i have a question on picking random entries from a database. I have 4 tables, products, bids and autobids, and users. Products ------- id 20,21,22,23,24(prime_key) price........... etc........... users ------- id(prim_key) name user1,user2,user3 etc bids ------- product_id user_id created autobids -------- user_id product_id Now a multiple users can have an autobid on an product. So for the next bidder I want to select a random user from the autobid table example of the query in language: for each product in the autobid table I want a random user, which is not the last bidder. On product 20 has user1,user2,user3 an autobidding. On product 21 has user1,user2,user3 an autobidding Then I want a resultset that looks for example like this 20 – user2 21 – user3 Just a random user. I tried miximg the GOUP BY (product_id) and making it RAND(), but I just can't get the right values from it. Now I am getting a random user, but all the values that go with it don't match. Can someone please help me construct this query, I am using php and mysql

    Read the article

  • How to uniquely identify a azure solution?

    - by Hasan Khan
    Is there any way to detect an azure solution uniquely? I want to develop a library that is licensed per solution. The only way to enforce this without having a licensing server is to have a unique identity of the solution. Is any GUID of such sort available? Something like RoleEnvironment.DeploymentID. When does DeploymentID change?

    Read the article

  • shouldAutorotateToInterfaceOrientation is not working in iOS 6

    - by Saif
    In iOS 6 shouldAutorotateToInterfaceOrientation is not working but it work fine in iOS 5.0 or 5.1. What should i need to change in ios 6. Here is my code - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation { if([[[SampleApplicationAppDelegate instance].callInfoDictionary valueForKey:IS_CHAT] isEqualToString:NO_RESPONSE]) { int nAngle = 0; BOOL bRet = NO; switch (interfaceOrientation) { case UIInterfaceOrientationPortrait: nAngle = 90; bRet = YES; NSLog(@".......Preview = %f %f",_previewCamera.frame.size.width,_previewCamera.frame.size.height); _previewCamera.transform = CGAffineTransformMakeRotation(M_PI*1.5); NSLog(@"Preview = %f %f",_previewCamera.frame.size.width,_previewCamera.frame.size.height); break; case UIInterfaceOrientationPortraitUpsideDown: nAngle = 270; bRet = YES; _previewCamera.transform = CGAffineTransformMakeRotation(M_PI_2); break; case UIInterfaceOrientationLandscapeLeft: nAngle = 0; bRet = YES; //_previewCamera.transform = CGAffineTransformMakeRotation(M_PI*1.5); break; case UIInterfaceOrientationLandscapeRight: nAngle = 180; bRet = YES; //_previewCamera.transform = CGAffineTransformMakeRotation(M_PI_2); break; default: break; } return bRet; } if(interfaceOrientation == UIInterfaceOrientationPortrait || interfaceOrientation == UIInterfaceOrientationPortraitUpsideDown) return YES; return NO; } when i search for this orientation problem i found all this 1 2 but nothing work for me :( Please help .....

    Read the article

  • What is the best place to display the language in your url

    - by Saif Bechan
    I have a multi-language website that makes use of pretty urls, so called search engine friendly urls. Now there are a few places to define the language in the url. 1) www.mydomain.com/en/articles/random www.mydomain.com/nl/articles/random 2) en.mydomain.com/articles/random nl.mydomain.com/articles/random 3) www.mydomain.com/articles/random?lang=en www.mydomain.com/articles/random?lang=nl Is there any preffered way of showing this, or is there another way better that I did not show. I would like to hear your comments on this.

    Read the article

  • What choices to make for an application backend

    - by Saif Bechan
    I am creating an web application and I at the point that i am starting to make backend choices. Now there are a lot of ways to go with this, so I am looking for some good points and back practices. Some of the question i have involve: Should i make a seperate table in the db for admin users Should i extend make some classes to load the admin data and the normal data, or make seperate classes for the admin section Where can i get some information on making different types of users Just some best practices for a backend My application is written in PHP with an MySQL database.

    Read the article

  • [MySQL] Efficiently store last X records per item

    - by Saif Bechan
    I want to store the last X records in an MySQL database in an efficient way. So when the 4th record is stored the first should be deleted. The way I do this not is first run a query getting the items. Than check what I should do then insert/delete. There has to be a better way to do this. Any suggestions? Edit I think I should add that the records stored do not have a unique number. They have a mixed par. For example article_id and user_id. Then I want to make a table with the last X items for user_x. Just selecting the article from the table grouped by user and sorted by time is not an option for me. The table where I do the sort and group on has millions of records and gets hit a lot for no reason. So making a table in between with the last X records is way more effient. PS. I am not using this for articles and users.

    Read the article

  • SQL SERVER Project

    - by Saif Omari
    My Application Database Without Project and without Source safe, i planned to make my DB to be as project and add it to TFS, but I have no idea how to script the stored procedures, Triggers, Views, Functions, and what is the best practice to Make Update Script for All My stored procedures, Triggers, Views, and Functions to My customers DB.

    Read the article

  • Redirecting to frontpage after 404 error in PHP

    - by Saif Bechan
    I have a php web page that now uses custom error pages when a page is not found. The custom error pages are included in PHP. So when somebody types in an URL that does not exists I just include an error page, and the error page starts with: <?php header("HTTP/1.1 404 Not> Found"); ?> This also tells crawlers that the page does not exist. Now I have set up a new system. When a user types a wrong url, the user is sent back to the frontpage and a message is displayed on the frontpage. I redirect to the frontpage like this: header('Location:' . __TINY_URL . '/'); Now the problem is PHP just sends back a 200 code, page found. How can I mix these two to create a 404 code on the frontpage. And is this overall a nice way of presenting and error page.

    Read the article

  • Get count of rows in each table while having more than 1 tables

    - by sneha khan
    I have more then one tables on same page and want to add a line show count of each table as below. I tried something but it gives sum of count of all table rows. <table> <tr> <td>Some data</td> <td>More data</td> </tr> <tr> <td>Some data</td> <td>More data</td> </tr> </table> <table> <tr> <td>Some data</td> <td>More data</td> </tr> <tr> <td>Some data</td> <td>More data</td> </tr> </table> <script type="text/javascript" src="jquery.js"></script> <script type="text/javascript"> $().ready(function(){ //I want to add a line after each table showing each table row count $("table").after(??? + " rows found."); }); </script>

    Read the article

  • what is the exact difference between PHP static class and singleton class

    - by Saif Bechan
    I have always used a Singleton class for a registry object in PHP. As all Singleton classes I think the main method looks like this: class registry { public static function singleton() { if( !isset( self::$instance ) ) { self::$instance = new registry(); } return self::$instance; } public function doSomething() { echo 'something'; } } So whenever I need something of the registry class I use a function like this: registry::singleton()->doSomethine(); Now I do not understand what the difference is between creating just a normal static function. Will it create a new object if I just use a normal static class. class registry { public static function doSomething() { echo 'something'; } } Now I can just use: registry::doSomethine(); Can someone explain to me what the function is of the singleton class. I really do not understand this.

    Read the article

< Previous Page | 7 8 9 10 11 12 13 14 15 16  | Next Page >