force image same name

6 posts by 3 authors in: Forums > CMS Builder
Last Post: October 7, 2010   (RSS)

By Maurice - April 14, 2010

Hi IT team

is there a way to force a image in a section always to have the same name even when overwriting the old image???

Greetz Maurice
-------------------------------------------

Dropmonkey.nl

Re: [Maurice] force image same name

By Jason - April 14, 2010

Hi Maurice,

No, there isn't a built in way to handle that. If you can give me an example of the situation where you would need this, we can try to find a solution.

Thanks.
---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/

Re: [Jason] force image same name

By Maurice - April 15, 2010

yes we build email templates for email browsers like outlook.

customers can add product banners at the footer and this they can change cause we don't send the image its linked to the cms but if the image name changes than the link is gone and whe have to make a new template.

but i think we are to fast with our ideas hahahaha for cmsb.
hehehehehe
-------------------------------------------

Dropmonkey.nl

Re: [nkerschgens] force image same name

By Jason - October 7, 2010

Hi,

We could certainly look into creating a custom plugin for you.

You can limit the number of files that can be uploaded to an upload field by editing that field. In this way you can guarantee that there would never be more than one image per record. Then, instead of always having to use the same name, you could create a dynamic url to your image by pulling the information directly from cms builder.
The code would look similar to this:

<?php if($record['image']): ?>
<?php $banner = $record['image'][0];?>
<img src="http://<?php echo $_SERVER['HTTP_HOST'];?><?php echo $image['urlPath'];?>" height="<?php echo $image['height'];?>" width="<?php echo $image['width'];?>" alt="<?php echo $image['info1'];?>" />
<?php endif ?>


Using a method like this, you could dynamically create a path to the image regardless of what it was called. Would this work for you?

If you're still interested in a custom plugin, please send an email to consulting@interactivetools.com with a list of requirements and we can make a quote for you.

Hope this helps.
---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/

Re: [Jason] force image same name

By nkerschgens - October 7, 2010

Hi Jason,

This wil not work for us, the HTML stationery that we create will be used in emailclients like outlook etc. The HTML file is located on the local machine of the user (for outlook: c:\program files\common files\microsoft share\stationery)

I will send the question to the emailaddress