You guys and gals have been so great. I have another one for you.
The site I am developing in MODx is an online catalog-lite. There is no real e-commerce to the site. There is just a catalog of items the client sends me. Before getting in to the Ditto calls to have the categories update themselves, I need to get the single item Template straight.
I have attached an image of just the body of my single item page. I’ve already made a [*content*] TV for the item information at the top.
What I am having some issues with are the TVs for the 4 to 6 images of each item. I’d like to be able to streamline the inputting of new items as much as possible. I see the creation of each Resource like this:
1. Input item description in to [*content*] field.
2. Upload each of the 4 to 6 images.
Is it possible to have the TV for the Image automatically resize the picture and to insert an ALT tag based on the title of the Resource?
I’ve been tooling around in my test area with this, but I want to do this the right way from the beginning. Any insights would be great.
Thanks in advance!
Is it possible to have the TV for the Image automatically resize the picture and to insert an ALT tag based on the title of the Resource?
1. You could use:
http://modxcms.com/extras/package/341 |
http://modxcms.com/forums/index.php/topic,16002.0.html //Think you need
PHx to be installed
Also check out MaxiGallery and DirectResize plugin...
2. <...alt="[*pagetitle*]"> or [*
variable-name*]
I’d like to use alt={*pagetitle*}, but doesn’t the Image variant of the TV supply the entire img src="" tag? Start and finish tags?
This is not a valid MODx tag --> {* *}
!!
Use in
MODx096x/EVO ---> [*VariableName*] OR in
Revolution ---> [[*VariableName]]
//you probably know this but to be clear for others.
If you use the Image "widget" you can put [*DocumentVariable*] for "Alternate Text" when seting up the TV!
Of course, of course. Just a typo.
I’ll try that. Thanks.
-
☆ A M B ☆
- 24,524 Posts
If you use the Image "widget" you can put [*DocumentVariable*] for "Alternate Text" when seting up the TV!
Now that is nice to know! I’ve often avoided using the widget because of not knowing. Now if the widget only offered a "Title" field so there would be a tooltip on hover (great for using little icons to indicate what kind of download a link is for, such as .pdf or .doc)
[blond alert - you can add it in the Attributes field of the widget!]
Just how long have I been using MODx?
I just wanted to follow up and say thanks to both of you. Between both of your comments, I was able to figure out exactly what I wanted to do wit this. Thanks again!
A new issue with this particular TV.
Now that the size (400x300px) is tied to the TV. When I make my Ditto call, the image is tied to that size. I cannot resize it on the Gallery page. It remains 400x300px.
Is there a way to override the size of the TV? Or is there a way to make the size of the TV tied to the page it is on, i.e. 400x300 on the initial page, smaller on the Gallery page (more likely the solution)?
I’ve attached screen shots of the Single Item page where the image is 400x300, the Gallery page where it needs to be smaller (260x195) and finally how I resize the TV using the Attributes field.
Any help is greatly appreciated. Thank you.
Wow!!

You just teached me something I should have known -->
http://modxcms.com/forums/index.php/topic,39359.msg237861.html#msg237861
"Just how long have I been using MODx?"
The easist way of changing the size of your image TV is to NOT using the image widget (leave blank)
and instead get your TV like this <img src="[*yourTV*]" width... >
But it’s PHP Thumbs you want.