5 of 7
5
Textile Editor Helper (TEH) extension
Posted: 02 July 2008 08:09 AM   [ Ignore ]   [ # 73 ]  
Lab Technician
Avatar
RankRankRankRank
Total Posts:  1735
Joined  03-26-2006

Yep, you’re right Nathan. I made sure to put the “proper” Textile plugin in with the other files in the Markitup extension.

I really would like a “Middle Ground” extension though…basically TEH, but TEH running on jQuery. I like Markitup (otherwise I wouldn’t have spent time making an Extension) but sometimes I want to be able to switch formatting type right there on the publish page (can’t do that with the Markitup Ext) and I don’t necessarily need the super-fancy skin, either.

 Signature 

ryan masuga
—————
Masuga Design | Member, EE Pro Network
My EE Add-Ons | {devot:ee}
Twitter: masuga | masugadesign | devot_ee

Profile
 
 
Posted: 04 July 2008 10:34 AM   [ Ignore ]   [ # 74 ]  
Lab Technician
Avatar
RankRankRankRank
Total Posts:  1735
Joined  03-26-2006

Ugh, I wish TEH played nicer with the other kids in the schoolyard. Figured out how to get it to work alongside Playa by changing Playa’s priority to 11, but now I’m finding that TEH conflicts with my extension Dulee Noted. Maybe I have to put Dulee Noted into non-conflict mode.

There’s always something!

UPDATE: Putting Dulee Noted’s jQuery in no-conflict mode didn’t solve the issue, nor did changing the priority. If I can figure out how to put TEH on jQuery, believe me, I’m going to do it!

 Signature 

ryan masuga
—————
Masuga Design | Member, EE Pro Network
My EE Add-Ons | {devot:ee}
Twitter: masuga | masugadesign | devot_ee

Profile
 
 
Posted: 08 July 2008 12:37 PM   [ Ignore ]   [ # 75 ]  
Research Assistant
RankRankRank
Total Posts:  547
Joined  01-05-2005

I’m having conflict issues with this extension and Playa.  The CSS is outputting fine which was a problem for a few other people it seems, you can also select related entries click add and they move across OK.  The problem is the “0 items selected” never increases and when you submit the entry the selected related entries don’t save.

Disable TEH and everything works as expected.  I’ve tried changing Playa’s priority but I believe that solution relates to another problem.

Can anyone help?

 Signature 

Celebrating again soon.

Profile
 
 
Posted: 08 July 2008 12:47 PM   [ Ignore ]   [ # 76 ]  
Lab Technician
Avatar
RankRankRankRank
Total Posts:  1735
Joined  03-26-2006

I wish it was a requirement that custom extensions for the 1.x branch of EE had to use jQuery downer

As it is, I find I’m relying on Playa for my builds, and TEH is a “nice-to-have” but not totally necessary. If I could put TEH on jQuery and in no-conflict mode, I’d do it in a second, but every time I look at it under the hood, I get confused by something.

smallbeer, when you change the priority of Playa, do you disable/re-enable the extension afterwards?

 Signature 

ryan masuga
—————
Masuga Design | Member, EE Pro Network
My EE Add-Ons | {devot:ee}
Twitter: masuga | masugadesign | devot_ee

Profile
 
 
Posted: 08 July 2008 12:59 PM   [ Ignore ]   [ # 77 ]  
Research Assistant
RankRankRank
Total Posts:  547
Joined  01-05-2005

Yeah I’m disabling/enabling each time.  Ryan, can you confirm whether the other conflict issues have been similar to mine or were they just the CSS problem?  At least then I’ll know that people have fixed the same issue.

 Signature 

Celebrating again soon.

Profile
 
 
Posted: 24 July 2008 11:53 AM   [ Ignore ]   [ # 78 ]  
Lab Assistant
Avatar
RankRank
Total Posts:  118
Joined  12-29-2004

Hi guys - just wanted to let you know I updated TEH to a new version using jQuery and gave Prototype the boot. Grab it at the top of the thread.

I’ve tested and it plays nice now with Playa. Hope this is better for all of us now. (I wanna use Playa too dammit!) There’s no queries at all anymore as it just uses javascript to attach itself to a field with Textile format selected so those that had the issue of it not showing up sometimes should be fixed. It also loads a lot faster for me without Prototype slowing it down.

I also added the option to encode email addresses using EE’s encode tag (which has to be escaped for textile so the quotes don’t get mangled). By default it still just makes a regular mailto link though.

The settings are also cleaned up so there’s just a path to jQuery (change it to point to your existing jquery file if you want), one path the “teh” folder, and then just the help url and setting for encoding the email or not. Should be easier to set up and move around.

Upgrade note: I added a prefix to the extension filename like all good EE addons should be using (hey, this was one of my first extensions!), so it may be easier to just dump the old one first and install the new version clean.

And one last thing, I still think mdesign’s would be a better more well-rounded solution going forward, but for those of set on just Textile I hope this is helpful.

Edit-add:I also just tested with mdesign’s Dulee Noted extension and they seem to like each other just fine. Sweet extension by the way, adding that handy one to my default list! Sorry for all the conflicts, hope this fixes everything…but let me know if you run into any troubles…

 Signature 

imagehat studio
the forum user formerly known as lavalamp

Profile
 
 
Posted: 24 July 2008 01:19 PM   [ Ignore ]   [ # 79 ]  
Lab Technician
Avatar
RankRankRankRank
Total Posts:  1735
Joined  03-26-2006

Goodness gracious this bit of news made my day. I really cannot wait to try this. Thanks!

 Signature 

ryan masuga
—————
Masuga Design | Member, EE Pro Network
My EE Add-Ons | {devot:ee}
Twitter: masuga | masugadesign | devot_ee

Profile
 
 
Posted: 25 July 2008 05:03 AM   [ Ignore ]   [ # 80 ]  
Research Assistant
RankRankRank
Total Posts:  547
Joined  01-05-2005

This would be excellent news if only I could get it working!  I’ve installed the new jquery version on a fresh EE install with no other extensions.  The textarea has textile as it’s text formating choice but the toolbar doesn’t show up on the publish/edit page.

I’m getting no javascript errors, the paths are all correct.  Any ideas?

 Signature 

Celebrating again soon.

Profile
 
 
Posted: 25 July 2008 09:36 AM   [ Ignore ]   [ # 81 ]  
Lab Assistant
Avatar
RankRank
Total Posts:  118
Joined  12-29-2004

Weird, I’ve installed it in 3 EE sites now without a problem… It sounds like you’ve got everything set up right, and you’ve probably tried disabling/renabling/rechecking settings already, so let me double-check on a fresh install and see.

 Signature 

imagehat studio
the forum user formerly known as lavalamp

Profile
 
 
Posted: 25 July 2008 11:05 AM   [ Ignore ]   [ # 82 ]  
Lab Assistant
Avatar
RankRank
Total Posts:  118
Joined  12-29-2004

smallbeer - I’ve just double-checked on a fresh install and everything is working for me (tested in Safari & FF on a mac). You may want to grab a fresh copy and give it a go again, I just uploaded an update to change the email encoding option.

Otherwise, is there anything different about your test install? Masking the CP or pointing to an existing jQuery file or anything?

 Signature 

imagehat studio
the forum user formerly known as lavalamp

Profile
 
 
Posted: 26 July 2008 06:57 AM   [ Ignore ]   [ # 83 ]  
Research Assistant
RankRankRank
Total Posts:  547
Joined  01-05-2005

OK I figured it out.  The toolbar will only display if I choose “Display Formatting Menu” when choosing Textile as the text formatting.

Is there anyway of changing that?

 Signature 

Celebrating again soon.

Profile
 
 
Posted: 26 July 2008 09:48 AM   [ Ignore ]   [ # 84 ]  
Lab Assistant
Avatar
RankRank
Total Posts:  118
Joined  12-29-2004

smallbeer - grab the extension again at the top of the thread - should be fixed now.

 Signature 

imagehat studio
the forum user formerly known as lavalamp

Profile
 
 
Posted: 27 August 2008 09:27 AM   [ Ignore ]   [ # 85 ]  
Lab Technician
Avatar
RankRankRankRank
Total Posts:  1570
Joined  08-02-2006

Hi,

I’ve just downloaded this and it seems to be working great. I really don’t need all of the buttons that the TEH provides and I’m wondering if there is an easy way to remove the buttons that I don’t need? I assume I’ll need to hack the textile-editor.js file but I’m not sure what to edit since I don’t do JavaScript. Anyone help me out here?

 Signature 

Deron Sizemore
==========
Random Jabber | Sizcons | NiceStylesheet | Kentucky Golfing | LogoGala
Twitter: Deron Sizemore | LogoGala

Profile
 
 
Posted: 27 August 2008 09:38 AM   [ Ignore ]   [ # 86 ]  
Lab Assistant
Avatar
RankRank
Total Posts:  236
Joined  01-18-2006

I think you edit the textile-editor-config.js file. There are a list of variables at the top. I think you can comment out the ones you don’t need.

 Signature 

Eric Barstad
Shadow Box Creative Media Ltd.

EE Pro Network

Profile
 
 
Posted: 27 August 2008 09:48 AM   [ Ignore ]   [ # 87 ]  
Lab Assistant
Avatar
RankRank
Total Posts:  118
Joined  12-29-2004

Deron, Eric’s exactly right, in the textile-editor-config.js file you can comment out any of the buttons you don’t want. Basically each of the lines at the top that begin “teButtons.push”... is either a button or separator and can be commented out or deleted altogether.

 Signature 

imagehat studio
the forum user formerly known as lavalamp

Profile
 
 
Posted: 27 August 2008 10:02 AM   [ Ignore ]   [ # 88 ]  
Lab Technician
Avatar
RankRankRankRank
Total Posts:  1735
Joined  03-26-2006

Conversely, you can add buttons that do cool things, too. I made one that takes a selected image tag, wraps it with a div, floats it left and adds optional spans for photo credit and caption below the image (much like pics in ESPN.com articles). I even created a little custom icon for it and uploaded that image with the other icons.

 Signature 

ryan masuga
—————
Masuga Design | Member, EE Pro Network
My EE Add-Ons | {devot:ee}
Twitter: masuga | masugadesign | devot_ee

Profile
 
 
Posted: 27 August 2008 11:35 AM   [ Ignore ]   [ # 89 ]  
Lab Technician
Avatar
RankRankRankRank
Total Posts:  1570
Joined  08-02-2006
imagehat - 27 August 2008 09:48 AM

Deron, Eric’s exactly right, in the textile-editor-config.js file you can comment out any of the buttons you don’t want. Basically each of the lines at the top that begin “teButtons.push”... is either a button or separator and can be commented out or deleted altogether.

Thank you very much. That seems easy enough. This extension will come in so handy for me. Thanks for developing it.

mdesign - 27 August 2008 10:02 AM

Conversely, you can add buttons that do cool things, too. I made one that takes a selected image tag, wraps it with a div, floats it left and adds optional spans for photo credit and caption below the image (much like pics in ESPN.com articles). I even created a little custom icon for it and uploaded that image with the other icons.

That is the next thing I was going to ask about. I don’t need any additional buttons right now, but might later.

I see this in the config file:

// Add the new custom buttons
teButtons.push(new TextileEditorButtonSeparator(''));
teButtons.push("<button id=\"ed_link\"><img ></button>");
teButtons.push("<button id=\"ed_email\"><img ></button>");
teButtons.push("<button id=\"ed_help\"><img ></button>");

Like I said, I’m basically less than a noob with javascript so I’m wondering if this is a starting template for creating a button? If so, what all do I need to change in that code to generate a new button and get it to do what I want?

EDIT: Ok, so the code I pasted above didn’t turn out like it looks in the actual config file. Hopefully someone will get the gist of what I’m asking.

 Signature 

Deron Sizemore
==========
Random Jabber | Sizcons | NiceStylesheet | Kentucky Golfing | LogoGala
Twitter: Deron Sizemore | LogoGala

Profile
 
 
Posted: 27 August 2008 11:52 AM   [ Ignore ]   [ # 90 ]  
Lab Assistant
Avatar
RankRank
Total Posts:  118
Joined  12-29-2004

Yes, but those are custom buttons I added which are a bit more complex in that they have specific callback functions to create the link dialogs, etc.

If you’re just looking to add your own “regular” textile formatting buttons, it’s much easier. In that case you could use the last commented line in the default buttons as a basis for your new button:

//teButtons.push(new TextileEditorButton('[id]', '[image.png]', '[open]', '[close]', '[accesskey]', '[Title]', '[simple or extended]'));

So quick example - if you wanted to add a code button you could do something like:

teButtons.push(new TextileEditorButton('ed_code', 'code.png', '@', '@', 'c', 'Code'));

...and of course add the icon to the teh/images folder

edit/add: and if you do the icons are of course the ever-popular famfam silk icons

 Signature 

imagehat studio
the forum user formerly known as lavalamp

Profile
 
 
   
5 of 7
5
 
Post Marker Legend
New Topic New posts Hot Topic Hot Topic with new posts New Poll New Poll Moved Topic Moved Topic Sticky Topic Sticky topic
Old Topic No new posts Hot Old Topic Hot Topic with no new posts Old Poll Old Poll Closed Topic Closed Topic Announcement Announcements
Theme
Change Theme
Visitor Statistics
The most visitors ever was 1149, on July 16, 2007 09:33 AM
Total Registered Members: 65026 Total Logged-in Users: 39
Total Topics: 82116 Total Anonymous Users: 17
Total Replies: 441307 Total Guests: 195
Total Posts: 523423    
Members ( View Memberlist )
Newest Members:  meenoiYang.JianuoioitsukiNathan HammondalexcigadamstaneckiLucas Mayscybermilltstitt