Tuesday, October 28, 2014

Jquery Prev and Next selector

.prev() and .next() both are Traversing Method . “.prev” Method Returns the previous sibling element of the selected element and
  “next()”Returns the next sibling element of the selected element
.Prev example
<ul>
  <li>list item 1</li>
  <li id=”item2">list item 2</li>
  <li id=”item3">list item 3</li>
  <li>list item 4</li>
  <li>list item 5</li>
</ul>

$("li#item3" ).prev().css( "background-color", "red" );
In this example output second li background –color goes to red

.next() example

P
<ul>
  <li>list item 1</li>
  <li id=”item2">list item 2</li>
  <li id=”item3">list item 3</li>
  <li id=”item4">list item 4</li>
  <li>list item 5</li>
</ul>

$("li#item3" ).next().css( "background-color", "red" );
In this example output fourth li background –color goes to red






Friday, October 17, 2014

PayPal Payflow Pro Payment gateway implementation asp.net

Payflow is a payment gateway that allows you to pay using a credit card or checks, among others. PayPal accounts are not supported by Payflow. You can sign up for an account,  if you create developer testing account you have to the follow the step
1) On registration page   please checked the checkbox “  I do not have a Processor. Setup test account.”
2) Fill out the from
3) click on read Gateway Agreement (otherwise term condition checkbox is not enable)
4) Checked the term condition checkbox
After the submit button your testing account is created. Now  you are able to log intohttps://manager.paypal.com to manage your account settings. Here PayPal ask to login the following credential
USER : when you have create account in registration field (Login Name )
VENDOR  : (same   as user)
PARTNER : by default PayPal
PWD : when you have create account in registration field (Password )

So you have completed the account related stuff. Now you can download the paypaflow sdk from this link (http://paypal.github.io/sdk/ )  and integrate according to your application .don’t forget to set up your  credential

Timer concept javascript asp.net

In this example we have shown SetInveral   JavaScript function how to use. The following example is give below


  <span id="sptimeLeft" style="font-weight: bold; color: red"></span>

<script type="text/javascript">

             var tm = null;
                function TimerDisplay(n) {

                    tm = setInterval(countDown, 1000);

                    function countDown() {
                        n--;
                        if (n == 0) {
                            clearInterval(tm);
                        }
                        $("#sptimeLeft").html(n + " seconds Left");
                    }
                }

        $(function () {

            $(".red").on('click'function () {
               
                    TimerDisplay40);
               
                else {
                    clearInterval(tm);
                    $("#sptimeLeft").html("");
                }

            }
            );

        });
    </script>



comma separated values in oracle sql

Oracle coma Spited value Using regular Expression
select regexp_substr('1,2,3,4,'[^,]+', 1, level) as name from  dual
connect by regexp_substr('1,2,3,4, '[^,]+', 1, level) is not null

PayU payment gateway implementation asp.net

PayU also offers an online interface where the merchant can view transaction details, settlement reports, analytic reports etc. and also take action like capture, cancel, refund etc. This online interface can be accessed through https://www.PayU.in by using the username and password provided to you.

In order to asp.net intergrate  payu  Payment gateway . https://www.payu.co.za/for-developers/?selectedProduct=easymerchant clicks on this link. Some samples are provided in the above link. After seeing that you will be clear with the transaction process. If you go for live  frist create  merchant account PayU. Then change the username and password,retrurnUrl and cancal and merchant reference.

       
        soapContent += "<merchantReference>1351079862</merchantReference>";

        // The return url for redirect shuold be configured accordingly

  // set soap username
        XmlNode userName = soapEnvelopeXml.SelectSingleNode("//wsse:Username",nsmgr);
        userName.InnerText = "Staging Integration Store 1";

        // set soap password
        XmlNode userPassword = soapEnvelopeXml.SelectSingleNode("//wsse:Password",nsmgr);
        userPassword.InnerText = "78cXrW1W";

http://blogsiteslist.com