Search Results

Search found 261 results on 11 pages for 'mohammad ashraful alam'.

Page 6/11 | < Previous Page | 2 3 4 5 6 7 8 9 10 11  | Next Page >

  • news website with php and links

    - by mohammad reza
    newly i have created a news website, everything is based on php and mysql, NOW with more attention on other news website i see something wrong with my site in all of them when you are click on a news, that news open like a new page and in link bar you can see the link of that news like this: http://www.wired.com/wiredscience/2012/09/space-shuttle-endeavour-lands-in-los-angeles/ BUT in my website i have a page that named viewer.php and this page connected to database, when you are click on a news in my site you see something like this in link bar: www.example.com/viewer.php?ne_id=14 ne_id in my news table set specific number for a news like 14 and all of news (title, content and so on)saved on database how that site work? how to create like that site? i don't have any idea? if you know somthing (EVERYTHING) i need it please , i have really confused really sorry for my terrible english and thanks for your time

    Read the article

  • Unable to load detached NIB in View

    - by Sheehan Alam
    I have two NIB's ParentViewController.xib ChildViewController.xib ParentViewController.xib contains a UIView and a UIViewController. ChildViewController.xib contains a UIButton I want ChildViewController.xib to load in the ParentViewController.xib's UIView I have done the following: Created @property for UIView in ParentViewController Connected File's Owner to UIView in ParentViewController Set UIViewController in ParentViewController's NIB Name property to ChildViewController in Interface Builder Set ChildViewController view property to UIView in ParentViewController I was hoping this would load ChildViewController into my UIView in ParentViewController but no luck. I did get the following warning, which could be the culprit: 'View Controller (Child View)' has both its 'NIB Name' property set and its 'view' outlet connected. This configuration is not supported. I also have added additional code in ParentViewController's viewDidLoad(): - (void)viewDidLoad { [super viewDidLoad]; ChildViewController *childViewController = [[ChildViewController alloc]initWithNibName:@"ChildViewController" bundle:nil]; childViewController.view = self.myView; } Any thoughts on why ChildViewController does not load in the UIView of ParentViewController?

    Read the article

  • How to detect if certain characters are at the end of an NSString?

    - by Sheehan Alam
    Let's assume I can have the following strings: "hey @john..." "@john, hello" "@john(hello)" I am tokenizing the string to get every word separated by a space: [myString componentsSeparatedByString:@" "]; My array of tokens now contain: @john... @john, @john(hello) For these cases. How can I make sure only @john is tokenized, while retaining the trailing characters: ... , (hello) Note: I would like to be able to handle all cases of characters at the end of a string. The above are just 3 examples.

    Read the article

  • Loading an external image via XAML code in WPF?

    - by Mohammad
    I have an image lock.png beside of my WPF exe file in the images folder. Now, I'm gonna load it into the WPF Project as an image, I've used the following XAML code: <Image Stretch="Fill" Source="pack://siteoforigin:,,,/images/lock.png" /> It works, but Expression Blend or Visual Studio doesn't show it when I'm working on the project. How can we show external images in these situations?

    Read the article

  • Presenting a Popover From a Rect Problem

    - by Sheehan Alam
    I have a UITableViewCell that has some labels and images that can be clicked. I want to present a popover whenever a user clicks on any part of the cell. How can I achieve this without interfering with the click actions of the labels & images? I am currently creating an invisible button ontop of some other clickable items in the cell and calling the popover: [replyPopover presentPopoverFromRect:CGRectMake(77, 25, 408, 68) inView:self permittedArrowDirections: UIPopoverArrowDirectionDown animated:YES]; Unfortunately, because the button is on top of the labels & images I am unable to click them. How can I show a popover by clicking on the background of a cell, so that there is no interference when clicking images & labels inside the cell?

    Read the article

  • Memory over-release problem when I am animating UIView

    - by Sheehan Alam
    I have enabled NSZombie's and I am getting the following message in my console when I am running my application: *** -[UIViewAnimationState release]: message sent to deallocated instance 0xf96d7e0 Here is the method that is performing the animation -(void)loadAvatar:(STObject*)st { NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init]; avatar.alpha = 0; avatar.frame = avatarRectSmall; avatar.image = [ImageCache getMemoryCachedImageAtUrl:st.avatar_url]; [UIView beginAnimations:nil context:nil]; [UIView setAnimationDuration:.50]; avatar.frame = avatarRectNormal; [avatar setAlpha:1]; [UIView commitAnimations]; [pool release]; pool = nil; } I don't always get a crash, only sometimes. I'm wondering what is getting released?

    Read the article

  • jQuery DOM element creation vs innerHTML

    - by Mohammad
    While having one of my questions answered, cletus mentioned that when creating elements in jQuery it's better to use direct DOM element creation, instead of innerHTML. I tried googling it but I wasn't able to find a good article with comparisons. I've provided this code bellow as an example and I was wondering if someone could help me rewrite it in direct DOM element creation form in hope that i would also learn the difference afterwards. var img = $(this); img.append('<p class="cap"><a href="'+img.parent().attr('href')+'">'+ img.attr('title')+'</p></a>'); Thanks so much.

    Read the article

  • Problem with reusing UITableViewCell's

    - by Sheehan Alam
    I have a UITableView that is re-using cells when the user scrolls. Everything appears and scrolls fine, except when the user clicks on an actual row, the highlighted cell displays some text from another cell. I'm not exactly sure why. #define IMAGE_TAG 1111 #define LOGIN_TAG 2222 #define FULL_NAME_TAG 3333 // Customize the appearance of table view cells. - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { static NSString *CellIdentifier = @"Cell"; STUser *mySTUser = [[[STUser alloc]init]autorelease]; mySTUser = [items objectAtIndex:indexPath.row]; AsyncImageView* asyncImage = nil; UILabel* loginLabel = nil; UILabel* fullNameLabel = nil; UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier]; if (cell == nil) { cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:CellIdentifier] autorelease]; } else { asyncImage = (AsyncImageView *) [cell.contentView viewWithTag:IMAGE_TAG]; loginLabel = (UILabel *) [cell.contentView viewWithTag:LOGIN_TAG]; fullNameLabel = (UILabel *) [cell.contentView viewWithTag:FULL_NAME_TAG]; } // Configure the cell... cell.accessoryType = UITableViewCellAccessoryDisclosureIndicator; CGRect frame = CGRectMake(0, 0, 44, 44); asyncImage = [[[AsyncImageView alloc]initWithFrame:frame] autorelease]; asyncImage.tag = IMAGE_TAG; NSURL* url = [NSURL URLWithString:mySTUser.avatar_url_large]; [asyncImage loadImageFromURL:url]; [cell.contentView addSubview:asyncImage]; loginLabel.tag = LOGIN_TAG; CGRect loginLabelFrame = CGRectMake(60, 0, 200, 10); loginLabel = [[[UILabel alloc] initWithFrame:loginLabelFrame] autorelease]; loginLabel.text = [NSString stringWithFormat:@"%@",mySTUser.login]; [cell.contentView addSubview:loginLabel]; fullNameLabel.tag = FULL_NAME_TAG; CGRect fullNameLabelFrame = CGRectMake(60, 20, 200, 10); fullNameLabel = [[[UILabel alloc] initWithFrame:fullNameLabelFrame] autorelease]; fullNameLabel.text = [NSString stringWithFormat:@"%@ %@",mySTUser.first_name, mySTUser.last_name]; //[NSString stringWithFormat:@"%@",mySTUser.login]; [cell.contentView addSubview:fullNameLabel]; return cell; }

    Read the article

  • Memory problem with basic UITableView when scrolling

    - by Sheehan Alam
    I have a very simple UITableView that has 3 sections, and 3 rows per section. #pragma mark - #pragma mark UITableView delegate methods - (NSInteger)tableView:(UITableView *)tblView numberOfRowsInSection:(NSInteger)section { return 3; } - (UITableViewCell *)tableView:(UITableView *)tblView cellForRowAtIndexPath:(NSIndexPath *)indexPath { static NSString *CellIdentifier = @"Cell"; UITableViewCell *cell = [tblView dequeueReusableCellWithIdentifier:CellIdentifier]; if (cell == nil) { cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] autorelease]; } // Configure the cell... return cell; } - (NSInteger)numberOfSectionsInTableView:(UITableView *)tblView { if (tblView == self.tableView) { return 3; } else { return 1; } } Everything shows up fine, but as soon as I scroll my application crashes and my debugger tells me: * -[ProfileViewController tableView:cellForRowAtIndexPath:]: message sent to deallocated instance 0x5ae61b0 I'm not exactly sure what I am doing wrong.

    Read the article

  • How to add dimensions to dynamic img elements

    - by Mohammad
    I use a Json call to get a list of image addresses, then I add them individually to a div like this. <div id="container"> <img src="A.jpg" alt="" /> <img src="B.jpg" alt="" /> ... </div> Unfortunately the image dimension is not part of the Json information but I do need them for later JQuery DOM interactivity. Do any of you JQuery geniuses know of a code that would flawlessly add the width and height to the individual image elements in the container after they load? I was thinking maybe the code could wait for the images to have a width bigger than 5px then add the new width and height to the element. But I wouldn't know how to go about that and make it work stably. Thank you so much!

    Read the article

  • UIPageControl design challenge

    - by Sheehan Alam
    My app has a UITabBarController that loads many different UINavigationControllers. I want a UIPageControl to switch between the different UINavigationControllers. Do I place the UIPageControl in my UINavigationController or in my appDelegate? Suggestions and best practices are welcome.

    Read the article

  • Can't compile code when working with CALayer

    - by Sheehan Alam
    For some reason I get linker errors when I try and use CALayer: "_OBJC_CLASS_$_CALayer", referenced from: I have imported the following headers: #import <Foundation/Foundation.h> #import <UIKit/UIKit.h> #import <QuartzCore/QuartzCore.h> Code: arrowImage = [[CALayer alloc] init];

    Read the article

  • Navigation Items in UITableViewController are not appearing?

    - by Sheehan Alam
    I am displaying a UITableViewController inside of a UITabBarController that is being presented modally: -(IBAction)arButtonClicked:(id)sender{ //this is a uitableviewcontroller ARViewController* arViewController = [[[ARViewController alloc] initWithNibName:@"ARViewController" bundle:nil]autorelease]; LeaderBoardTableViewController* lbViewController = [[[LeaderBoardTableViewController alloc] initWithNibName:@"LeaderBoardTableViewController" bundle:nil]autorelease]; lbViewController.title = @"Leaderboard"; arTabBarController = [[UITabBarController alloc] initWithNibName:nil bundle:nil]; arTabBarController.viewControllers = [NSArray arrayWithObjects:arViewController, lbViewController, nil]; arTabBarController.selectedViewController = arViewController; [self presentModalViewController:arTabBarController animated:YES]; } In my viewDidLoad for arViewController method I am setting the navigation items: - (void)viewDidLoad { [super viewDidLoad]; // Uncomment the following line to preserve selection between presentations. self.clearsSelectionOnViewWillAppear = NO; self.title = @"AR"; leaderBoardButton = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemOrganize target:self action:@selector(leaderBoardButtonClicked:)]; self.navigationItem.rightBarButtonItem = leaderBoardButton; } My navigation bar doesn't appear when it is inside of the UITabBarController, but when I push the view itself I am able to see it. What am I missing?

    Read the article

  • Problem streaming video on iPhone, only audio is playing

    - by Sheehan Alam
    I am trying to stream a video using MPMoviePlayerController but only audio is working. How can I get the video to appear? - (void)loadView { NSString *url = @"http://d1xt8xjto3lfs9.cloudfront.net/060810/afternoonupdate060810.mov"; MPMoviePlayerController *moviePlayer = [[MPMoviePlayerController alloc] initWithContentURL:[NSURL URLWithString:url]]; [moviePlayer play]; }

    Read the article

  • How to scroll the horizontal scrollbar in an iFrame from the parent frame?

    - by Mohammad
    Is there any cross browser way to scroll the horizontal scroll bar of an IFrame with super wide content with Javascript inside the parent frame. Also I need it to be attached to the mouse wheel event. This is what I have so far, it's a bit copy and paste at the moment and doesn't work unfortunately. //var myIframe = document.getElementById('iframeWithWideContent'); //myIframe.onload = function (myIframe) { var mouseWheelEvt = function (e){ var event = e || window.event; if (document.body.doScroll){ document.body.doScroll(event.wheelDelta>0?"left":"right"); }else if ((event.wheelDelta || event.detail) > 0){ document.body.scrollLeft -= 10; }else{ document.body.scrollLeft += 10; } return false; } if ("onmousewheel" in document.body){ document.body.onmousewheel = mouseWheelEvt; }else{ document.body.addEventListener("DOMMouseScroll", mouseWheelEvt); } //}? I probably should uncomment that code, replace document.body with myIframe though I wouldn't know what I'm doing wrong. Demo on JSBIN link fixed Any help from you JavaScript Lords would be very appreciated. Thank you!

    Read the article

< Previous Page | 2 3 4 5 6 7 8 9 10 11  | Next Page >