How this post-UrlRequest of Android convert into IOS?
up vote
1
down vote
favorite
The below Jsoup post request i am trying to convert into IOS but not working like and also set cookies for this so, please any solution for this. i tried to 4-5 days but not success. so, please help me the android code like below:
str2 = Jsoup.connect("https://parivahan.gov.in/rcdlstatus/vahan/rcDlHome.xhtml").validateTLSCertificates(false).followRedirects(true)
.method(Method.POST).cookies(cookies).
referrer("https://parivahan.gov.in/rcdlstatus/?pur_cd=102").
header("Content-Type",
"application/x-www-form-urlencoded")
.header("Host", "parivahan.gov.in")
.header("HEADER_ACCEPT", "application/xml, text/xml, */*; q=0.01")
.header("Accept-Language", "en-US,en;q=0.5")
.header("Accept-Encoding", "gzip, deflate, br")
.header("X-Requested-With", "XMLHttpRequest")
.header("Faces-Request", "partial/ajax")
.header("Origin", "https://parivahan.gov.in")
.userAgent("Mozilla/5.0 (Windows NT 6.1; Win64; x64) " +
"AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.140 " +
"Safari/537.36").data("javax.faces.partial.ajax", "true")
.data("javax.faces.source", str2).data("javax.faces.partial.execute",
"@all").data("javax.faces.partial.render",
"form_rcdl:pnl_show form_rcdl:pg_show form_rcdl:rcdl_pnl")
.data(str2, str2).data("form_rcdl", "form_rcdl")
.data("form_rcdl:tf_reg_no1", str3).data("form_rcdl:tf_reg_no2", vhcasino)
.data("javax.faces.ViewState", vhtype).execute().body();
In this request many headers and parameter passed so how it perform in ios properly please give any suggestion for it.
My IOS Code :
let posturl = URL(string: "https://parivahan.gov.in/rcdlstatus/vahan/rcDlHome.xhtml")
var postreq = URLRequest(url: posturl!)
postreq.httpMethod = "POST"
HTTPCookieStorage.shared.setCookies(self.cookie, for: posturl!, mainDocumentURL: nil)
postreq.setValue("https://parivahan.gov.in/rcdlstatus/?pur_cd=102", forHTTPHeaderField: "Referer")
postreq.addValue("application/x-www-form-urlencoded", forHTTPHeaderField: "Content-Type")
postreq.addValue("application/xml, text/xml, */*; q=0.01", forHTTPHeaderField: "Accept")
postreq.setValue("parivahan.gov.in", forHTTPHeaderField: "Host")
postreq.setValue("en-US,en;q=0.5", forHTTPHeaderField: "Accept-Language")
postreq.setValue("gzip, deflate, br", forHTTPHeaderField: "accept-encoding")
postreq.setValue("XMLHttpRequest", forHTTPHeaderField: "X-Requested-With")
postreq.setValue("partial/ajax", forHTTPHeaderField: "Faces-Request")
postreq.setValue("https://parivahan.gov.in/", forHTTPHeaderField: "Origin")
let userAgent = "Mozilla/5.0 (Windows NT 6.1; Win64; x64) " + "AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.140" + "Safari/537.36"
postreq.setValue(userAgent, forHTTPHeaderField: "User-Agent")
let postparam = ["javax.faces.partial.ajax" : "true" ,
"javax.faces.source" : self.str2,
"javax.faces.partial.execute" : "@all",
"javax.faces.partial.render" : "form_rcdl:pnl_show form_rcdl:pg_show form_rcdl:rcdl_pnl" ,
self.str2 : self.str2 ,
"form_rcdl" : "form_rcdl" ,
"form_rcdl:tf_reg_no1" : self.regno1,
"form_rcdl:tf_reg_no2" : self.regno2,
"javax.faces.ViewState": self.vhtype]
do
{
postreq.httpBody = try JSONSerialization.data(withJSONObject: postparam, options: )
} catch {
print(error,"error in postreq body")
}
print(self.str2)
print(self.regno1,"reg no1")
print(self.regno2,"reg no2")
let posttask = URLSession.shared.dataTask(with: postreq, completionHandler: {(data, response, err) in
if let http = response as? HTTPURLResponse
{
print(http.statusCode)
}
if err == nil
{
let con = String(data: data!, encoding: String.Encoding(rawValue: String.Encoding.utf8.rawValue))as String?
print(con!,"post urlrequest content")
}
})
posttask.resume()
android ios swift nsurlrequest
|
show 3 more comments
up vote
1
down vote
favorite
The below Jsoup post request i am trying to convert into IOS but not working like and also set cookies for this so, please any solution for this. i tried to 4-5 days but not success. so, please help me the android code like below:
str2 = Jsoup.connect("https://parivahan.gov.in/rcdlstatus/vahan/rcDlHome.xhtml").validateTLSCertificates(false).followRedirects(true)
.method(Method.POST).cookies(cookies).
referrer("https://parivahan.gov.in/rcdlstatus/?pur_cd=102").
header("Content-Type",
"application/x-www-form-urlencoded")
.header("Host", "parivahan.gov.in")
.header("HEADER_ACCEPT", "application/xml, text/xml, */*; q=0.01")
.header("Accept-Language", "en-US,en;q=0.5")
.header("Accept-Encoding", "gzip, deflate, br")
.header("X-Requested-With", "XMLHttpRequest")
.header("Faces-Request", "partial/ajax")
.header("Origin", "https://parivahan.gov.in")
.userAgent("Mozilla/5.0 (Windows NT 6.1; Win64; x64) " +
"AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.140 " +
"Safari/537.36").data("javax.faces.partial.ajax", "true")
.data("javax.faces.source", str2).data("javax.faces.partial.execute",
"@all").data("javax.faces.partial.render",
"form_rcdl:pnl_show form_rcdl:pg_show form_rcdl:rcdl_pnl")
.data(str2, str2).data("form_rcdl", "form_rcdl")
.data("form_rcdl:tf_reg_no1", str3).data("form_rcdl:tf_reg_no2", vhcasino)
.data("javax.faces.ViewState", vhtype).execute().body();
In this request many headers and parameter passed so how it perform in ios properly please give any suggestion for it.
My IOS Code :
let posturl = URL(string: "https://parivahan.gov.in/rcdlstatus/vahan/rcDlHome.xhtml")
var postreq = URLRequest(url: posturl!)
postreq.httpMethod = "POST"
HTTPCookieStorage.shared.setCookies(self.cookie, for: posturl!, mainDocumentURL: nil)
postreq.setValue("https://parivahan.gov.in/rcdlstatus/?pur_cd=102", forHTTPHeaderField: "Referer")
postreq.addValue("application/x-www-form-urlencoded", forHTTPHeaderField: "Content-Type")
postreq.addValue("application/xml, text/xml, */*; q=0.01", forHTTPHeaderField: "Accept")
postreq.setValue("parivahan.gov.in", forHTTPHeaderField: "Host")
postreq.setValue("en-US,en;q=0.5", forHTTPHeaderField: "Accept-Language")
postreq.setValue("gzip, deflate, br", forHTTPHeaderField: "accept-encoding")
postreq.setValue("XMLHttpRequest", forHTTPHeaderField: "X-Requested-With")
postreq.setValue("partial/ajax", forHTTPHeaderField: "Faces-Request")
postreq.setValue("https://parivahan.gov.in/", forHTTPHeaderField: "Origin")
let userAgent = "Mozilla/5.0 (Windows NT 6.1; Win64; x64) " + "AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.140" + "Safari/537.36"
postreq.setValue(userAgent, forHTTPHeaderField: "User-Agent")
let postparam = ["javax.faces.partial.ajax" : "true" ,
"javax.faces.source" : self.str2,
"javax.faces.partial.execute" : "@all",
"javax.faces.partial.render" : "form_rcdl:pnl_show form_rcdl:pg_show form_rcdl:rcdl_pnl" ,
self.str2 : self.str2 ,
"form_rcdl" : "form_rcdl" ,
"form_rcdl:tf_reg_no1" : self.regno1,
"form_rcdl:tf_reg_no2" : self.regno2,
"javax.faces.ViewState": self.vhtype]
do
{
postreq.httpBody = try JSONSerialization.data(withJSONObject: postparam, options: )
} catch {
print(error,"error in postreq body")
}
print(self.str2)
print(self.regno1,"reg no1")
print(self.regno2,"reg no2")
let posttask = URLSession.shared.dataTask(with: postreq, completionHandler: {(data, response, err) in
if let http = response as? HTTPURLResponse
{
print(http.statusCode)
}
if err == nil
{
let con = String(data: data!, encoding: String.Encoding(rawValue: String.Encoding.utf8.rawValue))as String?
print(con!,"post urlrequest content")
}
})
posttask.resume()
android ios swift nsurlrequest
1
you can use postman to generate swift code for your api
– Vivek Mishra
Nov 20 at 5:28
1
how use postman for this can you guide me ?
– jinal rakholiya
Nov 20 at 5:29
2
execute your api as you normally do in postman and after that click on the code option on the right side. From their it will show you a dropdown that in which language you want to generate the code for
– Vivek Mishra
Nov 20 at 5:33
1
But this is not api it is a URL and get html partial-response in output so how can i go ?
– jinal rakholiya
Nov 20 at 5:37
@jinalrakholiya Can you please share your IOS code with parameter , header and url.
– Dixit Akabari
Nov 21 at 6:36
|
show 3 more comments
up vote
1
down vote
favorite
up vote
1
down vote
favorite
The below Jsoup post request i am trying to convert into IOS but not working like and also set cookies for this so, please any solution for this. i tried to 4-5 days but not success. so, please help me the android code like below:
str2 = Jsoup.connect("https://parivahan.gov.in/rcdlstatus/vahan/rcDlHome.xhtml").validateTLSCertificates(false).followRedirects(true)
.method(Method.POST).cookies(cookies).
referrer("https://parivahan.gov.in/rcdlstatus/?pur_cd=102").
header("Content-Type",
"application/x-www-form-urlencoded")
.header("Host", "parivahan.gov.in")
.header("HEADER_ACCEPT", "application/xml, text/xml, */*; q=0.01")
.header("Accept-Language", "en-US,en;q=0.5")
.header("Accept-Encoding", "gzip, deflate, br")
.header("X-Requested-With", "XMLHttpRequest")
.header("Faces-Request", "partial/ajax")
.header("Origin", "https://parivahan.gov.in")
.userAgent("Mozilla/5.0 (Windows NT 6.1; Win64; x64) " +
"AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.140 " +
"Safari/537.36").data("javax.faces.partial.ajax", "true")
.data("javax.faces.source", str2).data("javax.faces.partial.execute",
"@all").data("javax.faces.partial.render",
"form_rcdl:pnl_show form_rcdl:pg_show form_rcdl:rcdl_pnl")
.data(str2, str2).data("form_rcdl", "form_rcdl")
.data("form_rcdl:tf_reg_no1", str3).data("form_rcdl:tf_reg_no2", vhcasino)
.data("javax.faces.ViewState", vhtype).execute().body();
In this request many headers and parameter passed so how it perform in ios properly please give any suggestion for it.
My IOS Code :
let posturl = URL(string: "https://parivahan.gov.in/rcdlstatus/vahan/rcDlHome.xhtml")
var postreq = URLRequest(url: posturl!)
postreq.httpMethod = "POST"
HTTPCookieStorage.shared.setCookies(self.cookie, for: posturl!, mainDocumentURL: nil)
postreq.setValue("https://parivahan.gov.in/rcdlstatus/?pur_cd=102", forHTTPHeaderField: "Referer")
postreq.addValue("application/x-www-form-urlencoded", forHTTPHeaderField: "Content-Type")
postreq.addValue("application/xml, text/xml, */*; q=0.01", forHTTPHeaderField: "Accept")
postreq.setValue("parivahan.gov.in", forHTTPHeaderField: "Host")
postreq.setValue("en-US,en;q=0.5", forHTTPHeaderField: "Accept-Language")
postreq.setValue("gzip, deflate, br", forHTTPHeaderField: "accept-encoding")
postreq.setValue("XMLHttpRequest", forHTTPHeaderField: "X-Requested-With")
postreq.setValue("partial/ajax", forHTTPHeaderField: "Faces-Request")
postreq.setValue("https://parivahan.gov.in/", forHTTPHeaderField: "Origin")
let userAgent = "Mozilla/5.0 (Windows NT 6.1; Win64; x64) " + "AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.140" + "Safari/537.36"
postreq.setValue(userAgent, forHTTPHeaderField: "User-Agent")
let postparam = ["javax.faces.partial.ajax" : "true" ,
"javax.faces.source" : self.str2,
"javax.faces.partial.execute" : "@all",
"javax.faces.partial.render" : "form_rcdl:pnl_show form_rcdl:pg_show form_rcdl:rcdl_pnl" ,
self.str2 : self.str2 ,
"form_rcdl" : "form_rcdl" ,
"form_rcdl:tf_reg_no1" : self.regno1,
"form_rcdl:tf_reg_no2" : self.regno2,
"javax.faces.ViewState": self.vhtype]
do
{
postreq.httpBody = try JSONSerialization.data(withJSONObject: postparam, options: )
} catch {
print(error,"error in postreq body")
}
print(self.str2)
print(self.regno1,"reg no1")
print(self.regno2,"reg no2")
let posttask = URLSession.shared.dataTask(with: postreq, completionHandler: {(data, response, err) in
if let http = response as? HTTPURLResponse
{
print(http.statusCode)
}
if err == nil
{
let con = String(data: data!, encoding: String.Encoding(rawValue: String.Encoding.utf8.rawValue))as String?
print(con!,"post urlrequest content")
}
})
posttask.resume()
android ios swift nsurlrequest
The below Jsoup post request i am trying to convert into IOS but not working like and also set cookies for this so, please any solution for this. i tried to 4-5 days but not success. so, please help me the android code like below:
str2 = Jsoup.connect("https://parivahan.gov.in/rcdlstatus/vahan/rcDlHome.xhtml").validateTLSCertificates(false).followRedirects(true)
.method(Method.POST).cookies(cookies).
referrer("https://parivahan.gov.in/rcdlstatus/?pur_cd=102").
header("Content-Type",
"application/x-www-form-urlencoded")
.header("Host", "parivahan.gov.in")
.header("HEADER_ACCEPT", "application/xml, text/xml, */*; q=0.01")
.header("Accept-Language", "en-US,en;q=0.5")
.header("Accept-Encoding", "gzip, deflate, br")
.header("X-Requested-With", "XMLHttpRequest")
.header("Faces-Request", "partial/ajax")
.header("Origin", "https://parivahan.gov.in")
.userAgent("Mozilla/5.0 (Windows NT 6.1; Win64; x64) " +
"AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.140 " +
"Safari/537.36").data("javax.faces.partial.ajax", "true")
.data("javax.faces.source", str2).data("javax.faces.partial.execute",
"@all").data("javax.faces.partial.render",
"form_rcdl:pnl_show form_rcdl:pg_show form_rcdl:rcdl_pnl")
.data(str2, str2).data("form_rcdl", "form_rcdl")
.data("form_rcdl:tf_reg_no1", str3).data("form_rcdl:tf_reg_no2", vhcasino)
.data("javax.faces.ViewState", vhtype).execute().body();
In this request many headers and parameter passed so how it perform in ios properly please give any suggestion for it.
My IOS Code :
let posturl = URL(string: "https://parivahan.gov.in/rcdlstatus/vahan/rcDlHome.xhtml")
var postreq = URLRequest(url: posturl!)
postreq.httpMethod = "POST"
HTTPCookieStorage.shared.setCookies(self.cookie, for: posturl!, mainDocumentURL: nil)
postreq.setValue("https://parivahan.gov.in/rcdlstatus/?pur_cd=102", forHTTPHeaderField: "Referer")
postreq.addValue("application/x-www-form-urlencoded", forHTTPHeaderField: "Content-Type")
postreq.addValue("application/xml, text/xml, */*; q=0.01", forHTTPHeaderField: "Accept")
postreq.setValue("parivahan.gov.in", forHTTPHeaderField: "Host")
postreq.setValue("en-US,en;q=0.5", forHTTPHeaderField: "Accept-Language")
postreq.setValue("gzip, deflate, br", forHTTPHeaderField: "accept-encoding")
postreq.setValue("XMLHttpRequest", forHTTPHeaderField: "X-Requested-With")
postreq.setValue("partial/ajax", forHTTPHeaderField: "Faces-Request")
postreq.setValue("https://parivahan.gov.in/", forHTTPHeaderField: "Origin")
let userAgent = "Mozilla/5.0 (Windows NT 6.1; Win64; x64) " + "AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.140" + "Safari/537.36"
postreq.setValue(userAgent, forHTTPHeaderField: "User-Agent")
let postparam = ["javax.faces.partial.ajax" : "true" ,
"javax.faces.source" : self.str2,
"javax.faces.partial.execute" : "@all",
"javax.faces.partial.render" : "form_rcdl:pnl_show form_rcdl:pg_show form_rcdl:rcdl_pnl" ,
self.str2 : self.str2 ,
"form_rcdl" : "form_rcdl" ,
"form_rcdl:tf_reg_no1" : self.regno1,
"form_rcdl:tf_reg_no2" : self.regno2,
"javax.faces.ViewState": self.vhtype]
do
{
postreq.httpBody = try JSONSerialization.data(withJSONObject: postparam, options: )
} catch {
print(error,"error in postreq body")
}
print(self.str2)
print(self.regno1,"reg no1")
print(self.regno2,"reg no2")
let posttask = URLSession.shared.dataTask(with: postreq, completionHandler: {(data, response, err) in
if let http = response as? HTTPURLResponse
{
print(http.statusCode)
}
if err == nil
{
let con = String(data: data!, encoding: String.Encoding(rawValue: String.Encoding.utf8.rawValue))as String?
print(con!,"post urlrequest content")
}
})
posttask.resume()
android ios swift nsurlrequest
android ios swift nsurlrequest
edited Nov 21 at 6:38
asked Nov 20 at 5:20
jinal rakholiya
253
253
1
you can use postman to generate swift code for your api
– Vivek Mishra
Nov 20 at 5:28
1
how use postman for this can you guide me ?
– jinal rakholiya
Nov 20 at 5:29
2
execute your api as you normally do in postman and after that click on the code option on the right side. From their it will show you a dropdown that in which language you want to generate the code for
– Vivek Mishra
Nov 20 at 5:33
1
But this is not api it is a URL and get html partial-response in output so how can i go ?
– jinal rakholiya
Nov 20 at 5:37
@jinalrakholiya Can you please share your IOS code with parameter , header and url.
– Dixit Akabari
Nov 21 at 6:36
|
show 3 more comments
1
you can use postman to generate swift code for your api
– Vivek Mishra
Nov 20 at 5:28
1
how use postman for this can you guide me ?
– jinal rakholiya
Nov 20 at 5:29
2
execute your api as you normally do in postman and after that click on the code option on the right side. From their it will show you a dropdown that in which language you want to generate the code for
– Vivek Mishra
Nov 20 at 5:33
1
But this is not api it is a URL and get html partial-response in output so how can i go ?
– jinal rakholiya
Nov 20 at 5:37
@jinalrakholiya Can you please share your IOS code with parameter , header and url.
– Dixit Akabari
Nov 21 at 6:36
1
1
you can use postman to generate swift code for your api
– Vivek Mishra
Nov 20 at 5:28
you can use postman to generate swift code for your api
– Vivek Mishra
Nov 20 at 5:28
1
1
how use postman for this can you guide me ?
– jinal rakholiya
Nov 20 at 5:29
how use postman for this can you guide me ?
– jinal rakholiya
Nov 20 at 5:29
2
2
execute your api as you normally do in postman and after that click on the code option on the right side. From their it will show you a dropdown that in which language you want to generate the code for
– Vivek Mishra
Nov 20 at 5:33
execute your api as you normally do in postman and after that click on the code option on the right side. From their it will show you a dropdown that in which language you want to generate the code for
– Vivek Mishra
Nov 20 at 5:33
1
1
But this is not api it is a URL and get html partial-response in output so how can i go ?
– jinal rakholiya
Nov 20 at 5:37
But this is not api it is a URL and get html partial-response in output so how can i go ?
– jinal rakholiya
Nov 20 at 5:37
@jinalrakholiya Can you please share your IOS code with parameter , header and url.
– Dixit Akabari
Nov 21 at 6:36
@jinalrakholiya Can you please share your IOS code with parameter , header and url.
– Dixit Akabari
Nov 21 at 6:36
|
show 3 more comments
1 Answer
1
active
oldest
votes
up vote
0
down vote
You are using Html Parser for Android which will not work on the Swift(IOS) you have to use different plugin I am Not pro in Swift but i found this Plugin hope it helps.
And a Bit Suggestion Swift is based on objective c that is different Language than Android which is using Kotlin and Java we cannot Use Same Plugin
1
So, how can i achieve this task ?
– jinal rakholiya
Nov 20 at 5:49
1
@jinalrakholiya follow these Links 1.) stackoverflow.com/questions/31080818/… 2.) github.com/scinfu/SwiftSoup and Study them
– Prem Sarojanand
Nov 20 at 6:18
1
This is the html parser but i wan't to get response from post request with header and parameter like above. the html parser use in next step after completely get response.
– jinal rakholiya
Nov 20 at 6:22
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
0
down vote
You are using Html Parser for Android which will not work on the Swift(IOS) you have to use different plugin I am Not pro in Swift but i found this Plugin hope it helps.
And a Bit Suggestion Swift is based on objective c that is different Language than Android which is using Kotlin and Java we cannot Use Same Plugin
1
So, how can i achieve this task ?
– jinal rakholiya
Nov 20 at 5:49
1
@jinalrakholiya follow these Links 1.) stackoverflow.com/questions/31080818/… 2.) github.com/scinfu/SwiftSoup and Study them
– Prem Sarojanand
Nov 20 at 6:18
1
This is the html parser but i wan't to get response from post request with header and parameter like above. the html parser use in next step after completely get response.
– jinal rakholiya
Nov 20 at 6:22
add a comment |
up vote
0
down vote
You are using Html Parser for Android which will not work on the Swift(IOS) you have to use different plugin I am Not pro in Swift but i found this Plugin hope it helps.
And a Bit Suggestion Swift is based on objective c that is different Language than Android which is using Kotlin and Java we cannot Use Same Plugin
1
So, how can i achieve this task ?
– jinal rakholiya
Nov 20 at 5:49
1
@jinalrakholiya follow these Links 1.) stackoverflow.com/questions/31080818/… 2.) github.com/scinfu/SwiftSoup and Study them
– Prem Sarojanand
Nov 20 at 6:18
1
This is the html parser but i wan't to get response from post request with header and parameter like above. the html parser use in next step after completely get response.
– jinal rakholiya
Nov 20 at 6:22
add a comment |
up vote
0
down vote
up vote
0
down vote
You are using Html Parser for Android which will not work on the Swift(IOS) you have to use different plugin I am Not pro in Swift but i found this Plugin hope it helps.
And a Bit Suggestion Swift is based on objective c that is different Language than Android which is using Kotlin and Java we cannot Use Same Plugin
You are using Html Parser for Android which will not work on the Swift(IOS) you have to use different plugin I am Not pro in Swift but i found this Plugin hope it helps.
And a Bit Suggestion Swift is based on objective c that is different Language than Android which is using Kotlin and Java we cannot Use Same Plugin
answered Nov 20 at 5:47
Prem Sarojanand
147
147
1
So, how can i achieve this task ?
– jinal rakholiya
Nov 20 at 5:49
1
@jinalrakholiya follow these Links 1.) stackoverflow.com/questions/31080818/… 2.) github.com/scinfu/SwiftSoup and Study them
– Prem Sarojanand
Nov 20 at 6:18
1
This is the html parser but i wan't to get response from post request with header and parameter like above. the html parser use in next step after completely get response.
– jinal rakholiya
Nov 20 at 6:22
add a comment |
1
So, how can i achieve this task ?
– jinal rakholiya
Nov 20 at 5:49
1
@jinalrakholiya follow these Links 1.) stackoverflow.com/questions/31080818/… 2.) github.com/scinfu/SwiftSoup and Study them
– Prem Sarojanand
Nov 20 at 6:18
1
This is the html parser but i wan't to get response from post request with header and parameter like above. the html parser use in next step after completely get response.
– jinal rakholiya
Nov 20 at 6:22
1
1
So, how can i achieve this task ?
– jinal rakholiya
Nov 20 at 5:49
So, how can i achieve this task ?
– jinal rakholiya
Nov 20 at 5:49
1
1
@jinalrakholiya follow these Links 1.) stackoverflow.com/questions/31080818/… 2.) github.com/scinfu/SwiftSoup and Study them
– Prem Sarojanand
Nov 20 at 6:18
@jinalrakholiya follow these Links 1.) stackoverflow.com/questions/31080818/… 2.) github.com/scinfu/SwiftSoup and Study them
– Prem Sarojanand
Nov 20 at 6:18
1
1
This is the html parser but i wan't to get response from post request with header and parameter like above. the html parser use in next step after completely get response.
– jinal rakholiya
Nov 20 at 6:22
This is the html parser but i wan't to get response from post request with header and parameter like above. the html parser use in next step after completely get response.
– jinal rakholiya
Nov 20 at 6:22
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53386669%2fhow-this-post-urlrequest-of-android-convert-into-ios%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
1
you can use postman to generate swift code for your api
– Vivek Mishra
Nov 20 at 5:28
1
how use postman for this can you guide me ?
– jinal rakholiya
Nov 20 at 5:29
2
execute your api as you normally do in postman and after that click on the code option on the right side. From their it will show you a dropdown that in which language you want to generate the code for
– Vivek Mishra
Nov 20 at 5:33
1
But this is not api it is a URL and get html partial-response in output so how can i go ?
– jinal rakholiya
Nov 20 at 5:37
@jinalrakholiya Can you please share your IOS code with parameter , header and url.
– Dixit Akabari
Nov 21 at 6:36