SV: [thelist] Parsing document server side (was Adding title withcss)

Wesley Mason wes at
Thu Jun 24 13:08:20 CDT 2004

Hash: SHA1

I think this should work (yet again, just an example, doubt it'll work  
as I mainly work in PHP, and haven't done much ASP or ASP.NET, or  
JavaScript/EMCAScript, recently):

// <bad code>
Dim regexp;
Set regexp = new RegEx;

result =  
a>', '<a href="\1.pdf" title="PDF Doc">\2</a>');
// </bad code>

Although this seems incredibly wrong and clunky to me, anyone else with  
ASP/.NET/JScript regex experience fancy having a go?

- --
Wesley Aaron Mason
(1st Vamp)
Weblog from nowhere:
Webcomic from somewhere:
Public PGP/GPG Key:

On Jun 24, 2004, at 4:26 pm, Andreas Wahlin wrote:

> <Yes, parsing the link and adding the title value before sending it to
> the client.
> Probably the best way to do this would be a regular expression, like
> parsing <a href="(.)*.pdf"> and replacing it with <a href="\1.pdf"
> title="PDF Doc"> or the like (*note*, just an example, definitely not
> tested and almost certainly won't work as is).>
> I've spent a (short) while googling for information on this. Do you
> actually mean that I can create this mock document
> <%@Language="JavaScript"%>
> <%
> Parsing(<a href="(.)*.pdf">, title="pdf-link"); //THIS IS WHERE I DON'T
> %>
> <html>
> <body
> <a href="doc.pdf">document</a>
> </body>
> </html>
> And that the server will spit out the href as something like
> <a href="doc.pdf" title="pdf-link">document</a>
> In the end (when all parameters are good). So the server can get what
> would be html content, and change that just as a client side script
> would/could? I want some code please :) Not working code but the
> functions to call if any ... Or maybe I misunderstood the technique?
> Andreas
> --
> * * Please support the community that supports you.  * *
> For unsubscribe and other options, including the Tip Harvester
> and archives of thelist go to:
> Workers of the Web, evolt !
Version: GnuPG v1.2.4 (Darwin)


More information about the thelist mailing list