<div dir="ltr"><div><div><div><div><div><div><div><div><div>Hi All,<br><br></div>I would like to know how can i rewrite/convert a URL containing number is scientific form to normal integer.<br><br></div>For eg: <br><br></div>
I have something like this coming in the URL<br><br></div><a href="http://domain.com/public/domain/app/1.024e+06/1028422/1028422_b24db5c8391ec5c5d93cd0ac083acbdf">http://domain.com/public/domain/app/1.024e+06/1028422/1028422_b24db5c8391ec5c5d93cd0ac083acbdf</a><br>
<br></div>I would like to have to have the URL having a normal integer so the output should be <br><br><a href="http://domain.com/public/domain/app/1024000/1028422/1028422_b24db5c8391ec5c5d93cd0ac083acbdf">http://domain.com/public/domain/app/1024000/1028422/1028422_b24db5c8391ec5c5d93cd0ac083acbdf</a><br>
<br></div>Playing around something like this for testing<br><br> if (req.http.Host ~ "<a href="http://domain.com">domain.com</a>") {<br> set req.url = regsub(req.url, "^/public/domain/app/[+|-]?\d\.?\d{0,}[E|e|X|x](10)?[\^\*]?[+|-]?\d+/(.*)/(.*)$", "/public/domain/app/\d+/(.*)/(.*)$");<br>
}<br><br><br></div>Any ideas or any clues if the syntax for the matching scientific nos is correct?<br><br></div>Regards,<br></div>Kevin<br></div>