Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#16 2009-05-29 12:52:40

progre55
Member
Registered: 2006-05-02
Posts: 668

Re: Write Tab: Reorganizing Information

redbot:

Sory for the delay in getting back to you.

Regarding the hiding of the ALT field, I tried the above code tucked into your plug in and although it returned no errors, it also did not do the desired effect. I then thought maybe the above code needs to be inserted into the original plug in, but I am uncertain where that may need to be. Any additional guidance would be appreciated.

After seeing your comment about the load order, I took a look at this page unfortunately I have been unsuccesful in getting any of the plug ins to “change” their order when adding that line of code. They all still show as 5. I am sure I am missing something easy ….

progre55

Offline

#17 2009-05-29 12:56:01

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 12,427
Website GitHub

Re: Write Tab: Reorganizing Information

progre55 wrote:

I have been unsuccesful in getting any of the plug ins to “change” their order when adding that line of code

Have you tried going to the Admin->Plugins tab, putting a check mark next to bot_show_image and then using the ‘With Selected’ tool at the bottom to change the order to 6?


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Hire Txp Builders – finely-crafted code, design and Txp

Offline

#18 2009-05-29 13:02:59

progre55
Member
Registered: 2006-05-02
Posts: 668

Re: Write Tab: Reorganizing Information

Bloke:

I go to Admin,Plugins tab, I put a check mark next to bot_show_image BUT I do not see the last past of your statement:and then using the ‘With Selected’ tool at the bottom to change the order to 6

My bad, I have to start opening my eyes. Thanks.

progre55

Last edited by progre55 (2009-05-29 13:04:51)

Offline

#19 2009-05-29 13:16:34

redbot
Plugin Author
Registered: 2006-02-14
Posts: 1,410

Re: Write Tab: Reorganizing Information

progre55 wrote:

Regarding the hiding of the ALT field, I tried the above code tucked into your plug in and although it returned no errors, it also did not do the desired effect. I then thought maybe the above code needs to be inserted into the original plug in, but I am uncertain where that may need to be. Any additional guidance would be appreciated.

Hi, I presume after you changed plugins load order it still doesn’t work?
Strange, I use this same code in more than one site and it always works. have you pasted it exactly after the other lines you added before?

Offline

#20 2009-05-29 13:46:48

progre55
Member
Registered: 2006-05-02
Posts: 668

Re: Write Tab: Reorganizing Information

redbot:

This is what I have:

echo
		'<script language="javascript" type="text/javascript">'.n.
		'	$(document).ready(function() {'.n.
'		$("#bot_article_image").insertAfter($("#override-form"));'.n.
		'	});'.n.	
		'		$( function() {
						$("#lam-pictures").load( function(){
							$(this).contents().find("input[name*=alt]").hide();
							$(this).contents().find("label[for=alt]").hide();
						});
					});'.n.	
		'</script>';	

I also changed its order to number to “6”

progre55

Offline

#21 2009-05-29 13:56:27

redbot
Plugin Author
Registered: 2006-02-14
Posts: 1,410

Re: Write Tab: Reorganizing Information

You must move down the fourth line. Try this

echo
		'<script language="javascript" type="text/javascript">'.n.
		'	$(document).ready(function() {'.n.
'		$("#bot_article_image").insertAfter($("#override-form"));'.n.
		'		$( function() {
						$("#lam-pictures").load( function(){
							$(this).contents().find("input[name*=alt]").hide();
							$(this).contents().find("label[for=alt]").hide();
						});
					});'.n.	
		'	});'.n.	
		'</script>';

Last edited by redbot (2009-05-29 13:58:09)

Offline

#22 2009-05-29 14:01:51

progre55
Member
Registered: 2006-05-02
Posts: 668

Re: Write Tab: Reorganizing Information

redbot:

That worked and I think it was my mistake originally. What I was looking at was the blank write tab and not an article that had been already cretaed. when I looked at a created article the alt was now removed.

Do you know if there is a way to remove it from the blank write tab? No big deal, but it would make the form cleaner.

Thanks for all the help.

progre55

Offline

#23 2009-05-29 14:36:04

redbot
Plugin Author
Registered: 2006-02-14
Posts: 1,410

Re: Write Tab: Reorganizing Information

It should work (and works for me) in a blank article also. Which version of bot_show_image are you running?

Offline

#24 2009-05-29 14:37:24

progre55
Member
Registered: 2006-05-02
Posts: 668

Re: Write Tab: Reorganizing Information

bot_show_image (0.4)

Offline

#25 2009-05-29 14:47:07

redbot
Plugin Author
Registered: 2006-02-14
Posts: 1,410

Re: Write Tab: Reorganizing Information

I’m sorry I have no more ideas then. It should work…
As a last desperate try you could try resetting the plugins load order to the default one (5), but I doubt this will change something.
Should I come up with a an idea I’ll post it here

Offline

#26 2009-05-29 14:48:05

progre55
Member
Registered: 2006-05-02
Posts: 668

Re: Write Tab: Reorganizing Information

No problem, I will take several cracks at it and let you know if I discover anything. as always, thank you for the assistance.

progre55

Offline

#27 2009-05-29 16:25:51

the_ghost
Plugin Author
From: Minsk, The Republic of Belarus
Registered: 2007-07-26
Posts: 907
Website

Re: Write Tab: Reorganizing Information

progre55, you should check what version of jquery is loaded. Redbot’s example will work in 1.3+ versions


Providing help in hacking ATM! Come to courses and don’t forget to bring us notebook and hammer! What for notebook? What a kind of hacker you are without notebok?

Offline

#28 2009-05-29 17:33:08

redbot
Plugin Author
Registered: 2006-02-14
Posts: 1,410

Re: Write Tab: Reorganizing Information

the_ghost wrote:

progre55, you should check what version of jquery is loaded. Redbot’s example will work in 1.3+ versions

I also thought it could have to do with jquery version but actually I’m using 2.6 and it works.

Last edited by redbot (2009-05-29 17:33:36)

Offline

#29 2009-05-29 19:22:01

progre55
Member
Registered: 2006-05-02
Posts: 668

Re: Write Tab: Reorganizing Information

Guys I will test further. Like I mentioned, it works fine on articles that have been saved, it is only on new articles where the alt field is still displayed.

I will let you know. Thanks for the assistance.

progre55

Offline

#30 2009-05-29 22:12:07

redbot
Plugin Author
Registered: 2006-02-14
Posts: 1,410

Re: Write Tab: Reorganizing Information

Oops! You are right. The mistake was mine as I told you to modify the bot_show_image plugin (which of course executes only when an article actually exists).
I was trying to let you save time and efforts by modifying this plugin instead of creting a new one but I was terribly wrong.
If you can wait till tomorrow I’ll post a ready-made simple plugin which does what you want (and this time it must work).

Offline

Board footer

Powered by FluxBB