Jump to content

linkify value of cell dbgrid


delagoutte

Recommended Posts

I have data in database (plain text) that are display on dbgrid.

I would like search url in content and create on the fly, hyperlink for this url finded.

 

For this i try to use 2 js lib : 

http://benalman.com/projects/javascript-linkify/

or http://soapbox.github.io/linkifyjs/docs/

 

for this i use this code for benalman lib :

    aGrid.ClientEvents.ExtEvents.Values['reconfigure']:=
      'function reconfigure(sender, store, columns, oldStore, oldColumns, eOpts)'+#13#10+
      '{'+#13#10+
      '    columns.forEach(function(col) {'+#13#10+
      '        col.renderer = '+#13#10+
      '            function(v)' +#13#10+
      '            { return linkify(v);} '+#13#10+
      '    });'+#13#10+
      '}';

linkifyStr(v,{}); with soapbox lib

 

but it don't work for both i have the error

JS Error: Argument 1 of Node.insertBefore is not an object.  ext-sync-min.js:8:2362

Could you give me your help please with this lib or other ?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...