Skip to search.

Breaking News Visit Yahoo! News for the latest.

×Close this window

ntb-clips · The NoteTab Clips List

The Yahoo! Groups Product Blog

Check it out!

Group Information

? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Hear how Yahoo! Groups has changed the lives of others. Take me there.

Messages

Advanced
Messages Help
Messages 18075 - 18104 of 23800   Oldest  |  < Older  |  Newer >  |  Newest
Messages: Show Message Summaries Sort by Date ^  
#18075 From: rainmark <rainmark@...>
Date: Tue Jul 15, 2008 4:50 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
layman_nine
Send Email Send Email
 
Here's the first chunk of script I'm trying to get rid of.

<script language="Javascript">
<!--
  top.document.title = document.title + ' #6152.312';
//-->
</script>

rainmark wrote:
>
> I'm getting the following error message:
> "Closure cannot immediately follow BegOfLine, EndOfLine or another
> closure"
>
> I'm using NoteTab Pro 4.95/np
>
> Axel Berger wrote:
> >
> > rainmark wrote:
> > > For instance, I would like the clip to find and delete all
> > > the text between and including the script tags.
> >
> > A simple task for Regex. Replace "<TAG>.*?</TAG>" with nothing
> >
> > Axel
> >
> >
> > No virus found in this incoming message.
> > Checked by AVG - http://www.avg.com <http://www.avg.com>
> > Version: 8.0.138 / Virus Database: 270.4.11/1553 - Release Date:
> 7/15/2008 5:48 AM
> >
>
>
> No virus found in this incoming message.
> Checked by AVG - http://www.avg.com
> Version: 8.0.138 / Virus Database: 270.4.11/1553 - Release Date: 7/15/2008
5:48 AM
>

#18076 From: "Don - HtmlFixIt.com" <don@...>
Date: Tue Jul 15, 2008 4:58 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
dpasseng
Send Email Send Email
 
rainmark wrote:
> Here's the first chunk of script I'm trying to get rid of.
>
> <script language="Javascript">
> <!--
>  top.document.title = document.title + ' #6152.312';
> //-->
> </script>
>
> rainmark wrote:
>> I'm getting the following error message:
>> "Closure cannot immediately follow BegOfLine, EndOfLine or another
>> closure"
>>
>> I'm using NoteTab Pro 4.95/np

Regex was completely different in 4.95.  I'd recommend that you update,
as it's worth it, especially for regex work.  We are up to 5.7 or
something now I think.

#18077 From: Eric Fookes <egroups@...>
Date: Tue Jul 15, 2008 6:28 pm
Subject: NoteTab 5.7 now released
eric_fookes
Send Email Send Email
 
Hi everyone,

We're pleased to announce the release of NoteTab 5.7 (all versions).

You will find the upgrade information through NoteTab's "Check for
Updates" feature, which is available from the Help menu. If you don't
see the version 5.7 info in the News and Updates window, make sure you
click on the "Get headlines" button at the top-left of the dialog box to
refresh the list.

Improvements since previous update:
-----------------------------------

* Updated the regular expressions engine to the latest release, which is
based on PCRE 7.7.

* Improved the Strip HTML Tags feature. Now correctly processes
unordered lists, ordered lists, and definition lists. Also improved
processing speed.

* Added the Outline Tutorial shortcut under the Help menu to easily open
the Readme.otl document.

* Added support for a new type of "text" hyperlink. You can now open
files in their associated application by using an exclamation character
(!) at the start of the hyperlink text. The following example will open
the GIF file in your associated image viewer: [!Samples\notetab.gif].
See the [Readme.otl::Hyperlinks] topic for more details (tip: to open
the document, hold down the Ctrl key while you double-click on the text
between the square brackets).

* Opening a shortcut file (.lnk) in NoteTab now always opens its target
file.

* Added support for folder and file name tokens. These tokens represent
either fully qualified folder names or system variables. See "Folder and
File Name Tokens" topic in Help for more details on this feature.

* Improved the /usb switch option. You now only need to use this command
the first time you run NoteTab off a USB drive. NoteTab will store the
option in its INI file on the USB drive. To cancel the option, run
NoteTab with the /usb=false command-line switch.

* Added keyboard shortcuts to combo-box and edit-box controls in
dialogs: Ctrl+Z = undo; Ctrl+Backspace = delete word before cursor;
Ctrl+Delete = delete from cursor till end of word.

* NoteTab Pro: added Ctrl+Shift+Up/Down keyboard shortcut to extend
selection range a paragraph at a time.

* Fixed several issues affecting certain complex regular expression
operations.

* Fixed issue with AutoReplace feature failing to work when an Outline
document is open.

* Fixed issue when using keyboard shortcuts to open context menus.

* Fixed several accessibility issues. Added configuration file for
Window-Eyes, JAWS for Windows, and Dolphin Hal; these are stored in the
Accessibility subfolder. Use the following command-line switch to
install them in the appropriate folders:
NoteTab.exe /acc=install
or
NotePro.exe /acc=install

* The Voluntary Product Accessibility Template (VPAT), which describes
how NoteTab conforms to Section 508 of the Rehabilitation Act, is
available from the following Web page:
http://www.notetab.com/vpat.php

* Freeware and Trial versions of NoteTab are now protected with a
different third-party product, which should significantly reduce
compatibility issues.

* Updated the spell-checker help file to the HTML Help format. Previous
WinHelp format does not work on Windows Vista without installing extra
support files.

* Added new print shortcuts to the Utilities library and Clipbar.

* Added many new Clip commands and functions.

* Some other minor improvements and issues fixed.

* Updated references to Fookes Software to reflect the new legal form of
business company. Fookes Software is now a Limited (Ltd) company, which
is owned by Fookes Holding Ltd.

--
Regards,

Eric Fookes
http://www.fookes.com/

#18078 From: rainmark <rainmark@...>
Date: Tue Jul 15, 2008 7:11 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
layman_nine
Send Email Send Email
 
Ok, I have upgraded my NotetabLite to 5.7

I need to find and delete all info between script tags including the
ones that have more than just the word "script" in them. (see below)

This - Replace "<TAG>.*?</TAG>" with nothing

Isn't working for that.

Don - HtmlFixIt.com wrote:
>
> rainmark wrote:
> > Here's the first chunk of script I'm trying to get rid of.
> >
> > <script language="Javascript">
> > <!--
> > top.document.title = document.title + ' #6152.312';
> > //-->
> > </script>
> >
> > rainmark wrote:
> >> I'm getting the following error message:
> >> "Closure cannot immediately follow BegOfLine, EndOfLine or another
> >> closure"
> >>
> >> I'm using NoteTab Pro 4.95/np
>
> Regex was completely different in 4.95. I'd recommend that you update,
> as it's worth it, especially for regex work. We are up to 5.7 or
> something now I think.
>
>
> No virus found in this incoming message.
> Checked by AVG - http://www.avg.com
> Version: 8.0.138 / Virus Database: 270.4.11/1553 - Release Date: 7/15/2008
5:48 AM
>

#18079 From: rainmark <rainmark@...>
Date: Tue Jul 15, 2008 7:23 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
layman_nine
Send Email Send Email
 
Some times, there are many, many lines of text between these script tags.

I'm trying to find a way of finding and deleting ALL the text between
and including the script tags. Maybe I didn't make that clear.
--------------------------------------------
rainmark wrote:
>
> Ok, I have upgraded my NotetabLite to 5.7
>
> I need to find and delete all info between script tags including the
> ones that have more than just the word "script" in them. (see below)
>
> This - Replace "<TAG>.*?</TAG>" with nothing
>
> Isn't working for that.
>
> Don - HtmlFixIt.com wrote:
> >
> > rainmark wrote:
> > > Here's the first chunk of script I'm trying to get rid of.
> > >
> > > <script language="Javascript">
> > > <!--
> > > top.document.title = document.title + ' #6152.312';
> > > //-->
> > > </script>
> > >
> > > rainmark wrote:
> > >> I'm getting the following error message:
> > >> "Closure cannot immediately follow BegOfLine, EndOfLine or another
> > >> closure"
> > >>
> > >> I'm using NoteTab Pro 4.95/np
> >
> > Regex was completely different in 4.95. I'd recommend that you update,
> > as it's worth it, especially for regex work. We are up to 5.7 or
> > something now I think.
> >
> >
> > No virus found in this incoming message.
> > Checked by AVG - http://www.avg.com <http://www.avg.com>
> > Version: 8.0.138 / Virus Database: 270.4.11/1553 - Release Date:
> 7/15/2008 5:48 AM
> >
>
>
> No virus found in this incoming message.
> Checked by AVG - http://www.avg.com
> Version: 8.0.138 / Virus Database: 270.4.11/1553 - Release Date: 7/15/2008
5:48 AM
>

#18080 From: "Don - HtmlFixIt.com" <don@...>
Date: Tue Jul 15, 2008 7:33 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
dpasseng
Send Email Send Email
 
rainmark wrote:
> Some times, there are many, many lines of text between these script tags.
>
> I'm trying to find a way of finding and deleting ALL the text between
> and including the script tags. Maybe I didn't make that clear.

Okay, try this:

((?s)<script.*?>.*?<\/script>)

See what that does for you.

Open the search and replace dialog,

tick regex box

past that in the top line

nothing in the bottom line

cursor should be at the top ...

click find ... see if if finds the right things and if yes, replace them
one at a time until you see if it is working

as always, work on a back up

Don

#18081 From: "Sheri" <silvermoonwoman@...>
Date: Tue Jul 15, 2008 7:42 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
silvermoonwo...
Send Email Send Email
 
--- In ntb-clips@yahoogroups.com, rainmark <rainmark@...> wrote:
>
> Some times, there are many, many lines of text between these script
tags.
>
> I'm trying to find a way of finding and deleting ALL the text between
> and including the script tags. Maybe I didn't make that clear.
> --------------------------------------------
> rainmark wrote:
> >
> > Ok, I have upgraded my NotetabLite to 5.7
> >
> > I need to find and delete all info between script tags including the
> > ones that have more than just the word "script" in them. (see below)
> >
> > This - Replace "<TAG>.*?</TAG>" with nothing
> >
> > Isn't working for that.

Try it this way:

^!Replace "(?s)<script language="Javascript">.*?</script>" >> "" RAWS0

Regards,
Sheri

#18082 From: rainmark <rainmark@...>
Date: Tue Jul 15, 2008 7:38 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
layman_nine
Send Email Send Email
 
Here's an example of what I'm trying to find and delete. Look at all
this mess between the script tags.

<script language="JavaScript">
   <!--
/*** Start script to force spider-friendly orphans info frameset ***/
//If we're not in the frameset...
if (parent.location.href == self.location.href) {
//Check to see if this is a spider-friendly URL...
if
((location.pathname.indexOf("/messages/")>0)&&(location.pathname.indexOf("?")==-\
1)){
var path = location.pathname;
var urlArray = path.split('messages');
var webtag = urlArray[0].replace("/", "");
var msgID = urlArray[1].replace("/", "");
msgID = msgID.replace("/", ".");
var theURL = 'http:\/\/' + location.hostname + '\/' + webtag +
'messages/?msg=' + msgID;
window.location.href = theURL;
}
}
/*** End script to force spider-friendly orphans info frameset ***/

//Get keywords for eBay ad

function getmetaContents(mn){
var m = document.getElementsByTagName('meta');
for(var i in m){
if(m[i].name == mn){
return m[i].content;
}
}
}

var keywords = getmetaContents('keywords');

   //Clean up data
   keywords = keywords.replace('\n',' ').toLowerCase();
   keywords = keywords.replace('\"',' ');
   keywords = keywords.replace('\'',' ');
   keywords = keywords.replace(/^\s+/gi, "");
   keywords = keywords.replace(/\s+$/gi, "");
   keywords = keywords.replace(/[\s,_-]/gi, " ");
   keywords = keywords.replace(/\s{2,}/gi, " ");

   //put words in array we can use later on
   var kwArray = keywords.split(" ");

   //Randomize ad position
   var ranUnrounded = Math.random()*3;
   var ranNumber = Math.round(ranUnrounded);
   if (ranNumber<1){
     ranNumber = 1
     }
   var adPosition = ranNumber;
   var adPosition2 = ranNumber + 5;

   //But if disable_ads is yes, don't show anything
   var disable_ads = 'y';
   disable_ads = disable_ads.toLowerCase();
   if
((disable_ads.indexOf("y")==0)||(disable_ads.indexOf("t")==0)||(disable_ads==1))\
{
     var adPosition = 0;
     var adPosition2 = 0;
     }

   function google_ad_request_done(google_ads) {

     // Proceed only if we have ads to display!
     if (google_ads.length > 0 ) {

       //Start writing out HTML
       document.write("<table cellspacing=\"0\" cellpadding=\"0\"
width=\"96%\" class=\"msgtable\"><tr><td class=msg valign=top><a
name=\"a1\"> <\/a><table width=\"100%\" cellspacing=0 cellpadding=0
border=0><tr class=msghead><td width=\"1%\"
class=\"msgbfr1\"> <\/td><td><table border=0 cellpadding=0
cellspacing=0><tr class=msghead><td  width=\"1%\" align=right nowrap
class=msgT>To: <\/td><td width=\"68%\" nowrap
class=msgFname><b>ALL<\/b> <nobr><\/nobr> <\/td><td width=\"30%\"
align=right nowrap
class=msgDate><i>Advertisement<\/i> <\/td><\/tr><tr
style=\"line-height: 3px;\"><td width=\"1%\"> <\/td><td
width=\"68%\" nowrap> <\/td><td align=right
nowrap> <\/td><\/tr><\/table><\/td><\/tr><tr><td width=\"1%\"
rowspan=3 class=\"msgleft\"> <\/td><td nowrap class=wintiny><div
style=\"line-height:5px\"> </div>");

     //If we can create feedback link, do so, otherwise display text
     if (google_info.feedback_url) {
       document.write("<a href=\"" + google_info.feedback_url + "\">Ads
by Google</a>");
       } else {
       document.write("Ads By Google");
        }

     document.write(" <\/td><\/tr><tr><td
height=8><\/td><\/tr><tr><td class=msgtxt>");

     // For text ads, display each ad in turn.
     if (google_ads[0].type == 'text') {
       for(i = 0; i < 4; ++i) {
if(google_ads.length>=(i+1)){
         document.write("<b><a class=\"msgrlink\" href=\"" +
google_ads[i].url + "\" target=\"_top\" onmouseOver=\"status='" +
google_ads[i].visible_url + "';return true\"
onmouseOut=\"window.status='';return true\">" + google_ads[i].line1 +
"</a></b><div>" + google_ads[i].line2 + " " + google_ads[i].line3 +
"</div><a class=\"wintiny\" href=\"" +  google_ads[i].url + "\"
target=\"_top\" onmouseOver=\"status='" + google_ads[i].visible_url +
"';return true\" onmouseOut=\"window.status='';return true\">" +
google_ads[i].visible_url + "</a><div
style=\"line-height:20px\"> </div>");
}
       }
     }
   }

   //Finish writing HTML

document.write("<\/td><\/tr><tr><td> <\/td><td> <\/td><\/tr><\/table><\
\/td><\/tr><\/table><p><\/p>");

   }

function showGoogle(){
   //Set Google vars
   google_ad_client = "pub-2093616136278178";
   google_ad_output = "js";
   google_max_num_ads = 20;
   google_ad_type  = "text";
   google_page_url =
"http://forums.delphiforums.com/n/pfx/forum.aspx?webtag=lawvsgrace&nav=keywords"\
;
   google_feedback = "on";
   google_ad_channel ="3496937134+2674402605";

   //Grab Google script
   document.write('<s' + 'cript type=\"text\/javas' + 'cript\"
language=\"JavaS' + 'cript\"
src=\"http:\/\/pagead2.googlesyndication.com\/pagead\/show_ads.js\"></scr'
+ 'ipt>\n');
   }

function showEbay(){
var title = ForumName.replace(" ", "+");
document.write("<div align=\"center\"><scr" + "ipt language=\"JavaS" +
"cript\"
src=\"http:\/\/lapi.ebay.com\/ws\/eBayISAPI.dll?EKServer&ai=emrwDxs%7E%7D*&bdrco\
lor=FFCC00&cid=0&eksize=1&encode=ISO-8859-1&endcolor=FF0000&endtime=y&fbgcolor=F\
FFFFF&fntcolor=000000&fs=1&hdrcolor=FFFFFF&hdrimage=1&hdrsrch=n&img=y&lnkcolor=0\
000FF&logo=2&num=3&numbid=y&paypal=n&popup=y&prvd=9&query="
+ kwArray[0] + "+" + kwArray[1] + "+" + kwArray[2] +
"&r0=4&shipcost=n&sid=dfInline&siteid=0&sort=MetaEndSort&sortby=endtime&sortdir=\
asc&srchdesc=y&tbgcolor=FFFFFF&title=Auctions+selected+for+"
+ title +
"&tlecolor=FFCE63&tlefs=1&tlfcolor=000000&toolid=10004&track=5335821231&width=57\
0\"><\/sc"
+ "ript></div>");
}

   //-->
   </script>

#18083 From: rainmark <rainmark@...>
Date: Tue Jul 15, 2008 7:52 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
layman_nine
Send Email Send Email
 
It looks like that did the trick on all the scripts, Don. Now what I
need is a clip that will wipe all that stuff out in one go.

And I'm no good with RegEx at all. So it looks like I'm going to have to
read up on that in the help file to find out what all those characters
are doing because I've got other chunks of text I want to find/delete too.

Don - HtmlFixIt.com wrote:
>
> Okay, try this:
>
> ((?s)<script.*?>.*?<\/script>)
>
>
>

#18084 From: Axel Berger <Axel-Berger@...>
Date: Tue Jul 15, 2008 8:16 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
absalom_nemini
Send Email Send Email
 
rainmark wrote:
> This - Replace "<TAG>.*?</TAG>" with nothing
> Isn't working for that.

It is. Only as jotted down it was only a rough draft in need of
refining.

This "(?s)<script.*?</script>" will do as expected. The (?s)
statement makes the anything placeholder .*? accept line breaks too.

Axel

#18085 From: "Sheri" <silvermoonwoman@...>
Date: Tue Jul 15, 2008 8:18 pm
Subject: Re: Extract information using Find, Copy & Paste
silvermoonwo...
Send Email Send Email
 
--- In ntb-clips@yahoogroups.com, "Chuck" <kc4vjb@...> wrote:
>
> WORKED PERFECTLY!!!
>
> Thank you so much for your efforts on my behalf.
>
> I will try to merge the two clips and see what happens. I'm
> reasonabley sure I wil be posting here again requesting
> additional assistance.
>
> Just out of curosity, what language is the "Clip Lanugage" based
> on. Perhaps I could find some tutorial info about it. I have read
> the clip tutorial by Jody Adair and it was a great starting place
> but nowhere can I find a reference to "^$GetDocMatchAll" or "^!
> SetListDelimiter". Also, I'm sure the switches you used in
> assigning the criteria for the varibles %Pattern% and ^%Pattern%
> are probably in the Help files someplace but I can't find them.
> For instance, I do recognise the hex representations for space
> and quotes although I don't know why there is a "-" in front of
> them. I really don't want to become a pest.

For the latest commands and functions you will need to consult the
Clip Help file (Help on Clip Programming under the Help Menu.) Jody's
tutorial predates NoteTab version 5.

> I don't know why there is a "-" in front of
> them.

Maybe you meant "\" because I don't see any "-" ?

^$GetDocMatchAll$ is a clipcode function that uses Regular
Expressions. The variable in my clip named ^%Pattern% is holding a
Regular Expression. There is yet another help file for Regular
Expressions :D

See the Help Menu item "Help on Regular Expressions".

The reason I put it into a variable was so I could split it over two
lines without you needing to edit it.

^$GetDocMatchAll$ separates matches by the value set in
^!SetListDelimiter. "^P" is NoteTab's token for a line break.

Something you may find helpful in learning and writing clips is my
ClipCode Syntax clips. You'll find that in the Files area of the Clips
Forum on Yahoo. I expect to be posting an update to it when I get a
chance, probably today, to add new commands and functions that just
arrived in NoteTab version 5.7.

I don't think ClipCode is modeled after any other language per se. But
its regular expression engine is the latest version of PCRE. PCRE is
Perl compatible and among other things is also used in PHP.

>
> Once again, THANK YOU for taking the time to assist me.

You're welcome!

As Jody (RIP) would have said:

Happy clippin'!

Regards,
Sheri

#18086 From: "Don - HtmlFixIt.com" <don@...>
Date: Tue Jul 15, 2008 8:22 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
dpasseng
Send Email Send Email
 
rainmark wrote:
> It looks like that did the trick on all the scripts, Don. Now what I
> need is a clip that will wipe all that stuff out in one go.
>
> And I'm no good with RegEx at all. So it looks like I'm going to have to
> read up on that in the help file to find out what all those characters
> are doing because I've got other chunks of text I want to find/delete too.
>
> Don - HtmlFixIt.com wrote:
>> Okay, try this:
>>
>> ((?s)<script.*?>.*?<\/script>)
>>
>>
Sheri's clip will work on an open document.  You can do mine with the
search disk function if you like to get a whole directory.  I'm not sure
you really need a clip.

Mine is wiping out all scripts, her's only javascript scripts (properly
labeled just so).

the ?s at the start means work across multiple lines.

The <script means exactly what it looks like.

the .*? means two things, the .* means zero or more of any characters
(so unlimited or none) can follow the script word, but the ? stops it at
the next > -- called non-greedy, so that it doesn't go from the first to
the last script tag if more than one is in the document.

the .*? includes everything between two adjoining >< characters.  same
explanation as above, it is not greedy so it doesn't include more than
to the next <

I'm not sure if I need the \ before the / but I think I do, it says I
really mean a / and not something else - it's called escaping a special
character because sometimes the / has other and special meanings -- I
think -- this part always confuses me what does and does not need to be
escaped ... but in any event if it doesn't have to be it doesn't hurt in
this case and if it does have to be well then aren't I brilliant? lol

and the rest means exactly what it says.

the opening and closing () are actually not necessary, but if you for
example wanted to replace all of it with say a carriage return or a
comment (here used to reside a script) you could then put what was
deleted back in.  So feel free to lose those.

I am a plodder at this regex stuff, so I'm sure someone else will refine
it or explain what I am wrong about.  Have at it
Flo/Sheri/Axel/Alec/Larry/Everybody Else :-)

Axel's suggestion will work as well (note the similarity) however I like
having the closing > on the script tag searched for as it will stop
possible issues if you have a non-closed tag or something.

#18087 From: Sheri <silvermoonwoman@...>
Date: Tue Jul 15, 2008 8:50 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
silvermoonwo...
Send Email Send Email
 
Don - HtmlFixIt.com wrote:
>
> Sheri's clip will work on an open document.  You can do mine with the
> search disk function if you like to get a whole directory.  I'm not sure
> you really need a clip.
>

True, but: using the search disk function to make replacements is not
supported in NoteTab Light (except in Standard Trial mode).

Regards,
Sheri

#18088 From: "Chuck" <kc4vjb@...>
Date: Tue Jul 15, 2008 9:25 pm
Subject: Re: Extract information using Find, Copy & Paste
kc4vjb
Send Email Send Email
 
Hi,

Thank you for taking the time to answer my questions.

I have just updated to NoteTab 5.7.  I'll peruse the help file/s in
more earnest.

The question concerning the "-" was a typo on my part. (Opps - sorry!)

At any rate, I really appreciate your assistance and patience.

Hope you have a great day.

Regards,

Chuck


--- In ntb-clips@yahoogroups.com, "Sheri" <silvermoonwoman@...> wrote:
>
> --- In ntb-clips@yahoogroups.com, "Chuck" <kc4vjb@> wrote:
> >
> > WORKED PERFECTLY!!!
> >
> > Thank you so much for your efforts on my behalf.
> >
> > I will try to merge the two clips and see what happens. I'm
> > reasonabley sure I wil be posting here again requesting
> > additional assistance.
> >
> > Just out of curosity, what language is the "Clip Lanugage" based
> > on. Perhaps I could find some tutorial info about it. I have read
> > the clip tutorial by Jody Adair and it was a great starting place
> > but nowhere can I find a reference to "^$GetDocMatchAll" or "^!
> > SetListDelimiter". Also, I'm sure the switches you used in
> > assigning the criteria for the varibles %Pattern% and ^%Pattern%
> > are probably in the Help files someplace but I can't find them.
> > For instance, I do recognise the hex representations for space
> > and quotes although I don't know why there is a "-" in front of
> > them. I really don't want to become a pest.
>
> For the latest commands and functions you will need to consult the
> Clip Help file (Help on Clip Programming under the Help Menu.)
Jody's
> tutorial predates NoteTab version 5.
>
> > I don't know why there is a "-" in front of
> > them.
>
> Maybe you meant "\" because I don't see any "-" ?
>
> ^$GetDocMatchAll$ is a clipcode function that uses Regular
> Expressions. The variable in my clip named ^%Pattern% is holding a
> Regular Expression. There is yet another help file for Regular
> Expressions :D
>
> See the Help Menu item "Help on Regular Expressions".
>
> The reason I put it into a variable was so I could split it over two
> lines without you needing to edit it.
>
> ^$GetDocMatchAll$ separates matches by the value set in
> ^!SetListDelimiter. "^P" is NoteTab's token for a line break.
>
> Something you may find helpful in learning and writing clips is my
> ClipCode Syntax clips. You'll find that in the Files area of the
Clips
> Forum on Yahoo. I expect to be posting an update to it when I get a
> chance, probably today, to add new commands and functions that just
> arrived in NoteTab version 5.7.
>
> I don't think ClipCode is modeled after any other language per se.
But
> its regular expression engine is the latest version of PCRE. PCRE is
> Perl compatible and among other things is also used in PHP.
>
> >
> > Once again, THANK YOU for taking the time to assist me.
>
> You're welcome!
>
> As Jody (RIP) would have said:
>
> Happy clippin'!
>
> Regards,
> Sheri
>

#18089 From: "Don - HtmlFixIt.com" <don@...>
Date: Tue Jul 15, 2008 10:53 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
dpasseng
Send Email Send Email
 
Sheri wrote:
> Don - HtmlFixIt.com wrote:
>> Sheri's clip will work on an open document.  You can do mine with the
>> search disk function if you like to get a whole directory.  I'm not sure
>> you really need a clip.
>>
>
> True, but: using the search disk function to make replacements is not
> supported in NoteTab Light (except in Standard Trial mode).
>
> Regards,
> Sheri
>
Gotcha, he had pro 4.95, so I presumed pro for 5.7.  I don't even bother
to think about light honestly any more.

#18090 From: Tony Hirtenstein <tonyh@...>
Date: Wed Jul 16, 2008 11:54 am
Subject: Extract Topics From An Outline
tonyhir
Send Email Send Email
 
The OtlTools library contains a clip called "Extract Topics From An
Outline", which appears to do exactly what I want (transfer topics with
particular text to another outline) but crashes with an error message in line 89
(which I found was due to a line wrap: that problem is solved).

	 However, it ends with a mysterious dialogue box entitled "Complete
Clip".  (Those words are not to be seen in the clip.)  What is it for and what
are you expected to enter?

	 The clip is attributed to Wayne VanWeerthuizen and dates from 2002.  Am
I missing a more recent version of the library?

--



******************* A.T.Hirtenstein ****************************
West Oxfordshire ******************* <tonyh@...>
"If you take refuge in God, He will bring what you need when you need it."

#18091 From: rainmark <rainmark@...>
Date: Wed Jul 16, 2008 5:10 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
layman_nine
Send Email Send Email
 
Yes, I understand what you're saying, Axel. But I tried it by replacing
"TAG" with "script" and it still wasn't working, but maybe that's
because I was doing it in NoteTab 4.95. I was getting error messages.

Anyway, I seem to be making progress here with the suggestions I'm getting.

Thanks to everybody for the input. (I'm still working on the Clip
because there are other chunks of text I'm trying to get rid of and each
one is a little different.)

Axel Berger wrote:
>
> rainmark wrote:
> > This - Replace "<TAG>.*?</TAG>" with nothing
> > Isn't working for that.
>
> It is. Only as jotted down it was only a rough draft in need of
> refining.
>
> Axel
>
>
> No virus found in this incoming message.
> Checked by AVG - http://www.avg.com
> Version: 8.0.138 / Virus Database: 270.5.0/1555 - Release Date: 7/16/2008 6:43
AM
>

#18092 From: rainmark <rainmark@...>
Date: Wed Jul 16, 2008 5:18 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
layman_nine
Send Email Send Email
 
I was wondering about the opening and closing (), but I don't understand
what you mean when you say "you could then put what was deleted back in."

Don - HtmlFixIt.com wrote:
>
>
> the opening and closing () are actually not necessary, but if you for
> example wanted to replace all of it with say a carriage return or a
> comment (here used to reside a script) you could then put what was
> deleted back in. So feel free to lose those.
>

#18093 From: rainmark <rainmark@...>
Date: Wed Jul 16, 2008 5:22 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
layman_nine
Send Email Send Email
 
The "0" at the end of "RAWS0" is a 'zero', right? What does that do?

Sheri wrote:
>
>
> ^!Replace "(?s)<script language="Javascript">.*?</script>" >> "" RAWS0
>
> Regards,
> Sheri
>

#18094 From: rainmark <rainmark@...>
Date: Wed Jul 16, 2008 5:28 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
layman_nine
Send Email Send Email
 
I'll probably ugrade to pro 5.x eventually, but I'm not quite ready to
shell out the extra bucks right now and I needed to get started testing
one of these files so I upgraded my Lite version. And I don't need to do
a whole folder (yet) anyway, so...

And another thing is, since I need to delete various chunks of text, I
have to use a clip. (I guess?)

Don - HtmlFixIt.com wrote:
>
>  he had pro 4.95, so I presumed pro for 5.7. I don't even bother
> to think about light honestly any more.
>

#18095 From: Axel Berger <Axel-Berger@...>
Date: Wed Jul 16, 2008 5:39 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
absalom_nemini
Send Email Send Email
 
rainmark wrote:
> And another thing is, since I need to delete various chunks of text, I
> have to use a clip. (I guess?)

You very rarely have to. Clips is like having an apprentice. You can
either do everything yourself every time, or you call your
apprentice and carefully show her how to do it just once. You then
tell her "Now you do it" and sit back and relax. Suits me fine.

Axel

#18096 From: ntb-clips@yahoogroups.com
Date: Wed Jul 16, 2008 7:04 pm
Subject: New file uploaded to ntb-clips
ntb-clips@yahoogroups.com
Send Email Send Email
 
Hello,

This email message is a notification to let you know that
a file has been uploaded to the Files area of the ntb-clips
group.

   File        : /ClipcodeSyntax57.zip
   Uploaded by : silvermoonwoman2001 <silvermoonwoman@...>
   Description : Clip Writing Aid - includes all commands and functions in
NoteTab version 5.7.

You can access this file at the URL:
http://groups.yahoo.com/group/ntb-clips/files/ClipcodeSyntax57.zip

To learn more about file sharing for your group, please visit:
http://help.yahoo.com/l/us/yahoo/groups/original/members/web/index.htmlfiles

Regards,

silvermoonwoman2001 <silvermoonwoman@...>

#18097 From: "Sheri" <silvermoonwoman@...>
Date: Wed Jul 16, 2008 7:39 pm
Subject: Re: Extract Topics From An Outline
silvermoonwo...
Send Email Send Email
 
--- In ntb-clips@yahoogroups.com, Tony Hirtenstein <tonyh@...> wrote:

>  However, it ends with a mysterious dialogue box entitled
> "Complete Clip". (Those words are not to be seen in the clip.)
> What is it for and what are you expected to enter?
>

That indicates that there is an error in the clip somewhere.

>  The clip is attributed to Wayne VanWeerthuizen and dates from
> 2002. Am I missing a more recent version of the library?

Where did you get it and what variant and version of NoteTab are you
running?

#18098 From: "Pat" <kitpath@...>
Date: Wed Jul 16, 2008 8:14 pm
Subject: Re: Extract Topics From An Outline
kitpath
Send Email Send Email
 
Sheri already said what I was thinking! ha ha.

Here is a clip that will do it.


--begin--
H="List headings in new doc"
;jody
^!SetFocus Outline
^!Keyboard Shift+F10 T
^!TOOLBAR PASTE NEW
---end---

#18099 From: "Sheri" <silvermoonwoman@...>
Date: Wed Jul 16, 2008 8:17 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
silvermoonwo...
Send Email Send Email
 
--- In ntb-clips@yahoogroups.com, rainmark <rainmark@...> wrote:
>
> The "0" at the end of "RAWS0" is a 'zero', right? What does that do?
>
> Sheri wrote:
> >
> >
> > ^!Replace "(?s)<script language="Javascript">.*?</script>" >> "" RAWS0
> >

A zero in options for a regex replacement command targets the whole
match for replacement. The whole match is the default, so it should
also work without including the zero, but my preference is to include
it. Otherwise you can include a number from 1 to 9 corresponding to
parenthesized substring within an overall pattern. For example, if you
put the .*? in parentheses, that would be substring 1. Then the
replacement would leave the tags in place and replace only the text
between the tags.

Regards,
Sheri

#18100 From: "Don - HtmlFixIt.com" <don@...>
Date: Wed Jul 16, 2008 11:57 pm
Subject: Re: [Clip] Delete whole sections of info from html files.
dpasseng
Send Email Send Email
 
Sheri wrote:
> --- In ntb-clips@yahoogroups.com, rainmark <rainmark@...> wrote:
>> The "0" at the end of "RAWS0" is a 'zero', right? What does that do?
>>
>> Sheri wrote:
>>>
>>> ^!Replace "(?s)<script language="Javascript">.*?</script>" >> "" RAWS0
>>>
>
> A zero in options for a regex replacement command targets the whole
> match for replacement. The whole match is the default, so it should
> also work without including the zero, but my preference is to include
> it. Otherwise you can include a number from 1 to 9 corresponding to
> parenthesized substring within an overall pattern. For example, if you
> put the .*? in parentheses, that would be substring 1. Then the
> replacement would leave the tags in place and replace only the text
> between the tags.
>
> Regards,
> Sheri
>

Which was what I was talking about with the parenthesis around the
outside of my regex.  I was making it all a parenthesized substring, and
that was not necessary in our/your/my case.  I do that because I often
have three or four search terms back to back and then remove some bits
and not others.  Makes it easier to work with.

Sheri, when will you do a clipcode type of library for regex searches?

#18101 From: Alec Burgess <buralex@...>
Date: Thu Jul 17, 2008 9:50 am
Subject: Re: [Clip] ClipcodeSyntax57 (was:New file uploaded to ntb-clips)
alecb3ca
Send Email Send Email
 
ntb-clips@yahoogroups.com (ntb-clips@yahoogroups.com) wrote (in part)
(on 2008-07-16 at 15:04):
>   File        : /ClipcodeSyntax57.zip
>   Uploaded by : silvermoonwoman2001 <silvermoonwoman@...>
>   Description : Clip Writing Aid - includes all commands and functions in
NoteTab version 5.7.
>
> You can access this file at the URL:
> http://groups.yahoo.com/group/ntb-clips/files/ClipcodeSyntax57.zip
You added the '0' option at the end of:
H="^!Replace"
^!Replace "SearchText" >> "ReplaceText" [Options TCIBGWHRSAO]
to match the 'n' option in the current Help:
> n: Represents a number between 1 and 9 inclusive. This option is only
> valid when used with the R option for regexp searches. NoteTab
> selects the corresponding regexp subpattern. This option was added to
> NoteTab 5.0.
I guess for completeness first line s/b modified to read:
Represents a number between 1 and 9 inclusive (0 - optional matches the
entire pattern).

Question (I haven't tested): what if anything does putting a number
between 1 and 9 do in a ^!Replace statement give that the "Replace Text"
can itself contain references to $1, ..., $9

The only semi-sensible semantics I can guess is that (say)

     * ^!replace "some  regexp pattern" >> "" rwsai5
           o would be equivalent to:
     * ^!replace "some  regexp pattern" >> "$1$2$3$4$6$7$8$9" rwsai
           o ie everything except $5
           o or ... that it has the effect of making $0=$5 and
             $1,..$4,$6,...$9 be identically = ^%empty%

In case you're curious ... I re-downloaded ClipcodeSyntax52 extracted
both zips and am comparing them in BeyondCompare (their beta trial
version expires Aug 31 and I figured this was a good way to try it
before going back to CompareIt!, KDiff3 and WinMatch)

^!MakeShortcut (my and Larry's current favorite command) - not update.
By analogy with the multi-format ^!Select command I think it should be
something like this:

     H="^!MakeShortcut"
     ^!MakeShortcut ShortcutLocation "Target" ["Arguments"]
     ["Description"] [CmdShow] ["StartInFolder"] [IconIndex]
     or
     ^!MakeShortcut ShortcutLocation "Target" ["Arguments"]
     ["Description"] [CmdShow] ["StartInFolder"] ["IconFile"]
     or
     ^!MakeShortcut ShortcutLocation "Target" ["Arguments"]
     ["Description"] [CmdShow] ["StartInFolder"] ["IconFile::IconIndex"]

<off-topic>
Sheri - my "favorite" compare program CompareIt! has really good support
for using regexps to alter lines to allow comparisons (eg in a log-file
strip date-stamps for comparison)
Unfortunately file editing support gets taken away after 30 days unless
you register - otherwise everything else is allowed.

I played briefly with the equivalent construct in KDiff3 when I wanted
to compare three versions of log files. It operates by shelling out to a
sed or perl script (probably works with grep as well?)
I managed to do the strip time function (ie remove HH:MM:SS from
beginning of all lines) with this

     * Settings/Configure/Diff/"Line-matching preprocessor command":
           o sed "s/^......../IGNORE TIME/"


Have you used it?

I forget who suggested BeyondCompare - FWIW - its slick for what it does
well, but curiously deficient in some (IMO) obvious
features/requirements. Namely toggle Horiz/Vertical comparisons and
support for pre-compare modifications as described above.

I haven't really looked in great detail at others in the COMPARE category.
</off-topic>

--
Regards ... Alec (buralex@gmail)



[Non-text portions of this message have been removed]

#18102 From: Alec Burgess <buralex@...>
Date: Thu Jul 17, 2008 10:38 am
Subject: Re: [Clip] ClipcodeSyntax57
alecb3ca
Send Email Send Email
 
Alec Burgess (buralex@...) wrote (in part)  (on 2008-07-17 at 05:50):
> ntb-clips@yahoogroups.com (ntb-clips@yahoogroups.com) wrote (in part)
> (on 2008-07-16 at 15:04):
>>   File        : /ClipcodeSyntax57.zip
>>   Uploaded by : silvermoonwoman2001 <silvermoonwoman@...>
>>   Description : Clip Writing Aid - includes all commands and functions in
NoteTab version 5.7.
>>
>>
>> You can access this file at the URL:
>> http://groups.yahoo.com/group/ntb-clips/files/ClipcodeSyntax57.zip
Follow up: I'm not sure where they'd belong (or how organized) but would
it make sense to put all the defined Environment variables and locations
(and others?) that Eric has added that now return values somewhere in
ClipcodeSyntax.otl .... maybe they are there already and I missed them?

--
Regards ... Alec (buralex@gmail)

#18103 From: Alec Burgess <buralex@...>
Date: Thu Jul 17, 2008 10:47 am
Subject: [Clip] ClipcodeSyntax57 (resent for proper threading)
alecb3ca
Send Email Send Email
 
Note: I've resent this after realizing that Yahoo-groups threads it with
all the other File upload notifications.
Please don't reply to this rather than the original message.

ntb-clips@yahoogroups.com (ntb-clips@yahoogroups.com) wrote (in part)
(on 2008-07-16 at 15:04):
>   File        : /ClipcodeSyntax57.zip
>   Uploaded by : silvermoonwoman2001 <silvermoonwoman@...>
>   Description : Clip Writing Aid - includes all commands and functions in
NoteTab version 5.7.
>
> You can access this file at the URL:
> http://groups.yahoo.com/group/ntb-clips/files/ClipcodeSyntax57.zip
You added the '0' option at the end of:
H="^!Replace"
^!Replace "SearchText" >> "ReplaceText" [Options TCIBGWHRSAO]
to match the 'n' option in the current Help:
> n: Represents a number between 1 and 9 inclusive. This option is only
> valid when used with the R option for regexp searches. NoteTab
> selects the corresponding regexp subpattern. This option was added to
> NoteTab 5.0.
I guess for completeness first line s/b modified to read:
Represents a number between 1 and 9 inclusive (0 - optional matches the
entire pattern).

Question (I haven't tested): what if anything does putting a number
between 1 and 9 do in a ^!Replace statement give that the "Replace Text"
can itself contain references to $1, ..., $9

The only semi-sensible semantics I can guess is that (say)

     * ^!replace "some  regexp pattern" >> "" rwsai5
           o would be equivalent to:
     * ^!replace "some  regexp pattern" >> "$1$2$3$4$6$7$8$9" rwsai
           o ie everything except $5
           o or ... that it has the effect of making $0=$5 and
             $1,..$4,$6,...$9 be identically = ^%empty%


^!MakeShortcut (mine and Larry's current favorite command) - not
updated. By analogy with the multi-format ^!Select command I think it
should be something like this:

     H="^!MakeShortcut"
     ^!MakeShortcut ShortcutLocation "Target" ["Arguments"]
     ["Description"] [CmdShow] ["StartInFolder"] [IconIndex]
     or
     ^!MakeShortcut ShortcutLocation "Target" ["Arguments"]
     ["Description"] [CmdShow] ["StartInFolder"] ["IconFile"]
     or
     ^!MakeShortcut ShortcutLocation "Target" ["Arguments"]
     ["Description"] [CmdShow] ["StartInFolder"] ["IconFile::IconIndex"]

Combined from 2nd email:
Follow up: I'm not sure where they'd belong (or how organized) but would
it make sense to put all the defined Environment variables and locations
(and others?) that Eric has added that now return values somewhere in
ClipcodeSyntax.otl .... maybe they are there already and I missed them?

<off-topic>
In case you're curious ... I re-downloaded ClipcodeSyntax52 extracted
both zips and am comparing them in BeyondCompare (their beta trial
version expires Aug 31 and I figured this was a good way to try it
before going back to CompareIt!, KDiff3 and WinMatch)

Sheri - my "favorite" compare program CompareIt! has really good support
for using regexps to alter lines to allow comparisons (eg in a log-file
strip date-stamps for comparison)
Unfortunately file editing support gets taken away after 30 days unless
you register - otherwise everything else is allowed.

I played briefly with the equivalent construct in KDiff3 when I wanted
to compare three versions of log files. It operates by shelling out to a
sed or perl script (probably works with grep as well?)
I managed to do the strip time function (ie remove HH:MM:SS from
beginning of all lines) with this

     * Settings/Configure/Diff/"Line-matching preprocessor command":
           o sed "s/^......../IGNORE TIME/"


Have you used it?

I forget who suggested BeyondCompare - FWIW - its slick for what it does
well, but curiously deficient in some (IMO) obvious
features/requirements. Namely toggle Horiz/Vertical comparisons and
support for pre-compare modifications as described above.

I haven't really looked in great detail at others in the COMPARE category.
</off-topic>

--
Regards ... Alec (buralex@gmail)



[Non-text portions of this message have been removed]

#18104 From: Don Daugherty <daugherty@...>
Date: Thu Jul 17, 2008 1:40 pm
Subject: Inconsistent RegExp Behavior
dondaugherty...
Send Email Send Email
 
The following one line clip functions fine when applied to the Sample
text starting with "Begin copy here", but not when applied to a larger
file from which it was extracted  The larger file is about 35k --  I'll
forward it to anyone who wants to see it but didn't included it here
since it makes things slower for those on dial-up.  Any ideas on why it
fails on more complicated?  Does ^!Find give-up after trying a certain
number of unsuccessful matchs?

Clip:
^!Find "<script(([[:blank:][:print:]]*\R)*)?</script>\R" RW

Begin copy here

<script type="text/javascript">
<!--
function writeStars(numStars) {
   if (numStars == -9999) {document.write('<div class="na">- -</div>');}
   else { for (i=0; i<numStars; i++) {
   //
   var star="/images/performance/star_small.png";
   //
   document.write('<img src="' + star + '" width="12" height="12"/>');
    } }
}
function writeDate(whatKind) {
   if (whatKind == 'short') {theDate = '03/31/08';}
   else if (whatKind == 'long') {theDate = 'March 31, 2008';}
   document.write(theDate);
}
//-->
</script>
</head>
<body>

<div class="metricsobject">
   <noscript>
   <img src="/utilities/tracking/zag.gif?Log=1&jd=1" border="0"
width="1Weight="1" alt=""/>
   </noscript>
</div>

End copy here

Messages 18075 - 18104 of 23800   Oldest  |  < Older  |  Newer >  |  Newest
Add to My Yahoo!      XML What's This?

Copyright © 2010 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines NEW - Help