Search Results

Search found 2 results on 1 pages for 'spoier'.

Page 1/1 | 1 

  • mod_perl2 send original requested url

    - by spoier
    Hello all, I have a mod_perl module to intercept the http response fase but I just want to intercept it and satisfy that request... In other words, I want to get the request and return what the client requested... I have something like this: use strict; use Apache2::RequestRec (); # for $r->content_type use Apache2::RequestIO (); # for $r->puts use Apache2::Const -compile => qw(:common); sub handler { my $r = shift; $r->content_type('text/html'); return Apache2::Const::OK; } 1; Apparently it doesn't work...

    Read the article

  • Is it possible to exclude some elements from parsing when using regular expression and .replace()?

    - by Fletus Mefitis
    <script language="javascript"> $("div.post-content , .parsedsig").each(function(){ if($(this).html().indexOf("[/tabulaScriptum]") != -1) { pattern = /\[tabulaScriptum=(.*?)\]([^\[]*)\[\/tabulaScriptum\]/gi $(this).html($(this).html().replace(pattern, "<div class='tabulaScriptum'><div class='tabulaNomen'>$1</div><div class='tabulaImpleo'>$2</div></div>")) } }); </script> This script is working perfectly, except for one thing... I need not to replace [tabulaScriptum=][/tabulaScriptum] in certain elements. For example, I don't want to replace those "tags" in element that has class .code-box. Is it possible? Clarification: element .code-box is located within .post-content. Clarification #2: this script creates simple division spoiler. .tabulaScriptum is spoier's body, .tabulaNomen is spoiler's name and button which, in turn, reveals(or hides) .tabulaImpleo on click. Reveal\hide script is located in some other place, and I didn't post it here since it doesn't really matter. Clarification #3: http://jsfiddle.net/PRtsw/1/ fiddle.

    Read the article

1