Ccavenue iOS Kit Integration Kit

CCAvenue Gateway Integration kit for ios Application

Since the CCAvenue shows server side options we need to connect to web view and load the ccavenue gateway which is compatable with iphone screens.
Here in Our application we need to do small things as follows

First create the html file and parameters related to your ccavenue gateway

<html>

<body>

<form name='form2' method='post' action='UR URL HERE'>

<input type="text" name='Merchant_Id'><br>
<input type="text" name='Amount'><br>
<input type="text" name='Order_Id'><br>
<input type="text" name='Redirect_Url'><br>
<input type="text" name='Checksum'><br>
<input type="text" name='billing_cust_name'><br>
<input type="text" name='billing_cust_address'><br>
<input type="text" name='billing_cust_address'><br>
<input type="text" name='billing_cust_tel'><br>
<input type="text" name='billing_cust_email'><br>
<input type="text" name='delivery_cust_name'><br>
<input type="text" name='delivery_cust_address'><br>
<input type="text" name='delivery_cust_tel'><br>
<input type="text" name='delivery_cust_notes'><br>
<input type="text" name='Merchant_Param'><br>

</form>

</body>

After that load the web view on your screen

  NSURL *url = [NSURL URLWithString: @"https://www.ccavenue.com/shopzone/cc_details.jsp"];

webView.delegate = self;
webView.scalesPageToFit = YES;

NSString *strUsername = [[NSUserDefaults standardUserDefaults] objectForKey:@"userName"];

NSString *body = [NSString stringWithFormat: @"Merchant_Id=%@&Amount=%@&Order_Id=%@&Redirect_Url=%@&Checksum=%@&billing_cust_name=%@&billing_cust_address=%@&billing_cust_country=%@&billing_cust_tel=%@&billing_cust_email=%@&delivery_cust_name=%@&delivery_cust_address=%@&delivery_cust_tel=%@&delivery_cust_notes=%@&Merchant_Param=%@",@"XXXXX",@"10",@"123456",@"http://us2guntur.com/us2guntur/CCAvenueredirecturl.jsp",@"1234567890",@"Test",@"Hyderabad",@"India",@"1357896437",@"Test1000",@"Guntur",@"234567896",@"",@""];

NSLog(@"%@",body);

NSMutableURLRequest *request = [[NSMutableURLRequest alloc]initWithURL: url];
[request setHTTPMethod: @"POST"];
[request setHTTPBody: [body dataUsingEncoding: NSUTF8StringEncoding]];
[webView loadRequest: request];

CCAvenue iOS kit integration kit

I have achieved today only for IOS 9. To run just you need to download api from CCAvenue

We will Re Add by drag and drop openssl/ and lib/ folders

After downloading follow these steps:

  1. Delete old reference of from framework/build phases
  2. You will find 2 folders openssl/ and lib/ under Openssl/openssl-1.0.1i-iOS folder.
  3. Just drag drop each folder under Frameworks folder and DON'T FORGET TO CHECK COPY FILES IF NEEDED.
  4. Also under Build Settings of project go for Search Paths->Library Search Paths remove what is provided Users/test/desktop/.... and add $(PROJECT_DIR) again add $(inherited)
  5. Do 4th step for Search Paths->User Header Search Paths.remove and add same as 4th step.
  6. Compile you will find error gone.

I tested in Simulator working fine.

On Device

on device build was failed. To run on Device also.

  1. I set Enable Bitcode to NOunder Build Options for project
  2. Rebuild again and error gone.

ccavenue mobile app integration in iOS

Three simple steps:

  • (1) Go to Build Setting ,
  • (2) add your (openssl ios) lib path on libray search path ,
  • (3) add your (openssl ios) include path on user Header Search path

Sample Image



Related Topics



Leave a reply



Submit