position graphic after menu text
- Derek Fielding
- Super Advanced
- Posts: 30
- Joined: Thu Jan 15, 2004 12:20 pm
- Location: UK
position graphic after menu text
I want to put a small grahic AFTER my menu text.
Using the following I can position the image before the text
aI("text= menu text here;image=gif/info.gif;url=http://www.my_link.com;;separatorsize=0")
How do I position the graphic AFTER the munu text?
I seem to remember that this was possible on Ver 3
Derek Fielding
Using the following I can position the image before the text
aI("text= menu text here;image=gif/info.gif;url=http://www.my_link.com;;separatorsize=0")
How do I position the graphic AFTER the munu text?
I seem to remember that this was possible on Ver 3
Derek Fielding
Try this...
Notice I removed an extra ; (you had ;;), and added 2 towards the end of the aI for proper syntax.
Code: Select all
aI("text=menu text here;image=gif/info.gif;url=http://www.my_link.com/;separatorsize=0;imagealign=right;");
John
- Derek Fielding
- Super Advanced
- Posts: 30
- Joined: Thu Jan 15, 2004 12:20 pm
- Location: UK
To get an image after the text you have to put in the image html tag, ie.
"text=whatever<img src=http://whateverpath/whatever image and so on.
Ruth
"text=whatever<img src=http://whateverpath/whatever image and so on.
Ruth
- Derek Fielding
- Super Advanced
- Posts: 30
- Joined: Thu Jan 15, 2004 12:20 pm
- Location: UK
Hi Ruth
I am an absolute novice with javascript code. I cannot work out how to apply your solution. The code
aI("text=menu text here;image=gif/info.gif;url=http://www.my_link.com/;separatorsize=0") work fine but puts the image to the left of the script"Menu text here"
Can you give me the detailed code to convert the line so that the image appears after the text.
Derek Fielding
I am an absolute novice with javascript code. I cannot work out how to apply your solution. The code
aI("text=menu text here;image=gif/info.gif;url=http://www.my_link.com/;separatorsize=0") work fine but puts the image to the left of the script"Menu text here"
Can you give me the detailed code to convert the line so that the image appears after the text.
Derek Fielding
This just uses a regular html img tag like you do on pages. Leave out the image= part. Immediately after the text and before the semi-colon that closes it put in the html image tag, then the semi-colon, then url and the rest of what you have in your aI.
Code: Select all
aI("text=menu text here<img src=http://www.whatever.com/usairgrd.gif border=0>;url=and so on to the end of that aI like you have it.
Derek, don't forget proper syntax at the end of your statement...
Sorry 'bout my wrong answer. It was my turn... 
Code: Select all
aI("text=menu text here<img src=http://www.whatever.com/usairgrd.gif;url=http://www.my_link.com/;border=0;separatorsize=0;");

John
- Derek Fielding
- Super Advanced
- Posts: 30
- Joined: Thu Jan 15, 2004 12:20 pm
- Location: UK
Hi Ruth,
Thanks very much for the code. (now I realize that white spaces can disable a line of code I might get somewhere !!)
I have combined the code with a Milonic tooltip and everything works OK and the graphic appears after the text as I wanted. However I need to put some spaces after the text to space off the graphic. I have tried but that breaks the code. I could mod the graphic so that it will have a space at its left but I would rather do it with code. How can I produce a space of about 5 characters ? The full code I am using is shown below and I have indicated where I need the space. The url where this is being used is
http://www.get-the-message.org.uk
and the item (Guest Book) is in the main menu.
aI("text=Guest Book space here please<img src=gif/info.gif border=0> ;url=http://www.efreeguestbooks.com/mg/multi ... on=showtip('<table width=300><tr><td><font face=arial size=2><b>Due to a misunderstanding our guest book had been limited to 10 entries.<br><br>We now know, as at April 2004, there have been over 540 unseen entries.<br><br>We apologise to anyone who has made an entry in our guest book which warranted a reply.<br><br>Our new guestbook opens in a new window - please close the new window when you wish to return to this site.<br><br><font color=red>Please sign our guestbook before you leave<br>Click now</font></b></td></tr></table>');separatorsize=0")
Thanks again - Derek
Thanks very much for the code. (now I realize that white spaces can disable a line of code I might get somewhere !!)
I have combined the code with a Milonic tooltip and everything works OK and the graphic appears after the text as I wanted. However I need to put some spaces after the text to space off the graphic. I have tried but that breaks the code. I could mod the graphic so that it will have a space at its left but I would rather do it with code. How can I produce a space of about 5 characters ? The full code I am using is shown below and I have indicated where I need the space. The url where this is being used is
http://www.get-the-message.org.uk
and the item (Guest Book) is in the main menu.
aI("text=Guest Book space here please<img src=gif/info.gif border=0> ;url=http://www.efreeguestbooks.com/mg/multi ... on=showtip('<table width=300><tr><td><font face=arial size=2><b>Due to a misunderstanding our guest book had been limited to 10 entries.<br><br>We now know, as at April 2004, there have been over 540 unseen entries.<br><br>We apologise to anyone who has made an entry in our guest book which warranted a reply.<br><br>Our new guestbook opens in a new window - please close the new window when you wish to return to this site.<br><br><font color=red>Please sign our guestbook before you leave<br>Click now</font></b></td></tr></table>');separatorsize=0")
Thanks again - Derek
Derek, you are at more than 15 versions down-level. You're running 5.0RC45, and current is 5.12 release. Much has been improved/fixed in that span. "Technically", the version you are running is no longer supported, so I would suggest you move on up.
Also, I notice you're calling part of the menu code from a different domain than the page is located on. A Milonic license typically covers one domain only.
Looking at your code I do not see the mentioned after 'Guest Book'.
You can remove the double ;; items in your aI statements.
Close your aI statements like this example...
Note the ;"); at the end of the line.
Keep extra spaces out of the aI lines...
and...
Note the ; ;separatorsize and aI (...
Your effect statement will not work as is. If you don't need it, just take it out. If you do, use overfilter and outfilter, as...
These would go in menu styles.
The above is not meant as a 'pick on Derek', but only to clean up some syntax problems.

Also, I notice you're calling part of the menu code from a different domain than the page is located on. A Milonic license typically covers one domain only.
Looking at your code I do not see the mentioned after 'Guest Book'.
You can remove the double ;; items in your aI statements.
Close your aI statements like this example...
Code: Select all
...final statement;");
Keep extra spaces out of the aI lines...
Code: Select all
aI("text=Home Page;url=index.html;onfunction=showtip('Our Home Page'); ;separatorsize=0")
Code: Select all
aI ("text=
Your effect statement will not work as is. If you don't need it, just take it out. If you do, use overfilter and outfilter, as...
Code: Select all
overfilter="Fade(duration=0.2);Alpha(opacity=90);Shadow(color='#777777', Direction=135, Strength=5)";
outfilter="randomdissolve(duration=0.3)";
The above is not meant as a 'pick on Derek', but only to clean up some syntax problems.
John
- Derek Fielding
- Super Advanced
- Posts: 30
- Joined: Thu Jan 15, 2004 12:20 pm
- Location: UK
Seems I'm getting in here late, but...
So... using an <img> tag in the text property is, as Ruth suggested, a good alternative. I'll just add that you can also set the align attribute in the <img> tag, to adjust the alignment of the image within the menu item. Like so:
Keep in mind that, when right aligning an image, it's best to place the <img> tag before the text; that way, the vertical alignment will match the text. Now, no matter how wide you make the menu item, the image should always align to at the right side of the menu item.
Hope that helps,
Kevin
I don't think it was your turn yet, John. My first thought was to try imagealign also. In fact I did try it, and it doesn't work. I think imagealign just doesn't work yet (?).John wrote:Sorry 'bout my wrong answer. It was my turn...
So... using an <img> tag in the text property is, as Ruth suggested, a good alternative. I'll just add that you can also set the align attribute in the <img> tag, to adjust the alignment of the image within the menu item. Like so:
Code: Select all
aI("text=<img src=imageName.gif border=0 align=right>Item Text;url=whatever.htm;itemwidth=150;");
Hope that helps,
Kevin
- Derek Fielding
- Super Advanced
- Posts: 30
- Joined: Thu Jan 15, 2004 12:20 pm
- Location: UK