Regular expressions

Exclude some file types from a list
================================

function Filter()
    {
        var arr = new Array(9);
//Dummy
        arr[0] = "something.aspx";
        arr[1] = "something.ascx";
        arr[2] = "something.gif";
        arr[3] = "something.asrx";
        arr[4] = "something.jp";
        arr[5] = "something.cab";
        arr[6] = "something.bat";
        arr[7] = "something.arr";
        arr[8] = "something.ashx";
        var rgex = /.*[.](?!(aspx|ascx|gif)$).*$/;
        var filtered = new Array(8);

        for(var i=0;i<arr.length;i++)
        {
            if(rgex.test(arr[i]))
                filtered[i] = arr[i];
            else
                filtered[i] = "ok";

        }

    }

29 Responses to “Regular expressions”

  1. Kylie Batt Says:

    ?? ????? ?????? ?? ?????????? ??????. ???? ??? ????????….

    ?????         arr[5] = “something.cab”;
            arr[6] = “something.bat”;
            arr[7] = “something.arr”;
            arr[8] = “something…..

  2. Kylie Batt Says:

    ?? ????? ????…

    ?????, ??????????, ????????, ?????????         arr[5] = “something.cab”;
            arr[6] = “something.bat”;
            arr[7] = “something.arr”;…

  3. Kylie Batt Says:

    ??????? ???…

    ?????? ?? ?????????????????? ?????????? ?????? ??????? ??????????         arr[5] = “something.cab”;
            arr[6] = …

  4. james Says:

    < a href = “http://cn.soundtracksong.ru/?p=11&lol= enormous@forte.garnet“>.< / a >…

    tnx for info!!…

  5. Jeffrey Says:

    < a href = “http://eu.skalyrics.ru/?p=15&lol= alusik@commodity.convenience“>.< / a >…

    good info….

  6. alberto Says:

    < a href = “http://com.artistcluster.ru/?p=29&lol= dystopian@habla.inadvertently“>.< / a >…

    thanks for information!…

  7. Eric Says:

    < a href = “http://org.albumtoken.ru/?p=4&lol= reik@greater.rushes“>.< / a >…

    ???….

  8. alfredo Says:

    < a href = “http://uk.songnic.ru/?p=47&lol= pascal@childish.italian“>.< / a >…

    ??? ?? ????….

  9. joshua Says:

    < a href = “http://org.artistguild.ru/?p=47&lol= cambridgeport@camden.reciprocate“>.< / a >…

    tnx!!…

  10. arturo Says:

    < a href = “http://net.albumxchange.ru/?p=15&lol= confirmation@emerged.accomplishing“>.< / a >…

    ?????????????!…

  11. Dwight Says:

    < a href = “http://ru.songfrigate.ru/?p=18&lol= alcotts@marlin.gallop“>.< / a >…

    ??? ?? ????!…

  12. billy Says:

    < a href = “http://fr.songwright.ru/?p=21&lol= vendome@unwired.fruitfulness“>.< / a >…

    tnx for info….

  13. enrique Says:

    < a href = “http://gov.artiststream.ru/?p=33&lol= arthurs@sedoi.localities“>.< / a >…

    ??? ?? ????!…

  14. hugh Says:

    < a href = “http://fr.artistcat.ru/?p=30&lol= acceleration@corder.erwin“>.< / a >…

    thank you!!…

  15. Willie Says:

    < a href = “http://ch.albumroad.ru/?p=16&lol= pineapple@sues.updated“>.< / a >…

    ???….

  16. fred Says:

    < a href = “http://ru.mp3flight.ru/?p=7&lol= fluctuating@hoyt.dietary“>.< / a >…

    good!…

  17. Felix Says:

    < a href = “http://ru.artistcove.ru/?p=18&lol= idea@australites.deserve“>.< / a >…

    ??????????!!…

  18. shannon Says:

    < a href = “http://fr.instrumentallyrics.ru/?p=26&lol= eclat@unknowns.confucius“>.< / a >…

    ???!…

  19. leslie Says:

    < a href = “http://fr.songroad.ru/?p=18&lol= birthright@friction.annes“>.< / a >…

    ñýíêñ çà èíôó!…

  20. Bradley Says:

    < a href = “http://fr.songsquad.ru/?p=41&lol= seize@folds.radionic“>.< / a >…

    tnx for info….

  21. terry Says:

    < a href = “http://ru.musicallyrics.ru/?p=1&lol= prowl@immensity.rime“>.< / a >…

    thanks!…

  22. Dale Says:

    < a href = “http://en.albumxchange.ru/?p=30&lol= stair@diman.whose“>.< / a >…

    ñïàñèáî çà èíôó!…

  23. Shaun Says:

    < a href = “http://net.artistguild.ru/?p=15&lol= riverside@sago.today“>.< / a >…

    tnx for info!…

  24. rodney Says:

    < a href = “http://ch.songnik.ru/?p=21&lol= stimulatory@ringing.custer“>.< / a >…

    áëàãîäàðþ….

  25. Jesus Says:

    < a href = “http://com.artistscript.ru/?p=35&lol= gait@backstairs.cozen“>.< / a >…

    good info!!…

  26. franklin Says:

    < a href = “http://eu.reggaemp3.ru/?p=18&lol= leyte@hopkinsian.geographically“>.< / a >…

    tnx!…

  27. troy Says:

    < a href = “http://uk.artistpride.ru/?p=17&lol= bodin@compounds.curricular“>.< / a >…

    áëàãîäàðåí!!…

  28. alfred Says:

    < a href = “http://adaptations.rnblyrics.ru/?p=1&lol= cascading@youuns.sociologically“>.< / a >…

    áëàãîäàðåí….

  29. Evan Says:

    < a href = “http://eu.mp3flight.ru/?p=31&lol= brownish@disengage.despondency“>.< / a >…

    good….

Leave a Reply