Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#385 2011-04-06 14:01:56
Re: [plugin] [ORPHAN] upm_image: More powerful image display
photonomad wrote:
Oliver, use
<txp:php></txp:php>
instead of<?php ?>
Thanks but that didn’t work, Im sure all <txp:php> is replace <?php?> ? I think its more the fact im trying to parse php inside string…
Is there a php variable or some I can use? The Full code Id like is
<txp:upm_article_image >
<img src="<txp:php> echo resize("<txp:upm_img_full_url />,array("w"=>200,"h"=>200)); </txp:php>" />
</txp:upm_article_image >
but some thing to replace <txp:upm_img_full_url />
to make it work?
Offline
#386 2011-04-06 14:11:04
Re: [plugin] [ORPHAN] upm_image: More powerful image display
oliverker
You can’t use TXP tags inside PHP. Well, not directly like that. You need to choose to either:
a) wrap the tag in a call to parse()
so it can be interpreted
or
b) call the tag directly using, for example:
<txp:php>
echo resize(upm_img_full_url(array()), array("w"=>200,"h"=>200));
</txp:php>
And, for the record, yes it does matter if you use <?php
vs <txp:php>
. By default, Textpattern does not allow the former syntax so you’ll see errors or your code will not run.
Last edited by Bloke (2011-04-06 14:11:24)
The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.
Txp Builders – finely-crafted code, design and Txp
Offline
#387 2011-04-06 14:24:15
Re: [plugin] [ORPHAN] upm_image: More powerful image display
Bloke wrote:
You can’t use TXP tags inside PHP. Well, not directly like that. You need to choose to either:
a) wrap the tag in a call toparse()
so it can be interpreted
or
b) call the tag directly using, for example:
Thanks for your help but neither of those solutions work? Sorry, Im (as you guessed) not very good at php
this is the page I’m trying to get to work http://earthymarketing.co.uk/clients/
Offline
#388 2011-04-06 14:35:58
Re: [plugin] [ORPHAN] upm_image: More powerful image display
oliverker wrote:
neither of those solutions work
They will. Once you get rid of the Syntax errors in your code. Look at the page source code and you’ll see lots of “<b>Parse error</b>: syntax error, unexpected T_STRING…” messages. Fix those and the problem will go away.
What does your code look like now?
Last edited by Bloke (2011-04-06 14:36:40)
The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.
Txp Builders – finely-crafted code, design and Txp
Offline
#389 2011-04-06 18:08:23
Re: [plugin] [ORPHAN] upm_image: More powerful image display
Bloke wrote:
What does your code look like now?
Thanks for you help Bloke, Think Ive got the script work now, but It seems like it doesn’t like the full image url? You can see from the link above that when just sending it:
<img src="<txp:php> echo resize('images/uploads/19.jpg', array("w"=>200,"h"=>200)); </txp:php>" />
then it is ok with that domain, but
<img src="<txp:php>
echo resize(upm_img_full_url(array()), array("w"=>200,"h"=>200));
</txp:php>" />
must be something in the script with the full url? Is there a way of removing the url?
Many thanks
Offline
#390 2011-08-14 18:56:53
- roelof
- Member
- Registered: 2005-03-27
- Posts: 647
Re: [plugin] [ORPHAN] upm_image: More powerful image display
Hello,
A time ago I asked how I can get multiple images next to each other with this plugin.
Some one said i have to use inline.
Now Im back from holidays and still I have questions.
I have this :
<txp:upm_image type=“image” image_id=“26” class=“image” />
Where in the css do I have to use the inline ?
Roelof
Offline
#391 2011-08-14 20:41:21
Re: [plugin] [ORPHAN] upm_image: More powerful image display
Just curious, what do people use this plugin for these days? I was under the impression that the new image tag features in Txp 4.3 negated the need for at least a few image plugins.
Offline
#392 2011-08-15 00:52:46
Re: [plugin] [ORPHAN] upm_image: More powerful image display
aswihart wrote:
Just curious, what do people use this plugin for these days? I was under the impression that the new image tag features in Txp 4.3 negated the need for at least a few image plugins.
Yes, the core tags can do everything that most of the image plugins, including upm_image, do. Users that are used to the plugin might still keep using, and existing sties and projects will keep using if they don’t want to migrate. There is no problem if you keep using the plugins even that core offers same functionality.
Offline
#393 2011-08-15 08:33:42
- roelof
- Member
- Registered: 2005-03-27
- Posts: 647
Re: [plugin] [ORPHAN] upm_image: More powerful image display
Hello,
Can anyone tell me how I can make the same thing with only using the core tags ?
I use this plugin but if I can do the same without im happy to learn.
Roelof
Offline
#394 2011-08-15 16:29:25
Re: [plugin] [ORPHAN] upm_image: More powerful image display
roelof wrote:
Can anyone tell me how I can make the same thing with only using the core tags ?
I use this plugin but if I can do the same without im happy to learn.
How are you using upm_image? Provide the output you need and someone can help.
Piwik Dashboard, Google Analytics Dashboard, Minibar, Article Image Colorpicker, Admin Datepicker, Admin Google Map, Admin Colorpicker
Offline
#395 2011-08-15 18:47:46
- masa
- Member
- From: Asturias, Spain
- Registered: 2005-11-25
- Posts: 1,091
Re: [plugin] [ORPHAN] upm_image: More powerful image display
Related question: do the core tags allow you to pull in the image caption field?
That’s what I use upm_image for.
Offline
#396 2011-08-15 23:32:35
- uli
- Moderator
- From: Cologne
- Registered: 2006-08-15
- Posts: 4,310
Re: [plugin] [ORPHAN] upm_image: More powerful image display
In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links
Offline