Anne Rice build 5

All new Coranto Addons, updates and patches to addons, will be released here...also, get support for addons within!

Moderators: Spunkmeyer, Dale Ray, SrNupsen, Bluetooth, Jackanape

Anne Rice build 5

Postby plushpuffin » Tue Dec 23, 2003 11:53 pm

case-insensitive matching!
case-insensitive matching!
case-insensitive matching!

The replacement/reverse-replacement code has been optimized. It now constructs a regex and then evals it, instead of having if() statements inside of if() statements the way it used to...

(Don't use dollar signs in your patterns. They don't work now, if they ever did before)

If there are any problems, please let me know.

Oops, I just realized I put this in the wrong forum. Mods please move!
I LIKE PIE
User avatar
plushpuffin
 
Posts: 411
Joined: Tue Mar 12, 2002 1:28 pm
Location: Buffalo, NY

Postby kriko » Wed Dec 24, 2003 12:25 am

Moved since you requested. If some people don't know where they can find the wonderful addon then here is a link:
http://www.wwddfd.com/craddons/107222323578083.shtml
Kristjan aka. kriko
now a wireless expert
User avatar
kriko
 
Posts: 3328
Joined: Sat Feb 24, 2007 8:13 pm

Postby faithless » Thu Dec 25, 2003 4:55 pm

I adore Anne Rice. er. The coranto addon. not the writer.
Er. naming an addon after a writer wouldn't pose any legal problems?
just a thought that came to mind.

and ur nick being partly the name of a book publisher, one can only imagine our darling plush poring over books. with vampire stories from rice being her favourites. :wink:
faithless
 
Posts: 1335
Joined: Wed Oct 16, 2002 4:17 pm
Location: Infront of the Computer

Postby LoneOwl » Fri Dec 26, 2003 6:21 am

Just go with the good ol' BDSM erotica novels.

And legal problems? Why? My only problem with the name is possible confusion it could cause. Guys and girls may be wanting something other than an advanced glossary addon.
User avatar
LoneOwl
 
Posts: 1465
Joined: Sun Mar 10, 2002 2:57 am
Location: That one place, you know?

Postby officeslave » Fri Dec 26, 2003 8:31 am

W00t. My site has become completely dependent upon Anne Rice's bbcoding abilities.
officeslave
 
Posts: 125
Joined: Tue Apr 23, 2002 11:23 am

Postby faithless » Thu Jan 01, 2004 11:00 am

just thought i brought it up.
in build 5, when ever i post a news item which anne rices runs thru for replacing,

this chunk of text appears all over the coranto top screen.
Code: Select all
$$fn =~ s/\Q<br>\E/((annerice0))/g
$$fn =~ s/\Q<hr>\E/((annerice1))/g
$$fn =~ s~\Q[b]\E([^\[]+)\Q[/b]\E~\<strong\>$1\<\/strong\>~g;
$$fn =~ s~\Q[i]\E([^\[]+)\Q[/i]\E~\<em\>$1\<\/em\>~g;
$$fn =~ s~\Q[u]\E([^\[]+)\Q[/u]\E~\<strong\>\<em\>$1\<\/em\>\<\/strong\>~g;
$$fn =~ s~\Q[quote]\E([^\[]+)\Q[/quote]\E~\<\/p\>\<p\ class\=\"quote\"\>$1\<\/p\>\<p\>~g;
$$fn =~ s~\Q[url="\E([^\"]+)\Q"]\E([^\[]+)\Q[/url]\E~\<a\ href\=\"$1\"\>$2\<\/a\>~g;
$$fn =~ s~\Q[url]\E([^\[]+)\Q[/url]\E~\<a\ href\=\"$1\"\>$1\<\/a\>~g;
$$fn =~ s~\Q[img="\E([^\"]+)\Q"]\E([^\[]+)\Q[/img]\E~\<img\ src\=\"$1\"\ alt\=\"$2\"\ \/\>~g;
$$fn =~ s~\Q[img]\E([^\[]+)\Q[/img]\E~\<img\ src\=\"$1\"\ alt\=\"$1\"\ \/\>~g;
$$fn =~ s~\Q<img src="\E([^\"]+)\Q">\E~\<img\ src\=\"$1\"\ alt\=\"$1\"\ \/\>~g;
$$fn =~ s~\Q<img src="\E([^\"]+)\Q" alt="\E([^\"]+)\Q">\E~\<img\ src\=\"$1\"\ alt\=\"$2\"\ \/\>~g;


which seems to because of this line of code in various places of annerice.pl
Code: Select all
print '<h4>' . HTMLescape("$code") . '</h4>';


is it required? it looks unsightly with all that code running all over the top screen.
faithless
 
Posts: 1335
Joined: Wed Oct 16, 2002 4:17 pm
Location: Infront of the Computer

Postby plushpuffin » Mon Jan 05, 2004 3:22 am

No, it isn't required. That was just my debugging code, which I forgot to turn off. Sorry. I have uploaded a new Anne Rice build 5, without the debugging code. GG
I LIKE PIE
User avatar
plushpuffin
 
Posts: 411
Joined: Tue Mar 12, 2002 1:28 pm
Location: Buffalo, NY

Postby bozoka45 » Fri Jan 30, 2004 5:05 am

I asked plushpuffin this question, but maybe someone else will know an answer.

Is there a way to make Anne Rice run the find and replace routine on all news items, without modifing them all? Apparently a full rebuild won't even do it. I guess Anne Rice is attached to the submit page?

I think this would be a great addition. It would help Coranto become more dynamic.
User avatar
bozoka45
 
Posts: 1159
Joined: Sun Mar 23, 2003 8:38 pm
Location: New Orleans

Postby plushpuffin » Sat Jan 31, 2004 6:54 pm

It could be done, but I'm not up to it right now. Anne Rice is open source, feel free to modify it and release a new version.
I LIKE PIE
User avatar
plushpuffin
 
Posts: 411
Joined: Tue Mar 12, 2002 1:28 pm
Location: Buffalo, NY

Postby bozoka45 » Tue Feb 03, 2004 6:20 am

Well, I made it work when I do a full rebuild (or partial) when I added these two hooks:

Code: Select all
$addon->hook('BuildNews_PreLoop', \$ModifyNews_Edit_TopRow, 4);
$addon->hook('Build_GetData', \$AnneRice_SaveNews, 4);


Unfortunately, I think it really slows down the time of the Full Rebuild. Any ideas/sugestions to fix this? Maybe a button within Anne Rice itself that does the full rebuild? Thats probably beyond my expertise (which are next to none), but I will try and work out something.

I guess you could say AnneRice beta 5.1 is found here:

http://members.cox.net/al6585/cra_annerice.txt

(View the source)
User avatar
bozoka45
 
Posts: 1159
Joined: Sun Mar 23, 2003 8:38 pm
Location: New Orleans

Postby bozoka45 » Tue Feb 03, 2004 6:27 am

Also, just thinking out loud here:

But since AnneRice uses a glossdat.txt file to do the find and replace action, would it be possible to automatically add items to the glossdat.txt file using a profile?
User avatar
bozoka45
 
Posts: 1159
Joined: Sun Mar 23, 2003 8:38 pm
Location: New Orleans

Postby Joyrex » Tue Feb 03, 2004 4:53 pm

Possibly, if you can get the profile's style output to match the format of the glossdat.txt file. That's a pretty good idea, although the automatic part is a bit misleading - what part of it would be automatic? would you have custom fields set up to populate the glossdat file? That's no different than entering the data via the Admin section of Coranto, unless you wanted specifc fields you used when publishing an entry to also populate the glossdat...
We are the music makers...we are the dreamers of the dreams...
User avatar
Joyrex
 
Posts: 259
Joined: Fri Jun 14, 2002 9:37 pm

Postby bozoka45 » Tue Feb 03, 2004 5:03 pm

I have alot of entries I can add to Anne Rice, due to the nature of my website. All of these entires could be made from news posts, just by taking the subject, disecting it, and using the news id. The style wasn't hard to figure out.

It seems like it will work, I will update you shortly.

The only probably would be that if I ever wanted to add items besides news items to my Anne Rice database, I'd have to fudge the entry somehow. I'll cross that bridge when I come to it.
User avatar
bozoka45
 
Posts: 1159
Joined: Sun Mar 23, 2003 8:38 pm
Location: New Orleans

Postby bozoka45 » Tue Feb 03, 2004 10:02 pm

I might use two versions of Anne Rice. I will just have to edit the Addon a little. The first version would be used to automatically update a glossary file based on a field name. The second version could be the version that would be editable by me.
User avatar
bozoka45
 
Posts: 1159
Joined: Sun Mar 23, 2003 8:38 pm
Location: New Orleans

Postby plushpuffin » Wed Feb 04, 2004 3:04 am

http://www.wwddfd.com/c/cra_annerice_b6.txt

Here's a shell of what you need. I've left the guts to you, because my server was bugging out on me. Dunno why.

I think what you need to do is call modifynews_toprow hook, and then call modifysave_3 hook. This will simulate editing and saving a news item, hopefully it will be compatible with all other addons. Who knows...
I LIKE PIE
User avatar
plushpuffin
 
Posts: 411
Joined: Tue Mar 12, 2002 1:28 pm
Location: Buffalo, NY

Next

Return to Addon Release and Support

Who is online

Users browsing this forum: No registered users and 2 guests

cron